用GDB调试NGINX
2016-05-31 15:16
351 查看
首先configure加上参数--with-debug。
然后cd objs,修改Makefile,定义CFLAGS = -pipe -g -O0 -fno-inline -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror。
最后make && sudo make install。
进入/usr/local/nginx(或者其他自定义目录),修改conf/nginx.conf,加入三行:
[delphi] view
plain copy
master_process off;
daemon off;
error_log logs/error.log debug;
启动gdb调试:sudo gdb sbin/nginx。
Enjoy it!
然后cd objs,修改Makefile,定义CFLAGS = -pipe -g -O0 -fno-inline -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror。
最后make && sudo make install。
进入/usr/local/nginx(或者其他自定义目录),修改conf/nginx.conf,加入三行:
[delphi] view
plain copy
master_process off;
daemon off;
error_log logs/error.log debug;
启动gdb调试:sudo gdb sbin/nginx。
Enjoy it!
相关文章推荐
- nginx+keepalived负载均衡可用框架(补一 keepalived安装配置-热备-(服务器层和应用层))
- nginx rwrite及增加不记录特定状态日志nginx模块
- 两台服务器如何互相做nginx负载均衡
- windows下安装nginx
- nginx location 匹配规则
- Nginx RTMP 模块 nginx-rtmp-module 指令详解
- 解决nginx负载均衡的session共享问题
- PHP(FastCGI)在Nginx的alias下出现404错误的解决方法
- 切割nginx日志
- linux 查看nginx 安装路径
- 记录一次chown误操作导致服务宕机修复过程(linux+nginx+php+mysql)
- nginx代理详解
- Linux Centos 6.5_x86安装Nginx
- 服务器监控之zabbix监控Nginx篇
- nginx禁止指定user_agent
- nginx的一些安全配置笔记
- Nginx开启Gzip压缩大幅提高页面加载速度
- Nginx安装部署
- nginx cpu过高或过低--状态简单分析与监控
- nginx lua 模块开发