Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Possible Duplicate:
du vs. df difference

I am running a server with Debian stable.

If I call:

df -h

this is the result I get:

Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/my-var   2.8G  2.3G  358M  87% /var

While if I call:

du -sh /var

This is the result I get:

832M    /var

How can this happen? Which one is correct? Thank you!

share|improve this question

marked as duplicate by Iain Dec 24 '12 at 13:46

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

Hello, welcome to serverfault, this question has already been here : serverfault.com/questions/57098/du-vs-df-difference –  user130370 Dec 24 '12 at 12:32
lsof | grep deleted and check whether the deleted files are still holding space and then if required, restart the service –  Soham Chakraborty Dec 24 '12 at 12:47

1 Answer 1

One quite common reason, especially on /var is that some processes keep files open that are already deleted. The system will not actually free the space until they are closed, but they are not listed anymore and therefore not seen by du.

/var keeps log files among other things and this sort of issue can easily happen there.

share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.