心之所愿,无事不成。 Nothing is impossible to a willing heart.
ssh-keygen -t rsa -C "your_email@example.com"
三个回车(也可以设置密码)就生成秘钥在~/.ssh/目录下
ssh-copy-id -i ~/.ssh/id_rsa.pub 用户名@IP
然后输入服务器密码就好了