Re: [zfs-discuss] ZFS snapshot used space question

2012-09-15 Thread Matthew Ahrens
On Thu, Aug 30, 2012 at 1:11 PM, Timothy Coalson wrote: > Is there a way to get the total amount of data referenced by a snapshot > that isn't referenced by a specified snapshot/filesystem? I think this is > what is really desired in order to locate snapshots with offending space > usage. Try

Re: [zfs-discuss] ZFS snapshot used space question

2012-08-31 Thread Timothy Coalson
I went ahead and hacked this script together, so let me elaborate. First, though, a teaser: $ ./snapspace.sh mainpool/storage SNAPSHOTOLDREFS UNIQUE UNIQUE% zfs-auto-snap_monthly-2011-11-14-18h59 34.67G 11.0G 31% zfs-auto-snap_monthly-2011-12-1

Re: [zfs-discuss] ZFS snapshot used space question

2012-08-31 Thread Truhn, Chad
>Is there a way to get the total amount of data referenced by a snapshot that >isn't referenced by a specified snapshot/filesystem? I think this is what is >really desired in order to locate >snapshots with offending space usage. The >written and written@ attributes seem to only do the rever

Re: [zfs-discuss] ZFS snapshot used space question

2012-08-30 Thread Timothy Coalson
Is there a way to get the total amount of data referenced by a snapshot that isn't referenced by a specified snapshot/filesystem? I think this is what is really desired in order to locate snapshots with offending space usage. The written and written@ attributes seem to only do the reverse. I thi

Re: [zfs-discuss] ZFS snapshot used space question

2012-08-30 Thread Richard Elling
For illumos-based distributions, there is a "written" and "written@" property that shows the amount of data writtent to each snapshot. This helps to clear the confusion over the way the "used" property is accounted. https://www.illumos.org/issues/1645 -- richard On Aug 29, 2012, at 11:12 AM,

Re: [zfs-discuss] ZFS snapshot used space question

2012-08-30 Thread Truhn, Chad
>On Wed, Aug 29, 2012 at 8:58 PM, Timothy Coalson wrote: >> As I understand it, the used space of a snapshot does not include anything >> that is in more than one snapshot. >True. It shows the amount that would be freed if you destroyed the >snapshot right away. Data held onto by more than one

Re: [zfs-discuss] ZFS snapshot used space question

2012-08-29 Thread Stefan Ring
On Wed, Aug 29, 2012 at 8:58 PM, Timothy Coalson wrote: > As I understand it, the used space of a snapshot does not include anything > that is in more than one snapshot. True. It shows the amount that would be freed if you destroyed the snapshot right away. Data held onto by more than one snapsho

Re: [zfs-discuss] ZFS snapshot used space question

2012-08-29 Thread Timothy Coalson
As I understand it, the used space of a snapshot does not include anything that is in more than one snapshot. There is a bit of a hack, using the verbose and dry run options of zfs send, that will tell you how much data must be transferred to replicate each snapshot incrementally, which should hel

[zfs-discuss] ZFS snapshot used space question

2012-08-29 Thread Truhn, Chad
All, I apologize in advance for what appears to be a question asked quite often, but I am not sure I have ever seen an answer that explains it. This may also be a bit long-winded so I apologize for that as well. I would like to know how much unique space each individual snapshot is using. I h