open_basedir限制,虽然路径在PHP的配置中

时间:2014-10-04 18:56:56

标签: php nginx

我正在运行Nginx,我正在尝试安装postfixAdmin。当我尝试去setup.php时, 它说config.inc.php丢失了,虽然它存在,并且权限是正确的。

错误日志显示了这一点:

[error] 18493#0: *22 FastCGI sent in stderr: "PHP message: PHP Warning: is_file(): open_basedir restriction in effect. File(/usr/share/webapps/postfixAdmin/config.inc.php) is not within the allowed path(s): (/srv/http/:/home/:/tmp/:/usr/share/pear/:/usr/share/webapps/) in /usr/share/webapps/postfixAdmin/common.php on line 62" while reading response header from upstream

基本上说open_basedir限制我访问/usr/share/webapps/,尽管/usr/share/webapps/位于open_basedir列表中。我甚至手动添加了/usr/share/webapps/postfixAdmin,它仍然给了我同样的错误。

为什么这样做?

1 个答案:

答案 0 :(得分:1)

请注意php.ini:open_basedir不遵循任何sysmlinks。因此,如果config.ini.php通过/ etc /中的符号链接驻留,则还必须指定该目录。