Introduction
If you have ever looked at a list of the most popular web servers, Nginx is almost certainly near the top. As of mid-2026, Nginx powers roughly 43% of all web-facing computers tracked by Netcraft. It serves some of the highest-traffic websites in the world, and it does so using far less memory and fewer system resources than many of its competitors.
The reason comes down to a single architectural decision: Nginx uses an event-driven, non-blocking model instead of dedicating one process or thread to each connection.
That sentence gets repeated often, but what does it actually mean? What problem does event-driven architecture solve? What was wrong with the older approach? And how does Nginx manage to handle thousands of simultaneous connections with just a handful of worker processes?
This article is the first in the "Inside Nginx" series. We are going to trace the path from the old process-per-connection model to the event-driven approach that Nginx introduced, understand the operating system mechanisms that make it possible, and see why this design changed how engineers think about building web servers.
By the end, you will understand what happens inside Nginx when a connection arrives, why the traditional approach collapsed under load, and what trade-offs event-driven architecture introduces.
Before We Begin: The Building Blocks
Already comfortable with processes, threads, file descriptors, and blocking I/O? Skip ahead to "The Old Way".
To understand why Nginx's architecture matters, you need a working knowledge of a few operating system concepts. These are the foundations everything else builds on.
Processes and Threads
A process is a running instance of a program. When you start Nginx, the operating system creates a process for it, complete with its own memory space, file descriptor table, and execution context. Processes are isolated from each other. If one crashes, others continue running.
A thread is a lighter unit of execution that lives inside a process. Multiple threads within the same process share memory, which makes communication between them faster but also introduces the risk of race conditions and the complexity of synchronization (locks, mutexes, and so on).
Creating a new process is expensive. The operating system must allocate memory, copy page tables, set up a new execution context, and register the process in the scheduler. Threads are cheaper to create than processes, but they still consume stack memory and require the kernel's attention for scheduling.
File Descriptors
In Unix-based operating systems, almost everything is represented as a file. Regular files on disk, network sockets, pipes between processes: the kernel gives each one an integer handle called a file descriptor (FD). When your program opens a file, the kernel returns a small integer (say, 3), and from that point on, you read from and write to that integer.
This matters for web servers because every network connection is a file descriptor. A server handling 10,000 simultaneous connections has at least 10,000 open file descriptors, plus a few more for log files, configuration, and internal communication.
Blocking vs. Non-Blocking I/O
When a program calls read() on a file descriptor, two things can happen.
In blocking I/O (the default), the process suspends entirely until data is available. If a client is sending data slowly over a network connection, the process sits idle, doing nothing, waiting. It cannot handle other connections during this time. The operating system puts it to sleep and wakes it up when data arrives.
In non-blocking I/O, the read() call returns immediately. If data is available, you get it. If not, the kernel returns an EWOULDBLOCK error code, and your program can go do something else and check back later.
Blocking I/O is simpler to program: you call read, you get data, you process it. Non-blocking I/O is more complex because your program must track which connections have data ready and revisit them at the right time. But non-blocking I/O allows a single process to juggle many connections without waiting on any of them.
Context Switching
When the operating system moves the CPU from running one process to another, it performs a context switch. This involves saving the current process's registers, program counter, and stack pointer, then loading the next process's state.
Context switches are not free. The direct cost is measured in microseconds (roughly 2.7 to 5.5 microseconds on modern hardware), but the indirect costs are larger. The CPU's caches (L1, L2, L3) are filled with the old process's data. The Translation Lookaside Buffer (TLB), which speeds up virtual-to-physical memory address translation, gets flushed. The new process starts with cold caches and must re-warm them. When you have thousands of processes switching rapidly, these indirect costs compound significantly.
With these building blocks in place, you can now see why the choice between "one process per connection" and "one process handling many connections" has such dramatic consequences.
The Old Way: Apache's Process-Per-Connection Model
To understand why Nginx exists, you need to understand what came before it.
Apache HTTP Server, first released in 1995, became the dominant web server of the early internet. For years, it powered the majority of websites in the world. Its default architecture, known as the prefork MPM (Multi-Processing Module), followed a straightforward strategy: for every incoming connection, fork a new child process to handle it.
The logic was simple and reliable. When a request arrived, the master process handed it off to a dedicated child process. That child process owned the connection exclusively. It read the request, processed it, sent the response, and then either died or went back into a pool to wait for the next connection. Each child process ran in its own memory space, completely isolated from the others.
This model had real advantages in the 1990s and early 2000s:
Stability. If a child process crashed (because of a buggy CGI script, for example), it took down only that one connection. The rest of the server kept running.
Simplicity. Developers writing server modules did not need to worry about thread safety, shared memory, or synchronization. Each process had its own copy of everything.
Compatibility. Many early server-side technologies (mod_php, mod_perl) were not thread-safe. The process-per-connection model meant this did not matter.
For the web of the late 1990s, this worked well. Pages were mostly static HTML with a few images. Users clicked a link, waited for the page to load, read it for a while, and clicked another link. Connections were short-lived, and concurrent connection counts were low.
Where It Broke Down
The problem was resource consumption. Each Apache child process consumed approximately 5 to 10 MB of memory, sometimes more when loaded with modules like mod_php. A server handling 100 concurrent connections needed 100 processes and roughly 500 MB to 1 GB of memory. That was manageable.
But the web was changing. Websites became more dynamic. AJAX requests meant browsers opened multiple connections simultaneously. Keep-alive connections (HTTP/1.1's persistent connections) meant each connection stayed open longer, holding onto its dedicated process even while idle. Users expected faster load times, which required more parallel asset downloads.
At 1,000 concurrent connections, Apache's prefork model needed 1,000 processes and somewhere between 5 GB and 10 GB of memory, just for the process overhead. At 10,000 connections, the numbers became absurd. And the memory was only part of the problem: the operating system's scheduler had to manage all those processes, and the context-switching overhead between them consumed a meaningful percentage of available CPU time.
Apache later introduced the worker MPM, which used threads instead of processes. This reduced memory overhead because threads share the parent process's memory space. But it still assigned one thread per connection. Thread stacks still consumed memory (typically 1 to 8 MB each), and the context-switching problem remained. The fundamental architectural assumption, that each connection deserved its own execution context, had not changed.
The web needed a different approach.
The C10K Problem: What Broke and Why
In 1999, a software engineer named Dan Kegel published an influential paper titled "The C10K Problem." The question he posed was deceptively simple: how do you build a server that handles 10,000 concurrent connections on a single machine?
The "C" stood for "concurrent." It was not about total requests per day or peak throughput. It was specifically about connections that are open at the same time, many of them idle or slow, all of them consuming server resources.
Ten thousand sounds modest by today's standards, but in 1999, most web servers struggled well before reaching that number. The process-per-connection model hit a wall not because of any single bottleneck, but because of how multiple costs compounded:
Memory. 10,000 processes at 5 MB each means 50 GB of memory, just for the process overhead. In 1999, a high-end server might have 1 to 4 GB of RAM.
Context switches. The operating system's scheduler must cycle through all 10,000 processes. Even if each switch takes only 5 microseconds of direct CPU time, the indirect costs (cache misses, TLB flushes) make the real cost much higher. Under heavy context switching, a significant fraction of CPU time goes to switching rather than doing useful work.
Scheduling overhead. The kernel's process scheduler itself uses data structures (run queues, priority calculations) that become more expensive as the number of processes grows.
File descriptor limits. Early Unix kernels had hard limits on the number of open file descriptors, sometimes as low as 1,024 per process or a few thousand system-wide.
Kegel's paper surveyed the available techniques for working around these limits: non-blocking I/O, I/O multiplexing system calls like select() and poll(), and asynchronous I/O. He catalogued their strengths and weaknesses, and argued that the operating system primitives for handling many connections efficiently already existed, but most server software was not using them.
The C10K paper did not invent these techniques. What it did was frame the problem clearly enough that it became a benchmark for server architecture. It asked the engineering community: if the hardware and the kernel can handle 10,000 connections, why can't our servers?
One of the people paying attention was a Russian systems administrator named Igor Sysoev.
The Event-Driven Solution: How Nginx's Architecture Works
Igor Sysoev began working on Nginx in 2002 while employed at Rambler, one of the largest web portals in Russia at the time. Rambler's traffic was growing rapidly, and Apache could not keep up. Sysoev set out to build a web server that could handle the volume Rambler needed, and he designed it from scratch around a different fundamental assumption.
Instead of assigning one process (or thread) per connection, Nginx uses a small number of worker processes. Each worker runs a single-threaded event loop that can handle thousands of connections simultaneously.
The key insight is that most network connections spend the vast majority of their time waiting. Waiting for the client to send data. Waiting for a response from an upstream server. Waiting for a file to be read from disk. In the process-per-connection model, each of those waits ties up an entire process that does nothing. In the event-driven model, waiting costs almost nothing because no dedicated process is sitting idle.
Here is how it works, at a high level:
A new connection arrives. The worker process accepts it and registers the connection's file descriptor with the operating system's event notification mechanism.
The worker immediately moves on to handle other connections. It does not wait for data.
When data becomes available on any registered file descriptor, the operating system notifies the worker.
The worker processes the available data for that connection (reads the request, sends a response chunk, proxies to an upstream), then goes back to checking for events on other connections.
This cycle repeats continuously in a tight loop.
The worker never blocks. It never waits. It cycles through events as fast as the CPU can process them. A single worker process can handle thousands of connections because it spends essentially zero time on idle connections.
Nginx was publicly released on October 4, 2004. Its architecture was purpose-built for the C10K problem, and it showed. Where Apache needed thousands of processes and gigabytes of memory, Nginx handled the same load with a handful of workers consuming a fraction of the resources.
The Event Loop and I/O Multiplexing: How the Kernel Helps
The event-driven model only works because the operating system kernel provides mechanisms to monitor many file descriptors at once and report which ones are ready for I/O. These mechanisms are called I/O multiplexing system calls, and their evolution is a significant part of this story.
select() (1983)
The oldest I/O multiplexing system call, select(), was introduced in BSD 4.2 in 1983. You give it a set of file descriptors to watch, and it blocks until at least one of them is ready.
The problem is how it works internally. Every time you call select(), you must pass the entire set of file descriptors you are interested in. The kernel scans through all of them linearly to check which ones are ready. The time complexity is O(n) where n is the number of file descriptors. Worse, select() has a hard-coded limit of 1,024 file descriptors on most systems (defined by the FD_SETSIZE constant). For a server handling more than 1,024 connections, select() simply cannot work.
poll() (1986)
The poll() system call removed the 1,024 file descriptor limit. You can watch as many descriptors as you want. However, poll() still has the same fundamental performance problem: every call requires passing the entire list of descriptors, and the kernel still scans them linearly. At 10,000 connections, you are copying a large array into kernel space and scanning through all 10,000 entries on every call, even if only a few connections have data ready. The time complexity remains O(n).
epoll (Linux, 2002)
The breakthrough came with epoll, introduced in Linux kernel 2.5.44. Instead of passing the entire set of file descriptors on every call, epoll uses a persistent interest list maintained inside the kernel.
The workflow:
Create an epoll instance with epoll_create().
Register file descriptors you care about using epoll_ctl(). The kernel adds them to its internal data structure (a red-black tree).
Call epoll_wait(), which blocks until one or more registered descriptors are ready.
epoll_wait() returns only the descriptors that are actually ready, not the entire set.
The critical difference: adding or removing a descriptor is an O(log n) operation on the red-black tree, and waiting is O(1) with respect to the total number of monitored descriptors, because the kernel maintains a separate ready list. When data arrives on a socket, the kernel's interrupt handler adds that socket's descriptor to the ready list. epoll_wait() simply returns whatever is on that list.
For a server monitoring 50,000 connections where 100 are active at any given moment, select() and poll() scan through all 50,000 on every call. epoll returns only the 100 that have data. The performance difference is dramatic.
kqueue (FreeBSD, 2000)
FreeBSD developed a similar mechanism called kqueue, introduced in FreeBSD 4.1. Like epoll, kqueue uses a kernel-managed event queue and returns only the events that actually occurred. It is arguably more flexible than epoll because it can monitor more than just file descriptors: timers, signals, process events, and file system changes all go through the same interface.
Nginx supports both epoll and kqueue, as well as older mechanisms like select and poll, choosing the best available option at compile time based on the operating system. On Linux, it uses epoll. On FreeBSD and macOS, it uses kqueue. This is why Nginx performs well across different Unix-like systems.
What This Means for Nginx
The combination of non-blocking I/O and efficient I/O multiplexing is what makes the event loop viable. Without epoll or kqueue, a server handling 10,000 connections would still need to scan through all 10,000 descriptors on every iteration of the event loop, which would negate much of the benefit. With these modern kernel interfaces, the event loop's per-iteration cost scales with the number of active connections, not the total number of connections. That is the mechanism that makes the C10K problem solvable in a single process.
Nginx's Master-Worker Process Model
Nginx does not run as a single process. It uses a master-worker architecture that separates management concerns from request handling.
The Master Process
When you start Nginx, the first thing that runs is the master process. This process runs as root (or whatever user started Nginx) and handles administrative tasks:
Reading and validating the configuration file.
Binding to privileged ports (80 and 443 require root on most systems).
Creating, starting, and managing worker processes.
Handling signals for graceful reloads (SIGHUP), graceful shutdowns (SIGQUIT), and fast shutdowns (SIGTERM).
The master process never handles client connections directly. Its sole purpose is to manage the lifecycle of worker processes.
Worker Processes
The master spawns a configurable number of worker processes. Each worker runs with reduced privileges (typically as the nginx or www-data user) and operates its own independent event loop.
Each worker is single-threaded. It does not share memory with other workers (beyond the read-only shared memory segments used for caching and session data). Workers are independent: they accept connections from the same listening socket using the operating system's built-in load balancing (on modern Linux kernels, the SO_REUSEPORT socket option allows each worker to have its own listener, further reducing contention).
This design gives Nginx the benefits of both worlds. The event-driven model within each worker eliminates the overhead of per-connection processes. Multiple workers utilize all available CPU cores. And process isolation means a bug that crashes one worker does not bring down the server.
How Many Workers?
The standard recommendation is to set worker_processes to auto, which creates one worker per CPU core. The reasoning: each worker's event loop is CPU-bound (it processes events as fast as the CPU allows), so having more workers than cores means they compete for CPU time and introduce unnecessary context switches between workers. Having fewer means some cores sit idle.
The worker_connections directive sets the maximum number of simultaneous connections each worker can handle. The total theoretical capacity of an Nginx server is:
max_connections = worker_processes x worker_connections
With 4 CPU cores and worker_connections set to 4,096, Nginx can handle up to 16,384 simultaneous connections. In practice, the actual limit depends on available memory, file descriptor limits, and the nature of the connections (proxied connections use two file descriptors each: one for the client, one for the upstream).
Graceful Reloads
One of the practical benefits of this architecture is configuration reloading without downtime. When you send a SIGHUP signal to the master process (or run nginx -s reload), the master reads the new configuration, spawns new worker processes with the updated settings, and signals the old workers to finish their current connections and exit. At no point are incoming connections dropped.
What This Looks Like in Practice
Let's look at how these architectural concepts appear in a real Nginx configuration and how you can observe the behavior on a running system.
A Minimal Configuration
worker_processes auto;
events {
worker_connections 4096;
use epoll; # Linux; kqueue on FreeBSD/macOS
multi_accept on;
}
worker_processes auto tells Nginx to create one worker per CPU core. The events block configures the event loop. worker_connections 4096 allows each worker to handle up to 4,096 simultaneous connections. use epoll explicitly selects the I/O multiplexing mechanism (Nginx will choose the best available one automatically if you omit this). multi_accept on tells each worker to accept as many new connections as possible in a single event loop iteration, rather than accepting one at a time.
Observing the Process Model
On a running Nginx server with 4 CPU cores, you can see the master-worker model in action:
$ ps aux | grep nginx
root 1234 0.0 0.1 nginx: master process
nginx 1235 0.2 0.5 nginx: worker process
nginx 1236 0.3 0.5 nginx: worker process
nginx 1237 0.2 0.5 nginx: worker process
nginx 1238 0.3 0.5 nginx: worker process
One master process running as root, four workers running as the nginx user. Each worker process has a relatively small memory footprint. Under load, these four processes can collectively handle tens of thousands of connections.
You can also inspect the file descriptor count for a worker process:
$ ls /proc/1235/fd | wc -l
847
This shows 847 open file descriptors for worker process 1235. Each client connection is one file descriptor. Each proxied upstream connection is another. The worker manages all of them from a single thread.
Connection Flow
When a client connects to an Nginx server configured as a reverse proxy, the following sequence occurs:
The client establishes a TCP connection. One of the worker processes accepts it (a new file descriptor is created).
The worker registers this file descriptor with epoll/kqueue for read events.
The worker continues processing other connections. No waiting.
The kernel signals that data is available on the client's file descriptor. The worker reads the HTTP request.
The worker opens a connection to the upstream server (another file descriptor) and sends the proxied request.
The worker registers the upstream file descriptor for read events and moves on.
When the upstream response arrives, the worker reads it and writes it back to the client.
When the response is complete and the connection is closing, the worker removes the file descriptors from the event watcher and closes the sockets.
At every step, the worker moves on to other work instead of waiting. The entire flow is driven by events: "data available to read," "socket ready to write," "connection closed." The worker reacts to these events as they arrive.
Apache Fought Back: The Event MPM
Apache did not stand still while Nginx gained ground. In Apache 2.4 (released in 2012), the Event MPM became a stable, recommended option. It was Apache's answer to the connection scalability problem.
The Event MPM is a hybrid design. It uses a pool of threads (like the worker MPM), but it adds an important optimization: threads are no longer permanently assigned to keep-alive connections. When a response has been sent and the connection is waiting for the next request (the keep-alive idle state), the Event MPM moves that connection to a dedicated listener thread that uses non-blocking I/O. The actual worker threads are freed to handle other active requests.
This addressed the most obvious waste in Apache's original model. Under HTTP/1.1 with keep-alive enabled (which is the default), connections remain open for seconds or even minutes between requests. In the old model, each of those idle connections held a thread hostage. The Event MPM releases that thread.
However, the Event MPM still assigns one thread per active request. While a request is being processed (reading from disk, executing a CGI script, waiting for a database), it occupies a dedicated thread. The event-driven behavior only applies to idle keep-alive connections.
This creates a meaningful architectural difference from Nginx:
Nginx never assigns a dedicated process or thread to any connection, active or idle. The event loop handles everything.
Apache Event MPM frees threads from idle connections but still dedicates a thread to every actively-processed request.
In benchmarks, this shows. At 1,000 concurrent connections, Apache's Event MPM consumes roughly 1,850 MB of memory compared to Nginx's approximately 142 MB. Apache performs well at moderate connection counts, but the per-thread overhead compounds as concurrency grows. Nginx's flat resource model scales more predictably.
Apache's Event MPM was a significant improvement and made Apache competitive again for many workloads. But it could not change the fundamental architecture of a server originally designed around the assumption that each connection gets its own execution context. Nginx, built from scratch with an event-driven core, did not have that constraint.
When Event-Driven Architecture Breaks Down
Nginx's event-driven model is not a universal solution. Understanding where it struggles is as important as understanding where it excels.
CPU-Heavy Operations Block the Event Loop
The event loop runs on a single thread. If any operation takes a long time to complete and does not yield control back to the loop, every other connection handled by that worker stalls. This is the biggest weakness of the event-driven model.
For Nginx specifically, this is rarely a problem in practice because Nginx is designed to do I/O-bound work: accepting connections, reading requests, writing responses, proxying to upstream servers. These operations complete quickly. Nginx deliberately does not run application logic (like PHP or Python code) inside its worker processes.
But if you configure Nginx to perform CPU-intensive tasks (complex Lua scripting with OpenResty, heavy regular expression matching, or on-the-fly image processing), a single slow operation can delay thousands of other connections sharing that worker. This is why Nginx works best as a reverse proxy, load balancer, or static file server, with application processing offloaded to dedicated backend services.
Blocking Disk I/O on Linux
One area where Nginx historically had a workaround is disk I/O on Linux. The read() system call for files on disk is technically blocking on Linux, even in non-blocking mode. If the requested data is not in the kernel's page cache, the process must wait for the disk to deliver it.
Nginx addresses this in two ways. For many workloads, frequently accessed files stay in the operating system's page cache, so reads return immediately. For workloads with large file sets that exceed the cache (video streaming, large file downloads), Nginx offers a thread_pool mechanism that offloads blocking file reads to a separate pool of threads, keeping the main event loop unblocked. Additionally, Nginx can use asynchronous I/O (aio) on systems that support it, and sendfile() for zero-copy file delivery.
Debugging Difficulty
Event-driven code is inherently harder to debug than sequential, blocking code. In the process-per-connection model, you can attach a debugger to a single process and trace a request from start to finish in a straightforward sequence. In the event-driven model, a single request's handling is spread across multiple event loop iterations, interleaved with the processing of many other requests. Tracing what happened to a specific connection requires understanding the event sequence rather than a linear execution path.
Not for Application Servers
Nginx does not run application code. It cannot replace Apache with mod_php or a Node.js application server. Event-driven architecture is ideal for I/O multiplexing (shuffling bytes between clients and backends), but running arbitrary application logic requires a different model. This is why modern deployments pair Nginx as a reverse proxy with application servers like PHP-FPM, Gunicorn, Puma, or uvicorn.
Frequently Asked Questions
Is Nginx single-threaded?
Not exactly. Nginx runs multiple worker processes, each of which is single-threaded in terms of its event loop. The master process manages the workers but does not handle connections. Each worker independently handles thousands of connections using non-blocking I/O. Additionally, Nginx can use thread pools for specific tasks like blocking disk reads, but the core connection-handling logic remains single-threaded per worker.
If each worker is single-threaded, how does Nginx use multiple CPU cores?
By running one worker process per CPU core. Each worker's event loop saturates one core. With four cores and four workers, Nginx can process events on all four cores simultaneously. The workers are independent processes that share the listening socket but do not share data or state (beyond read-only shared memory for caching).
Why doesn't Nginx just use threads like Java or Go servers?
Threads still have overhead: stack memory (typically 1 to 8 MB per thread), kernel scheduling, and context switching. For I/O-bound work (which is most of what a web server or reverse proxy does), event-driven I/O with kernel-level notification mechanisms like epoll achieves the same concurrency with far less overhead. Thread-per-connection models make more sense for CPU-bound workloads where each connection requires sustained computation.
Can Nginx replace Apache completely?
For serving static files, reverse proxying, load balancing, TLS termination, and HTTP caching: yes, and it will generally use fewer resources. However, Nginx cannot run application code directly the way Apache can with modules like mod_php. If your setup relies on Apache-specific features (like .htaccess files or specific authentication modules), migrating requires more work.
What is the difference between Nginx and Nginx Plus?
Nginx (the open-source version) provides the core web server, reverse proxy, and load balancing functionality. Nginx Plus is a commercial product from F5 Networks (which acquired Nginx Inc. in 2019) that adds features like active health checks, session persistence, a live dashboard, and commercial support.
How does Nginx compare to newer alternatives like Caddy or Envoy?
Caddy offers automatic HTTPS and simpler configuration at the cost of somewhat lower raw performance. Envoy, designed as a service mesh proxy, focuses on observability and dynamic configuration through APIs. Both use event-driven architectures similar to Nginx. The choice depends on your specific requirements: Nginx remains the most widely deployed and battle-tested option for general-purpose reverse proxying and static file serving.
What happens if an Nginx worker process crashes?
The master process detects the crash and immediately spawns a new worker. Existing connections handled by the crashed worker are lost, but all other workers continue serving their connections without interruption. The new worker starts accepting new connections immediately.
Conclusion and Key Takeaways
Nginx uses an event-driven architecture because the problem it was designed to solve, handling tens of thousands of simultaneous connections on a single server, fundamentally cannot be solved efficiently by dedicating one process or thread per connection.
The process-per-connection model that Apache popularized worked well for the early web, where connections were short-lived and concurrency was low. As the web evolved toward persistent connections, AJAX requests, and massive user bases, the memory overhead and context-switching costs of that model made it unsustainable.
Nginx's architecture rests on a chain of enabling technologies: non-blocking I/O allows a process to manage many connections without waiting on any of them; I/O multiplexing system calls like epoll and kqueue allow the kernel to efficiently report which connections need attention; and the master-worker process model spreads the event-driven workload across all available CPU cores while maintaining stability through process isolation.
The trade-off is real: event-driven code is more complex, harder to debug, and any blocking operation inside the event loop stalls every connection in that worker. Nginx mitigates this by limiting itself to I/O-bound work and delegating application logic to separate backend servers.
This architectural decision, made by Igor Sysoev in 2002 for a Russian web portal, became the template for how modern web infrastructure handles concurrency. Understanding it is the foundation for everything else in this series.
References and Further Reading
The C10K Problem by Dan Kegel (1999). The original paper that framed the concurrent connections challenge.
Inside NGINX: How We Designed for Performance & Scale by Owen Garrett, NGINX Blog.
Nginx Architecture from the official Nginx documentation.
Apache MPM Documentation for details on the prefork, worker, and event MPMs.
epoll(7) man page for the Linux I/O multiplexing interface.
kqueue(2) man page for the FreeBSD/macOS event notification interface.
Nginx vs Apache: A Practical Comparison on DigitalOcean Community.
Thread Pools in NGINX Boost Performance 9x! on the NGINX Blog, explaining how thread pools address blocking disk I/O.