php环境为lnmp一键安装包,php5.6。运行项目代码显示

Warning: require(): open_basedir restriction in effect. File(/mnt/hgfs/extraproject/yoga/simplewind/等信息

解决方案

修改
/usr/local/nginx/conf/fastcgi.conf

fastcgi_param PHP_ADMIN_VALUE "open_basedir=$document_root/:/tmp/:/proc/";
 ```
此行注释,重启nginx即可。

如果再不生效,则将`open_basedir`设置为NULL

fastcgi_param PHP_ADMIN_VALUE “open_basedir=NULL”;
“`
重启nginx

如未注明,均为原创,转载请注明来自Peak Xin's Blog

No Comments »