|
To generate a public key, run the program
$ ssh-keygen -t rsa
The public key will be placed at ~/.ssh/id_rsa.pub. To install your public key immediately in the remote servers' authorized_keys file invoke following command:
$ ssh-copy-id -i ~/.ssh/id_rsa.pub username@remote.host
When you don't have ssh-copy-id command in your box (Mac OS X)
Copy your public key (~/.ssh/id_rsa.pub) to the remote machine. In the remote machine:
$ cat /location/of/id_rsa.pub >> ~/.ssh/authorized_keys
|