bug-coreutils
[Top][All Lists]
Advanced

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

AW: df: Wrong Gigabyte-Output


From: Matzwelt.info
Subject: AW: df: Wrong Gigabyte-Output
Date: Fri, 2 Sep 2005 22:35:32 +0200

OK, what i have to do to get in 1 GB output und df -h. I test with 1026MB
(1.1 GB), 1018MB (1018MB), 996MB (996MB). Why i can´t get an output of 1.0GB
with these MB?

sh-2.05b# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/hda3            1004M  472M  523M  48% /

sh-2.05b# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/hda3             996M  472M  515M  48% /

sh-2.05b# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/hda3            1018M  472M  536M  47% / 

##########

Here are some more tests with the goal to make 1.0 GB Partition

server:/# clear
server:/# df -h
Dateisystem          Größe Benut  Verf Ben% Eingehängt auf
/dev/hda3            1018M  472M  536M  47% /
tmpfs                 504M     0  504M   0% /dev/shm
/dev/hda1              54M  8,0M   45M  16% /boot
/dev/hda5             958M   17M  893M   2% /mnt/1
/dev/hda6             1,1G   33M  943M   4% /mnt/2
/dev/hda7             942M   17M  879M   2% /mnt/3
/dev/hda8             1,1G   33M  958M   4% /mnt/4
/dev/hda9             912M   17M  849M   2% /mnt/5
/dev/hda10            857M   17M  798M   2% /mnt/6
server:/# df -m
Dateisystem          1M-Blöcke   Benutzt Verfügbar Ben% Eingehängt auf
/dev/hda3                 1018       472       536  47% /
tmpfs                      504         0       504   0% /dev/shm
/dev/hda1                   54         8        45  16% /boot
/dev/hda5                  958        17       893   2% /mnt/1
/dev/hda6                 1027        33       943   4% /mnt/2
/dev/hda7                  942        17       879   2% /mnt/3
/dev/hda8                 1043        33       958   4% /mnt/4
/dev/hda9                  912        17       849   2% /mnt/5
/dev/hda10                 857        17       798   2% /mnt/6
server:/# df -H
Dateisystem           Größe   Benut  Verf Ben% Eingehängt auf
/dev/hda3              1,1G   495M   562M  47% /
tmpfs                  529M      0   529M   0% /dev/shm
/dev/hda1               56M   8,4M    47M  16% /boot
/dev/hda5              1,1G    17M   937M   2% /mnt/1
/dev/hda6              1,1G    34M   989M   4% /mnt/2
/dev/hda7              988M    17M   921M   2% /mnt/3
/dev/hda8              1,1G    34M   1,1G   4% /mnt/4
/dev/hda9              956M    17M   890M   2% /mnt/5
/dev/hda10             899M    17M   837M   2% /mnt/6
server:/# df
Dateisystem          1K-Blöcke   Benutzt Verfügbar Ben% Eingehängt auf
/dev/hda3              1041744    482824    548320  47% /
tmpfs                   515716         0    515716   0% /dev/shm
/dev/hda1                54416      8175     45680  16% /boot
/dev/hda5               980308     16428    914084   2% /mnt/1
/dev/hda6              1051472     32828    965232   4% /mnt/2
/dev/hda7               964500     16428    899076   2% /mnt/3
/dev/hda8              1067288     32828    980244   4% /mnt/4
/dev/hda9               932880     16428    869064   2% /mnt/5
/dev/hda10              877544     16428    816540   2% /mnt/6

-----Ursprüngliche Nachricht-----
Von: Paul Eggert [mailto:address@hidden 
Gesendet: Freitag, 2. September 2005 21:03
An: Matzwelt.info
Cc: address@hidden
Betreff: Re: df: Wrong Gigabyte-Output

"Matzwelt.info" <address@hidden> writes:

> ich saw this Problem after Dist-Upgrade (aptitude) from Debian 3.0 (woody)
> to Debian 3.1 (sarge). 3304 MB must be output 3,2(265625) GB on df -h.

I don't see a bug here.  As I understand it, you had 3,463,516,160
bytes on your partition, which is about 3303.07 MiB (one MiB == 2**20
bytes).  df always rounds up (POSIX requires this) so it rounds up the
total to 3304 MiB-blocks.  That same total is also equal to about 3.23
GiB (one GiB == 2**30 bytes), so df -h's "3,3G" is also correctly
rounded up.  Also, df -H's "3,5G" is also correctly rounded up, since
the actual value is about 3.46 GB.

Does this explain what you observed?  If not, please clarify.  Thanks.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]