Nginx提示noinputfilespecified。
内容导读
互联网集市收集整理的这篇技术教程文章主要介绍了Nginx提示noinputfilespecified。,小编现在分享给大家,供广大互联网技能从业者学习和参考。文章包含2688字,纯文字阅读大概需要4分钟。
内容图文
![Nginx提示noinputfilespecified。](/upload/InfoBanner/zyjiaocheng/241/9e77998fd0084bcdb71c671ff38b018e.jpg)
server
{
listen 80;
server_name ***.****.com;
index index.php index.html index.htm;
root /home/wwwroot/default;
error_page 404 /404.html;
error_page 502 504 /502.html;
include enable-php.conf;
location / {
index index.php index.html ;
}
location /nginx_status
{
stub_status on;
access_log off;
}
location /status {
stub_status on;
access_log off;
}
location ~ .*\.(gif|jpg|jpeg|png|bmp|swf)$
{
# expires 30d;
}
location ~ .*\.(js|css)?$
{
# expires 12h;
}
location ~ \.php$ {
#root html;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
#fastcgi_param SCRIPT_FILENAME /mnt/wwwroot/default$fastcgi_script_name;
include fastcgi_params;
}
access_log /home/wwwlogs/access.log access;
}
其中root /home/wwwroot/default;
改成root /mnt/wwwroot/default;
提示no input file specified
。
/mnt/wwwroot/default
这个目录肯定是存在的,因为其他的配置server是可以访问的
奇怪的是设置/home/wwwroot/default
好使,设置为root /mnt/wwwroot/default;
就报错,
这两个文件夹的内容是完全一致的。
求解。
原因
找到问题的原因了,目录下有个.user.ini
文件,nginx跨目录用的,直接cp过来,这个文件没改内容还是open_basedir=/home/wwwroot/default:/tmp/:/proc/
改成open_basedir=/mnt/wwwroot/default:/tmp/:/proc/
就好使了
回复内容:
因为磁盘位置不够了要做迁移,vhost的配置文件
server
{
listen 80;
server_name ***.****.com;
index index.php index.html index.htm;
root /home/wwwroot/default;
error_page 404 /404.html;
error_page 502 504 /502.html;
include enable-php.conf;
location / {
index index.php index.html ;
}
location /nginx_status
{
stub_status on;
access_log off;
}
location /status {
stub_status on;
access_log off;
}
location ~ .*\.(gif|jpg|jpeg|png|bmp|swf)$
{
# expires 30d;
}
location ~ .*\.(js|css)?$
{
# expires 12h;
}
location ~ \.php$ {
#root html;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
#fastcgi_param SCRIPT_FILENAME /mnt/wwwroot/default$fastcgi_script_name;
include fastcgi_params;
}
access_log /home/wwwlogs/access.log access;
}
其中root /home/wwwroot/default;
改成root /mnt/wwwroot/default;
提示no input file specified
。
/mnt/wwwroot/default
这个目录肯定是存在的,因为其他的配置server是可以访问的
奇怪的是设置/home/wwwroot/default
好使,设置为root /mnt/wwwroot/default;
就报错,
这两个文件夹的内容是完全一致的。
求解。
原因
找到问题的原因了,目录下有个.user.ini
文件,nginx跨目录用的,直接cp过来,这个文件没改内容还是open_basedir=/home/wwwroot/default:/tmp/:/proc/
改成open_basedir=/mnt/wwwroot/default:/tmp/:/proc/
就好使了
set $phproot /mnt/wwwroot/default;
fastcgi_param SCRIPT_FILENAME $phproot/$fastcgi_script_name;
内容总结
以上是互联网集市为您收集整理的Nginx提示noinputfilespecified。全部内容,希望文章能够帮你解决Nginx提示noinputfilespecified。所遇到的程序开发问题。 如果觉得互联网集市技术教程内容还不错,欢迎将互联网集市网站推荐给程序员好友。
内容备注
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 gblab@vip.qq.com 举报,一经查实,本站将立刻删除。
内容手机端
扫描二维码推送至手机访问。