Linux - Find - Find Empty Files

find ./ -type f -size 0

or

find ./ -type f -empty

This commands will find all zero size files in the current directory with sub-directories and then print the full pathname for each file to the screen.


Find and then delete all zero size files

To find and then delete all zero size files, there are variants you can use:

find ./ -type f -size 0 -exec rm -f {} \;
 
find ./ -type f -size 0 | xargs rm -f
 
find ./ -type f -size 0 -delete

NOTE: The -delete option is the best choice when it is supported by the find you are using.

It avoids the overhead of executing the rm command by doing the unlink() call inside find().