[syslog-ng]first day of month bug?

jamie rishaw jamie@playboy.com
Mon, 4 Feb 2002 12:40:29 -0600


On Sat, Feb 02, 2002 at 04:47:25PM -0600, Alex Howansky wrote:
> 
> (libol-0.2.23, syslog-ng 1.4.14)
> 
> In my configuration, I have a destination defined like this:
> 
> destination d_app { file("/var/log/app/$YEAR$MONTH$DAY"); };
> 
> This is a wonderful feature, as it gives me a sort of "automatic rotation" of
> logfiles. However, there seems to be a bug that occurs on the first of every
> month. If I look in the /var/log/app directory, I'll see files like:
> 
> 20010201
> 20020101
> 20020102
> 20020103
> [...]

I'm seeing the same thing, a little different format:

        file("/logs/hosts/$HOST/$YEAR-$MONTH/$DAY/$FACILITY" perm(0644));

noc% ls -l
total 8
drwxr-xr-x   3 root  wheel  512 Dec 31 23:00 2001-01
drwxr-xr-x  14 root  wheel  512 Dec 30 23:00 2001-12
drwxr-xr-x  33 root  wheel  512 Jan 30 23:00 2002-01
drwxr-xr-x   6 root  wheel  512 Feb  3 23:00 2002-02

noc% ls -l 2001-01 
total 2
drwxr-xr-x  2 root  wheel  512 Dec 31 23:00 01

The first message on 2001-01/01 was dated Jan  1 00:00:00 and the last
was dated Jan  1 00:59:59. (It's a high volume generator.. 6225 messages
in that hour).

The file in its correct place - 2002-01/01 - started at 01:00:00.

I just kind of let it go thinking that it was one thing but apparently i'm
not the only one :)

Box: FreeBSD 4.4-R, syslog-ng 1.4.14, libol 0.2.23

TIA.

jamie

-- 
jamie rishaw <jamie@playboy.com>
sr. wan/unix engineer/ninja // playboy enterprises inc.
[opinions stated are mine, and are not necessarily those of the bunny]

"UNIX was not designed to stop people from doing stupid things, because
 that would also stop them from doing clever things." -- Doug Gwyn