How much space do snapshots use in ZFS?

I created a pool and want to create a volume. I don't know how much space snapshots will occupy. Is there any way or formula exist to compute space requirements for snapshots?


The actual meta-data of snapshots are negligible.

As a copy-on-write file system, ZFS snapshots only require space for modified data; creating a snapshot does not immediately duplicate everything. If you have a snapshot of given size, and then add or modify files summing up to 100GB, the snapshot will "cost" you 100GB.

It might even be a little bit smaller because of compression and deduplication.

  • Good point about compression/deduplication. Note that the snapshot might be anything between much smaller and much larger in that case, not only a little bit smaller. – jlliagre Mar 18 '15 at 8:33
  • For compression, there might be a slight overhead on already compressed data, yes. I don't think it should grow beyond the amount of data changed because of deduplication, or am I missing something here? Ignoring any file system overhead, but this would have existed anyway. – Jens Erat Mar 18 '15 at 8:36
  • You are right, the snapshot size cannot (significantly) exceed the zvol size, here 100GB. I was thinking in term of comparing the parent dataset used size and the snapshot used size. A 100GB zvol can use much less than 100GB and then be smaller than its snapshot if the latter is less compressed. Measuring the size used by deduplicated data is even more confusing as it exists only in one dataset but might be referred to by several ones. – jlliagre Mar 18 '15 at 9:28

A snapshot initially takes a very negligible amount of space.

Its size grows later when existing data in the snapshotted dataset is updated or deleted.

The maximum size of a snapshot is the size of the original dataset unless compression and/or deduplication is enabled in which case you might have a snapshot smaller or larger than its parent dataset.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.