首页  >  问答  >  正文

nginx php-fpm 报一个错误“open_basedir restriction in effect” 求教

lnmp一键安装包 web环境
Message: is_dir(): open_basedir restriction in effect. File(/mnt/web_site_log/www.abc.com/) is not within the allowed path(s): (/vagrant/vbee2:/tmp/:/proc/)

其中/mnt/web_site_log/www.abc.com/是日志目录,这个我已经手动建立了,所属用户和所属组已经给了www用户

不知道是哪里出了问题,在php.ini里加了 open_basedir=/vagrant/vbee2/:/tmp/:/proc/ 这一段也不行。

搞了一晚上,也没搜索到解决办法。而且还有一个问题就是验证码图标不显示,请问这是哪里的原因呢。

谢谢了

PHPzPHPz2713 天前632

全部回复(1)我来回复

  • 世界只因有你

    世界只因有你2017-05-16 17:23:45

    open_basedir限制了PHP能操作的目录,你应该把/mnt/web_site_log/www.abc.com/也加入到open_basedir中.
    open_basedir=/vagrant/vbee2/:/tmp/:/proc/:/mnt/web_site_log/www.abc.com/

    回复
    0
  • 取消回复