转自:http://www.bcoder.cn/17251.htmlhtml
我和不少人同样都是linux菜鸟,可是呢又对此非常感兴趣,不折腾就是不爽;linux
我下载了centos 6.4安装好在VMware 虚拟机后一切正常;centos
因而我在本机安装下载Putty来链接虚拟机中的centos系统ssh
结果提示:Network error:Connection refused 错误code
意思是:链接被拒绝server
这里顺便给你们提供一个putty中文版下载htm
地址:http://www.5yun.org/148.html教程
ping了一下虚拟机ip,能正常平通ip
进入Centos终端输入 #ssh localhostget
若是提示:ssh: connect to host localhost port 22: Connection refused 错误
不用管它,没有启动sshd服务的缘故
安装sshd命令: #yum install openssh-server
安装好后开启: #/etc/init.d/sshd start
万一此时仍是链接不上去,关闭防火墙或者开放22端口便可
关闭防火墙命令:# /etc/init.d/iptables stop
大功告成,此时window 7 已经能够正经常使用putty访问 虚拟机centos了
小提示:
以上命令操做必须在root权限下进行,否则会操做失败;
切换选择root权限教程请看 http://www.5yun.org/138.html 详细介绍