一、安装ssh的步骤:
1.安装openssh-server
CentOS/Linux系统命令行输入如下命令:
yum install -y openssl openssh-server
2. 修改配置文件
用vim打开配置文件/etc/ssh/sshd_config
将上图的PermitRootLogin
,RSAAuthentication
,PubkeyAuthentication
的设置为YES文章来源:https://www.toymoban.com/news/detail-591534.html
3、启动ssh的服务
systemctl start sshd.service
4、设置开机自动启动ssh服务
systemctl enable sshd.service
5、设置文件夹~/.ssh的访问权限:
文章来源地址https://www.toymoban.com/news/detail-591534.html
到了这里,关于CentOS/Linux系统安装SSH并配置SSH登录密钥的文章就介绍完了。如果您还想了解更多内容,请在右上角搜索TOY模板网以前的文章或继续浏览下面的相关文章,希望大家以后多多支持TOY模板网!