Copy directory tree with access rights but without files

To copy only directory structure with access rights from current directory (./) to target directory (../test1) issue the following command:

find ./* -type d -print | cpio -pdumv ../test1


1) to supress command screen output remove '-v' option.
2) Newer ever use 'cpio' to copy files!!! (because 8Gb file size limitation, use 'pax' instead)

Last posts

  1. Force user to change password

    tags: userpassword

  2. Redirect STDERR to STDOUT and then to file

    tags: shellbash