linux httpd启动无法访问问题
文章目录
linux(centos6.9)中成功安装httpd,成功访问前遇到两个问题:
1.启动时报:httpd: Could not reliably determine the server's fully qualified domain name
这是因为未配置serverName的原因,找到httpd.conf进入编辑,修改ServerName localhost:80,就不会报错了。
另外查看httpd安装路径,使用whereis httpd,一般是在/etc或者/var下,如图:
2.成功启动后无法访问,主要是因为Linux的防火墙拦截,用命令service iptables status查看防火墙状态,如果是开着就关闭:service iptables stop。
如下图:
解决这两个问题后可正常访问。
评论
登录后参与技术讨论,分享你的经验与见解。
登录 / 注册暂无评论