scp,ssh双机互信操作步骤
Node1:
# ssh-keygen -t rsa
# ssh-keygen -t rsa
这一步是生成密钥
# ssh-copy-id -i ~/.ssh/id_rsa.pub root@node2.xueping365.com
# ssh-copy-id -i ~/.ssh/id_rsa.pub root@node2.xueping365.com
~/.ssh/id_rsa.pub是密钥得得绝对路径,root@node2.xueping365.com是目的地址
Node2:
# ssh-keygen -t rsa
# ssh-copy-id -i ~/.ssh/id_rsa.pub root@node1.xueping365.com
Node2:
# ssh-keygen -t rsa
# ssh-copy-id -i ~/.ssh/id_rsa.pub root@node1.xueping365.com