Date: Thu, 8 Nov 2007 11:22:20 +0300 From: Yuri Pankov <yuri.pankov@gmail.com> To: Per olof Ljungmark <peo@intersonic.se> Cc: questions@freebsd.org Subject: Re: syslog time resolution Message-ID: <20071108082220.GB18314@darklight.org.ru> In-Reply-To: <47322023.6060707@intersonic.se> References: <47322023.6060707@intersonic.se>
next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, Nov 07, 2007 at 09:29:23PM +0100, Per olof Ljungmark wrote: > Hi, > > I would like to increase the number of decimals reported in logfiles by > syslogd(8), anyone knows if it is possible and perhaps a hint on how to do > it? > > tcpdump for instance, has six decimals: 21:25:20.160833 whereas the > standard syslog has zero decimal secs. > > I am only referring to events within a single system so it's not related to > clock accuracy. > > Thanks and sorry if I missed the obvious! > > --per Guessing on syslogd source (src/usr.sbin/syslogd/syslogd.c, line ~900) time() and ctime() functions are used to get timestamps, which return only full seconds. So, if I'm not mistaken, there's no easy way to get desired behaviour from base's syslogd. Yuri
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20071108082220.GB18314>