I wanted to rsync and preserve owner and group permissions rsync -av -o -g ~localuser/ remoteuser@somewhere:~/ but file perms will match remoteuser. https://askubuntu.com/questions/719439/using-rsync-with-sudo-on-the-destination-machine edit /etc/sudoers on remote machine adding: ALL=NOPASSWD:/usr/bin/rsync on local machine: rsync ... --rsync-path="sudo rsync" ...