gpt4 book ai didi

centos 6.3 上的 Apache2 选项索引

转载 作者:行者123 更新时间:2023-12-04 19:32:22 24 4
gpt4 key购买 nike

在新安装的 Centos 6.3 上

我从 Ubuntu 导入了虚拟主机的配置。这是配置的一部分

DocumentRoot /otherhome/test.cofares.net
ServerName test.cofares.net

<Directory "/otherhome/test.cofares.net">
allow from all
Options +Indexes
</Directory>

http://test.cofares.net 的请求我在错误日志中收到以下错误
Directory index forbidden by Options directive: /otherhome/test.cofares.net/

目录索引适用于子目录 http://test.cofares.net/test没问题

任何建议缺少什么?

相同的配置适用于 Ubuntu Server 12.04。

问候

最佳答案

尝试这个。并确保在应用后重新启动 apache:

<Directory "/otherhome/test.cofares.net">
Options +Indexes FollowSymLinks
AllowOverride all
Order Allow, Deny
Allow from All
Satisfy All
</Directory>

或许可以试试 Satisfy Any反而:
<Directory "/otherhome/test.cofares.net">
Options +Indexes FollowSymLinks
AllowOverride all
Order Allow, Deny
Allow from All
Satisfy Any
</Directory>

编辑:那些似乎不起作用?然后试试这个。注意我正在设置整个 <VirtualHost>指令并从 <Directory> 中删除引号指示:
<VirtualHost *:80>
DocumentRoot /otherhome/test.cofares.net
ServerName test.cofares.net

<Directory /otherhome/test.cofares.net>
Options Indexes FollowSymLinks
Allow from All
</Directory>

</VirtualHost>

关于centos 6.3 上的 Apache2 选项索引,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/14535487/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com