On Monday 11 October 2004 10:43 am, Stephen Tait wrote: > I'm having a great deal of difficulty setting up two computers to log into > one another for automated backup purposes. For the moment, I'm just trying > to get one machine to log into the other non-interactively, and since it's > over the internet I was going to use SSH. > > Generated a v2 DSA public/private keypair on host1 under > /home/sync/.ssh/sync-host1 and sync-host1.pub > SCP'd the public key over to host2 > Added the .pub to ~/.ssh/authorized_keys2 (and authorized_keys FWIW) > > Now when I try and SSH from host1 with it (please note, names have been > changed to protect the innocent);
I just went through this yesterday, and here is my recipe. On machine 1: 1. Create your public/private key (I used dsa): ssh-keygen -t dsa 2. Copy the contents of ~/.ssh/id_dsa.pub to machine 2 using ssh-copy-id: ssh-copy-id -i ~/.ssh/id_dsa.pub machine2 ssh-copy-id copies the id_dsa.pub file located in your .ssh/ to machine2 using ssh. It sets up the authorized_key file and permissions appropriately. Once it is copied over, then you should be able to ssh into machine2 from machine1 without typing in a password. John -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]