rync w/ user and pass

how can I rsync to an external server using a username and password? can i do this all in the command without adding anything to the conf file?

thanks
qwertqAsked:
Who is Participating?
 
Jan SpringerConnect With a Mentor Commented:
I would recommend using rsync over ssh.

The process to generate and put into place the publlic key is very easy and well described here:

http://linuxcrypt.net/?p=32
0
 
mzalfresCommented:
You can use option '-e "rsh -l <remote user>'. In such case, you need to set up remote '.rhosts' file, to allow rlogin without providing password from your login and machine.

Suppose, machine you are running rsync is 'source.rsync.com', your local user is 'suser' and remote machine is 'target.rsync.com' and remote user is 'ruser'.

For remote user, you need to enter line in the ~ruser/.rhosts:

source.rsync.com suser

This will allow rlogin from suser without password.

Then run rsync with -e "rsh -l ruser" and other options you need.

Another way is providing password in local file and using --password-file=<FILENAME> option.
Probably there are others :)

0
 
qwertqAuthor Commented:
there i no way to specify the password in the command with user? i was hoping not to have to edit any files like the conf.

whats the password file method?
0
 
Jan SpringerCommented:
If you use rsync over ssh and public key authentication, you do not need to provide a password if the SSH daemon on the destination server does not require it.

This also gives you protection of encrypted file transfers which rsync, by itself, does not.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.