nginx工作原理及配置

发布时间:2022-07-01 发布网站:脚本宝典
脚本宝典收集整理的这篇文章主要介绍了nginx工作原理及配置脚本宝典觉得挺不错的,现在分享给大家,也给大家做个参考。

模块与工作原理

nginx由内核和模块组成。其中,内核的设计非常微小和简洁,完成的工作也非常简单,仅仅通过查找配置文件将客户端请求映射到一个location block(location是nginx配置中的一个指令,用于URL匹配),而在这个location中所配置的每个指令将会启动不同的模块去完成相应的工作。

模块分类

nginx的模块从结构上分为核心模块、基础模块和第三方模块

  • HTTP模块、EVENT模块和MaiL模块等属于核心模块
  • HTTP Access模块、HTTP FastCGI模块、HTTP Proxy模块和HTTP RewrITe模块属于基本模块
  • HTTP Upstream模块、Request Hash模块、Notice模块和HTTP Access Key模块属于第三方模块

用户根据自己的需要开发的模块都属于第三方模块。 nginx模块从功能上分为三类,分别是F1a;

  • Handlers(处理器模块)。此类模块直接处理请求,并进行输出内容和修改headers信息等操作。handlers处理器模块一般只能有一个
  • filters(过滤器模块)。此类模块主要对其他处理器模块输出的内容进行修改操作,最后由nginx输出
  • PRoxies(代理器模块)。就是nginx的HTTP Upstream之类的模块,这些模块主要与后端一些服务比如fastcgi等操作交互,实现服务代理和负载均衡等功能

nginx模块分为:核心模块、事件模块、标准Http模块、可选Http模块、邮件模块、第三方模块和补丁

nginx基本模块:所谓基本模块,指的是nginx默认的功能模块,它们提供的指令,允许你使用定义nginx基本功能的变量,在编译时不能被禁用,包括:

  • 核心模块:基本功能和指令,如进程管理和安全。常见的核心模块指令,大部分是放置在配置文件的顶部
  • 事件模块:在Nginx内配置网络使用的能力。常见的events(事件)模块指令,大部分是放置在配置文件的顶部
  • 配置模块:提供包含机制

更多的指令,请参考nginx官方文档

nginx的工作原理

nginx的模块直接被编译进nginx,因此属于静态编译方式。

启动nginx后,nginx的模块被自动加载,与apache不一样,首先将模块编译为一个so文件,然后在配置文件中指定是否进行加载。

在解析配置文件时,nginx的每个模块都有可能去处理某个请求,但是同一个处理请求只能由一个模块来完成。

nginx的进程架构: 启动nginx时,会启动一个Master进程,这个进程不处理任何客户端的请求,主要用来产生worker线程,一个worker线程用来处理n个request。

worker 进程中,ngx_worker_process_cycle()函数就是这个无限循环的处理函数。在这个函数中,一个请求的简单处理流程如下:

  1. 操作系统提供的机制(例如 epoll, kqueue 等)产生相关的事件。
  2. 接收和处理这些事件,如是接收到数据,则产生更高层的 request 对象。
  3. 处理 request 的 header 和 body。
  4. 产生响应,并发送回客户端。
  5. 完成 request 的处理。
  6. 重新初始化定时器及其他事件。

    nginx工作原理及配置

    多进程模型的处理方式:
  • 首先,;master进程一开始就会根据我们的配置,来建立需要listen的网络socket fd,然后fork出多个worker进程。
  • 其次,根据进程的特性,新建立的worker进程,也会和master进程一样,具有相同的设置。因此,其也会去监听相同ip端口的套接字socket fd。 然后,这个时候有多个worker进程都在监听同样设置的socket fd,意味着当有一个请求进来的时候,所有的worker都会感知到。这样就会产生所谓的“惊群现象”。为了保证只会有一个进程成功注册到listenfd的读事件,nginx中实现了一个“accept_mutex”类似互斥锁,只有获取到这个锁的进程,才可以去注册读事件。其他进程全部accept 失败。
  • 最后,监听成功的worker进程,读取请求,解析处理,响应数据返回给客户端,断开连接,结束。因此,一个request请求,只需要worker进程就可以完成。

nginx模块一次常规的HTTP请求和响应的过程

nginx工作原理及配置

一个典型的HTTP处理周期: 7. 客户端发送HTTP请求 8. Nginx基于配置文件中的位置选择一个合适的处理模块 9. (如果有)负载均衡模块选择一台后端服务器 10. 处理模块进行处理并把输出缓冲放到第一个过滤模块上 11. 第一个过滤模块处理后输出给第二个过滤模块 12. 然后第二个过滤模块又到第三个 13. 依此类推 –> 最后把响应发给客户端。

Nginx本身做的工作实际很少,当它接到一个HTTP请求时,它仅仅是通过查找配置文件将此次请求映射到一个location block,而此location中所配置的各个指令则会启动不同的模块去完成工作,因此模块可以看做Nginx真正的劳动工作者。

基本的WEB服务请求步骤

nginx工作原理及配置

  1. 建立连接 — 接受一个客户端连接,或者如果不希望与这个客户端建立连接,就将其关闭。
  2. 接收请求 — 从网络中读取一条 HTTP 请求报文。
  3. 处理请求 — 对请求报文进行解释,并采取行动。
  4. 访问资 — 访问报文中指定的资源。
  5. 构建响应 — 创建带有正确首部的 HTTP 响应报文。
  6. 发送响应 — 将响应回送给客户端。
  7. 记录事务处理过程 — 将与已完成事务有关的内容记录在一个日志文件中。

nginx部署

nginx的安装

# 关闭火墙和selinux
[root@localhost ~]# Systemctl disable --now firewalld
Removed /etc/systemd/system/multi-user.target.wants/firewalld.service.
Removed /etc/systemd/system/dbus-org.Fedoraproject.FirewallD1.service.
[root@localhost ~]# sed -ri 's/^(SELINUX=).*/1disabled/g' /etc/selinux/config
[root@localhost ~]# reboot 
[root@localhost ~]# getenforce 0
Disabled
# 创建系统用户nginx
[root@localhost ~]# useradd -r -M -s /sbin/noLOGin nginx
# 安装依赖环境
[root@localhost ~]# yum -y install pcre-devel oPEnssl openssl-devel gd-devel gcc gcc-c++ vim wget make
[root@localhost ~]# yum -y groups mark install 'Development Tools'
# 创建日志存放目录
[root@localhost ~]# mkdir -p /VAR/log/nginx
[root@localhost ~]# chown -R nginx.nginx /var/log/nginx
# 下载nginx
[root@localhost ~]# cd /usr/src/
[root@localhost src]# wget http://nginx.org/download/nginx-1.12.0.tar.gz
# 编译安装
[root@localhost src]# ls
debug  kernels  nginx-1.12.0.tar.gz
[root@localhost src]# tar xf nginx-1.12.0.tar.gz
[root@localhost src]# cd nginx-1.12.0
[root@localhost nginx-1.12.0]# ./configure 
--prefix=/usr/local/nginx 
--user=nginx 
--group=nginx 
--with-debug 
--with-http_ssl_module 
--with-http_realip_module 
--with-http_image_filter_module 
--with-http_gunzip_module 
--with-http_gzip_static_module 
--with-http_stub_status_module 
--http-log-path=/var/log/nginx/access.log 
--error-log-path=/var/log/nginx/error.log
[root@localhost nginx-1.12.0]# make -j $(grep 'processor' /proc/cpuinfo | wc -l) && make install
# 配置环境变量
[root@localhost ~]# echo 'export PATH=/usr/local/nginx/sbin:$PATH' > /etc/profile.d/nginx.sh
[root@localhost ~]# . /etc/profile.d/nginx.sh

# 启动nginx
[root@localhost ~]# nginx
[root@localhost ~]# ss -anlt
State    recv-Q   Send-Q     Local Address:Port     Peer Address:Port   
LISTEN   0        128              0.0.0.0:80            0.0.0.0:*      
LISTEN   0        128              0.0.0.0:22            0.0.0.0:*      
LISTEN   0        128                 [::]:22               [::]:*      
# 写service文件让nginx开机自启
[root@localhost ~]# cat > /usr/lib/systemd/system/nginx.service <<EOF
[Unit]
Description=nginx
After=network.target

[Service]
Type=forking
ExecStart=/usr/local/nginx/sbin/nginx
ExecReload=/usr/local/nginx/sbin/nginx -s reload
ExecStop=/usr/local/nginx/sbin/nginx -s quit
Privatetmp=true

[Install]
WantedBy=multi-user.target
EOF
[root@localhost ~]# systemctl daemon-reload
[root@localhost ~]# systemctl enable --now  nginx
Created syMLink /etc/systemd/system/multi-user.target.wants/nginx.service → /usr/lib/systemd/system/nginx.service.
Job for nginx.service failed because the control process exited with error code.
See "systemctl status nginx.service" and "journalctl -xe" for details.

nginx工作原理及配置

nginx的配置文件详解

主配置文件:/usr/local/nginx/conf/nginx.conf

  • 默认启动nginx时,使用的配置文件是:安装路径/conf/nginx.conf文件
  • 可以在启动nginx时通过-c选项来指定要读取的配置文件 nginx常见的配置文件及其作用
配置文件作用
nginx.confnginx的基本配置文件
mime.typesMIME类型关联的扩展文件
fastcgi.conf与fastcgi相关的配置
proxy.conf与proxy相关的配置
sites.conf配置nginx提供的网站,包括虚拟主机

nginx.conf的内容分为以下几段:

  • main配置段:全局配置段。其中main配置段中可能包含event配置段
  • event {}:定义event模型工作特性
  • http {}:定义http协议相关的配置 配置指令:要以分号结尾,语法格式如下:
derective value1 [value2 ...];

支持使用变量:

  • 内置变量:模块会提供内建变量定义
  • 自定义变量:set var_name value 用于调试、定位问题的配置参数 是否以守护进程方式运行Nginx 守护进程(daemon)是脱离终端并且在后台运行的进程。它脱离终端是为了避免进程执行过程中的信息在任何终端上显示,这样一来,进程也不会被任何终端所产生的信息所打断。Nginx毫无疑问是一个需要以守护进程方式运行的服务,因此,默认都是以这种方式运行的。
daemon {on|off};    //是否以守护进程方式运行nginx,调试时应设置为off
master_process {on|off};    //是否以master/worker模型来运行nginx,调试时可以设置为off
error_log 位置 级别;    //配置错误日志
[root@localhost ~]# vim /usr/local/nginx/conf/nginx.conf
#user  nobody;
worker_processes  1;
daemon off;

[root@localhost ~]# nginx -s stop;nginx

正常运行必备的配置参数

不过Nginx还是提供了关闭守护进程的模式,之所以提供这种模式,是为了方便跟踪调试Nginx,毕竟用GDB调试进程时最烦琐的就是如何继续跟进fork出的子进程了。

# user USERNAME [GROUPNAME]		//指定允许worker进程的用户和组
[root@localhost ~]# vim /usr/local/nginx/conf/nginx.conf
user  nginx nginx;

# pid /path/to/pid_file			//指定nginx守护进程的pid文件
[root@localhost ~]# vim /usr/local/nginx/conf/nginx.conf
pid        logs/nginx.pid;
[root@localhost ~]# ls /usr/local/nginx/logs/
nginx.pid
[root@localhost ~]# systemctl stop nginx.service 
[root@localhost ~]# ls /usr/local/nginx/logs/

# worker_rlimit_nofile number	//设置所有woker进程最大可以打开的文件数,默认1024

# worker_rlimit_core size	    //指明所有worker进程所能够使用的总体的最大核心文件大小,保持默认即可

优化性能的配置参数

worker_processes n;    //启动n个worker进程,这里的n为了避免上下文切换,通常设置为cpu总核心数-1或等于总核心数
worker_cpu_affinity cpumask ...;    //将进程绑定到某cpu中,避免频繁刷新缓存
//cpumask:使用8位二进制表示cpu核心,如:
    0000 0001   //第一颗cpu核心
    0000 0010   //第二颗cpu核心
    0000 0100   //第三颗cpu核心
    0000 1000   //第四颗cpu核心
    0001 0000   //第五颗cpu核心
    0010 0000   //第六颗cpu核心
    0100 0000   //第七颗cpu核心
    1000 0000   //第八颗cpu核心

#查看cpu
[root@localhost ~]# vim /usr/local/nginx/conf/nginx.conf
worker_processes  3;
worker_cpu_affinity 0001 0010 0100;
[root@localhost ~]# systemctl restart nginx.service 
[root@localhost ~]# ps -ef | grep nginx
root        1571       1  0 23:13 ?        00:00:00 nginx: master process /usr/local/nginx/sbin/nginx
nginx       1572    1571  0 23:13 ?        00:00:00 nginx: worker process
nginx       1573    1571  0 23:13 ?        00:00:00 nginx: worker process
nginx       1574    1571  0 23:13 ?        00:00:00 nginx: worker process
root        1576    1485  0 23:13 pts/0    00:00:00 grep --color=auto nginx

[root@localhost ~]# top
top - 23:31:29 up 22 min,  1 user,  load average: 0.00, 0.00, 0.00
Tasks: 223 total,   1 running, 222 sleeping,   0 stopped,   0 zombie
%Cpu(s):  0.0 us,  0.0 sy,  0.0 ni,100.0 id,  0.0 wa,  0.0 hi,  0.0 si,  0.0 st
MiB Mem :   3752.0 total,   3300.8 free,    216.8 used,    234.4 buff/cache
MiB Swap:   4044.0 total,   4044.0 free,      0.0 used.   3305.5 avail Mem 

    PID USER      PR  NI    VIRT    RES    Shr S  %CPU  %MEM     TIME+ COMMAND                                                       
      1 root      20   0  242256  10628   8180 S   0.0   0.3   0:00.92 systemd                                                       
      2 root      20   0       0      0      0 S   0.0   0.0   0:00.00 kthreadd                                                      
      3 root       0 -20       0      0      0 I   0.0   0.0   0:00.00 rcu_gp    
                                                          
#按shift+f ,输入nginx,回车

Locate string nginx

    PID USER      PR  NI    VIRT    RES    SHR S  %CPU  %MEM     TIME+ COMMAND                                                       
   1485 root      20   0   26516   4928   3452 S   0.0   0.1   0:00.03 bash                                                          
   1571 root      20   0   80256   1092     56 S   0.0   0.0   0:00.00 nginx                                                         
   1572 nginx     20   0  111708   6276   4700 S   0.0   0.2   0:00.00 nginx                                                         
   1573 nginx     20   0  111708   6276   4700 S   0.0   0.2   0:00.00 nginx                                                         
   1574 nginx     20   0  111708   6276   4700 S   0.0   0.2   0:00.00 nginx   

# 按f, 将光标移到  P       = Last Used Cpu (SMP)
Fields Management for window 1:Def, whose current sort field is %CPU
   navigate with Up/Dn, Right selects for move then <Enter> or Left commits,
   'd' or <Space> toggles display, 's' sets sort.  Use 'q' or <Esc> to end!

* PID     = Process Id             WCHAN   = Sleeping in Function
* USER    = Effective User Name    Flags   = Task Flags <sched.h>
* PR      = Priority               CGROUPS = Control Groups      
* NI      = Nice Value             SUPGIDS = Supp Groups IDs     
* VIRT    = Virtual Image (KiB)    SUPGRPS = Supp Groups names   
* RES     = Resident Size (KiB)    TGID    = Thread Group Id     
* SHR     = Shared Memory (KiB)    OOMa    = OOMEM Adjustment    
* S       = Process Status         OOMs    = OOMEM Score current 
* %CPU    = CPU usage              envIRON = Environment vars    
* %MEM    = Memory Usage (RES)     vMj     = Major Faults delta  
* TIME+   = CPU Time, hundredths   vMn     = Minor Faults delta  
* COMMAND = Command Name/Line      USED    = Res+Swap Size (KiB) 
  PPID    = Parent Process pid     nsIPC   = IPC namespace Inode 
  UID     = Effective User Id      nsMNT   = MNT namespace Inode 
  RUID    = Real User Id           nsNET   = NET namespace Inode 
  RUSER   = Real User Name         nsPID   = PID namespace Inode 
  SUID    = Saved User Id          nSUSER  = USER namespace Inode
  SUSER   = Saved User Name        nsUTS   = UTS namespace Inode 
  GID     = Group Id               LXC     = LXC container name  
  GROUP   = Group Name             RSan    = RES Anonymous (KiB) 
  PGRP    = Process Group Id       RSfd    = RES File-based (KiB)
  TTY     = Controlling Tty        RSlk    = RES Locked (KiB)    
  TPGID   = Tty Process Grp Id     RSsh    = RES Shared (KiB)    
  SID     = Session Id             CGNAME  = Control Group name  
  nTH     = Number of Threads      NU      = Last Used NUMA node 
  P       = Last Used Cpu (SMP) 
  TIME    = CPU Time            
  SWAP    = Swapped Size (KiB)  
  CODE    = Code Size (KiB)     
  DATA    = Data+Stack (KiB)    
  nMaj    = Major Page Faults   
  nMin    = Minor Page Faults   
  nDRT    = Dirty Pages Count 

# 空格选择,按q

    PID USER      PR  NI    VIRT    RES    SHR S  %CPU  %MEM     TIME+ COMMAND                                                      P
   1571 root      20   0   80256   1092     56 S   0.0   0.0   0:00.00 nginx                                                        2
   1572 nginx     20   0  111708   6276   4700 S   0.0   0.2   0:00.00 nginx                                                        0
   1573 nginx     20   0  111708   6276   4700 S   0.0   0.2   0:00.00 nginx                                                        1
   1574 nginx     20   0  111708   6276   4700 S   0.0   0.2   0:00.00 nginx                                                        2


timer_resolution interval;    //计时器解析度。降低此值,可减少gettimeofday()系统调用的次数
worker_priority number;    //指明worker进程的nice值 number取19~-20,数值越低优先级越高
[root@localhost ~]# vim /usr/local/nginx/conf/nginx.conf
worker_priority -20;
[root@localhost ~]# systemctl restart nginx.service
[root@localhost ~]# ps -elf |grep nginx
1 S root        1750       1  0  80   0 - 20064 -      00:21 ?        00:00:00 nginx: master process /usr/local/nginx/sbin/nginx
5 S nginx       1751    1750  0  60 -20 - 27927 do_epo 00:21 ?        00:00:00 nginx: worker process
5 S nginx       1752    1750  0  60 -20 - 27927 do_epo 00:21 ?        00:00:00 nginx: worker process
5 S nginx       1753    1750  0  60 -20 - 27927 do_epo 00:21 ?        00:00:00 nginx: worker process
0 S root        1756    1485  0  80   0 -  3086 -      00:22 pts/0    00:00:00 grep --color=auto nginx

事件相关的配置:event{}段中的配置参数

accept_mutex {off|on};    //master调度用户请求至各worker进程时使用的负载均衡锁;on表示能让多个worker轮流地、序列化地去响应新请求
lock_file file;    //accept_mutex用到的互斥锁锁文件路径
use [epoll | rtsig | select | poll];    //指明使用的事件模型,建议让nginx自行选择
worker_connections #;    //每个进程能够接受的最大连接数


[root@localhost ~]# vim /usr/local/nginx/conf/nginx.conf
events {
    worker_connections  10240;
}

[root@localhost ~]# dnf -y install httpd-tools
[root@localhost ~]# ab  -n 3000 http://192.168.8.132/index.html
This is ApacheBench, Version 2.3 <$revision: 1843412 $>
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Licensed to The Apache Software Foundation, http://www.apache.org/

benchmarking 192.168.8.132 (be patient)
completed 300 requests
Completed 600 requests
Completed 900 requests
Completed 1200 requests
Completed 1500 requests
Completed 1800 requests
Completed 2100 requests
Completed 2400 requests
Completed 2700 requests
Completed 3000 requests
Finished 3000 requests


Server Software:        nginx/1.20.1
Server Hostname:        192.168.111.141
Server Port:            80

Document Path:          /index.html
Document Length:        612 bytes

Concurrency Level:      1
Time taken for tests:   0.376 seconds
Complete requests:      3000
Failed requests:        0
Total transferred:      2535000 bytes
HTML transferred:       1836000 bytes
Requests per second:    7974.21 [#/sec] (mean)
Time per request:       0.125 [ms] (mean)
Time per request:       0.125 [ms] (mean, across all concurrent requests)
Transfer rate:          6580.28 [Kbytes/sec] received

Connection Times (ms)
              min  mean[+/-sd] median   max
Connect:        0    0   0.0      0       0
Processing:     0    0   0.0      0       1
Waiting:        0    0   0.0      0       1
Total:          0    0   0.0      0       1

Percentage of the requests served within a certain time (ms)
  50%      0
  66%      0
  75%      0
  80%      0
  90%      0
  95%      0
  98%      0
  99%      0
 100%      1 (longest request)

网络连接相关的配置参数

keepalive_timeout number;    //长连接的超时时长,默认为65s
keepalive_requests number;    //在一个长连接上所能够允许请求的最大资源数
keepalive_disable [msie6|safari|none];    //为指定类型的UserAgent禁用长连接
tcp_nodelay on|off;    //是否对长连接使用TCP_NODELAY选项,为了提升用户体验,通常设为on
client_header_timeout number;    //读取http请求报文首部的超时时长
client_body_timeout number;    //读取http请求报文body部分的超时时长
send_timeout number;    //发送响应报文的超时时长

fastcgi的相关配置参数

# LNMP: php需启用FPM模型
location ~ .php$ {
  root html;
  fastcgi_pass 127.0.0.1:9000;      //定义反向代理
  fastcgi_index index.php;
  fastcgi_param SCRIPT_FILENAME /scripts$fastcgi_SCRIPT_NAME;		//.php文件路径
  include fastcgi_params;
}

nginx.conf配置文件案例 更改默认端口号以及进程数和指定特定配置文件

[root@localhost conf]# head nginx.conf

#user  nobody;
worker_processes  1;

#error_log  logs/error.log;
#error_log  logs/error.log  notice;
#error_log  logs/error.log  info;

#pid        logs/nginx.pid;

// 使用80端口
 server {
        listen       80;
        server_name  localhost;


// 使用源文件运行进程数如下
[root@localhost conf]# ps -ef | grep nginx
root      257815       1  0 16:46 ?        00:00:00 nginx: master process /usr/local/nginx/sbin/nginx
nginx     257816  257815  0 16:46 ?        00:00:00 nginx: worker process
root      258199  102060  0 16:46 pts/0    00:00:00 grep --color=auto nginx

// 将源文件以及mime.types文件copy一份到/opt目录中
[root@localhost conf]# cp nginx.conf /opt/
[root@localhost conf]# cp mime.types /opt/
[root@localhost conf]# cd /opt/
[root@localhost opt]# ls
mime.types  nginx.conf
[root@localhost opt]# nginx -t -c /opt/nginx.conf
nginx: the configuration file /opt/nginx.conf syntax is ok
nginx: configuration file /opt/nginx.conf test is successful

// 修改 worker_rlimit_nofile number; 参数为4
#user  nobody;
worker_processes  4;

server {
        listen       8070;
        server_name  localhost;

使用nginx服务控制命令重启并指定配置文件路径
[root@localhost opt]# nginx -s stop;nginx -c /opt/nginx.conf
[root@localhost ~]# ss -antl
State  Recv-Q Send-Q Local Address:Port   Peer Address:Port Process                                                     
LISTEN 0      128          0.0.0.0:22          0.0.0.0:*                                                                
LISTEN 0      128          0.0.0.0:8070        0.0.0.0:*                                                                
LISTEN 0      128             [::]:22             [::]:*  

 [root@localhost ~]# ps -ef | grep nginx
root      276931       1  0 16:56 ?        00:00:00 nginx: master process nginx -c /opt/nginx.conf
nginx     276932  276931  0 16:56 ?        00:00:00 nginx: worker process
nginx     276933  276931  0 16:56 ?        00:00:00 nginx: worker process
nginx     276934  276931  0 16:56 ?        00:00:00 nginx: worker process
nginx     276935  276931  0 16:56 ?        00:00:00 nginx: worker process
root      283466  276242  0 16:58 pts/2    00:00:00 grep --color=auto nginx

报错

nginx工作原理及配置

解决方法

[root@localhost nginx-1.12.0]# vim objs/Makefile
CFLAGS =  -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werrori -g
// 找到 -Werrori 后将其去掉

nginx工作原理及配置

[root@localhost nginx-1.12.0]# vim src/os/unix/ngx_user.c
#ifdef __glibc__
    /* work around the glibc bug */
     cd.current_salt[0] = ~salt[0];
#endif
// 把cd.current_salt[0] = ~salt[0];前后加上/* cd.current_salt[0] = ~salt[0];*/

脚本宝典总结

以上是脚本宝典为你收集整理的nginx工作原理及配置全部内容,希望文章能够帮你解决nginx工作原理及配置所遇到的问题。

如果觉得脚本宝典网站内容还不错,欢迎将脚本宝典推荐好友。

本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
如您有任何意见或建议可联系处理。小编QQ:384754419,请注明来意。