Article Directory
A, Nginx Profile
Nginx is a high-performance HTTP server and reverse proxy web server, but also provides IMAP / POP3 / SMTP services. Nginx is Rambler.ru Russia visited the second site developed by Igor Saisuoyefu is.
Nginx is a lightweight Web server / reverse proxy server and e-mail (IMAP / POP3) proxy server, distributed under BSD-like agreement. It features occupy less memory, high concurrency, concurrent nginx fact the same type of ability in web server performance is better, mainland China use nginx web site users are: Baidu, Jingdong, Sina, Netease, Tencent, Taobao.
Second, the installation step
1. Download Nginx
Official website address: http://nginx.org/
version of their choice, the best selection of stable version.
wget http://nginx.org/download/nginx-1.14.2.tar.gz
2, mounted reliance Nginx
yum install -y gcc-gcc++ pcre pcre-devel zlib zlib-devel openssl openssl-devel
3, a packet extracting Nginx
tar xf nginx-1.14.2.tar.gz
4, Configuration
./configure --prefix=/usr/local/nginx
If you encounter an error "./configure: error: C compiler cc is not found", as shown below
solution:
yum -y install gcc gcc-c++ autoconf automake make
5, compile and install
make & make install -j 4
6, start nginx
cd /usr/local/nginx
./sbin/nginx
7, view the Startup status
ps -ef|grep nginx
Browser to visit:
Other commonly used commands:
./nginx -s stop #停止
./nginx -s quit #退出
./nginx -s reload #重新加载