提示:shell
Connecting to 172.17.11.147:22...服務器
Could not connect to '172.17.11.147' (port 22): Connection failed.ssh
Type `help' to learn how to use Xshell prompt.ide
Xshell:\> spa
出現這種狀況的緣由:rest
1.服務器端防火牆關閉了22端口,沒有開啓ssh服務;server
2.沒有安裝ssh;ci
解決緣由1:使用netstat,查看是否啓動shh服務;get
開啓ssh服務:service sshd startit
關閉ssh服務: service sshd stop重啓ssh服務:servcie sshd restart
SSH服務開機自動啓動: chkconfig sshd on取消開機自啓動:chkconfig sshd off
開啓服務後,檢查服務狀態:service sshd status
解決緣由2:安裝ssh:
yum install openssh-server
服務器端防火牆封閉了22端口,