Work often use Linux to deploy application service, dealing with the log file is too large, the most common is playing a full server log file affect server performance, in the past we need to manually check the possible directory cleaned large files at the same time, this article is to introduce how to quickly search system of document method, improve the efficiency of your work

find

Find / -type f-size + 10240K # find / -type f-size + 10240KCopy the code

du

# check the current directory file size, reverse output in the top ten du - sh * | sort - rh | head - 10Copy the code

For details, you can find the Linux du command.