How to Install NGINX

Installing NGINX Open Source from a package is much easier and faster than building from source, but building from source enables you to compile in non-standard modules. Prebuilt packages are available for most popular Linux distributions, including CentOS, Debian, Red Hat Enterprise Linux (RHEL), SUSE Linux Enterprise Server (SLES), and Ubuntu. See Linux packages at nginx.org for the list of currently supported operating systems.

NGINX Open Source is available in two versions:

Mainline - Includes the latest features and bug fixes and is always up to date. It is reliable, but it may include some experimental modules, and it may also have some number of new bugs.

Stable - Doesn’t include all of the latest features, but has critical bug fixes that are always backported to the mainline version. We recommend the stable version for production servers.

Install the EPEL repository:

~$ sudo yum install epel-release

Update the repository:

~$ sudo yum update

Install NGINX Open Source:

~$ sudo yum install nginx

Verify the installation:

~$ sudo nginx -v
~$ nginx version: nginx/1.6.3

 

  • 21 Users Found This Useful
Was this answer helpful?