Step #1: Install nginx repo
Type the following wget command to install nginx yum configuration file:
[code language=”php”]
# cd /tmp
[/code]
CentOS Linux v6.x user type the following command:
[code language=”php”]
# wget http://nginx.org/packages/centos/6/noarch/RPMS/nginx-release-centos-6-0.el6.ngx.noarch.rpm
# rpm -ivh nginx-release-centos-6-0.el6.ngx.noarch.rpm
[/code]
Step #2: Install nginx web-server
Type the following yum command to install nginx web-server:
[code language=”php”]
# yum install nginx
[/code]
Step #3: Turn on nginx service
Type the following command:
[code language=”php”]
# chkconfig nginx on
[/code]
Start / stop / restart nginx web-server?
Type the following commands:
[code language=”php”]
# service nginx start
# service nginx stop
# service nginx restart
# service nginx status
# service nginx reload
[/code]