Req #69561 [Asn]: FPM access.log strftime locale not configurable
Edit report at https://bugs.php.net/bug.php?id=69561&edit=1
ID: 69561
Updated by: rasmus@php.net
Reported by: mb at lunetics dot com
Summary: FPM access.log strftime locale not configurable
Status: Assigned
Type: Feature/Change Request
Package: FPM related
Operating System: FreeBSD 10.1
PHP Version: 5.6.8
Assigned To: fat
Block user comment: N
Private report: N
New Comment:
This is because fpm logs before rshutdown is called for some reason. We reset the locale in
rshutdown and other sapis will log after shutdown.
eg.
https://github.com/php/php-src/blob/php-5.6.8/sapi/fpm/fpm/fpm_main.c#L1987-L1992
It should be safe to change that order
Previous Comments:
------------------------------------------------------------------------
[2015-05-01 21:27:21] mb at lunetics dot com
Okay, did some further testing.
So somewhere hidden there's a
setlocale(LC_ALL, 'de_DE.ISO8859-1', 'de_DE.ISO8859-15E');
call. So the current scripts Locale seems to affect the log output (which should be mostly English
in my opinion)
So it would be more a feature request having a custom locale for the fpm access.log strftime locale.
------------------------------------------------------------------------
[2015-05-01 21:06:49] mb at lunetics dot com
Description:
------------
It seems the access.log / php-fpm directive "guesses" the locale from the timezone set?
Systemtimezone is set to "Europe/Berlin" -> strftime %b -> "Mai"
tried setting the timezone to "Europe/London" -> strftime %b -> "Mail"
Would it be possible to set the locale for the access.log strftime parsing?
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=69561&edit=1
Thread (5 messages)