Nginx log timestamp

Maxim Dounin mdounin at mdounin.ru
Fri Dec 11 17:37:32 MSK 2009


Hello!

On Fri, Dec 11, 2009 at 08:39:33AM -0500, keepwalking wrote:

> Hello.
> 
> It currently have this custom log format:
> log_format  js '$remote_addr [$time_local] $request $country $geoip_region';
> 
> It is possible to get the unix timestamp ? Ex: 1260538968 ?

$msec will give you unix timestamp with milliseconds, i.e. 
something like "1260538968.123".

Maxim Dounin



More information about the nginx mailing list