省去每次登录远程主机的时候输入账号密码的麻烦,不过要求要有主机的root权限
1. ssh-keygen -t rsa(生成公钥私钥对)
2. scp /home/ddana/.ssh/id_rsa.pub root@192.168.1.225:/home/lsj/
3. cat /home/lsj/id_rsa.pub /root/.ssh/authorized_keys
1. ssh-keygen -t rsa(生成公钥私钥对)
2. scp /home/ddana/.ssh/id_rsa.pub root@192.168.1.225:/home/lsj/
3. cat /home/lsj/id_rsa.pub /root/.ssh/authorized_keys