title: Nginx startup prompt [emerg] no "events" section in configuration
body: <p>In the X-WAF deployment, you need to create a new nginx configuration file. However, when testing the nginx configuration, an error is found and nginx cannot be started.</p>
  
  <p>I refer to <a href="http://blog.51cto.com/14071176/2318054" rel="noreferrer">http://blog.51cto.com/14071176/2318054</a>，I did it step by step according to the configuration in the article, but I had a problem.</p>
  
  <pre><code>root@VM-0-6-ubuntu:~# /usr/local/openresty/nginx/sbin/nginx -t
  nginx: the configuration file /usr/local/openresty/nginx/conf/nginx.conf syntax is ok
  nginx: [emerg] no "events" section in configuration
  nginx: configuration file /usr/local/openresty/nginx/conf/nginx.conf test failed
  
  root@VM-0-6-ubuntu:~# /usr/local/openresty/nginx/sbin/nginx
  nginx: [emerg] no "events" section in configuration
  </code></pre>
  
  <p>Under normal circumstances, executing /usr/local/openresty/nginx/sbin/nginx -t will have two successes, but mine is a success and a failure.</p>