How To Install Nginx in Rehat 6 / Centos 6 - DC Geek

Breaking

DC Geek

I am still Learning

Follow By Mail

test banner

Post Top Ad

Responsive Ads Here

Post Top Ad

Responsive Ads Here

Saturday, July 13, 2013

How To Install Nginx in Rehat 6 / Centos 6



Peoples are using apache in their webservers.

Recently peoples are changing their apache to nginx for better performance

2 ways to install ngix 

Method 1: YUM Installation

Step 1:Download the repo

For CENTOS 6
wget http://nginx.org/packages/centos/6/noarch/RPMS/nginx-release-centos-6-0.el6.ngx.noarch.rpm
For RHEL 6
wget http://nginx.org/packages/centos/6/noarch/RPMS/nginx-release-rhel-6-0.el6.ngx.noarch.rpm

Step 2:Install the RPM

#rpm -ivh nginx-release-rhel-6-0.el6.ngx.noarch.rpm



Step 3:Install nginx

#yum install nginx

Method 2: RPM Installation

Step 1: Download the RPM File

For Centos click the architecture for rpm file x86_64  i386
For Redat click the architecture for rpm file   x86_64  i386
-->

Step 2: Install the rpm file

#rpm -ivh nginx-1.4.1-1.el6.ngx.i386.rpm


Step 3: Start the service & Check service on or off

#service nginx restart
#chkconfig --lidt nginx


Test nginx working or not

Type the ip address in the browser to check working or not


NGINX Succesfully installed and configuration files are locate in /etc/nginx/nginx.conf and /etc/nginx/conf.d/default.conf

Note: If you are doing any changes in conf you need to restart the configuration using

#service nginx reload
-->

No comments:

Post a Comment

Post Top Ad

Responsive Ads Here