1. Environment parameters: Linux: Centos6.5, Nginx:1.6.3
2. Nginx download, download address: wget http://nginx.org/download/nginx-1.6.3.tar.gz
3. Dependency installation
yum install pcre pcre-devel openssl openssl-devel -y
4. Create Nginx user and group
groupadd nginx
user add nginx -s / sbin/nologin -M -g nginx
5. Decompress Nginx
tar G./Configure --user = nginx
-GROUP = nginx --Prefix =/Application/Nginx1.6.3 ----http_stub_module ---ith-http_ssl_module
make && make install
8. Make soft connection
ln -s /application/nginx1.6.3/ /application/nginx
9. Start Nginx
/application/nginx /sbin/nginx
10. Nginx stop and restart
nginx -s stop
nginx -s reload
11. Check if Nginx is correct
/application/ nginx/sbin/nginx -t
12. Two ways to check whether the startup is successful
[root@cancer nginx]# netstat -lntup|grep 80tcp 0 0 0.0.0.0:80 0.0. 0:* NODE NAMEnginx 7853 root 6u IPv4 466356 0t0 TCP *:http ( LISTEN)
nginx 7854 nginx 6u IPv4 466356 0t0 TCP *:http (LISTEN)
The above introduces the compilation and installation of Nginx-163, including the relevant content. I hope it will be helpful to friends who are interested in PHP tutorials.