Stuart Anderson wrote:
> On Wed, Apr 16, 2008 at 02:07:53PM -0700, Richard Elling wrote:
>   
>>>> Personally, I'd estimate using du rather than ls.
>>>>    
>>>>         
>>> They report the exact same number as far as I can tell. With the caveat
>>> that Solaris ls -s returns the number of 512-byte blocks, whereas
>>> GNU ls -s returns the number of 1024byte blocks by default.
>>>
>>>  
>>>       
>> That is file-system dependent.  Some file systems have larger blocks
>> and ls -s shows the size in blocks.  ZFS uses dynamic block sizes, but
>> you knew that already... :-)
>> -- richard
>>
>>     
>
> OK, we are now clearly exposing my ignorance, so hopefully I can learn
> something new about ZFS.
>
> What is the distinction/relationship between recordsize (which as
> I understand is a fixed quantity for each ZFS dataset) and dynamic
> block sizes?  Are blocks what are allocated for metadata, and records
> what are allocated for data, i.e., the contents of files?
>
> What does it mean that blocks are compressed for a ZFS dataset with
> "compression=off"? Is this equivalent to saying that ZFS metadata is
> always compressed?
>
> Is there any ZFS documentation that shows by example exactly how to
> interpret the the various numbers from ls, du, df, and zfs used/refernced/
> available/compressratio in the context of compression={on,off}, possibly
> also refering to both sparse and non-sparse files?
>   

ls, du, and df have fairly rigorous definitions in their respective man
pages and specifications.  But only df has an estimate of remaining
available space. More detailed descriptions of the space usage and
properties which impact it is in the ZFS Admin Guide.
http://www.opensolaris.org/os/community/zfs/docs/zfsadmin.pdf

The elephant in the room is the question of how much physical
space you have free?  That is not easy to predict, especially with
compression. You might sleep better if you can convince yourself
that you'll never really know what is down the road until you get
there :-)
 -- richard

_______________________________________________
zfs-discuss mailing list
zfs-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss

Reply via email to