0

We are constantly low on space and look for files are installed programs in /tmp on out server. I notice the following for tmp but can't find a large file in /tmp.

drwxrwxrwt.  27 root   root            170131456 Jun 25 06:06 tmp

When I run

sudo du .

the total is 201184, where is the discrepancy in size coming from?

AdminBee
  • 22,803
  • Relating https://unix.stackexchange.com/q/252238/117549 (duplicate?) – Jeff Schaller Jun 25 '20 at 13:36
  • I'm not clear what "discrepancy" you refer to. The output from du is (by default) the number of 1024-byte blocks. So that shows around 196MiB used by /tmp and all its component directories and files. The size reported by ls is just the size of the /tmp directory (namelist), and is 162MiB, so you have around 33MiB of files beneath that. A df report would tell more. The bottom line is that at one time, /tmp contained two or three million files at once (depending on the file system it belongs to). – Paul_Pedant Jun 25 '20 at 16:12

0 Answers0