The FreeBSD Diary

The FreeBSD Diary (TM) Remember
I remember
[ HOME | TOPICS | INDEX | WEB RESOURCES | BOOKS | CONTRIBUTE | SEARCH | FEEDBACK | FAQ | FORUMS ]

 New Topic  |  Go to Top  |  Go to Topic  |  Search  |  Log In   Newer Topic  |  Older Topic 
 Rsync password --password-file format
Author: Geoff 
Date:   02-06-03 08:54

Hi there,

This might seem like a silly question, but what format is the password file used with the --password-file command?

I've exported RSYNC_PASSWORD=<password>, with no luck and put a plain-text password in /etc/rsync.pass, and chmod'd it to 640

then using the parameter --password-file /etc/rsync.pass
It -still- asks for the password.
(btw I am using -rsh='ssh -l <username>' to run the remote shell command... each time I run it, I get a
Password:

prompt.

Any thoughts?

-Geoff

Reply To This Message
 
 Re: Rsync password --password-file format
Author: Dan Langille 
Date:   02-06-03 11:36

From man rsync:

--password-file
This option allows you to provide a password in a file for
accessing a remote rsync server. Note that this option is only
useful when accessing a rsync server using the built in trans-
port, not when using a remote shell as the transport. The file
must not be world readable. It should contain just the password
as a single line.

So...

1 - it's plain text, a single line
2 - you should be using it when using remote shell as the tranport

I think that means it won't work with ssh. Your choice is then an ssh key with a blank/empty passphrase. Search for "authorised keys" in the article.

Mind you, I see myself using the password file and ssh as the medium, so I don't know what happened there.

Reply To This Message
 
 Re: Rsync password --password-file format
Author: Geoff 
Date:   03-06-03 06:34

Well, the file -is- plain text and -is- a single line
ie echo password > whatever-file-you want

Nevermind, I've skipped on ssh for now and am just using the rsync protocol in the daily shell script. It seems to work ok with that, without using the --password-file, and by setting the password as an environment variable (Yes, it clears the environment var directly after use, though I still know this is not as secure as it could be). Seems to work ok. I've also fixed up another problem I was havng where rsync would drop out frequently, and throw a time out error with a relatively generous time out. using the bwlimit parameter and allowing for a few kbps fixed it right up. Probably something to do with the slow response of some sort of ack in one direction or the other.

Basically on a 512k/128k ADSL connection, it would of been sending out at about 12-13k/s max. Restricting this to 9k/s allowing some k's left for other services (and perhaps something this protocol uses to acknowledge transfer? I'm not sure how it works exactly) and got rid of any time out issues that occured.

Reply To This Message
 Forum List  |  Threaded View   Newer Topic  |  Older Topic 


 Forum List  |  Need a Login? Register Here 
 User Login
 User Name:
 Password:
 Remember my login:
   
 Forgot Your Password?
Enter your email address or user name below and a new password will be sent to the email address associated with your profile.
How to get the most out of the forum

phorum.org