VPS侦探论坛

 找回密码
 注册
查看: 3091|回复: 1

LNMP1.4正式版的nginx log_format及access log配置

[复制链接]
发表于 2017-11-3 16:38:48 | 显示全部楼层 |阅读模式

之前版本的access log在nginx.conf中可配置,LNMP1.4正式版的nginx.conf中发现access_log off;虽然access_log off,但发现还是可能正常记录,这是为什么?vhost中也没有配置。


请问如何自定义配置access log的格式?
美国VPS推荐: 遨游主机LinodeLOCVPS主机云搬瓦工80VPSVultr美国VPS主机中国VPS推荐: 阿里云腾讯云。LNMP付费服务(代装/问题排查)QQ 503228080
发表于 2017-11-3 18:40:21 | 显示全部楼层


一个全局,一个指定,指定的可以自愿开启
按 http://nginx.org/en/docs/http/ngx_http_log_module.html 设置个log_format,access_log 文件名后指定上 新的log_format
Linux下Nginx+MySQL+PHP自动安装工具:https://lnmp.org
您需要登录后才可以回帖 登录 | 注册

本版积分规则

小黑屋|手机版|Archiver|VPS侦探 ( 鲁ICP备16040043号-1 )

GMT+8, 2024-9-20 18:38 , Processed in 0.026681 second(s), 20 queries .

Powered by Discuz! X3.4

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表