SSH连接服务器:Could not connect to ‘xxx.xxx.xx.xx‘ (port 22): Connection failed.

今早连接SSH服务发现报错很诡异;
从百度上搜索了一堆信息,现在收集整理给大家一些有用的解决方案
1.重新启动CentOS 2.重启VMWare 3.防火墙问题: 解决方案: (1)查看防火墙:service iptables status (2)先关闭防火墙:/etc/init.d/iptables stop (3)打开防火墙: service iptables start 启动: systemctl start firewalld (centos7用户) 关闭: systemctl stop firewalld (centos7用户) 4.查询是否开启22端口
查询所有打开端口命令
firewall-cmd --zone=public --list-ports

永久开启22端口
firewall-cmd --zone=public --add-port=80/tcp --permane

SSH连接服务器:Could not connect to ‘xxx.xxx.xx.xx‘ (port 22): Connection failed.最先出现在Python成神之路

版权声明:
作者:congcong
链接:https://www.techfm.club/p/25540.html
来源:TechFM
文章版权归作者所有,未经允许请勿转载。

THE END
分享
二维码
< <上一篇
下一篇>>