Avatar of alpha-lemming
alpha-lemming
 asked on

Huge difference between output of "du" and "df"


How full is this filesystem?
Can someone explain the discrepancy:
[root@vrc45sd ~]# mount
/dev/sda3 on / type ext3 (rw)
proc on /proc type proc (rw)
sysfs on /sys type sysfs (rw)
devpts on /dev/pts type devpts (rw,gid=5,mode=620)
/dev/sda1 on /boot type ext3 (rw)
tmpfs on /dev/shm type tmpfs (rw)
none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw)
[root@vrc45sd ~]# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/sda3              80G   51G   25G  68% /
/dev/sda1              99M   26M   69M  28% /boot
tmpfs                 754M     0  754M   0% /dev/shm
[root@vrc45sd ~]# du -scm /
22466   /
22466   total

Open in new window


Thanks!

LinuxLinux DistributionsLinux OS Dev

Avatar of undefined
Last Comment
omarfarid

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
jghelfman40

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
ericnils

I'm not sure why, but I am getting odd measurements using the -scm options as well.

Try this instead:
du -h --max-depth=0 /
SOLUTION
omarfarid

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
This is the best money I have ever spent. I cannot not tell you how many times these folks have saved my bacon. I learn so much from the contributors.
rwheeler23