nginx: [emerg] no events section in configuration

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了nginx: [emerg] no events section in configuration相关的知识,希望对你有一定的参考价值。

问题: nginx: [emerg] no "events" section in configuration
描述:

希望能告诉我怎么解决,不要太复杂吧。谢谢
我还想知道如果不配置,对nginx会有影响吗


解决方案1:

加如下的配置:

events {
  worker_connections  1024;  ## Default: 1024
}

不加没有啥影响,不加nginx就用默认的1024


以上是关于nginx: [emerg] no events section in configuration的主要内容,如果未能解决你的问题,请参考以下文章

nginx: [emerg] CreateFile() “D:项目资料 ginx-1.12.2/conf/nginx.conf“ failed (1113: No mapping for t

nginx: [emerg] CreateFile() “D:项目资料 ginx-1.12.2/conf/nginx.conf“ failed (1113: No mapping for t

Nginx报错:nginx: [emerg] open() “/usr/local/nginx/../conf/nginx.conf“ failed (2: No such file or direc

阿里云centOS7.4 nginx: [emerg] "server" directive is not allowed here in /etc/nginx/vhost/x

如何更正'nginx:[emerg]“流”指令在这里不允许'

[emerg]: getpwnam(“nginx”) failed