http://blog.chinaunix.net/xmlrpc.php?r=blog/article&uid=29791971&id=4702007
Nginx is a lightweight Web server/reverse proxy server and e-mail (IMAP/POP3) proxy Server, developed by the Russian program designer Igor Sysoev, which is characterized by a small amount of memory, high concurrency capability, The first public version of 0.1.0 was released on October 4, 2004, and the latest version is released on December 2, 2014 at 1.7.8.
Today in the Ttlsa Web site learning Nginx installation method, tested in the virtual machine, and then installed on the server again, I'll summarize the installation process.
Linux Systems: Centos 6.5 x64
nginx Version: 1.7.8
1, install Prce (redirect support) and OpenSSL (HTTPS support, if you do not need HTTPS can not be installed. )
- Yum-y Install pcre*
- Yum-y Install openssl*
CentOS 6.5 i installed the "basic server", the default two packages are not installed all, so both run the installation.
2. Download Nginx 1.7.8
- wget http://nginx.org/download/nginx-1.7.8.tar.gz
3, unzip the installation of the compilation
- TAR-ZXVF nginx-1.7.8.tar.gz
Then go to directory compilation installation
- CD nginx-1.7.8
- ./configure--prefix=/usr/local/nginx-1.5.1 \
- --with-http_ssl_module--with-http_spdy_module \
- --with-http_stub_status_module--with-pcre
If there is no error message, you can perform the following installation:
- Make
- Make install
4. Open Nginx Process
- /usr/local/nginx-1.7.8/sbin/nginx
To restart or close a process:
- /usr/local/nginx-1.7.8/sbin/nginx-s Reload
- /usr/local/nginx-1.7.8/sbin/nginx-s stop
5. Close the firewall or add a firewall rule to test it.
- Service Iptables Stop
or edit the configuration file:
- Vi/etc/sysconfig/iptables
Add such an open 80-port rule after saving:
- -A input-m state--state new-m tcp-p TCP--dport 80-j ACCEPT
To restart the service:
- Service Iptables Restart
CentOS 6.5 Installation Nginx 1.7.8 tutorial