Is it possible to add milliseconds in error.log and also timestamps
francis at daoine.org
Sat Mar 30 16:08:23 UTC 2019
On Fri, Mar 29, 2019 at 07:24:44AM -0400, sivak wrote:
> Also for some of the statements in error.log ,date and time is not added.Is
> there anyway to add it for missed ones?
Can you give some examples of what you do to generate these lines,
what the lines look like, and what you want them to look like instead?
As I understand things: in general in nginx, things written to error_log
have a timestamp included; and things written to stderr do not.
And most things written to stderr are because they were asked for,
or because the error log does not exist.
If you can show specific things that can be improved, then perhaps
someone will be inspired to change them.
I do not think that all stderr output should have a timestamp -- for example:
$ sbin/nginx -t
nginx: the configuration file /usr/local/nginx/conf/nginx.conf syntax is ok
nginx: configuration file /usr/local/nginx/conf/nginx.conf test is successful
looks correct to me as-is; as does
$ sbin/nginx -p
nginx: option "-p" requires directory name
Francis Daly francis at daoine.org
More information about the nginx