1.进入root模式
2.yum install openssh-server
3.vi /etc/ssh/ssh_config
4.反注释以下两行(删掉前面的#号):
Port 22Protocol 2
*Port参数: SSH监听端口,可以根据安全需要改动.
5.开通防火墙: iptables -I INPUT -p tcp -j ACCEPT
6.如果SSH没有随开机启动,在/etc/rc.local文件中加入一行/etc/init.d/sshd start