Nginx Web Server

Latest Article:

Install Nagios3 on Debian 5.0 Lenny

We show how to configure nginx on a 32-bit slice to serve dynamically-created content. Along the way, we show off a couple of troubleshooting techniques and how to work around the lack of a pre-compiled fastcgi package for Debian 5.0 Lenny.

The Nginx Web Server is a light weight and versatile server that can be configured for all the different tasks that many modern websites demand.

These Nginx tutorials take you from the basics of installing and configuring Nginx to more advanced techniques such as proxying to a third party backend.

Web logs:

Reading nginx web logs: Whether you're dealing with web server difficulties or just want to see what nginx is up to, your best bet is to look in its logs.

Interpreting common status codes in web logs: The status codes you find in your web logs are useful troubleshooting tools, but only if you know what they mean.

Customizing nginx web logs: You can create your own custom formats for nginx web logs, to record more information or to make them easier to read. Here's how.


SSL:

Managing SSL Certificates #1: Tips for organizing and managing your SSL certificates.

Managing SSL Certificates #2: How to test your SSL keys and certificates for problems before using them with a web site.


Web traffic reporting:

Installing awstats on Linux: The awstats program is a versatile tool for generating web traffic reports. We'll walk through a simple installation to track stats for your site.

Generating and viewing awstats reports: Now that awstats is installed we take a look at actually running the analysis and viewing the reports.

Scheduling awstats report generation: We've looked at running awstats reports, but only manually. Let's automate report generation so all you need to worry about is looking at those sweet, sweet numbers.


Ubuntu Intrepid and Nginx:

How to serve multiple domains: A commonly asked question is how to serve multiple domains. Let's take a look at the processes involved.


Ubuntu Intrepid - Installing Nginx via aptitude: Using the 'aptitude' package manager to install Nginx is very simple as it takes care of any dependencies and init scripts.


Ubuntu Intrepid - Installing Nginx from source: Although Ubuntu Hardy includes Nginx in its repositories, compiling from source will ensure we have the very latest version.

Ubuntu Intrepid - Adding an Nginx init script: Installing Nginx from source does not create an init file. Let's rectify that so Nginx automatically starts on a reboot.

Ubuntu Intrepid - Nginx from source layout: Adjusting the default layout created when installing Nginx from source allows for much easier administration on the vhosts.


Ubuntu Intrepid - Nginx Configuration: Whether installed from the package manager or from source, we can take a look at the default nginx.conf file and see what can be improved.


Ubuntu Intrepid - Nginx Virtual Hosts #1: Now Nginx is installed and running we can configure it to host multiple sites by creating virtual hosts.

Ubuntu Intrepid - Nginx Virtual Hosts #2: Continuing from the previous article, we can now look in detail at more of the settings available to us when creating a vhost.


Ubuntu Intrepid - Nginx, Rails and mongrels: Creating a virtual host to proxy requests to our rails application is very simple. Using a mongrel cluster has never been easier.

Ubuntu Intrepid - Nginx, Rails and thin: Creating a virtual host to proxy requests to the thin web server is very simple. Even easier then using mongrels.


Ubuntu Hardy and Nginx:

Ubuntu Hardy - Installing Nginx via aptitude: Using the 'aptitude' package manager to install Nginx is very simple as it takes care of any dependencies and init scripts.


Ubuntu Hardy - Installing Nginx from source: Although Ubuntu Hardy includes Nginx in its repositories, compiling from source will ensure we have the very latest version.

Ubuntu Hardy - Adding an Nginx init script: Installing Nginx from source does not create an init file. Let's rectify that so Nginx automatically starts on a reboot.

Ubuntu Hardy - Nginx from source layout: Adjusting the default layout created when installing Nginx from source allows for much easier administration on the vhosts.


Ubuntu Hardy - Nginx Configuration: Whether installed from the package manager or from source, we can take a look at the default nginx.conf file and see what can be improved.


Ubuntu Hardy - Nginx Virtual Hosts: Now Nginx is installed and running we can configure it to host multiple sites by creating virtual hosts.

Ubuntu Hardy - Nginx Virtual Host Settings: Continuing from the previous article, we can now look in detail at more of the settings available to us when creating a vhost.


Ubuntu Hardy - Nginx, Rails and mongrels: Creating a virtual host to proxy requests to our rails application is very simple. Using a mongrel cluster has never been easier.

Ubuntu Hardy - Nginx, Rails and thin: Creating a virtual host to proxy requests to the thin web server is very simple. Even easier then using mongrels.


CentOS and Nginx:

CentOS - Installing nginx via yum: Installing nginx on a CentOS Slice via the 'yum' package manager can be easily done by enabling extra repositories. Let's take a look.


CentOS - Installing nginx from source: Installing nginx on a CentOS Slice from source ensure you have the most up to date release to use.

CentOS - Adding an Nginx init script: Installing Nginx from source does not create an init file. Let's rectify that so Nginx automatically starts on a reboot.

CentOS - Nginx from source layout: Adjusting the default layout created when installing Nginx from source allows for much easier administration of the vhosts.


CentOS - Nginx Configuration: Whether installed from the package manager or from source, we can take a look at the default nginx.conf file and see what can be improved.


CentOS - Nginx Virtual Hosts #1: Now Nginx is installed and running we can configure it to host multiple sites by creating virtual hosts.

CentOS - Nginx Virtual Host Settings: Continuing from the previous article, we can now look in detail at more of the settings available to us when creating a vhost.


CentOS - Nginx, Rails, and mongrels: Creating a virtual host to proxy requests to our rails application is very simple. Using a mongrel cluster has never been easier.

CentOS - Nginx, Rails, and thin: Creating a virtual host to proxy requests to the thin web server is very simple. Even easier then using mongrels.


Debian Lenny and Nginx:

Debian Lenny - Installing Nginx via aptitude: Using the 'aptitude' package manager to install Nginx in Debian is very simple as it takes care of any dependencies and init scripts.

Debian Lenny - Installing Nginx from source: Although Debian Lenny includes Nginx in its repositories, compiling from source will ensure we have the very latest version.

Debian Lenny - Add an nginx init script: When we installed Nginx, no init script was created. Let's rectify that so Nginx automatically starts on a reboot.

Debian Lenny - Nginx from source layout: Adjusting the default layout created when installing Nginx from source allows for much easier administration on the vhosts.


Install Nagios3 on Debian 5.0 Lenny: We show how to configure nginx on a 32-bit slice to serve dynamically-created content. Along the way, we show off a couple of troubleshooting techniques and how to work around the lack of a pre-compiled fastcgi package for Debian 5.0 Lenny.


Debian Lenny - Nginx Configuration: Whether you installed Nginx via the package manager or from source, now we can take a look at the default nginx.conf file and see what can be improved.


Debian Lenny - Nginx Virtual Hosts #1: Now Nginx is installed and running we can configure it to host multiple sites by creating virtual hosts.

Debian Lenny - Nginx Virtual Hosts #2: Continuing from the previous article, we can now look in detail at more of the settings available to us when creating a vhost.


Gentoo and Nginx:

Gentoo - Nginx Install: Using the 'Portage' package manager to install Nginx is very simple as it takes care of any dependencies and init scripts.


Debian Etch and Nginx:

Debian Etch - Nginx install: Debian Etch comes with an older version of nginx. Let's install the latest stable version from source.

Debian Etch - Add an nginx init script: When we installed nginx, no init script was created. Let's rectify that so nginx automatically starts on a reboot.


Ubuntu Gutsy and Nginx:

Ubuntu Gutsy - Installing Nginx via aptitude: Using the package manager to install Nginx is very simple as it takes care of any dependencies and init scripts.


Ubuntu Gutsy - Nginx install from source: Although Ubuntu Gutsy includes a recent version of Nginx, compiling from source will ensure we have the very latest one.

Ubuntu Gutsy - Add an Nginx init script: Installing Nginx from source does not create an init file. Let's rectify that so Nginx automatically starts on a reboot.


Ubuntu Gutsy - Nginx Configuration Layout: Installing Nginx via aptitude creates a 'Debian' style Apache layout. Let's look at what that means.


Ubuntu Gutsy - Nginx Configuration #1: Now we can take a look at the main Gutsy nginx.conf file and see what the settings mean and what effect they have.


Ubuntu Gutsy - Nginx Virtual Hosts #1: Now Nginx is installed and running we can configure it to host multiple sites by creating virtual hosts.

Ubuntu Gutsy - Nginx Virtual Hosts #2: Continuing from the previous article, we now look in detail at more settings in the vhosts file.

Ubuntu Gutsy - Nginx, SSL and Virtual Hosts: How about securing the login area of an administration panel? No problem, let's configure a vhost for just that.


Ubuntu Gutsy - Generating a self signed SSL certificate for Nginx: Generating self signed SSL certificates for Nginx for use on administration areas.


Ubuntu Gutsy - Nginx, Rails and Mongrels: Using Nginx to proxy requests to mongrel server(s) is one of the ways of serving a Rails application.


Ubuntu Feisty and Nginx:

Ubuntu Feisty - Nginx install: Ubuntu Feisty includes an older version of nginx. Let's install the latest stable version from source.

Ubuntu Feisty - Add an Nginx init script: When we installed Nginx, no init script was created. Let's rectify that so Nginx automatically starts on a reboot.


Ubuntu LTS and Nginx:

Ubuntu LTS - Nginx install: Nginx is not included in the default repositories. Let's install the latest stable version from source.

Ubuntu LTS - Add an nginx init script: When we installed nginx, no init script was created. Let's rectify that so nginx automatically starts on a reboot.

Please feel free to request articles or comment with any suggestions or ideas of your own.

PickledOnion