[prev in list] [next in list] [prev in thread] [next in thread]
List: freebsd-questions
Subject: Re: Changing Syslog timestamp to UTC
From: Matthew Seaman <matthew () FreeBSD ! org>
Date: 2016-11-25 17:14:35
Message-ID: 569bfc21-0193-09da-bb32-9acb25621275 () freebsd ! org
[Download RAW message or body]
[Attachment #2 (multipart/mixed)]
On 11/25/16 17:06, San s wrote:
> Tried exporting TZ=UTC and restarting syslogd. This shows the syslogd
> restart related messages in UTC, but not rest of the messages. They
> are still showing up as system timezone.
That's because the timestamp isn't generated by syslogd, but by the
program that logs the message. This is what the -T option exists for --
except it only applies to system log messages received across the network.
About the only way I can suggest for solving this is to use rsyslog from
ports -- I believe that has the capability of changing the timestamp to
when it received the log messages, rather than when it was originally
generated. Plus it uses a rather more sensible timestamp format so the
date-time is a single column in the output, and you can tell what the
timezone offset from UTC was.
Cheers,
Matthew
["signature.asc" (application/pgp-signature)]
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic