CentOS开启SSH服务
开启ssh服务需要root权限,先使用root用户登录
检查是否安装ssh服务
rpm -qa | grep ssh
如果没有,执行命令安装
yum -y install openssh-server
启动ssh服务
service sshd start
重启ssh服务
service sshd restart
停止ssh服务
service sshd stop
ssh服务开机自启
chkconfig sshd on
ssh服务禁止开机自启
chkconfig sshd off
检查ssh服务是否开启
ps -ef | grep sshd