Simple installation and deployment of nginx on linux server

Reference steps: http://www.runoob.com/linux/nginx-install-setup.html

First, you need to install the relevant compilation tools
yum -y install make zlib zlib-devel gcc-c++ libtool  openssl openssl-devel


After the installation is successful, install PCRE:
[root@bogon src]# wget http://downloads.sourceforge.net/project/pcre/pcre/8.35/pcre-8.35.tar.gz
[root@bogon src]# tar zxvf pcre-8.35.tar.gz
[root@bogon src]# cd pcre-8.35
[root@bogon pcre-8.35]# ./configure

At this point, you should pay attention to whether the relevant tools required for compilation are complete. If not found or no, install the relevant tools again. If there is no problem, compile and install directly
[root@bogon pcre-8.35]# make && make install

After the installation is complete, check whether the installation is successful
[root@bogon pcre-8.35]# pcre-config --version



Then install nginx;
download address: wget http://nginx.org/download/nginx-1.6.2.tar.gz
Same as above, decompress it, and enter the directory for inspection
[root@bogon nginx-1.6.2]# ./configure --prefix=/usr/local/webserver/nginx --with-http_stub_status_module --with-http_ssl_module --with-pcre=/usr/local/src/pcre-8.35

What is missing at this time? If the compilation tool is not found in the system, an
error will be reported during make compilation: make: *** No rule to make target `build', needed by `default'. Stop.
Check the result and install it
[root@bogon nginx-1.6.2]# make
[root@bogon nginx-1.6.2]# make install

Then check if the installation was successful:
./nginx -v

The above is the installation process of nginx in the linux environment.

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=326942023&siteId=291194637