yum -y install openssh openssh-server openssh-clients
sshd服务
ssh user@ip ssh -p port user@ip
服务器ssh-keygen生成id_rsa和id_rsa.pub
client的.ssh/authorized_key中保存id_rsa.pub内容即可免密登录