Just to make sure: You can only use cp and find? Using
mkdir is out of the question?
If mkdir can be used, have a look at this:
Code:
find / -type d ! \( -name "mnt" -prune -o -name "mmc" -prune \) -exec mkdir -p "/new_location/"{} \;
The search starts at the root directory (/),
The
-type d only targets directories,
The
! \( -name "mnt" -prune -o -name "mmc" -prune \) excludes directories named mnt and mmc (including sub-directories),
The
-exec mkdir -p "/new_location/"{} \; creates the found directories in the /new_location/ directory.
To test what is found: Remove the
brown part.