Re: missing disk space
At 02:26 PM 2/7/2006 -0500, Peter Dumpert wrote:
>The first thing I found was that df and du did not even come close to
>agreeing. Here is the most recent:
>home:~# df -h /var
>Filesystem Size Used Avail Use% Mounted on
>/dev/sda2 10G 8.8G 716M 93% /var
>home:~# du -hs /var
In addition to the dangling file handles. df and du don't really measure
the same thing. du is basically sum(ls -R dir). i.e. it reads the
directory. du reports the number of used *blocks* in the filesystem. If ur
block size is 32k then even a 1 byte file uses up 32k out of the filesystem.
du would total up the size to 1 byte, the actual file length, whereas df
would total up to 32k. If u had tens of thousands (millions?) of small
files on the partition or even larger files with small remainders it could
lead to a huge discrepancy between du and df.
REMEMBER THE WORLD TRADE CENTER ---=< WTC 911 >=--
"...ne cede malis"