Nginx Web服务应用之功能模块技术了解

系列文章目录

一、nginx软件模块学习

官网地址:http://nginx.org/en/docs/

二、项目中常用的功能模块

1.标准的http功能模块集合

nginx http功能模块功能说明
http_core_module包括一些核心的http参数配置,对应nginx的配置为http区块部分
http_access_module访问控制模块,用来控制网站用户对nginx的访问
http_gzip_module压缩模块,对nginx返回的数据压缩,属于性能优化模块
http_fastcgi_modulefastcgi模块,和动态应用相关的模块
http_proxy_module代理模块
http_upstream_module负载均衡模块,可以实现网站的负载均衡以及节点健康检查
http_rewrite_moduleURL地址重写模块
http_limit_conn_module限制用户的并发连接以及请求数
http_limit_req_module定义的key限制nginx请求过程的速率
http_log_module访问日志模块,指定格式记录nginx客户访问日志
http_auth_basic_moduleweb认证,设置web用户通过账号和密码访问nginx
http_ssl_module加密的http
http_stub_status_module记录nginx基本访问状态信息

以上部分功能模块,绝大部分默认情况都会自动安装到nginx软件中,通过调整相应参数,达到性能优化的目的;

2.以tree型结构了解nginx的目录

rpm -qa tree <==是否安装
yum -y install tree <==安装

[root@root nginx]# tree /opt/nginx/
/opt/nginx/
├── cache
├── client_body_temp
├── conf		#包含nginx所有的配置文件目录,很重要
│   ├── fastcgi.conf        # fastcgi相关参数配置 
│   ├── fastcgi.conf.default  # fastcgi.conf的默认文件备份
│   ├── fastcgi_params	#fastcgi的参数文件
│   ├── fastcgi_params.default  #fastcgi的参数文件默认备份
│   ├── koi-utf
│   ├── koi-win
│   ├── mime.types   #媒体类型
│   ├── mime.types.default  
│   ├── nginx.conf    #nginx默认主配置
│   ├── nginx.conf.default  
│   ├── scgi_params
│   ├── scgi_params.default
│   ├── tcp.d
│   │   └── example.conf
│   ├── uwsgi_params
│   ├── uwsgi_params.default
│   └── win-utf
├── fastcgi_temp   #fastcgi 临时数据目录
├── html   #默认访问目录
│   ├── 50x.html
│   ├── error
│   │   ├── HTTP400.html
│   │   ├── HTTP401.html
│   │   ├── HTTP403.html
│   │   ├── HTTP404.html
│   │   ├── HTTP500.html
│   │   ├── HTTP501.html
│   │   ├── HTTP502.html
│   │   ├── HTTP503.html
│   │   ├── HTTP520.html
│   │   ├── HTTP521.html
│   │   └── HTTP533.html
│   └── index.html   #默认首页面
├── logs   #nginx默认日志路径 包括错误日志以及访问日志
│   ├── access.log
│   ├── error.log
│   ├── nginx.pid  #nginx的pid文件,nginx进程启动后,会把所有进程的id好写入这个文件里
│   └── tcp.log
├── proxy_temp   #临时目录
├── sbin   #nginx命令目录
│   └── nginx  #启动明林
├── scgi_temp
├── static
└── uwsgi_temp


  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

lwd2307997664

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值