df vs du

Booting, installing, newbie
Post Reply
Message
Author
GuestToday

df vs du

#1 Post by GuestToday »

When I run df I get:
# df -h
Filesystem Size Used Available Use% Mounted on
tmpfs 121.3M 64.3M 57.0M 53% /
/dev/hdd1 4.0G 1.6G 2.5G 39% /mnt/home
/dev/loop1 247.9M 19.2M 215.9M 8% /root
/dev/loop0 53.8M 53.8M 0 100% /.usr_cram
/dev/loop3 42.3M 42.3M 0 100% /.usr_devx
/dev/loop4 102.9M 102.9M 0 100% /.usr_more
none 446.9M 218.2M 215.9M 50% /usr

When I run du from /mnt/home I get:
# du -h
664K ./awlh3025_v6_0_5_30_xp
720M .

Why is /mnt/home "used" per df 1.6G and per du 720M?

Thanks!

User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

#2 Post by MU »

On my machine Idon't get these differences (XP, ntfs).

Maybe some files on c: are compressed, and this leads to wrong results?
Just a wild guess...
Mark

GuestToday

df vs du

#3 Post by GuestToday »

Thanks Mark!
Yes, home directory has pup001, usr_cram, usr_devx, and usr_more...

GuestToo
Puppy Master
Posts: 4083
Joined: Wed 04 May 2005, 18:11

#4 Post by GuestToo »

# cd /mnt/home
# pwd
/mnt/home
# du -h
4.9G .
# df -h
/dev/hda1 5.0G 4.9G 138.4M 97% /mnt/home

i also have compressed files in /mnt/home

# ls /mnt/home/usr*fs
/mnt/home/usr_cram.fs /mnt/home/usr_devx.sfs

which version of Puppy are you using?

User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

#5 Post by MU »

puppy 106.

But I don't mean compressed files likeusr_cram.fs, but the NTFS-compression.

NTFs can compress whole folders or single files.
They still have the same name like"boot.ini" (they are not "zipped").
This is a"internal" filesystem-compression.

You can set that up somewhere in the Options of XP.

It is this compression I think of, that might confuse external tools like the Linix-"du" or "df".

Mark

GuestToday

#6 Post by GuestToday »

I'm using 1.0.7a
Home directory is hdd1 formated vfat (fat32) with following contents:
# ls -al
drwxr-xr-x 3 root root 4096 Jan 1 1970 .
drwxr-xr-x 21 root root 420 Jun 2 2005 ..
drwxr-xr-x 2 root root 4096 Jul 7 20:58 awlh3025_v6_0_5_30_xp
-rwxr-xr-x 1 root root 6807361 Dec 9 00:01 image.gz
-rwxr-xr-x 1 root root 268435456 Dec 15 19:38 pup001
-rwxr-xr-x 1 root root 268435456 Oct 20 05:21 puppy.swp
-rwxr-xr-x 1 root root 33 Nov 9 22:35 radiosleep
-rwxr-xr-x 1 root root 240 Dec 1 13:27 rc.local.bkup
-rwxr-xr-x 1 root root 56348672 Dec 9 00:01 usr_cram.fs
-rwxr-xr-x 1 root root 44322816 Dec 16 05:38 usr_devx.sfs
-rwxr-xr-x 1 root root 107921408 Nov 11 20:47 usr_more.sfs
-rwxr-xr-x 1 root root 1047639 Dec 9 00:01 vmlinuz

awl* directory is wireless drivers:
# ls -al
drwxr-xr-x 2 root root 4096 Jul 7 20:58 .
drwxr-xr-x 3 root root 4096 Jan 1 1970 ..
-rwxr-xr-x 1 root root 76568 Apr 4 2004 Fw1130.bin
-rwxr-xr-x 1 root root 83320 Apr 4 2004 FwRad16.bin
-rwxr-xr-x 1 root root 84912 Apr 4 2004 FwRad17.bin
-rwxr-xr-x 1 root root 7204 Apr 4 2004 radio16.bin
-rwxr-xr-x 1 root root 8952 Apr 4 2004 radio17.bin
-rwxr-xr-x 1 root root 0 Sep 16 2003 tnet1130.cat
-rwxr-xr-x 1 root root 13854 Jul 2 2004 tnet1130.inf
-rwxr-xr-x 1 root root 386688 Jun 18 2004 tnet1130.sys

don't spend any cycles on this...was just curious...Thanks!

Post Reply