nginx installation under linux


1. wget http://nginx.org/download/nginx-1.13.9.tar.gz
2. tar -zxvf nginx-1.13.9.tar.gz
cd nginx-1.13.9/
3. nginx c compiler cc is not found, install gcc-c++ package
Command: yum install gcc-c++
4, zlib plugin installation: yum install zlibzlib, zlib-devel
5, pcre plugin installation: yum install pcre, pcre-devl
6, compile: ./configure -- prefix=/usr/local/nginx
7. Execute the installation: make & make install
 ps aux|grep nginx
 8. Start:
 ./sbin/nginx
 Quick shutdown: kill -INT 9332
 Change the configuration file, reread the configuration file smoothly: kill - HUP 9598

Reread the log, useful when the log is divided by month/day, commonly used for operation and maintenance: kill -USR1 9598

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325520911&siteId=291194637