How to understand snapshot space usage?

Hello =)

When I do

Code:
# zfs list -o space  tank3/project/sandra
NAME                  AVAIL   USED  USEDSNAP  USEDDS  USEDREFRESERV  USEDCHILD
tank3/project/sandra  35.6G  64.4G     47.6G   16.8G              0          0
I see that I have 16.8GB of data which also du would show me. If I do

Code:
# zfs list -t snapshot | grep sandra
tank3/project/sandra@lSecure5                           11.8M      -  48.3G  -
tank3/project/sandra@lSecure6                           1.26M      -  48.3G  -
tank3/project/sandra@lSecure7                           1.26M      -  48.3G  -
tank3/project/sandra@rSecure130805-183515                   0      -  35.6G  -
tank3/project/sandra@lSecure1                               0      -  35.6G  -
tank3/project/sandra@rSecure130806-070331               1.26M      -  35.6G  -
which gives me ~15MB of snapshots, but the first command showed I used 47.6GB.

How come are these numbers not the same? And how can I figure out the real (?) space each snapshot takes?

Hugs,
Sandra =)
 
Every snapshot is a Copy On Write copy of the dataset state from the time when it was made. If there are no changes in the dataset after the snapshot is made the snapshot will not take any space because all blocks of it are identical with the dataset's actual contents. When the dataset's contents change, the differences between the dataset and the snapshots are recorded as "deltas" for the blocks that have changed.

Hope this clears it up at least a bit.
 
So I suppose the delta are the ~15MB? Why is USEDSNAP then 47.6GB? Is there a way to see how much space each snapshot takes?
 
Back
Top