Making UFS snapshots

Daniel Feenberg feenberg at
Wed Aug 17 20:33:18 GMT 2005

I notice on this list that Garance Drosehn
<> reports making
a snapshot of a 4 gigabyte filesystem in less than one second. We have a
859 gigabyte filesystem and snapshots take about 75 minutes to complete.

Once done they appear to be exactly as advertised. Since we don't yet have
any actual files on the filesystem, we anticipated snapshots would be near
instantaneous. Even if time were linear in gross filesystem size it should
still be done in a minute or so.

During this time any other activity referencing (even reads) that
filesystem is blocked. Drive activity is continuous all during the 75
minutes, but cpu usage is only a few percent. The filesystem is on 4 300
gigabyte Maxtor SATA drives with a 3ware 9500S-8 controller in raid-5 mode
and using the FreeBSD supplied driver.

Another poster suggested reducing the number of inodes. Using "tunefs
-f" to increase the average file size from 16K to 64K reduced the time to
create a snapshot to 45 minutes. The snapshot size doesn't change.

The mdconfig and mounting the memory device take only a fraction of a
second - it is only making the snapshot file that takes so long.

This is with FreeBSD 5.4 Release #0 (right off the distribution disk, no
additional software). 

Is there likely a problem with our setup, or should we give up on the plan
of nightly snapshots? Is this a product of Raid 5, 3ware, super-linearity
or to be expected?


Daniel Feenberg
National Bureau of Economic Research
feenberg isat nber dotte org

More information about the freebsd-questions mailing list