In the case of work process is configured to support multi-threading in the following scene, there is an event at the same time will be handled by the main thread and worker thread. step1: in ngx_process_events_and_timers function, the main thread get the accept lock and set the ngx_accept_mutex_held to 1, at this time, the flags | = NGX_POST_EVENTS. And then enter ngx_process_events (epoll, unby Eagleye_Tiger - Nginx Mailing List - English