近日,在Apache2环境下部署Rails3应用时碰到此错误:
Permission denied: [某路径]/.htaccess pcfg_openfile: unable to check htaccess file, ensure it is readable
此时,在浏览器中不管是访问Rails3应用的根目录还是次级目录都会得到“403 - Forbidden”错误。查看apache2的error.log文件时会发现类似上面的信息。含具体路径的错误信息为:
Permission denied: /home/ubuntu/sites/myapp/.htaccess pcfg_openfile: unable to check htaccess file, ensure it is readable
此时,只需修改一下目录属性即可解决问题,即:
chmod +x -R /home/ubuntu/sites/myapp
Permission denied: /.htaccess pcfg_openfile: unable to check htaccess file, ensure it is readable
最新推荐文章于 2022-06-01 17:23:14 发布