Re: [PATCH][BTRFS-PROGS][V1] btrfs filesystem df

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Bart,

On Tue, Oct 9, 2012 at 11:43 AM, Bart Noordervliet
<bart@xxxxxxxxxxxxxxxx> wrote:
> Hi Goffredo,
>
> thank you very much for your work on making the btrfs filesystem df
> output that much more understandable. It is a real improvement
> already. I would however like to bring this comment from Hugo to your
> attention once again:
>
> On Wed, Oct 3, 2012 at 1:56 PM, Hugo Mills <hugo@xxxxxxxxxxxxx> wrote:
>>> $ ./btrfs filesystem df /
>>> Path: /
>>> Summary:
>>>   Disk_size:                 72.57GB
>>
>>    Also, use kB, MB, GB, TB for powers-of-ten based units, and KiB,
>> MiB, GiB, TiB for powers-of-two based units, please. I don't care
>> which you report in, but please do make the distinction. (And note
>> that it's kB with a lower case k, but KiB with an upper case K). This
>> brings us in line with the relevant ISO and IEEE standards.
>
> I strongly support this suggestion. With terabyte-disks being the norm
> and the difference between TB and TiB being 10%, we really can't
> afford ignoring the difference any longer. Contrary to Hugo, I also
> have a strong preference to change the calculations to use
> powers-of-ten. There is nothing binary about disk space; it's just a
> function of how many bits they reliably manage to cram onto a platter.
> And while the raw size of an SSD does tend to be binary, after
> reservation of the garbage-collection/spare area the effective size is
> also completely arbitrary. Any reference to powers-of-two is
> completely artificial in these areas. But if you don't want to change
> the calculation, please do change the units as Hugo requested.

I replayed in another email to Hugo about that. Basically I am not contrary
to the change, only it is unrelated to my patches. In may patches I use the
function pretty_sizes() which adds the suffix KB, MB, and this function was
here from 2008....

I am reviewing this function to change the suffix. However I noticed
that it needs
more work, because often the results are returned as:

> $ sudo btrfs fi show
> Label: 'antares-btrfs'  uuid: c0b83ac2-ded6-4b1a-a038-2d52ced11bba
>        Total devices 1 FS bytes used 20.60GB
>        devid    1 size 250.68GB used 39.79GB path /dev/vdb

Note " FS bytes used 20.60GB". To me the unit is or byte (the 2nd
word) or MB....

Regarding which unit we should use (MB or MiB), my feels is mixed. From one side
I am used to use the unit MiB, KiB; however from the other side the hard disks
are measured as GB and not GiB. For example an hard disk of 60GB
contains 60*10^9 bytes and not 60*2^30 bytes....

We could leave it configurable via a environmental variable. But this
could open
the door for a configuration file for the btrfs utility...


>
> Kind regards,
>
> Bart Noordervliet
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Filesystem Development]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux