nginx -t "nginx: [warn] only the last index in "index" directive should be absolute in 6 "的问题解决
修改完nginx的配置文件之后,执行nginx -t命令提示"nginx: [warn] only the last index in "index" directive should be absolute in 6 "
相关代码段为:
server
{
listen ;
server_name www.web1.com;
index index.jsp index.html index.htm
access_log /export/servers/nginx/logs/www.web1.com/access.log main;
error_log /export/servers/nginx/logs/www.web1.com/error.log warn;
#chunkin on;
error_page = @my_error;
location @my_error {
#chunkin_resume;
}
root /export/data/tomcatRoot/www.web1.com/; location / {
proxy_next_upstream http_500 http_502 http_503 http_504 error timeout invalid_header;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_pass http://tomcat_web1;
expires 1d;
}
location /logs/ {
autoindex off;
deny all;
} }
发现问题没? 原来是第5行少了一个;号...
填上,解决...
nginx -t "nginx: [warn] only the last index in "index" directive should be absolute in 6 "的问题解决的更多相关文章
- nginx配置默认首页(index.htnl index.htm)全流程(包含遇到问题的解决)
需求: 自己有个域名,原来直接扔在了服务器的文件夹里(根据客服人员指导),自己玩了一遍nginx的安装部署等操作之后,域名的指向发生了改变,到了nginx成功的界面. 自己抱着极大的好奇心来配置ngi ...
- nginx报错:403 Forbidden 并且访问首页index.php是下载文件的状态
nginx报错:403 Forbidden 并且访问首页index.php是下载文件的状态,不能正常解析php 系统有其他两个站访问是正常的 看日志没有看到明显的错误 搜索了下: 答案如下: php的 ...
- Nginx配置文件nginx.conf中文详解(转)
######Nginx配置文件nginx.conf中文详解##### #定义Nginx运行的用户和用户组 user www www; #nginx进程数,建议设置为等于CPU总核心数. worker_ ...
- Nginx配置文件nginx.conf中文详解
#定义Nginx运行的用户和用户组user www www; #nginx进程数,建议设置为等于CPU总核心数.worker_processes 8; #全局错误日志定义类型,[ debug | in ...
- Nginx配置文件nginx.conf详解
#定义Nginx运行的用户和用户组 user www www; #nginx进程数,建议设置为等于CPU总核心数. worker_processes 8; #全局错误日志定义类型,[ debug | ...
- (总结)Nginx配置文件nginx.conf中文详解
#定义Nginx运行的用户和用户组 user www www; #nginx进程数,建议设置为等于CPU总核心数. worker_processes 8; #全局错误日志定义类型,[ debug | ...
- nginx配置文件nginx.conf
#定义Nginx运行的用户和用户组user www www; #nginx进程数,建议设置为等于CPU总核心数.worker_processes 8; #全局错误日志定义类型,[ debug | in ...
- Nginx配置文件nginx.conf中文详解(总结)
PS:这篇是目前最完整的Nginx配置参数中文说明.更详细的模块参数请参考:http://wiki.nginx.org/Main #定义Nginx运行的用户和用户组 ...
- (总结)Nginx配置文件nginx.conf中文详解 <转>
转自 http://www.ha97.com/5194.html #定义Nginx运行的用户和用户组user www www; #nginx进程数,建议设置为等于CPU总核心数.worker_proc ...
随机推荐
- postgresql cast转换类型
代码 CAST(aa as NUMERIC)
- 收回动态VHD的未使用空间
随着虚拟机的运行,虚拟机磁盘所占空间越来越大,而实际使用并没有那么大,考虑回收未使用部分. 收回动态VHD的未使用空间(压缩VHD) 有一种方法是ghost,两个vhd文件对拷.本文不是那个方法 本文 ...
- ubuntu lua安装
#解压 tar -xzvf lua5.2.2.tar.gz #进入lua5.2.2文件夹 cd lua5.2.2 #执行make sudo make linux #提示如下错误: #lua.c:67: ...
- css中>,+,~的用法
1.>的用法 A>B选择A的所有子元素B(只选择一代) 2.+的用法 A+B选择紧随着A的兄弟元素B 3.~的用法 A~B选择位置处于A后面的所有兄弟元素B(不包含兄弟元素的子元素)
- AOP(以MVC中的过滤器为例)
MVC里面的Filter public class AOPFilterAttribute : ActionFilterAttribute, IExceptionFilter { public void ...
- centos 端口开放及关闭
之前有讲过公司新买的服务器使用的是CentOS 5.5,部署好Tomcat之后却发现输入114.80.*.*:8080(即ip:8080)却无法显示Tomcat默认的首页.因为以前部署在Win Ser ...
- perl命令批量替换文件内容
转自:http://www.jbxue.com/article/12638.html 使用perl命令批量替换文件内容. 对linux下的文件内容进行替换,有时不用编写perl脚本,用perl命令就可 ...
- dedecms 获取文章发布时间和获取文章最后更新时间
文章发布时间:[field:senddate function=MyDate('m-d',@me)/] 文章最后更新时间:[field:pubdate function=MyDate('m-d',@m ...
- 使用 桌面的 chrome 远程调试 Android 的页面
手机浏览器是没有开发者工具的,所以调试手机网页是非常麻烦.使用 chrome 的远程调试功能可以像调试桌面端那样调试手机页面. 准备 手机端:chrome for Android, 安装谷歌浏览器 桌 ...
- iis7以上版本权限控制
IIS7.5中(仅win7,win2008 SP2,win2008 R2支持),应用程序池的运行帐号,除了指定为LocalService,LocalSystem,NetWorkService这三种基本 ...