Ubuntu apach2,因为在路径的组件上缺少搜索权限



"因为缺少路径组件的搜索权限"这似乎是一个经常发生的问题。到目前为止,没有建议的解决方案在这里工作,所以我不得不再次问,如果我得到上述错误,我可以检查什么。

namei --modes ./index.html 
f: ./index.html
drwxr-sr-x .
-rw-r--r-- index.html

在Ubuntu 20.04

644权限可能是导致问题的原因。将它们设置为755,如果需要,重新启动Apache:

sudo chmod 755 /path/to/source
sudo service apache2 restart

这样问题就解决了。

最新更新