ssh_remote_without_password

2 machines, 1 called client , 1 called server , server need static ip address. client connects server by ssh without password.

 

step1: create pub_key on client, exectue on client 

  ssh-keygen -t  rsa

 

step2: copy pub_key to server, exectue on client 

  ssh-copy-id -i ~/.ssh/id_rsa.pub  fare@192.168.0.3

 

step3: login directly, exectue on client 

      ssh fare@192.168.0.3 

 

posted @ 2020-04-18 14:21  醉后不知道天在水  阅读(115)  评论(0编辑  收藏  举报