2019独角兽企业重金招聘Python工程师标准>>>

Nginx百科

服务器(软件)你能一口气说出几个?从当年“蹒跚学步”学java时开始用 Tomcat,到“PHP是最好的语言”那帮家伙的LAMP中A——Apache,从sun当年不温不火弄出的glassfish,到微软的独苗IIS。但是当“毛子”(没有贬义,其实毛子的科技我还是很仰视的)弄出了个Nginx,似乎有了当年卡巴斯基拍扁瑞星的那种给国人的震撼。尤其是这些年,Nginx似乎成了高性能、高并发等标签的开源服务器的代名词。

本系列就从一个Nginx小白的视角介绍Nginx的种种。

什么是Nginx?

  1. Nginx是一种服务器软件,可以—— 发布网络应用程序

  2. Nginx是一个高性能的http和反向代理服务器

    反向代理(Reverse Proxy)是指以代理服务器来接受internet上的连接请求,然后将请求转发给内部网络上的服务器,并将从服务器上得到的结果返回给internet上请求连接的客户端,此时代理服务器对外就表现为一个反向代理服务器。

  3. Nginx可以作为一个邮件服务器——代理邮件服务器,实现收发邮件。

  4. Nginx支持负载均衡(借助反向代理实现)。可以利用Nginx服务器作为分发用户请求到各个服务器的中间桥梁,而不实际处理用户的请求。

与其他服务器的比较:

Apache不支持高并发,而Nginx支持处理百万级的TCP连接,10万以上的并发连接。

Tomcat是面向Java的重服务器,而Nginx是一个轻量级的服务器。(但是Nginx可以和Tomcat联合部署,由Nginx来负责转发Java Web相关的请求给Tomcat,相关配置请关注本系列的后续文章)

Nginx跨平台,再见,IIS! :)

Nginx的优缺点:

优点:可以实现高并发、部署简单、内存消耗少、成本低

缺点:rewrite功能不够强,模块没有Apache的多

----------------------------------------------------------------------------------------------------------------------------------------------------------------------

安装Nginx

长话短说,一共以下几个步骤:

1)下载stable版本的Nginx源码包,本文用的是nginx-1.8.1.tar.gz,解压。

2)运行nginx-1.8.1.tar.gz/里的configure

3)如果运行./configure出错,按照错误提示,栈装nignx依赖的软件包:gcc、g++,pcre、pcre-devel,zlib、zlib-devel

4)make编译

5)make install

我在我的Fedora系统上的安装过程如下:

第一步,解压

[neil@neilhost Downloads]$ cp nginx-1.8.1.tar.gz ~/Documents/
[neil@neilhost Downloads]$ cd ~/Documents/
[neil@neilhost Documents]$ ll
总用量 832
drwxr-xr-x. 5 neil neil   4096 4月  22 2015 log
drwxr-xr-x. 4 neil neil   4096 2月  29 20:17 MyCraft
-rw-r-----. 1 neil neil 833473 3月   3 11:02 nginx-1.8.1.tar.gz
drwxr-xr-x. 5 neil neil   4096 5月  23 2015 ProgramAPP
drwxr-xr-x. 3 neil neil   4096 6月   5 2015 workspace-sts-3.6.4.RELEASE
[neil@neilhost Documents]$ tar -zxvf nginx-1.8.1.tar.gz
nginx-1.8.1/
nginx-1.8.1/auto/
nginx-1.8.1/conf/
nginx-1.8.1/contrib/
nginx-1.8.1/src/
nginx-1.8.1/configure
***这里很多很多,此处掠去XXXX个字。——解压完毕[neil@neilhost Documents]$ ll
总用量 836
drwxr-xr-x. 5 neil neil   4096 4月  22 2015 log
drwxr-xr-x. 4 neil neil   4096 2月  29 20:17 MyCraft
drwxr-xr-x. 8 neil neil   4096 1月  26 22:39 nginx-1.8.1
-rw-r-----. 1 neil neil 833473 3月   3 11:02 nginx-1.8.1.tar.gz
drwxr-xr-x. 5 neil neil   4096 5月  23 2015 ProgramAPP
drwxr-xr-x. 3 neil neil   4096 6月   5 2015 workspace-sts-3.6.4.RELEASE
[neil@neilhost Documents]$ cd nginx-1.8.1/
[neil@neilhost nginx-1.8.1]$ ll
总用量 660
drwxr-xr-x. 6 neil neil   4096 3月   3 11:03 auto
-rw-r--r--. 1 neil neil 251319 1月  26 22:39 CHANGES
-rw-r--r--. 1 neil neil 383019 1月  26 22:39 CHANGES.ru
drwxr-xr-x. 2 neil neil   4096 3月   3 11:03 conf
-rwxr-xr-x. 1 neil neil   2478 1月  26 22:39 configure
drwxr-xr-x. 4 neil neil   4096 3月   3 11:03 contrib
drwxr-xr-x. 2 neil neil   4096 3月   3 11:03 html
-rw-r--r--. 1 neil neil   1397 1月  26 22:39 LICENSE
drwxr-xr-x. 2 neil neil   4096 3月   3 11:03 man
-rw-r--r--. 1 neil neil     49 1月  26 22:39 README
drwxr-xr-x. 8 neil neil   4096 3月   3 11:03 src

第二步,运行configure。

[neil@neilhost nginx-1.8.1]$ ./configure
checking for OS+ Linux 3.17.4-301.fc21.x86_64 x86_64
checking for C compiler ... found+ using GNU C compiler+ gcc version: 4.9.2 20150212 (Red Hat 4.9.2-6) (GCC)
checking for gcc -pipe switch ... found
checking for gcc builtin atomic operations ... found
checking for C99 variadic macros ... found
checking for gcc variadic macros ... found
checking for unistd.h ... found
checking for inttypes.h ... found
checking for limits.h ... found
checking for sys/filio.h ... not found
checking for sys/param.h ... found
checking for sys/mount.h ... found
checking for sys/statvfs.h ... found
checking for crypt.h ... found
checking for Linux specific features
checking for epoll ... found
checking for EPOLLRDHUP ... found
checking for O_PATH ... found
checking for sendfile() ... found
checking for sendfile64() ... found
checking for sys/prctl.h ... found
checking for prctl(PR_SET_DUMPABLE) ... found
checking for sched_setaffinity() ... found
checking for crypt_r() ... found
checking for sys/vfs.h ... found
checking for nobody group ... found
checking for poll() ... found
checking for /dev/poll ... not found
checking for kqueue ... not found
checking for crypt() ... not found
checking for crypt() in libcrypt ... found
checking for F_READAHEAD ... not found
checking for posix_fadvise() ... found
checking for O_DIRECT ... found
checking for F_NOCACHE ... not found
checking for directio() ... not found
checking for statfs() ... found
checking for statvfs() ... found
checking for dlopen() ... not found
checking for dlopen() in libdl ... found
checking for sched_yield() ... found
checking for SO_SETFIB ... not found
checking for SO_ACCEPTFILTER ... not found
checking for TCP_DEFER_ACCEPT ... found
checking for TCP_KEEPIDLE ... found
checking for TCP_FASTOPEN ... found
checking for TCP_INFO ... found
checking for accept4() ... found
checking for eventfd() ... found
checking for int size ... 4 bytes
checking for long size ... 8 bytes
checking for long long size ... 8 bytes
checking for void * size ... 8 bytes
checking for uint64_t ... found
checking for sig_atomic_t ... found
checking for sig_atomic_t size ... 4 bytes
checking for socklen_t ... found
checking for in_addr_t ... found
checking for in_port_t ... found
checking for rlim_t ... found
checking for uintptr_t ... uintptr_t found
checking for system byte ordering ... little endian
checking for size_t size ... 8 bytes
checking for off_t size ... 8 bytes
checking for time_t size ... 8 bytes
checking for setproctitle() ... not found
checking for pread() ... found
checking for pwrite() ... found
checking for sys_nerr ... found
checking for localtime_r() ... found
checking for posix_memalign() ... found
checking for memalign() ... found
checking for mmap(MAP_ANON|MAP_SHARED) ... found
checking for mmap("/dev/zero", MAP_SHARED) ... found
checking for System V shared memory ... found
checking for POSIX semaphores ... not found
checking for POSIX semaphores in libpthread ... found
checking for struct msghdr.msg_control ... found
checking for ioctl(FIONBIO) ... found
checking for struct tm.tm_gmtoff ... found
checking for struct dirent.d_namlen ... not found
checking for struct dirent.d_type ... found
checking for sysconf(_SC_NPROCESSORS_ONLN) ... found
checking for openat(), fstatat() ... found
checking for getaddrinfo() ... found
checking for PCRE library ... not found
checking for PCRE library in /usr/local/ ... not found
checking for PCRE library in /usr/include/pcre/ ... not found
checking for PCRE library in /usr/pkg/ ... not found
checking for PCRE library in /opt/local/ ... not found./configure: error: the HTTP rewrite module requires the PCRE library.
You can either disable the module by using --without-http_rewrite_module
option, or install the PCRE library into the system, or build the PCRE library
statically from the source with nginx by using --with-pcre=<path> option.

看吧,出错了,原因是我的电脑没有装过pcre-devel的库,不过pcre有。这里首先安装pcre-devel,注意,无论pcre或pcre-devel都要是小写字母,虽然这里的提示貌似是大写的。(还有,如果你的系统没有安装过gcc和g++,这里应该也会提醒,不过我的系统已经安装了,所以直接提醒的是pcre)

[neil@neilhost nginx-1.8.1]$ sudo yum install pcre-devel
已加载插件:langpacks
正在解决依赖关系
--> 正在检查事务
---> 软件包 pcre-devel.x86_64.0.8.35-14.fc21 将被 安装
--> 正在处理依赖关系 pcre(x86-64) = 8.35-14.fc21,它被软件包 pcre-devel-8.35-14.fc21.x86_64 需要
--> 正在检查事务
---> 软件包 pcre.i686.0.8.35-8.fc21 将被 升级
---> 软件包 pcre.x86_64.0.8.35-8.fc21 将被 升级
---> 软件包 pcre.i686.0.8.35-14.fc21 将被 更新
---> 软件包 pcre.x86_64.0.8.35-14.fc21 将被 更新
--> 解决依赖关系完成依赖关系解决======================================================================================================================================================Package                              架构                             版本                                   源                                 大小
======================================================================================================================================================
正在安装:pcre-devel                           x86_64                           8.35-14.fc21                           updates                           537 k
为依赖而更新:pcre                                 i686                             8.35-14.fc21                           updates                           487 kpcre                                 x86_64                           8.35-14.fc21                           updates                           480 k事务概要
======================================================================================================================================================
安装  1 软件包
升级           ( 2 依赖软件包)总计:1.5 M
总下载量:537 k
Is this ok [y/d/N]: y
Downloading packages:
pcre-devel-8.35-14.fc21.x86_64.rpm                                                                                             | 537 kB  00:00:02
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction (shutdown inhibited)
警告:RPM 数据库已被非 yum 程序修改。正在更新    : pcre-8.35-14.fc21.x86_64                                                                                                          1/5 正在安装    : pcre-devel-8.35-14.fc21.x86_64                                                                                                    2/5 正在更新    : pcre-8.35-14.fc21.i686                                                                                                            3/5 清理        : pcre-8.35-8.fc21                                                                                                                  4/5 清理        : pcre-8.35-8.fc21                                                                                                                  5/5 验证中      : pcre-devel-8.35-14.fc21.x86_64                                                                                                    1/5 验证中      : pcre-8.35-14.fc21.i686                                                                                                            2/5 验证中      : pcre-8.35-14.fc21.x86_64                                                                                                          3/5 验证中      : pcre-8.35-8.fc21.x86_64                                                                                                           4/5 验证中      : pcre-8.35-8.fc21.i686                                                                                                             5/5 已安装:pcre-devel.x86_64 0:8.35-14.fc21                                                                                                                    作为依赖被升级:pcre.i686 0:8.35-14.fc21                                                 pcre.x86_64 0:8.35-14.fc21                                                完毕!

然后,继续configure运行。

[neil@neilhost nginx-1.8.1]$ ./configure
checking for OS+ Linux 3.17.4-301.fc21.x86_64 x86_64
checking for C compiler ... found+ using GNU C compiler+ gcc version: 4.9.2 20150212 (Red Hat 4.9.2-6) (GCC)
checking for gcc -pipe switch ... found
checking for gcc builtin atomic operations ... found
checking for C99 variadic macros ... found
checking for gcc variadic macros ... found
checking for unistd.h ... found
checking for inttypes.h ... found
checking for limits.h ... found
checking for sys/filio.h ... not found
checking for sys/param.h ... found
checking for sys/mount.h ... found
checking for sys/statvfs.h ... found
checking for crypt.h ... found
checking for Linux specific features
checking for epoll ... found
checking for EPOLLRDHUP ... found
checking for O_PATH ... found
checking for sendfile() ... found
checking for sendfile64() ... found
checking for sys/prctl.h ... found
checking for prctl(PR_SET_DUMPABLE) ... found
checking for sched_setaffinity() ... found
checking for crypt_r() ... found
checking for sys/vfs.h ... found
checking for nobody group ... found
checking for poll() ... found
checking for /dev/poll ... not found
checking for kqueue ... not found
checking for crypt() ... not found
checking for crypt() in libcrypt ... found
checking for F_READAHEAD ... not found
checking for posix_fadvise() ... found
checking for O_DIRECT ... found
checking for F_NOCACHE ... not found
checking for directio() ... not found
checking for statfs() ... found
checking for statvfs() ... found
checking for dlopen() ... not found
checking for dlopen() in libdl ... found
checking for sched_yield() ... found
checking for SO_SETFIB ... not found
checking for SO_ACCEPTFILTER ... not found
checking for TCP_DEFER_ACCEPT ... found
checking for TCP_KEEPIDLE ... found
checking for TCP_FASTOPEN ... found
checking for TCP_INFO ... found
checking for accept4() ... found
checking for eventfd() ... found
checking for int size ... 4 bytes
checking for long size ... 8 bytes
checking for long long size ... 8 bytes
checking for void * size ... 8 bytes
checking for uint64_t ... found
checking for sig_atomic_t ... found
checking for sig_atomic_t size ... 4 bytes
checking for socklen_t ... found
checking for in_addr_t ... found
checking for in_port_t ... found
checking for rlim_t ... found
checking for uintptr_t ... uintptr_t found
checking for system byte ordering ... little endian
checking for size_t size ... 8 bytes
checking for off_t size ... 8 bytes
checking for time_t size ... 8 bytes
checking for setproctitle() ... not found
checking for pread() ... found
checking for pwrite() ... found
checking for sys_nerr ... found
checking for localtime_r() ... found
checking for posix_memalign() ... found
checking for memalign() ... found
checking for mmap(MAP_ANON|MAP_SHARED) ... found
checking for mmap("/dev/zero", MAP_SHARED) ... found
checking for System V shared memory ... found
checking for POSIX semaphores ... not found
checking for POSIX semaphores in libpthread ... found
checking for struct msghdr.msg_control ... found
checking for ioctl(FIONBIO) ... found
checking for struct tm.tm_gmtoff ... found
checking for struct dirent.d_namlen ... not found
checking for struct dirent.d_type ... found
checking for sysconf(_SC_NPROCESSORS_ONLN) ... found
checking for openat(), fstatat() ... found
checking for getaddrinfo() ... found
checking for PCRE library ... found
checking for PCRE JIT support ... found
checking for md5 in system md library ... not found
checking for md5 in system md5 library ... not found
checking for md5 in system OpenSSL crypto library ... not found
checking for sha1 in system md library ... not found
checking for sha1 in system OpenSSL crypto library ... not found
checking for zlib library ... not found./configure: error: the HTTP gzip module requires the zlib library.
You can either disable the module by using --without-http_gzip_module
option, or install the zlib library into the system, or build the zlib library
statically from the source with nginx by using --with-zlib=<path> option.

错误又来了,提醒安装zlib的库,即zlib-devel。这里,我的系统因为已经安装了zlib,所以这里只需要安装zlib-devel即可。

[neil@neilhost nginx-1.8.1]$ sudo yum install zlib
已加载插件:langpacks
软件包 zlib-1.2.8-7.fc21.x86_64 已安装并且是最新版本
无须任何处理
[neil@neilhost nginx-1.8.1]$ sudo yum install zlib-devel
已加载插件:langpacks
正在解决依赖关系
--> 正在检查事务
---> 软件包 zlib-devel.x86_64.0.1.2.8-7.fc21 将被 安装
--> 解决依赖关系完成依赖关系解决======================================================================================================================================================Package                              架构                             版本                                    源                                大小
======================================================================================================================================================
正在安装:zlib-devel                           x86_64                           1.2.8-7.fc21                            fedora                            54 k事务概要
======================================================================================================================================================
安装  1 软件包总下载量:54 k
安装大小:134 k
Is this ok [y/d/N]: y
Downloading packages:
zlib-devel-1.2.8-7.fc21.x86_64 FAILED
http://ftp6.sjtu.edu.cn/fedora/linux/releases/21/Everything/x86_64/os/Packages/z/zlib-devel-1.2.8-7.fc21.x86_64.rpm: [Errno 14] curl#7 - "Couldn't connect"
正在尝试其它镜像。
zlib-devel-1.2.8-7.fc21.x86_64.rpm                                                                                             |  54 kB  00:00:00
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction (shutdown inhibited)正在安装    : zlib-devel-1.2.8-7.fc21.x86_64                                                                                                    1/1 验证中      : zlib-devel-1.2.8-7.fc21.x86_64                                                                                                    1/1 已安装:zlib-devel.x86_64 0:1.2.8-7.fc21                                                                                                                    完毕!

好了,继续configure运行。

[neil@neilhost nginx-1.8.1]$ ./configure
checking for OS+ Linux 3.17.4-301.fc21.x86_64 x86_64
checking for C compiler ... found+ using GNU C compiler+ gcc version: 4.9.2 20150212 (Red Hat 4.9.2-6) (GCC)
checking for gcc -pipe switch ... found
checking for gcc builtin atomic operations ... found
checking for C99 variadic macros ... found
checking for gcc variadic macros ... found
checking for unistd.h ... found
checking for inttypes.h ... found
checking for limits.h ... found
checking for sys/filio.h ... not found
checking for sys/param.h ... found
checking for sys/mount.h ... found
checking for sys/statvfs.h ... found
checking for crypt.h ... found
checking for Linux specific features
checking for epoll ... found
checking for EPOLLRDHUP ... found
checking for O_PATH ... found
checking for sendfile() ... found
checking for sendfile64() ... found
checking for sys/prctl.h ... found
checking for prctl(PR_SET_DUMPABLE) ... found
checking for sched_setaffinity() ... found
checking for crypt_r() ... found
checking for sys/vfs.h ... found
checking for nobody group ... found
checking for poll() ... found
checking for /dev/poll ... not found
checking for kqueue ... not found
checking for crypt() ... not found
checking for crypt() in libcrypt ... found
checking for F_READAHEAD ... not found
checking for posix_fadvise() ... found
checking for O_DIRECT ... found
checking for F_NOCACHE ... not found
checking for directio() ... not found
checking for statfs() ... found
checking for statvfs() ... found
checking for dlopen() ... not found
checking for dlopen() in libdl ... found
checking for sched_yield() ... found
checking for SO_SETFIB ... not found
checking for SO_ACCEPTFILTER ... not found
checking for TCP_DEFER_ACCEPT ... found
checking for TCP_KEEPIDLE ... found
checking for TCP_FASTOPEN ... found
checking for TCP_INFO ... found
checking for accept4() ... found
checking for eventfd() ... found
checking for int size ... 4 bytes
checking for long size ... 8 bytes
checking for long long size ... 8 bytes
checking for void * size ... 8 bytes
checking for uint64_t ... found
checking for sig_atomic_t ... found
checking for sig_atomic_t size ... 4 bytes
checking for socklen_t ... found
checking for in_addr_t ... found
checking for in_port_t ... found
checking for rlim_t ... found
checking for uintptr_t ... uintptr_t found
checking for system byte ordering ... little endian
checking for size_t size ... 8 bytes
checking for off_t size ... 8 bytes
checking for time_t size ... 8 bytes
checking for setproctitle() ... not found
checking for pread() ... found
checking for pwrite() ... found
checking for sys_nerr ... found
checking for localtime_r() ... found
checking for posix_memalign() ... found
checking for memalign() ... found
checking for mmap(MAP_ANON|MAP_SHARED) ... found
checking for mmap("/dev/zero", MAP_SHARED) ... found
checking for System V shared memory ... found
checking for POSIX semaphores ... not found
checking for POSIX semaphores in libpthread ... found
checking for struct msghdr.msg_control ... found
checking for ioctl(FIONBIO) ... found
checking for struct tm.tm_gmtoff ... found
checking for struct dirent.d_namlen ... not found
checking for struct dirent.d_type ... found
checking for sysconf(_SC_NPROCESSORS_ONLN) ... found
checking for openat(), fstatat() ... found
checking for getaddrinfo() ... found
checking for PCRE library ... found
checking for PCRE JIT support ... found
checking for md5 in system md library ... not found
checking for md5 in system md5 library ... not found
checking for md5 in system OpenSSL crypto library ... not found
checking for sha1 in system md library ... not found
checking for sha1 in system OpenSSL crypto library ... not found
checking for zlib library ... found
creating objs/MakefileConfiguration summary+ using system PCRE library+ OpenSSL library is not used+ using builtin md5 code+ sha1 library is not found+ using system zlib librarynginx path prefix: "/usr/local/nginx"nginx binary file: "/usr/local/nginx/sbin/nginx"nginx configuration prefix: "/usr/local/nginx/conf"nginx configuration file: "/usr/local/nginx/conf/nginx.conf"nginx pid file: "/usr/local/nginx/logs/nginx.pid"nginx error log file: "/usr/local/nginx/logs/error.log"nginx http access log file: "/usr/local/nginx/logs/access.log"nginx http client request body temporary files: "client_body_temp"nginx http proxy temporary files: "proxy_temp"nginx http fastcgi temporary files: "fastcgi_temp"nginx http uwsgi temporary files: "uwsgi_temp"nginx http scgi temporary files: "scgi_temp"[neil@neilhost nginx-1.8.1]$

以上就算是configure运行成功了。

第三步,额,如果把方才乱七八糟的安装这个库那个库算上,应该是第四步。

make,听说C/Cpp的fan们敲这句命令的时候哈有成就感,:),我只求别再出任何error了。

[neil@neilhost nginx-1.8.1]$ make
make -f objs/Makefile
make[1]: Entering directory '/home/neil/Documents/nginx-1.8.1'
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/nginx.o \src/core/nginx.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_log.o \src/core/ngx_log.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_palloc.o \src/core/ngx_palloc.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_array.o \src/core/ngx_array.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_list.o \src/core/ngx_list.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_hash.o \src/core/ngx_hash.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_buf.o \src/core/ngx_buf.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_queue.o \src/core/ngx_queue.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_output_chain.o \src/core/ngx_output_chain.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_string.o \src/core/ngx_string.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_parse.o \src/core/ngx_parse.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_inet.o \src/core/ngx_inet.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_file.o \src/core/ngx_file.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_crc32.o \src/core/ngx_crc32.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_murmurhash.o \src/core/ngx_murmurhash.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_md5.o \src/core/ngx_md5.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_rbtree.o \src/core/ngx_rbtree.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_radix_tree.o \src/core/ngx_radix_tree.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_slab.o \src/core/ngx_slab.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_times.o \src/core/ngx_times.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_shmtx.o \src/core/ngx_shmtx.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_connection.o \src/core/ngx_connection.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_cycle.o \src/core/ngx_cycle.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_spinlock.o \src/core/ngx_spinlock.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_cpuinfo.o \src/core/ngx_cpuinfo.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_conf_file.o \src/core/ngx_conf_file.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_resolver.o \src/core/ngx_resolver.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_open_file_cache.o \src/core/ngx_open_file_cache.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_crypt.o \src/core/ngx_crypt.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_proxy_protocol.o \src/core/ngx_proxy_protocol.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_syslog.o \src/core/ngx_syslog.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/event/ngx_event.o \src/event/ngx_event.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/event/ngx_event_timer.o \src/event/ngx_event_timer.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/event/ngx_event_posted.o \src/event/ngx_event_posted.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/event/ngx_event_accept.o \src/event/ngx_event_accept.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/event/ngx_event_connect.o \src/event/ngx_event_connect.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/event/ngx_event_pipe.o \src/event/ngx_event_pipe.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/os/unix/ngx_time.o \src/os/unix/ngx_time.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/os/unix/ngx_errno.o \src/os/unix/ngx_errno.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/os/unix/ngx_alloc.o \src/os/unix/ngx_alloc.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/os/unix/ngx_files.o \src/os/unix/ngx_files.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/os/unix/ngx_socket.o \src/os/unix/ngx_socket.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/os/unix/ngx_recv.o \src/os/unix/ngx_recv.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/os/unix/ngx_readv_chain.o \src/os/unix/ngx_readv_chain.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/os/unix/ngx_udp_recv.o \src/os/unix/ngx_udp_recv.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/os/unix/ngx_send.o \src/os/unix/ngx_send.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/os/unix/ngx_writev_chain.o \src/os/unix/ngx_writev_chain.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/os/unix/ngx_channel.o \src/os/unix/ngx_channel.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/os/unix/ngx_shmem.o \src/os/unix/ngx_shmem.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/os/unix/ngx_process.o \src/os/unix/ngx_process.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/os/unix/ngx_daemon.o \src/os/unix/ngx_daemon.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/os/unix/ngx_setaffinity.o \src/os/unix/ngx_setaffinity.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/os/unix/ngx_setproctitle.o \src/os/unix/ngx_setproctitle.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/os/unix/ngx_posix_init.o \src/os/unix/ngx_posix_init.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/os/unix/ngx_user.o \src/os/unix/ngx_user.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/os/unix/ngx_process_cycle.o \src/os/unix/ngx_process_cycle.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/os/unix/ngx_linux_init.o \src/os/unix/ngx_linux_init.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/event/modules/ngx_epoll_module.o \src/event/modules/ngx_epoll_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/os/unix/ngx_linux_sendfile_chain.o \src/os/unix/ngx_linux_sendfile_chain.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/src/core/ngx_regex.o \src/core/ngx_regex.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/ngx_http.o \src/http/ngx_http.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/ngx_http_core_module.o \src/http/ngx_http_core_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/ngx_http_special_response.o \src/http/ngx_http_special_response.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/ngx_http_request.o \src/http/ngx_http_request.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/ngx_http_parse.o \src/http/ngx_http_parse.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/ngx_http_header_filter_module.o \src/http/ngx_http_header_filter_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/ngx_http_write_filter_module.o \src/http/ngx_http_write_filter_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/ngx_http_copy_filter_module.o \src/http/ngx_http_copy_filter_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_log_module.o \src/http/modules/ngx_http_log_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/ngx_http_request_body.o \src/http/ngx_http_request_body.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/ngx_http_variables.o \src/http/ngx_http_variables.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/ngx_http_script.o \src/http/ngx_http_script.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/ngx_http_upstream.o \src/http/ngx_http_upstream.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/ngx_http_upstream_round_robin.o \src/http/ngx_http_upstream_round_robin.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/ngx_http_parse_time.o \src/http/ngx_http_parse_time.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_static_module.o \src/http/modules/ngx_http_static_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_index_module.o \src/http/modules/ngx_http_index_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_chunked_filter_module.o \src/http/modules/ngx_http_chunked_filter_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_range_filter_module.o \src/http/modules/ngx_http_range_filter_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_headers_filter_module.o \src/http/modules/ngx_http_headers_filter_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_not_modified_filter_module.o \src/http/modules/ngx_http_not_modified_filter_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/ngx_http_file_cache.o \src/http/ngx_http_file_cache.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_gzip_filter_module.o \src/http/modules/ngx_http_gzip_filter_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/ngx_http_postpone_filter_module.o \src/http/ngx_http_postpone_filter_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_ssi_filter_module.o \src/http/modules/ngx_http_ssi_filter_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_charset_filter_module.o \src/http/modules/ngx_http_charset_filter_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_userid_filter_module.o \src/http/modules/ngx_http_userid_filter_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_autoindex_module.o \src/http/modules/ngx_http_autoindex_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_auth_basic_module.o \src/http/modules/ngx_http_auth_basic_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_access_module.o \src/http/modules/ngx_http_access_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_limit_conn_module.o \src/http/modules/ngx_http_limit_conn_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_limit_req_module.o \src/http/modules/ngx_http_limit_req_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_geo_module.o \src/http/modules/ngx_http_geo_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_map_module.o \src/http/modules/ngx_http_map_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_split_clients_module.o \src/http/modules/ngx_http_split_clients_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_referer_module.o \src/http/modules/ngx_http_referer_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_rewrite_module.o \src/http/modules/ngx_http_rewrite_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_proxy_module.o \src/http/modules/ngx_http_proxy_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_fastcgi_module.o \src/http/modules/ngx_http_fastcgi_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_uwsgi_module.o \src/http/modules/ngx_http_uwsgi_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_scgi_module.o \src/http/modules/ngx_http_scgi_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_memcached_module.o \src/http/modules/ngx_http_memcached_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_empty_gif_module.o \src/http/modules/ngx_http_empty_gif_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_browser_module.o \src/http/modules/ngx_http_browser_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_upstream_hash_module.o \src/http/modules/ngx_http_upstream_hash_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_upstream_ip_hash_module.o \src/http/modules/ngx_http_upstream_ip_hash_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_upstream_least_conn_module.o \src/http/modules/ngx_http_upstream_least_conn_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/http -I src/http/modules \-o objs/src/http/modules/ngx_http_upstream_keepalive_module.o \src/http/modules/ngx_http_upstream_keepalive_module.c
cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \-o objs/ngx_modules.o \objs/ngx_modules.c
cc -o objs/nginx \
objs/src/core/nginx.o \
objs/src/core/ngx_log.o \
objs/src/core/ngx_palloc.o \
objs/src/core/ngx_array.o \
objs/src/core/ngx_list.o \
objs/src/core/ngx_hash.o \
objs/src/core/ngx_buf.o \
objs/src/core/ngx_queue.o \
objs/src/core/ngx_output_chain.o \
objs/src/core/ngx_string.o \
objs/src/core/ngx_parse.o \
objs/src/core/ngx_inet.o \
objs/src/core/ngx_file.o \
objs/src/core/ngx_crc32.o \
objs/src/core/ngx_murmurhash.o \
objs/src/core/ngx_md5.o \
objs/src/core/ngx_rbtree.o \
objs/src/core/ngx_radix_tree.o \
objs/src/core/ngx_slab.o \
objs/src/core/ngx_times.o \
objs/src/core/ngx_shmtx.o \
objs/src/core/ngx_connection.o \
objs/src/core/ngx_cycle.o \
objs/src/core/ngx_spinlock.o \
objs/src/core/ngx_cpuinfo.o \
objs/src/core/ngx_conf_file.o \
objs/src/core/ngx_resolver.o \
objs/src/core/ngx_open_file_cache.o \
objs/src/core/ngx_crypt.o \
objs/src/core/ngx_proxy_protocol.o \
objs/src/core/ngx_syslog.o \
objs/src/event/ngx_event.o \
objs/src/event/ngx_event_timer.o \
objs/src/event/ngx_event_posted.o \
objs/src/event/ngx_event_accept.o \
objs/src/event/ngx_event_connect.o \
objs/src/event/ngx_event_pipe.o \
objs/src/os/unix/ngx_time.o \
objs/src/os/unix/ngx_errno.o \
objs/src/os/unix/ngx_alloc.o \
objs/src/os/unix/ngx_files.o \
objs/src/os/unix/ngx_socket.o \
objs/src/os/unix/ngx_recv.o \
objs/src/os/unix/ngx_readv_chain.o \
objs/src/os/unix/ngx_udp_recv.o \
objs/src/os/unix/ngx_send.o \
objs/src/os/unix/ngx_writev_chain.o \
objs/src/os/unix/ngx_channel.o \
objs/src/os/unix/ngx_shmem.o \
objs/src/os/unix/ngx_process.o \
objs/src/os/unix/ngx_daemon.o \
objs/src/os/unix/ngx_setaffinity.o \
objs/src/os/unix/ngx_setproctitle.o \
objs/src/os/unix/ngx_posix_init.o \
objs/src/os/unix/ngx_user.o \
objs/src/os/unix/ngx_process_cycle.o \
objs/src/os/unix/ngx_linux_init.o \
objs/src/event/modules/ngx_epoll_module.o \
objs/src/os/unix/ngx_linux_sendfile_chain.o \
objs/src/core/ngx_regex.o \
objs/src/http/ngx_http.o \
objs/src/http/ngx_http_core_module.o \
objs/src/http/ngx_http_special_response.o \
objs/src/http/ngx_http_request.o \
objs/src/http/ngx_http_parse.o \
objs/src/http/ngx_http_header_filter_module.o \
objs/src/http/ngx_http_write_filter_module.o \
objs/src/http/ngx_http_copy_filter_module.o \
objs/src/http/modules/ngx_http_log_module.o \
objs/src/http/ngx_http_request_body.o \
objs/src/http/ngx_http_variables.o \
objs/src/http/ngx_http_script.o \
objs/src/http/ngx_http_upstream.o \
objs/src/http/ngx_http_upstream_round_robin.o \
objs/src/http/ngx_http_parse_time.o \
objs/src/http/modules/ngx_http_static_module.o \
objs/src/http/modules/ngx_http_index_module.o \
objs/src/http/modules/ngx_http_chunked_filter_module.o \
objs/src/http/modules/ngx_http_range_filter_module.o \
objs/src/http/modules/ngx_http_headers_filter_module.o \
objs/src/http/modules/ngx_http_not_modified_filter_module.o \
objs/src/http/ngx_http_file_cache.o \
objs/src/http/modules/ngx_http_gzip_filter_module.o \
objs/src/http/ngx_http_postpone_filter_module.o \
objs/src/http/modules/ngx_http_ssi_filter_module.o \
objs/src/http/modules/ngx_http_charset_filter_module.o \
objs/src/http/modules/ngx_http_userid_filter_module.o \
objs/src/http/modules/ngx_http_autoindex_module.o \
objs/src/http/modules/ngx_http_auth_basic_module.o \
objs/src/http/modules/ngx_http_access_module.o \
objs/src/http/modules/ngx_http_limit_conn_module.o \
objs/src/http/modules/ngx_http_limit_req_module.o \
objs/src/http/modules/ngx_http_geo_module.o \
objs/src/http/modules/ngx_http_map_module.o \
objs/src/http/modules/ngx_http_split_clients_module.o \
objs/src/http/modules/ngx_http_referer_module.o \
objs/src/http/modules/ngx_http_rewrite_module.o \
objs/src/http/modules/ngx_http_proxy_module.o \
objs/src/http/modules/ngx_http_fastcgi_module.o \
objs/src/http/modules/ngx_http_uwsgi_module.o \
objs/src/http/modules/ngx_http_scgi_module.o \
objs/src/http/modules/ngx_http_memcached_module.o \
objs/src/http/modules/ngx_http_empty_gif_module.o \
objs/src/http/modules/ngx_http_browser_module.o \
objs/src/http/modules/ngx_http_upstream_hash_module.o \
objs/src/http/modules/ngx_http_upstream_ip_hash_module.o \
objs/src/http/modules/ngx_http_upstream_least_conn_module.o \
objs/src/http/modules/ngx_http_upstream_keepalive_module.o \
objs/ngx_modules.o \
-lpthread -lcrypt -lpcre -lz
make[1]: Leaving directory '/home/neil/Documents/nginx-1.8.1'
make -f objs/Makefile manpage
make[1]: Entering directory '/home/neil/Documents/nginx-1.8.1'
sed -e "s|%%PREFIX%%|/usr/local/nginx|" \-e "s|%%PID_PATH%%|/usr/local/nginx/logs/nginx.pid|" \-e "s|%%CONF_PATH%%|/usr/local/nginx/conf/nginx.conf|" \-e "s|%%ERROR_LOG_PATH%%|/usr/local/nginx/logs/error.log|" \< man/nginx.8 > objs/nginx.8
make[1]: Leaving directory '/home/neil/Documents/nginx-1.8.1'
[neil@neilhost nginx-1.8.1]$

:),太好了,没错。

第五步,make install。

[neil@neilhost nginx-1.8.1]$
[neil@neilhost nginx-1.8.1]$ make install
make -f objs/Makefile install
make[1]: Entering directory '/home/neil/Documents/nginx-1.8.1'
test -d '/usr/local/nginx' || mkdir -p '/usr/local/nginx'
mkdir: 无法创建目录"/usr/local/nginx": 权限不够
objs/Makefile:1097: recipe for target 'install' failed
make[1]: *** [install] Error 1
make[1]: Leaving directory '/home/neil/Documents/nginx-1.8.1'
Makefile:12: recipe for target 'install' failed
make: *** [install] Error 2
[neil@neilhost nginx-1.8.1]$ make install
make -f objs/Makefile install
make[1]: Entering directory '/home/neil/Documents/nginx-1.8.1'
test -d '/usr/local/nginx' || mkdir -p '/usr/local/nginx'
mkdir: 无法创建目录"/usr/local/nginx": 权限不够
objs/Makefile:1097: recipe for target 'install' failed
make[1]: *** [install] Error 1
make[1]: Leaving directory '/home/neil/Documents/nginx-1.8.1'
Makefile:12: recipe for target 'install' failed
make: *** [install] Error 2
[neil@neilhost nginx-1.8.1]$ sudo make install
[sudo] password for neil:
make -f objs/Makefile install
make[1]: Entering directory '/home/neil/Documents/nginx-1.8.1'
test -d '/usr/local/nginx' || mkdir -p '/usr/local/nginx'
test -d '/usr/local/nginx/sbin'       || mkdir -p '/usr/local/nginx/sbin'
test ! -f '/usr/local/nginx/sbin/nginx'       || mv '/usr/local/nginx/sbin/nginx'           '/usr/local/nginx/sbin/nginx.old'
cp objs/nginx '/usr/local/nginx/sbin/nginx'
test -d '/usr/local/nginx/conf'       || mkdir -p '/usr/local/nginx/conf'
cp conf/koi-win '/usr/local/nginx/conf'
cp conf/koi-utf '/usr/local/nginx/conf'
cp conf/win-utf '/usr/local/nginx/conf'
test -f '/usr/local/nginx/conf/mime.types'        || cp conf/mime.types '/usr/local/nginx/conf'
cp conf/mime.types '/usr/local/nginx/conf/mime.types.default'
test -f '/usr/local/nginx/conf/fastcgi_params'        || cp conf/fastcgi_params '/usr/local/nginx/conf'
cp conf/fastcgi_params      '/usr/local/nginx/conf/fastcgi_params.default'
test -f '/usr/local/nginx/conf/fastcgi.conf'      || cp conf/fastcgi.conf '/usr/local/nginx/conf'
cp conf/fastcgi.conf '/usr/local/nginx/conf/fastcgi.conf.default'
test -f '/usr/local/nginx/conf/uwsgi_params'      || cp conf/uwsgi_params '/usr/local/nginx/conf'
cp conf/uwsgi_params        '/usr/local/nginx/conf/uwsgi_params.default'
test -f '/usr/local/nginx/conf/scgi_params'       || cp conf/scgi_params '/usr/local/nginx/conf'
cp conf/scgi_params         '/usr/local/nginx/conf/scgi_params.default'
test -f '/usr/local/nginx/conf/nginx.conf'        || cp conf/nginx.conf '/usr/local/nginx/conf/nginx.conf'
cp conf/nginx.conf '/usr/local/nginx/conf/nginx.conf.default'
test -d '/usr/local/nginx/logs'       || mkdir -p '/usr/local/nginx/logs'
test -d '/usr/local/nginx/logs' ||        mkdir -p '/usr/local/nginx/logs'
test -d '/usr/local/nginx/html'       || cp -R html '/usr/local/nginx'
test -d '/usr/local/nginx/logs' ||        mkdir -p '/usr/local/nginx/logs'
make[1]: Leaving directory '/home/neil/Documents/nginx-1.8.1'
[neil@neilhost nginx-1.8.1]$

啦啦啦啦,搞定!

等等,需要验证一下是否安装成功了。

找到安装的位置,发现对应的bin目录下已经有了可以运行的程序nginx,大功告成。

[neil@neilhost nginx-1.8.1]$ cd /usr/local/
[neil@neilhost local]$ ll
总用量 52
drwxr-xr-x. 2 root root 4096 3月  15 2015 bin
drwxr-xr-x. 2 root root 4096 8月  16 2014 etc
drwxr-xr-x. 2 root root 4096 8月  16 2014 games
drwxr-xr-x. 2 root root 4096 8月  16 2014 include
drwxr-xr-x. 2 root root 4096 8月  16 2014 lib
drwxr-xr-x. 2 root root 4096 8月  16 2014 lib64
drwxr-xr-x. 2 root root 4096 8月  16 2014 libexec
drwxr-xr-x. 4 root root 4096 6月  21 2015 mongodb
drwxr-xr-x. 6 root root 4096 3月   3 13:36 nginx
drwxr-xr-x. 4 root root 4096 3月  15 2015 redis
drwxr-xr-x. 2 root root 4096 8月  16 2014 sbin
drwxr-xr-x. 5 root root 4096 12月  4 2014 share
drwxr-xr-x. 2 root root 4096 8月  16 2014 src
[neil@neilhost local]$ [neil@neilhost local]$ cd nginx/
[neil@neilhost nginx]$ ll
总用量 16
drwxr-xr-x. 2 root root 4096 3月   3 13:36 conf
drwxr-xr-x. 2 root root 4096 3月   3 13:36 html
drwxr-xr-x. 2 root root 4096 3月   3 13:36 logs
drwxr-xr-x. 2 root root 4096 3月   3 13:36 sbin
[neil@neilhost nginx]$
[neil@neilhost nginx]$ ll sbin/
总用量 3260
-rwxr-xr-x. 1 root root 3334713 3月   3 13:36 nginx
[neil@neilhost nginx]$

本文算是个铺垫,为的是本系列后面的文章;也算给一开始刚用nginx的小白们一个详细的steps来follow。

转载于:https://my.oschina.net/happyBKs/blog/632241

Nginx笔记系列(1)——Nignx的安装部署相关推荐

  1. Elasticsearch系列之:Centos7安装部署Elasticsearch详细步骤

    Elasticsearch系列之:Centos7安装部署Elasticsearch详细步骤 一.下载ElasticSearch安装包 二.创建ES数据存储目录 三.创建ES所属用户 四.配置用户的打开 ...

  2. Nginx教程系列二:Linux安装nginx

    环境 centos 7.3 下载 官网下载地址:http://nginx.org/en/download.html 选择对应的版本下载即可,我这边是nginx-1.18.0,下载后放在/opt/sof ...

  3. DZZOffice(大桌子)企业文档协同平台教程系列(一)——安装部署教程

    一.DZZOffice介绍 Dzzoffice是一套开源办公套件,适用于企业.团队搭建自己的 类似"Google企业应用套件"."微软Office365"的企业 ...

  4. Linux学习笔记——Nginx安装部署

    5.3.Nginx安装部署 5.3.1.简介 Nginx(engine x)是一个高性能的HTTP和反向代理Web服务器,同时也提供了IMAP/POP3/SMTP服务. 同Tomcat一样,Nginx ...

  5. Nginx实战基础篇一 源码包编译安装部署web服务器

    Nginx实战基础篇一 源码包编译安装部署web服务器 版权声明: 本文遵循"署名非商业性使用相同方式共享 2.5 中国大陆"协议 您可以自由复制.发行.展览.表演.放映.广播或通 ...

  6. Nginx实战基础篇六 通过源码包编译安装部署LNMP搭建Discuz论坛

    Nginx实战基础篇六 通过源码包编译安装部署LNMP搭建Discuz论坛 版权声明: 本文遵循"署名非商业性使用相同方式共享 2.5 中国大陆"协议 您可以自由复制.发行.展览. ...

  7. 1 ELK安装部署并监控nginx

    ELK日志收集部署 ELK介绍 ELK是3个开源产品的组合: Elasticsearch Logstash Kibana 全部由Elastic开发维护. Elasticsearch是一个基于Lucen ...

  8. nginx安装部署和配置管理

    一.HTTP 介绍 HTTP协议是Hyper Text Transfer Protocol(超文本传输协议)的缩写,是用于从万维网(WWW:World Wide Web )服务器传输超文本到本地浏览器 ...

  9. Prometheus监控系列一 | 安装部署及配置

    Prometheus监控系列一 | 安装部署及配置 文章目录 0 简介 1 基础环境 2 安装Prometheus 2.1 安装 2.2 配置开机自启动 2.3 启动服务 2.4 验证 3 安装Gra ...

最新文章

  1. 中自苏研院2021招聘季开始啦!
  2. python工作技巧_Python常用小技巧汇总
  3. mongodb转实体对像_MongoDB 计划从“Data Sprawl”中逃脱
  4. 编译安装 zbar 时两次 make 带来的惊喜
  5. Table Store: 海量结构化数据实时备份实战
  6. 问题描述_vortex_新浪博客
  7. messagedigest 图片加密_MessageDigest的功能及用法(加密解密)
  8. IT职场人士值得关注的十大博客之二:人人都是产品经理
  9. 计算机视觉知识点-车型识别
  10. JS中实现继承的几种方式
  11. 计算机提示pdf不能加载,打开电脑中的PDF文档无法显示内容提示Please wait怎么解决...
  12. 无人驾驶常用专有名词
  13. 数据挖掘中分类和聚类的区别
  14. jmeter ramup设置_Jmeter(2)基础知识
  15. kindle自定义屏保之自定义字帖
  16. zigbee CC2530 系列教程 8 AD采集内部温度实验
  17. CSS拓展选择器 组合选择器 后代选择器 交集选择器 伪类选择器
  18. 简单有一定效果的条纹噪声消除算法
  19. RecyclerView实现竖向无限循环滚动的列表
  20. ubuntu基本操作命令超全(上)

热门文章

  1. python中换行的转义符_详解Python中的各种转义符\n\r\t
  2. 从内存细看static
  3. -Git 使用技巧 总结 MD
  4. 【BZOJ4231】回忆树 离线+fail树+KMP
  5. VS2017新建视图中文乱码解决办法
  6. 点击切换图标方法,jquery bootstrap方法
  7. 利用GoogleEarth影像打造Skyline MPT案例(转载)
  8. 找区间连续值(HDU5247)
  9. unix cut命令
  10. vb中如何才能有手型的光标?