V adresáři uživatele (třeba root)
local$ cd root
local$ rm -rf .ssh
local$ mkdir .ssh
Create now the public and private keys for our local host
local$ ssh-keygen -t rsa -f .ssh/id_rsa -C „localusername@localaddress“
the switch -C add the “localusername@localaddress” comment in the key content (ale nemusí být).
This command will ask for a passphrase, for simplicity leave it blank (press enter).
Now transfer the .ssh/id_rsa.pub file into the ssh folder on your remote host, maybe through scp, ftp or whatever.
Přihlašte se na vzdálený stroj (např. SYNOLOGY)
remote$ cd /root
remote$ mkdir .ssh
remote$ touch .ssh/authorized_keys
remote$ cat .ssh/id_rsa.pub >> .ssh/authorized_keys
remote$ chmod 644 .ssh/authorized_keys
remote$ chmod 700 .ssh
remote$ exit
Převzato z –
http://www.cesareriva.com/ssh-without-password/