cetos7 配置ssh

1.找到了 /etc/ssh/ 目录下的sshd服务配置文件 sshd_config,用Vim编辑器打开

将文件中,关于监听端口、监听地址前的 # 号去除
cetos7 配置ssh
开启允许远程登录
cetos7 配置ssh

开启使用用户名密码来作为连接验证
cetos7 配置ssh

开启 sshd 服务,输入 sudo service sshd start

检查 sshd 服务是否已经开启,输入ps -e | grep sshd

将 sshd 服务添加至自启动列表中,输入systemctl enable sshd.service

可以通过输入systemctl list-unit-files | grep sshd,查看是否开启了sshd 服务自启动