In this paper, the Linux operating system
installation steps
First, download Nginx and related components
First, remember to switch to the root account, and then switch to the / usr / local / src directory
cd …/usr/local/src
In turn download the following four components
wget http://www.openssl.org/source/openssl-fips-2.0.10.tar.gz
wget ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/pcre-8.40.tar.gz
After that, also install the C ++ compiler environment, if already installed, this step can be skipped
root@iZ2ze1329mslloepe7b2dcZ src]# yum install gcc-c++
Second, install Nginx and related components
Openssl installed
tar zxvf openssl-fips-2.0.10.tar.gz
After that, cut down to just extract the finished openssl-fips-2.0.10 directory to perform the installation
cd openssl-fips-2.0.10
./config && make && make install
I remember installing switch back to the parent directory.
Then install pcre
tar zxvf pcre-8.40.tar.gz
After that, cut down to just extract the finished pcre-8.40 directory to perform the installation
cd pcre-8.40
./configure && make && make install
I remember installing switch back to the parent directory.
Then install zlib
tar zxvf zlib-1.2.11.tar.gz
After that, cut down to just extract the finished zlib-1.2.11 directory to perform the installation
cd zlib-1.2.11
./configure && make && make install
I remember installing switch back to the parent directory.
Finally, install nginx
tar zxvf nginx-1.10.2.tar.gz
After that, cut down to just extract the finished nginx-1.10.2 directory to perform the installation
cd nginx-1.10.2
./configure && make && make install
Third, start Nginx
Sbin enter nginx executable directory, the execution of the following instruction
/usr/local/nginx/sbin/nginx -c /usr/local/nginx/conf/nginx.conf
After you enter directly in your browser, your server ip address, will appear the following interface
(Nginx immediately after the installation if you do not change nginx.conf configuration file, then it is listening on port 80 by default)