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 ...
随机推荐
- Python函数中参数* 和 ** 的区别
* 函数接收参数为元组 例如 def myfun(*args): #相当于 def myfun(1,2,3) ==> args 就相当于(1,2,3) for a in args: pri ...
- JAXB - Annotations, Annotations for the Schema: XmlSchema
This annotation can only be used with a package. It defines parameters that are derived from the xsd ...
- ASP防止盗链的一段代码
<%@Language="vbscript"%> <% Response.Buffer = true Response.Expires = -1441 ' var ...
- java多线程总结二:后台线程(守护线程)
所谓的后台线程,是指在程序运行的时候在后台提供一种通用服务的线程,并且这种线程并不属于程序中不可或缺的部分.因此当所有的非后台线程结束时,程序也就终止了,同时会杀死所有后台线程.反过来说,只要有任何非 ...
- 02线性表链式存储_LinkList--(线性表)
#include "stdio.h" #include "string.h" #include "ctype.h" #include &qu ...
- Server Error The server encountered an error and could not complete your request. 新建站点模版失败
500 Server Error Error: Server Error The server encountered an error and could not complete your req ...
- Java实战之03Spring-02Spring的核心之IoC
二.Spring的核心之IoC(Inversion of Control 控制反转) 1.IoC是什么? 回顾:连接池原理中的使用. 注意:我们在连接池原理中是使用构造函数注入的,当然还可以通过提供s ...
- 阅读 Linux 内核源码
阅读Linux Kernel Source Code 假如你在Linux系统下面阅读Linux内核源代码,那么需要准备一些工具. ①Linux的内核源码 内核源码的下载地址:Index of /pub ...
- NOIP201501&&02
NOIP201501金币 试题描述 国王将金币作为工资,发放给忠诚的骑士.第一天,骑士收到一枚金币:之后两天(第二天和第三天) ,每天收到两枚金币:之后三天(第四.五.六天) ,每天收到三枚金币:之后 ...
- OpenJudge/Poj 1915 Knight Moves
1.链接地址: http://bailian.openjudge.cn/practice/1915 http://poj.org/problem?id=1915 2.题目: 总Time Limit: ...