ssh without password on Ubuntu Jaunty

Mostly lifted from here but for my own notes.

  1. On client, run
    ssh-keygen
    Do not supply a passphrase. This creates a keypair in ~/.ssh.
  2. Copy the newly created file id_rsa.pub to server.
    scp -P 22 .ssh/id_rsa.pub bob@server:~/
  3. On server, append id_rsa.pub to file ~/.ssh/authorized_hosts (or create if does not exist).
    cat id_rsa.pub >> .ssh/authorized_hosts
  4. (Important) On server, in /etc/ssh/sshd_config change "StrictModes yes" to "StrictModes no".
  5. Restart sshd.
    sudo /etc/init.d/ssh restart
  6. On client, try logging in:
    ssh -p 22 bob@server