码迷,mamicode.com
首页 > 数据库 > 详细

redhat centos apache 403 错误 Forbidden You don't have permission to access / on this server

时间:2017-11-22 15:19:57      阅读:157      评论:0      收藏:0      [点我收藏+]

标签:redhat centos apache 403 错误 forbidden you don't have permission to access / on this server

redhat centos apache 403 错误

    centos7 apache2.2.34源码包安装成功,确认进程已启动( ps -le | grep httpd) ,防火墙已关闭,但访问时报错:

Forbidden  You don‘t have permission to access / on this server

原因为:安装目录/conf/httpd.conf配置文件中

    User deamon

    Group deamon

选项没有修改,上述配置为默认配置,将其修改为

    User test(安装http的用户名)

    Group test (安装http的用户组名)

访问正常。


注:centos7 防火墙开启、关闭设置

systemctl stop firewalld.service #停止firewall,start 开启
systemctl disable firewalld.service #禁止firewall开机启动
firewall-cmd --state #查看默认防火墙状态(关闭后显示notrunning,开启后显示running)

redhat centos apache 403 错误 Forbidden You don't have permission to access / on this server

标签:redhat centos apache 403 错误 forbidden you don't have permission to access / on this server

原文地址:http://2char.blog.51cto.com/13432435/1984083

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!