Linux Centos7 Apache 訪问 You don't have permission to access / on this server.
折腾了非常久,今天才找到了最正确的答案。感言真不easy。
百度出来的99%都是採集的内容。全都是错误的。
You don't have permission to access / on this server.
百度出的解决方法:
1)关闭selinux 。坑,server根本就没开启selinux
2)改动 httpd.conf 中的 allow from all!
坑,Apache都2.4+。根本就不存在 allow from all 。如今改为了 Require all granted!
3)改动 chcon -R httpd_user_content_t !坑,误人子弟。CentOS7 中根本就没这样一个上下文,由于selinux根本就没开启
4)改动 chown apache: -R /home/xxx.com/public_html。误人子弟,坑比!
这样把文件夹改了,他本来的用户却没有文件夹訪问权限了。逗比。!
。
……
百度了一个多小时,全都是这种解决方法。出来的网页全都是一大堆广告。
中国的最大搜索引擎搜索出来的都是那种布满广告的採集站!採集站不要紧,关键是全都是广告,连正常的阅读都无法阅读!
最后正确的解决方法:
chmod o+x /home/google.com
上一级文件夹的其它用户组也必须加上 x 运行权限否则Apache无法读取!
写到最后,感谢segmentfault 社区的热心人,不然真的瞎折腾几天可能又要放弃了。
牢骚一下,网上用百度搜索出来的东西根本就不准确!用不了Google,goagent总是断断续续。并且对英文不熟悉。瞎折腾的时候感觉自己就像chaoxian。落后可是自我感觉良好,非常多人用百度还认为自豪爱国。(by default.fu@foxmail.com)
Linux Centos7 Apache 訪问 You don't have permission to access / on this server.的更多相关文章
- CentOS出错You don't have permission to access on this server
检查http.conf发现没错之后.查找资料后发现时selinux的问题,所以须要关闭这个服务: 1 vi /etc/sysconfig/selinux 2 SELINUX=enforcing 改为 ...
- mac osx下apache下的坑: you don’t have permission to access / on this server
在Mac下Apache修改默认站点的目录时,遇到403错误, you don’t have permission to access / on this server 首先按照google到教程: 修 ...
- Apache启动后出现You don't have permission to access on this server的解决办法
安装好wampserver想在浏览器打开运行php的结果,发现: You don't have permission to access on this server 解决办法是: 在Apache的根 ...
- You don't have permission to access ××× on this server.
之前开发项目一直在linux上用的xampp集成环境,前几天突然想移到window上面去. 開始在window上安装了一个集成环境(名字大概是 Uniform Service),把项目文件已过去, o ...
- 问题解决:Apache: You don't have permission to access / on this server
虚拟主机(Virtual Host)是指在一个机器上运行多个网络站点 (比如:www.company1.com和www.company2.com). 如果每个网络站点拥有不同的IP地址,则虚拟主机可以 ...
- (转) 问题解决:Apache: You don't have permission to access / on this server
问题解决:Apache: You don't have permission to access / on this server 转自:http://blog.csdn.net/crazyboy20 ...
- apache出现You don't have permission to access / on this server. 提示
今天在新的linux上跑原来的代码,使用的虚拟主机的模式进行操作.几个相关的网站放在一个文件里,想法是通过网站列出的目录进行相应的网站进行操作.一切设置完成后,在浏览器中运行出现在You don't ...
- Apache提示You don't have permission to access / on this server问题解决
测试时遇到将一本地目录设置为一apache的虚拟主机,在httpd-vhosts.conf文件中进行简单设置,然后在hosts文件中将访问地址指向本地,启动apache,进行访问,却出现了You do ...
- apache出现You don’t have permission to access / on this server问题的解决
今天在部署一个系统时,在apache中新开了一个VirtualHost,然后设置了DocumentRoot,等访问时却提示“You don’t have permission to access / ...
随机推荐
- Winsock2_WSADATA
使用Winsock2进行win下网络编程的第一步是初始化Winsock.其中需要创建一个WSADATA类型的变量,这个变量用来保存Windows socket的实现信息. typedef struct ...
- jQuery radio 选中提示
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8&quo ...
- Python3.0 调用HTMLTestRunner生成的报告中不能显示用例中print函数的输出
官方原生的HTMLTestRunner.py支持python2.0版本,python3.0版本的使用需要做一些修改: Python3调用HTMLTestRunner执行用例生成测试报告中,不能正常显示 ...
- apm - 查询高级电源管理(APM) BIOS
总览 apm [ - vVmsS ] 描述 apm 读取 /proc/apm 并用人能看懂的格式输出.因为提供了首要的电池状态,这个命令在有兼容的 APM BIOS 的笔记本电脑上非常有用. apm ...
- linux中查看文件指定行的数据
http://jingyan.baidu.com/article/15622f24125872fdfdbea560.html
- jquery.form.min.js
/*! * jQuery Form Plugin * version: 3.51.0-2014.06.20 * Requires jQuery v1.5 or later * Copyright (c ...
- 「 Luogu P2657 」 windy数
# 题目大意 给出区间 $[a,b]$,求出区间中有多少数满足下列两个条件 不含有前导 $0$. 相邻两个数字之差的绝对值至少是 $2$. # 解题思路 数位 $DP$,用记忆化搜索来实现.设 $dp ...
- yii1框架,事务使用方法
Yii1框架事务操作方法如下: $transaction= Yii::app()->db->beginTransaction();//创建事务 $transaction->commi ...
- linux 命令终端提示符显示-bash-4.2#解决方法
原地址:http://blog.csdn.net/liulihui1988/article/details/52796395 终端提示符显示的是-bash-4.2# 而不是root@主机名 + 路径的 ...
- IIS 注册.NET Framework 4.0 命令
cmd执行以下命令 32位Windows:C:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_regiis.exe -i 64位Windows:C ...