thinkPHP5配置nginx环境无法打开(require():open_basedirrestrictionineffect.File(/mnt/hgfs/ro

 thinkphp5报错(2018-07-19 22:05:27)
  分类: linux

php报错

PHP Warning:  require(): open_basedir restriction in effect. File(/home/wwwroot/xxx.com/vendor/autoload.php) is not within the allowed path(s): (/home/wwwroot/xxx.com/public/:/tmp/:/proc/) in /home/wwwroot/xxx.com/public/index.php on line 24

Jul 19 21:55:04 localhost : PHP Warning:  require(/home/wwwroot/xxx.com/vendor/autoload.php): failed to open stream: Operation not permitted in /home/wwwroot/xxx.com/public/index.php on line 24

Jul 19 21:55:04 localhost : PHP Fatal error:  require(): Failed opening required '/home/wwwroot/xxx.com/public/../vendor/autoload.php' (include_path='.:/usr/local/php/lib/php') in /home/wwwroot/xxx.com/public/index.php on line 24

1,我是php7 ,php.ini里面的open_basedir 是注释掉的

2,后来查找到时fastcgi的问题

3,修改fastcgi的配置文件 /usr/local/nginx/conf/fastcgi.conf   

thinkphp5报错

重启nginx 搞定

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-06-26
  • 2022-12-23
  • 2021-12-28
  • 2022-12-23
  • 2021-11-18
猜你喜欢
  • 2021-06-22
  • 2022-01-14
  • 2022-12-23
  • 2021-08-20
  • 2021-07-04
  • 2022-12-23
  • 2021-05-15
相关资源
相似解决方案