登入遠端 ssh 不用打密碼二步驟

登入遠端 ssh 不用打密碼二步驟

先在本機做 key

ssh-keygen -t rsa

 

將做好的 key 傳到遠端,此次會輸入密碼
cat .ssh/id_rsa.pub | ssh usename@remote.ip 'cat >> .ssh/authorized_keys'

 

登入時即可不必打密碼
ssh remote.ip

 

完成!

Related Posts Plugin for WordPress, Blogger...

Leave a Reply