The default remote shell for rsync

rsync

Just curious, what is the default remote shell used by rsync when you're not using it in daemon mode? According to the man page it can be run via rsh or ssh. However nowhere in the man page does it specify how to set which one to use. So, when running it it prompts me for a password, but it doesn't seem to indicate which remote shell is being used. I know this is probably a dummy question, but I could really use some clarification. Thanks!

Best Answer

It's going to default to whatever shell you have set as default on the remote side. if your rsync line looks like this:

rsync -avz /local/file remoteuser@remote.host:/remote/file

... Then it's going to be remoteuser's default shell. Easy way to check is to cat /etc/passwd

EDIT: I answered what you asked, but not what you meant. Simple rule of thumb: If you're using two colons, you're probably using rsh. If you're using one colon, it's ssh.