• [备忘][转载]apache 403错误 You don't have permission to access on this server


    apache 403错误 You don't have permission to access on this server.

    在配置好了Apache服务器后,测试已经通过了,但是通过浏览器访问localhost时,出现403错误提示,
    Forbidden
    You don't have permission to access / on this server
    请教出现这个问题的原因是什么呢?如何解决?

    这是由于你更改了你的DocumentRoot,而更改了这个默认值后,下面还有一个值是要随着更改的。就在它下面不远的地方,有这样一段:
    #
    # This should be changed to whatever you set DocumentRoot to.
    #
    <Directory "\Your_New_DocumentRoot\">
    中括号里的内容就是你更改的新值。这样就不会出现403错误了。

    <Directory "/var/www/html1/">
    Options Indexes FollowSymLinks
    AllowOverride None
    Order allow,deny
    Allow from all
    </Directory>

    -----------------------------------------------

    http://hi.baidu.com/vking/blog/item/bc50f3d380296adfa9ec9af4.html
    apache昨天调试了一下午,都没有解决这个问题,到今天上午,仔细检查了一遍配置文件httpd.conf,找到这么一段:
    <Directory />
    Options FollowSymLinks
    AllowOverride None
    Order deny,allow
    deny from all
    Satisfy all
    </Directory>
    然后试着把deny from all中的deny改成了allow,保存后重起了apache,然后再一测试我的网页,哈哈!居然问题就出在这,访问测试网站完全正常了。

  • 相关阅读:
    recyclerView DiffUtil使用
    RecyclerView实现侧滑删除、置顶、滑动
    Android RecyclerView
    视频框架 Vitamio使用
    react native初始化项目
    react native环境搭建
    javascript Promise
    javascript 基础
    [IOS学习笔记]KVO
    [IOS学习笔记] UINavigationController Demo
  • 原文地址:https://www.cnblogs.com/szw/p/1996435.html
Copyright © 2020-2023  润新知