robocopy folder recursively retaining files and folders ownership and access permissions.
robocopy src dst /E /ZB /DCOPY:T /COPYALL /R:1 /W:1 /V /TEE /LOG:Robocopy.log
src : source dir (drive:\path or \server\share\path)
dst : destination dir (drive:\path or \server\share\path)
/E : copy subdirectories, including empty ones
/ZB : use restartable mode; if access denied use backup mode
/DCOPY:T : copy directory timestamps
/COPYALL : copy all file info (equivalent to /COPY:DATSOU). Copies the Data, Attributes, Timestamps, Owner, Permissions and Auditing info
/R:n : number of retries on failed copies: default is 1 million
/W:n : wait time between retries: default is 30 seconds
/V : produce verbose output, showing skipped files
/TEE : output to console window, as well as the log file
/LOG:file : output status to LOG file (overwrite existing log)