How to find all files that are larger than 1GB on the Mac HD?

Solution 1:

You can use the -x to avoid traversing mounted drives:

-x      Prevent find from descending into directories that have a device number different than that of the file from which the descent
        began.

You command should then be

$ sudo find -x / -type f -size +1G

Regarding the fact about the missing documentation: is not missing is just not easy to find. At the end of the PRIMARIES section of the man page

All primaries which take a numeric argument allow the number to be preceded by a plus sign ("+") or a minus sign ("-"). A preceding plus sign means "more than n", a preceding minus sign means "less than n" and neither means "exactly n".

Solution 2:

This will probably come out with slightly different results than find but you could use Spotlight. This method is far faster than traversing every file on the drive using find

In a Finder window, start a Spotlight search and choose the File Size and also System files from the drop down menu. (look for the + under the search field on the top right)enter image description here

If you are looking to do this on the command line, you can use:

mdfind "kMDItemFSSize >$[1024*1024*1024]"

In a test on my machine, the Spotlight search didn't find a couple of large files that were in the trash or one or two system files (like sleepimage). It also treated packages (such as applications and some VM images) differently from find. On the upside though mdutil was nearly instant rather than taking a few minutes for the find command to trawl through my disk.

Solution 3:

This will find folders too which is useful when low in disk space and deciding what to delete.

du -h 2>/dev/null | grep "G\t"