Pergunta

looking to use rsync to transfer directory from remote to local recursivly with a dry-run. So far from rync man pages I settle on this:

rsync -rnvh user@server.com:/directory /local_directory/

and I get this

rsync error: remote command not found (code 127)

do I have to use this:

scp -rv user@server.com:/directory /local_directory/

(Which works perfectly fine for my one-time limited case) I'd rather get rsync running.

I've tried installing rsync on server without success. My access is quite limited on the remote server.

Foi útil?

Solução

You don't need the -e ssh (unless you're using a really really ancient version of rsync) - ssh is the default.

For dry run:

rsync -avn user@server.com:/directory/ /local_directory/

For actual sync:

rsync -av user@server.com:/directory/ /local_directory/

Also note the trailing /s - otherwise you can end up with /local_directory/local_directory etc.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top