搞了两天没搞定,为什么根目录索引不能启用目录浏览呢,而二级目录就能目录浏览。

2013-02-08 00:44:07 +08:00
 kstsca
根目录访问显示

Forbidden You don't have permission to access / on this server. Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.

而二级目录以上目录可以正常索引

索引方式

<Directory "/hd2/www/"> Options Indexes FollowSymLinks </Directory>

errer.log信息

[Fri Feb 08 00:30:17 2013] [error] [client 222.93.25.158] Directory index forbidden by Options directive: /hd2/www/xxx.net/code/
[Fri Feb 08 00:30:17 2013] [error] [client 222.93.25.158] File does not exist: /hd2/www/xxx.net/code/error

inux centos apache 配置
2815 次点击
所在节点    Linux
3 条回复
cjou
2013-02-08 03:02:01 +08:00
首先检查一下www这个目录的权限
kstsca
2013-02-08 08:31:47 +08:00
www权限 没问题肯定
因为我在做过子目录 也报这样错误。
kstsca
2013-02-08 09:09:21 +08:00
搞定了 apache 配置文件不止一个httpd.conf
还有ssl.conf welcome.conf

这是一个专为移动设备优化的页面(即为了让你能够在 Google 搜索结果里秒开这个页面),如果你希望参与 V2EX 社区的讨论,你可以继续到 V2EX 上打开本讨论主题的完整版本。

https://www.v2ex.com/t/60066

V2EX 是创意工作者们的社区,是一个分享自己正在做的有趣事物、交流想法,可以遇见新朋友甚至新机会的地方。

V2EX is a community of developers, designers and creative people.

© 2021 V2EX