require(): open_basedir restriction in effect. File(/www/wwwroot/xcx/zerg/thinkphp/start.php) is not within the allowed path(s): (/www/wwwroot/xcx/zerg/public/:/tmp/:/proc/) in /www/wwwroot/xcx/zerg/p
解决方法:
在如下文件增加一项(如图所示)
在如下文件增加一项(如图所示):
#php文件采用fastcgi解析并设置参数
location ~ \.php {
try_files $uri = 404;
fastcgi_index /index.php;
fastcgi_pass ********;
#加载fastcgi.conf文件中的参数
include fastcgi.conf;
#设置有权限目录,fastcgi.conf中默认设置就是站点目录$document_root,如果要改变就需要重新赋值
#phalcon举例
#fastcgi_param PHP_ADMIN_VALUE "open_basedir=/www/wwwroot/xcx/zerg/:/data/tmp/php/upload/:/proc/";
}
访问项目:
继续配置
location / {
if (!-e $request_filename) {
rewrite ^(.*)$ /index.php?s=$ last;
break;
}
}
圆满解决!!!!!!!!!!!!!!
参考文件:
http://blog.csdn.net/leiflyy/article/details/68063423
https://www.iamle.com/archives/1609.html
http://blog.csdn.net/slqgenius/article/details/52949191(主要解决参看的文件)
require(): open_basedir restriction in effect. File(/www/wwwroot/xcx/zerg/thinkphp/start.php) is not within the allowed path(s): (/www/wwwroot/xcx/zerg/public/:/tmp/:/proc/) in /www/wwwroot/xcx/zerg/p的更多相关文章
- thinkPHP5配置nginx环境无法打开(require(): open_basedir restriction in effect. File(/mnt/hgfs/root/tp5/thinkphp/start.php) is not within the allowed path(s)
今天想把玩一下tp5,结果怎么都无法访问,每次都是报500错误,我把错误提示都打开看到下面的错误 require(): open_basedir restriction in effect. File ...
- Warning: require(): open_basedir restriction in effect. File(/www/wwwroot/../thinkphp/start.php) is not within the allowed path(s):
Warning: require(): open_basedir restriction in effect. File(/www/wwwroot//../thinkphp/start.php) is ...
- require(): open_basedir restriction in effect. File
新安装的 lnmp 环境,将项目放上报 require(): open_basedir restriction in effect. File 的错误! 错误日志显示,访问脚本不在 open_base ...
- php Warning: require(): open_basedir restriction in effect File(/www/wwwroot/default/
解决方案如下: 一.找到修改fastcgi的配置文件 (/usr/local/nginx/conf/fastcgi.conf) 二.vi进行编辑(保存退出) 三.对虚拟主机配置进行重写在Nginx低版 ...
- require(): open_basedir restriction in effect. 解决方法
在linux服务器部署thinkphp5的时候PHP报了这个错误, 如下: Warning: require(): open_basedir restriction in effect. File(/ ...
- LNMP - Warning: require(): open_basedir restriction in effect错误解决方法
LNMP 1.4或更高版本如果不想用防跨目录或者修改.user.ini的防跨目录的目录还需要将 /usr/local/nginx/conf/fastcgi.conf 里面的fastcgi_param ...
- open_basedir restriction in effect. File() is not within the allowed path(s)
目前发现eaccelerator安装之后如果php.ini中设置open_basedir将导致open_basedir的一些报错(open_basedir restriction in effect. ...
- php 环境require(): open_basedir restriction in effect 错误
php 环境require(): open_basedir restriction in effect 错误 错误日志显示,访问脚本不在 open_basedir的限定目录里面 解决方法打开fastc ...
- lnmp 环境require(): open_basedir restriction in effect 错误
最近配置开发用的lnmp环境,环境配置完成后,爆500错误,查看nginx错误日志 open_basedir 将 PHP 所能打开的文件限制在指定的目录树,包括文件本身 错误日志显示,访问脚本不在 o ...
随机推荐
- 跨服务器的SQL语句如何书写
select * into 本地库名..表名 from OPENDATASOURCE( 'SQLOLEDB', 'Data ...
- 应用内打开AppStore上某个应用的下载界面--SKStoreReviewController的使用
产品设计要求是这样的: 对应的初步代码是这样的: - (void)viewDidLoad { [super viewDidLoad]; // Do any additional setup after ...
- python 网络爬虫(三)
一.网站地图爬虫 在一个简单的爬虫中,我们将使用实例网站 robots.txt 文件中发现的网站地图来下载所有网站,为了解析网站地图,我们将会使用一个简单的正则表达式,从<loc>标签中提 ...
- redis之Set(有序)类型常用方法总结
redis之Set(有序)类型常用方法总结 存--ZADD key [NX|XX] [CH] [INCR] score member [score member ...] XX: 仅仅更新存在的成员, ...
- markdown基本语法教程
标题 一级标题 二级标题 三级标题 以此类推,总共六级标题,建议在警号后面加一个空格,这是最标准的markdown语法 列表 在markdown下: 列表的显示只需要在文字前加上-.+或*即可变为无序 ...
- S7-300 符号IO域的组态 HMI变量指针化的方法以及应用,在一个IO域显示多个温度值的办法
应用工业场景 例如需要测试很多个节点的温度值的时候,需要监控的位置很多,如果HMI的画面很小, 可以使用符号IO域和变量的间接寻址 符号IO域接近于VB中的combo 控件 实现上图的界面 : 上图界 ...
- element ui表格表头顺序错乱的问题
因为在项目中两个表格共用了同一个组件, 但由于表头不完全相同, 就通过v-if来控制表头的显示隐藏,没想到造成了表头顺序的错乱, 经过多方查找资料,最后找到了解决方法: 即为每一列el-table-c ...
- Gcd&Exgcd
欧几里得算法: \[gcd(a,b)=gcd(b,a\bmod b)\] 证明: 显然(大雾) 扩展欧几里得及证明: 为解决一个形如 \[ax+by=c\] 的方程. 根据裴蜀定理,当且仅当 \[gc ...
- windows远程桌面不显示本地磁盘
\\tsclient\D 在资源管理器输入上面的内容就可以访问本地的D盘,但是前提是连接远程桌面的时候设置了可以访问本地D盘.
- django 自定义模版过滤器
自定义的模版过滤器必须要放在app中,并且该app必须在INSTALLED_APPS中进行安装.然后再在这个app下面创建一个python包叫做templatetags(这个名字是固定的,不能随意更改 ...