itxb

问题现象:

  1. Nginx服务已启动
  2. 80端口被nginx监听
  3. 宿主和linux虚机可相互ping通
  4. Linux虚机可用curl访问网站
  5. 宿主无法用浏览器访问网站

 

排查:

1.  查看nginx的access.log发现没有请求进来

由此可判断是防火墙给挡住了

2. 检查iptables状态,发现iptables没有启动(其实是没有安装)

3. 百度后发现centos默认用firewall做为防火墙不是iptables, 于是用

systemctl stop firewalld.service

停止防火墙

4. 重新访问网站,成功!

相关文章:

  • 2022-01-03
  • 2022-01-18
  • 2022-12-23
  • 2021-09-27
  • 2021-09-27
  • 2021-09-27
  • 2021-10-08
  • 2022-02-28
猜你喜欢
  • 2021-09-27
  • 2021-05-07
  • 2021-07-27
  • 2021-11-10
  • 2021-08-28
  • 2021-10-07
  • 2021-11-01
相关资源
相似解决方案