编译安装nginx-debug模式

./configure --prefix=/opt/nginx-debug--with-debug

make ;make install

vi nginx.conf

worker_processes  1;

daemon off;

master_process  off;

error_log logs/error.log  debug;

启动nginx

Sbin/nginx &

查看调试日志error.log

Tail –f error.log