[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[cobalt-users] RSYNC + SSH with out password
- Subject: [cobalt-users] RSYNC + SSH with out password
- From: "MAHESH PATIL" <mahesh_patil_99@xxxxxxxxxxxx>
- Date: Mon May 20 19:42:11 2002
- List-id: Mailing list for users to share thoughts on Cobalt products. <cobalt-users.list.cobalt.com>
This mail is to help of all those who might look for the soluting of using RSYNC + SSH through cronjob. To avoid the wastage of time I had.
I did it in the following method.
THIS WORKS
If you want to use ssh non-interactively, don't try and do it with stored passwords; instead, use keys. For most any ssh, I believe you should be able to go something like this, where $dst is the destination host you want to connect to. Run this as the originating
user on the originating host, and if the dst user is not the same as the originating user, set dst to dstuser@dsthost.
$ ssh-keygen
# hit enter three times, to choose the default
# target of ~/.ssh/identity for the key, and enter
# an empty passphrase twice
$ ssh $dst mkdir -p .ssh
$ ssh $dst chmod 700 .ssh
$ scp .ssh/identity.pub $dst:.ssh/authorized_keys
$ ssh $dst chmod 600 .ssh/authorized_keys
At this point you should be able to ssh $dst with no password requested.
(This metod did not work for me. So I followed the method below and it worked perfectly. Assume that this mehod worked in old version of SSH.)
If you're using the latest version of openssh, and you wish to avoid violating RSA Data Security's patent on RSA public key encryption (valid for another 3 months from today, to the day) then you can use
$ ssh-keygen -d
to generate "id_dsa" and "id_dsa.pub" rather than "identity"; then
$ copy id_dsa.pub to $dst/.ssh/authorized_keys2.Q
Thats all.
--
This email was brought to you by Hindunet Mail
http://www.hindunet.com/freemail/