How to find total MB of a directory plus all subdirectories

Bruno Wolff III bruno at
Mon Mar 12 14:12:53 UTC 2007

On Sun, Mar 11, 2007 at 22:42:41 +0100,
  Nigel Henry <cave.dnb at> wrote:
> $ find /path/to/folder -type f | wc -l
> I did try ls -a, and ls -al, but both just give a subdirectory list, one with 
> a bit more info than the other.

find is probably the best solution in this case. But if you do want a
recursive directory list use the -R option. (On commands where recursion
is an option, it is usually -r or -R. Use the man command or the --help
option to get more information about the command.)

More information about the users mailing list