导航

CentOS7.5 安装ssh

Posted on 2018-12-11 17:04  许爱琪  阅读(975)  评论(1编辑  收藏  举报

yum -y install openssh-clients

 

如果出现 Permissions 0644 for ‘/root/.ssh/id_rsa’ are too open. 等错误显示了,原来只要把权限降到0600就ok了
输入命令
chmod 0600 /root/.ssh/id_rsa
然后就可以密钥登陆了

 

systectl stop sshd

systemctl start sshd

#配置开机启动

cat >> /etc/rc.local << EOF
/etc/init.d/sshd start
EOF