Preface
You will learn how to notes problems before your boss calls you about some pages not loading. You will learn how to find those problems using logs and your usual Linux toolbox. You will also learn how to minimize the probability of problems happening again.
Nginx started as a web accelerator reverse proxy inside one of the big Russian web companies of the early 2000s. The main web server software was Apache 1.3, and it started to show architectural problems serving thousands of relatively slow clients using the old process-based model. Smart web engineers were already building two-tier systems of light frontends based on the mod_proxy
Apache module or even used the squid caching proxy in the reverse proxy mode.
The early predecessor of Nginx was named mod_accel
, and it was also implemented as an Apache module. The mod_accel
module gained some popularity among the administrators of some of the busiest websites, but it is nothing compared with what Nginx later enjoyed. Both of them are built on the idea that the additional level of proxying on the server side of a busy website is a good thing, providing both the extra flexibility and separating the job of serving slow clients from the actual response generation.
Nginx took the idea of mod_proxy
module to the extreme by being a self-sufficient separate HTTP server with a goal to solve the so-called C10K problem, that is, serving 10,000 concurrent connections. The numbers do not look impressive at all in 2016, but they did in 2007 when Nginx first claimed a significant share of 1% of the Web according to Netcraft.
Since that time, the share grew manifold while Nginx steadily gained new functionality and remained the ideal open source success story project with a single, talented developer devoting his genius to producing free quality software, which the whole Web could benefit from.
In 2011, a commercial enterprise named Nginx, Inc. was founded, which allowed even more freedom for the developers (now a team). The firm provides both support services and a special subscription-based extended version of the software named Nginx Plus. We will mention some of the Nginx Plus features in the sixth chapter.
In 2016, Nginx is a great tool many businesses are built upon. However, it is still just a tool which requires a master to show its full potential. If you want to understand what is going on in your web server, to be able to write correct Nginx configuration files and read Nginx logs, and if you want your web server to be very fast, you will have to become that master.