Look at the manpage for find and then try this:
Assume the parent directory of the 00 - 0F subdirectories is called /large_directory
find /large_directory -type f -exec ls {} \;
Try this to make sure that the 'find' command is retrieving all the files you want, and NOT listing the subdirectory names.
Then try the same command with a small change, do :
find /large_directory -type f | xargs rm
This will delete all the files listed in the first find command.
You can verify that all the files were deleted by re-running the first find command.
You can verify that the directories under /large_directory still exist by typing this:
find /large_directory -type d -exec ls {} \;
This should return by showing all of your subdirectories.
Hope it helps. :-)
|