Nginx Installation Preparation
1. System Package Preparation
Prce rewrite (redirect) module requires http://www.pcre.org
Zlib gzip module requires http://www.zlib.net
The OpenSSL SSL feature requires https://www.openssl.org
Nginx installation Package
Nginx_upstream_check load based cookie session hold function
Nginx-goodies-nginx-sticky Background server check function https://bitbucket.org/nginx-goodies/nginx-sticky-module-ng/downloads
2. Create an Nginx user
useradd-d/home/nginx-u-P 123456 nginx
3. Unpack each package
Cd/home/nginx
Tar-xzf +.tar.gz suffix name of the package
Unzip +.zip suffix name of the package
4. Compiling files
CD nginx+ version number directory
./configure--prefix=/home/nginx/nginx--with-pcre=/home/nginx/pcre--with-zlib=/home/nginx/zlib--with-openssl=/ Home/nginx/openssl--user=nginx--group=nginx
5.make Installation
Make && make install
As long as no report error is installed properly
MAKE[1]: Leaving directory '/home/nginx/nginx-1.11.3 '
Because I have re-specified a new directory for Nginx, otherwise the default is to point to/usr/local/nginx
Because the Nginx user cannot create the Nginx directory under/ure/local, the directory will be error-not specified.
Installing Nginx under Linux installation