I need to set up keys for multiple server so I want to use custon name files for my keys. For example, trying to set up keys for my local NAS I do:
When I check ~/.ssh/authorized_keys on the NAS, I see my key is listed, but I still get a password prompt. I guess I need to do something special in this case?
xplorer4x4@xplorer4x4-MS-7673:~/.ssh$ ssh-keygen -t rsa
Generating public/private rsa key pair.
Enter file in which to save the key (/home/xplorer4x4/.ssh/id_rsa):wdlive
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in wdlive.
Your public key has been saved in wdlive.pub.
The key fingerprint is:
80:{EDITED}8d:ef xplorer4x4@xplorer4x4-MS-7673
The key's randomart image is:
{EDITED}
xplorer4x4@xplorer4x4-MS-7673:~/.ssh$ ssh-copy-id -i ~/.ssh/wdlive.pub root@192.168.1.160
root@192.168.1.160's password:
Now try logging into the machine, with "ssh 'root@192.168.1.160'", and check in:
~/.ssh/authorized_keys
to make sure we haven't added extra keys that you weren't expecting.
Generating public/private rsa key pair.
Enter file in which to save the key (/home/xplorer4x4/.ssh/id_rsa):wdlive
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in wdlive.
Your public key has been saved in wdlive.pub.
The key fingerprint is:
80:{EDITED}8d:ef xplorer4x4@xplorer4x4-MS-7673
The key's randomart image is:
{EDITED}
xplorer4x4@xplorer4x4-MS-7673:~/.ssh$ ssh-copy-id -i ~/.ssh/wdlive.pub root@192.168.1.160
root@192.168.1.160's password:
Now try logging into the machine, with "ssh 'root@192.168.1.160'", and check in:
~/.ssh/authorized_keys
to make sure we haven't added extra keys that you weren't expecting.
Comment