yansy 发表于 2010-12-30 23:51:58

怎么增加给域名log?

添加域名的时候没有选择log
时候如何增加?
vhost目录下的域名.conf 里 改成access_log on

重启lnmp也没有生成log文件..

licess 发表于 2010-12-31 10:40:37

将access_log on;替换为:
log_format域名'$remote_addr - $remote_user [$time_local] "$request" '
             '$status $body_bytes_sent "$http_referer" '
             '"$http_user_agent" $http_x_forwarded_for';
                access_log/home/wwwlogs/域名.logaccess;

域名.log需提前创建好

yansy 发表于 2010-12-31 19:59:22

:handshake
多谢
页: [1]
查看完整版本: 怎么增加给域名log?