I want to find those files which I cannot copy to another location such that I could do Rsync. I have an external HDD and my system´s HDD. The external HDD has files which my system is missing. I am thinking how to do this.
I can find those files/directories with permission denied -messages by
find / ! -perm /u+r
where some permissions are
drwx------ 1 501 root 6 Oct 22 2014 PortableCV_WebCruiter_20141022
The following command may work from commandlinefu.com, since remote data can be considered here as external HDD
rsync --rsync-path 'sudo rsync' username@source:/folder/ /local/
Rsync remote data as root using sudo If your user has sudo on the remote box, you can rsync data as root without needing to login as root. This is very helpful if the remote box does not allow root to login over SSH (which is a common security restriction).
How can you rsync files with permission denied problems between external HDD and system HDD?