Search files & directories on Linux
Less than 1 minute
Search files & directories on Linux

Today we will learn how to search files and directories filtered with various parameters.
The command we use is find. Consider a few examples:
# find / -name -iname '*hta*' -size +100M -mtime +3
search:
The complete system (/)
All files or directories containing hta ('hta')
Ignoring case (-iname)
With size larger than 100MB (-size +100 M)
Files modified more than 3 days
# find / -empty
Find files and empty directories (-empty)
As a final command, the following will search the folder sizes ordered from lowest to highest:
# du -hs $(du -s * | sort -g | awk '{print $2}')