Linux server: About the invisible occupation of disk space under linux

  

One day, logging in to a server, found the following different scenarios:

:~> df -h

Filesystem Size Used Avail Use% Mounted on

/dev/cciss/c0d0p1 9.9G 1.5G 7.9G 16% /

udev 16G 164K 16G 1% /dev

/dev /cciss/c0d0p3 20G 261M 19G 2% /usr/local

/dev/cciss/c0d0p4 104G 42G 56G 43% /data

:/data # du -sh ./*

4.0K ./corefile

4.0K ./iostat.tmp

4.0K ./log_manager

4.0K ./log_manager1

16K ./lost+found

2.2G ./web

In the data directory, only 2.2G is occupied. Why do you see 42 Gs under df?

After checking, it turns out that some of the deleted processes are doing good things

#lsof | Grep delete

ttserver 30316 REG 104,4 2946659 7979020 /data/ttserver/bin/ttserver (deleted)

ttserver 30316 REG 104,4 70393 8028168 /data//tt_feeds/log/tt .log (deleted)

ttserver 30316 REG 104,4 42446163552 8028170 /data/pet50/ttserver/tt_feeds/data/tt_feeds.tch (deleted)

The process in the data directory has not stopped. Then delete the file, so that the process that has been in memory keeps running, keep writing the disk~~~

If you also find that your disk has no end, the same problem exists

Copyright © Windows knowledge All Rights Reserved