CentOS下安装、配置SSH

mac2024-08-22  66

root 登录

su

检查 ssh是否安装

rpm -qa | grep ssh

SSH服务是否正在运行

/etc/init.d/sshd status

启动ssh

service sshd start

查看是否启动22端口

netstat -antp | grep sshd

检查sshd是否在本运行级别下设置为开机启动

chkconfig --list sshd

设置本级别

chkconfig --level 2345 sshd on

设置SSH服务为开机启动

chkconfig sshd on

配置参数

vim /etc/ssh/sshd_config

最新回复(0)