On Mon, Jan 10, 2011 at 2:40 PM, fred <f...@mautadine.com> wrote:
> Hello,
>
> I'm having a weird issue with my incremental setup.
>
> Here is the filesystem as it shows up with zfs list:
>
> NAME                                USED  AVAIL  REFER  MOUNTPOINT
> Data/FS1                           771M  16.1T   116M  /Data/FS1
> Data/f...@05                     10.3G      -  1.93T  -
> Data/f...@06                     14.7G      -  1.93T  -
> Data/f...@07                            0      -  1.93T  -
>
> Everyday, i sync this filesystem remotely with : zfs send -I X Y | ssh 
> b...@blah zfs receive Z
>
> Now, i'm having hard time transferring @06 to @07. So i tried to copy the 
> stream directly on the local filesystem to find out that the size of the 
> stream was more than 50G!
>
> Anyone know why my stream is way bigger than the actual snapshot size 
> (14.7G)? I don't have this problem on my others filesystems.

I think you are confused because the idea of "actual snapshot size" is
not well defined.

The stream size for a given snapshot is approximately the space that's
"new to that snapshot", which is not readily available.  However, it
is is somewhere between the snapshot's Unique space and its Referenced
space.  The Used space for a snapshot is the same as its Unique space.
 In your case, the stream size for @07 is 50GB, which is between the
Unique space (0) and the Referenced space (1.9TB).

We can actually put some more constraints on the stream size:

1. It must be more than the Unique space
2. It must be less than the Referenced space
3. It must be more than (the Referenced space) - (the previous
snapshot's Referenced space)
4. It must be less than the filesystem's UsedBySnaps property.

For more information, see the zfs(1m) manpage:

  Native Properties
...
     used
...
         When snapshots (see the "Snapshots"  section)  are  cre‐
         ated,  their space is initially shared between the snap‐
         shot and the file system,  and  possibly  with  previous
         snapshots.  As  the  file system changes, space that was
         previously shared becomes unique to  the  snapshot,  and
         counted  in  the  snapshot’s  space  used. Additionally,
         deleting snapshots can  increase  the  amount  of  space
         unique to (and used by) other snapshots.

--matt

ps. I assume that your filesystem (Data/FS1) is a clone, since its
Used is less than the snapshots' Referenced (and even their
Unique/Used!).  The above information applies to clones same as any
other filesystem.
_______________________________________________
zfs-discuss mailing list
zfs-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss

Reply via email to