Inconsistent /tmp Sizes

Derek Broughton news at pointerstop.ca
Sat Jan 12 17:17:37 UTC 2008


I'm not sure this ever got sent, so just in case:


Kenneth Jacker wrote:

> In addition, applications that use /tmp have the obligation to release
> their *temporary* storage.  

i don't think they really do - not, at least, by any official policy, but
it's good procedure.

> I have used Unix/Linux for *decades* and 
> have never seen /tmp fill up with just the passage of time.

And even if it did, the files that did it should be visible
> 
> Something else is going on here!

It's really very simple.  If "du -s" shows an odd number, it would make
sense to stop summarizing.  In my case:

# du -sh /tmp
2.8M    /tmp
# df -h /tmp
Filesystem            Size  Used Avail Use% Mounted on
/dev/sda6             1.9G  257M  1.7G  14% /

BUT:
# du -h /tmp
...
1.3M    /tmp/kde-derek
...
2.8M    /tmp

and many others.  IE, "du -s" is reporting the size ONLY for the exact path.  
That doesn't seem right, to me, but it's clear that it isn't reporting the
real usage.  I'd trust "df".
-- 
derek





More information about the ubuntu-users mailing list