Apache vs. Nginx LogFormat
Igor Sysoev
is at rambler-co.ru
Thu Apr 5 11:17:25 MSD 2007
On Thu, Apr 05, 2007 at 07:51:28AM +0200, Martin Minka wrote:
> could somebody help me to rewrite Apache LogFormat command to Nginx ?
>
> the Apache format is:
> LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"
> \"%{cookie}i\" %v" combined
log_format cookie '$remote_addr - $remote_user '
'[$time_local] "$request" $status $bytes_sent '
'"$http_referer" "$http_user_agent" '
'"$http_cookie" "$server_name"'
;
Some comments:
*) you could not name your format "combined" because there's already
predefined "combined" format compatible with Apache's one.
*) there's no %l in nginx: it useless in modern Internet and Apache
disables it by default: "IdentityCheck off".
--
Igor Sysoev
http://sysoev.ru/en/
More information about the nginx
mailing list