huge difference between du and df - no open file descriptors
Nils Effenberger
effenberger at work.de
Wed Jul 30 12:26:13 UTC 2014
Hi there,
du and df are showing signifcantly different values on our storage
system:
[root at zhoernchen ~]# df -h /
Filesystem Size Used Avail Capacity Mounted on
/dev/mirror/root 4.8G 4.1G 336M 93% /
[root at zhoernchen ~]# du -shx /
2.3G /
root at zhoernchen:~ # gpart show
=> 34 97696301 ada0 GPT (47G)
34 128 1 freebsd-boot (64K)
162 10485760 2 freebsd-ufs (5.0G)
10485922 10485760 3 freebsd-zfs (5.0G)
20971682 76724653 4 freebsd-zfs (37G)
=> 34 97696301 ada1 GPT (47G)
34 128 1 freebsd-boot (64K)
162 10485760 2 freebsd-ufs (5.0G)
10485922 10485760 3 freebsd-zfs (5.0G)
20971682 76724653 4 freebsd-zfs (37G)
(The zfs partitions are zil and l2arc of the zpool on HDDs)
My first thought was that this was due to open file descriptors but I
could'nt find anything relevant with fstat.
To be absolutely shure I rebooted (fortunately the system isn't
productive yet) but that didn't help either.
To enshure that I was using fstat correctly (I'm not that familiar with
FreeBSD) I created a file of ~350MB, opened it with less, deleted it
while opened, was able to find it with fstat, closed less and found the
system in following state:
root at zhoernchen:~ # du -shx /
2.2G /
root at zhoernchen:~ # df -h /
Filesystem Size Used Avail Capacity Mounted on
/dev/mirror/root 4.8G 4.5G -13M 100% /
Could someone explain this and how I get that fixed?
Thanks in advance,
Nils
--
Nils Effenberger
Junior UNIX-Administration
n at work Internet Informationssysteme GmbH Wandalenweg 5, 20097 Hamburg,
http://www.work.de E-Mail: effenberger at work.de, Tel: +49 40 2388090 -
Fax: +49 40 23880929
HR B 61 668 - Amtsgericht Hamburg, Geschaeftsfuehrer: Jan Diegelmann
More information about the freebsd-questions
mailing list