[Forum] Forskel på output fra `du -ch` og `df -h`?

From: Henrik Brix Andersen <btech1@users.sourceforge.net>
Date: Tue May 14 2002 - 19:04:05 CEST

Hej...

Hvad skyldes den store forskel på outputtet fra `du -ch` og `df -h`?
Eksempel:

[root@fungus local]# pwd
/usr/local

[root@fungus local]# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/hda3 251M 66M 172M 28% /
/dev/hda2 53M 14M 37M 27% /boot
/dev/hda8 8.7G 3.9G 4.4G 47% /home
/dev/hda10 1011M 48M 912M 5% /opt
none 188M 0 187M 0% /dev/shm
/dev/hda5 251M 8.3M 229M 4% /tmp
/dev/hda6 3.0G 1.9G 1017M 65% /usr
/dev/hda9 1011M 47M 913M 5% /usr/local
/dev/hda7 1011M 276M 684M 29% /var

(Her viser `df` at der er anvendt 47MB på /dev/hda9, altså /usr/local)

[root@fungus local]# du -hc
16k ./lost+found
3.5M ./bin
4.0k ./doc
4.0k ./etc
4.0k ./games
4.0k ./include
12k ./lib/netscape
11M ./lib/win32
92k ./lib/mplayer/vidix
96k ./lib/mplayer
12M ./lib
4.0k ./libexec
4.0k ./sbin
4.0k ./share/info
4.0k ./share/man/man1
4.0k ./share/man/man2
4.0k ./share/man/man3
4.0k ./share/man/man4
4.0k ./share/man/man5
4.0k ./share/man/man6
4.0k ./share/man/man7
4.0k ./share/man/man8
4.0k ./share/man/man9
4.0k ./share/man/mann
44k ./share/man
4.0k ./share/mplayer/font
4.0k ./share/mplayer/Skin
40k ./share/mplayer
4.0k ./share/doc
96k ./share
4.0k ./src
148k ./netscape/plugins
152k ./netscape
48k ./man/man1
52k ./man
15M .
15M total

(Her viser `du` at filerne i /usr/local fylder 15MB)

Forskellen er på hele 32MB?
Hvad skal man stole på?

Mvh
./Brix

-- 
Henrik Brix Andersen <btech1@users.sourceforge.net>
"I feel like... I feel like I could take on the World!"
                                 -- Purple Tentacle
Received on Tue May 14 19:04:05 2002

This archive was generated by hypermail 2.1.8 : Tue Jul 19 2005 - 16:03:45 CEST