Nginx-163 Compiling and installing

Source: Internet
Author: User
1. Environmental parameters: linux:centos6.5,nginx:1.6.3

2.Nginx download, download address: wget http://nginx.org/download/nginx-1.6.3.tar.gz

3. Dependent installation

Yum install pcre pcre-devel OpenSSL openssl-devel-y

4. Create Nginx Users and Groups

Groupadd Nginx

Useradd nginx-s/sbin/nologin-m-G nginx

5. Unzip the Nginx

Tar XF nginx-1.6.3.tar.gz

CD nginx-1.6.3

6. Compiling the Software

./configure \
--user=nginx \
--group=nginx \
--prefix=/application/nginx1.6.3 \
--with-http_stub_status_module \
--with-http_ssl_module

7. Installing the Software

Make && make install

8. Make a soft connection

Ln-s/application/nginx1.6.3//application/nginx

9.Nginx Start-up

/application/nginx/sbin/nginx

10.Nginx Stop and restart

Nginx-s stop

Nginx-s Reload

11. Check if Nginx is correct

/application/nginx/sbin/nginx -T

12. Two ways to check if a startup is successful

[Root@cancer nginx]# Netstat-lntup|grep 80
TCP 0 0 0.0.0.0:80 0.0.0.0:* LISTEN 7853/nginx


[Root@cancer nginx]# lsof-i: 80
COMMAND PID USER FD TYPE DEVICE size/off NODE NAME
Nginx 7853 root 6u IPv4 466356 0t0 TCP *:http (LISTEN)
Nginx 7854 nginx 6u IPv4 466356 0t0 TCP *:http (LISTEN)

The above describes the Nginx-163 compilation installation, including the aspects of the content, I hope the PHP tutorial interested in a friend helpful.

  • Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.