Peter Halverson
2008-Jan-29 22:48 UTC
rsync man pages, rsync faqs, problem with RSYNC_PASSWORD and --password-file
Hi all, This isn't a bug, its just a lapse in the documentation. I just got a script going that repeats every 5 seconds, that uses rsync to send data from A, running Ubuntu V6.06.1, to B, running cygwin. I got stuck on the issue of preventing the password prompt from interrupting the script. The problem is that the man pages are misleading, they suggest that RSYNC_PASSWORD and --password-file are the answer. That might have been true in the past, but now they just don't work, as far as I can tell. The documentation needs to say up front that the right way to do it is to use ssh-keygen on A, to create a public key file id_dsa.pub. Then to install that key's content in a file on B, in ~/.ssh/authorized_keys. This information, in an easily found place, would save many people some time and frustration. Other than that gripe, it's great to have rsync as a stable tool. Thanks!!!! Sincerely, Peter H. -- Peter Halverson Promethean Devices halverson@prometheandevices.com 626-287-3225
Matt McCutchen
2008-Jan-30 00:53 UTC
rsync man pages, rsync faqs, problem with RSYNC_PASSWORD and --password-file
On Tue, 2008-01-29 at 09:58 -0800, Peter Halverson wrote:> The problem is that the man pages are misleading, they suggest that > RSYNC_PASSWORD and --password-file are the answer.I don't see any such suggestion in either the rsync 2.6.9 manpage or the current development one. Both make it sufficiently clear that --password-file and RSYNC_PASSWORD are for daemon passwords, not remote shell passwords: === Rsync 2.6.9 manpage: == --password-file [...] Note that this option is only useful when accessing an rsync daemon using the built in transport, not when using a remote shell as the transport. RSYNC_PASSWORD [...] Note that this does not supply a password to a shell transport such as ssh. === Current development manpage: == --password-file [...] This option allows you to provide a password in a file for accessing an rsync daemon. [...] When accessing an rsync daemon using a remote shell as the transport, this option only comes into effect after the remote shell finishes its authentication (i.e. if you have also specified a password in the daemon?s config file). RSYNC_PASSWORD [Same text as rsync 2.6.9 version.]> The documentation needs to say up front that the right way to do it is > to use ssh-keygen on A, to create a public key file id_dsa.pub. Then to > install that key's content in a file on B, in ~/.ssh/authorized_keys.IMO, such details about a particular remote shell are outside the scope of the rsync man page.> This information, in an easily found place, would save many people some > time and frustration.Since version 3.0.0pre1, rsync exits with an error message if the user tries to use --password-file when a daemon is not involved. This should help. Matt