[syslog-ng]Problem with built in variables in syslog-ng

Glasser, Rob syslog-ng@lists.balabit.hu
Tue, 29 Apr 2003 16:28:51 -0700


This is a multi-part message in MIME format.

------_=_NextPart_001_01C30EA7.179BAE22
Content-Type: text/plain;
	charset="US-ASCII"
Content-Transfer-Encoding: quoted-printable

I'm banging my head here and can't figure out for the life of me what
happened. I had everything working, and after packaging up the binaries
into a solaris package and reinstalling via package to test the package,
some of the built in variables do not work.  For example I have this
destination statement:

destination network_log {
        file("/var/log/syslog-ng/$HOST/$FACILITY.$YEAR$MONTH$DAY"
                owner(root) group(root) perm(0600) dir_perm(0700)
create_dirs(yes)
        );=20
};

Before it worked correctly, I'd end up with a log entry like
/var/log/syslog-ng/hostabc/auth.20030429
Now I get: /var/log/syslog-ng/.29

Only the $DAY variable appears to be working, all of the others are
resolving to null.

When I truss the process I see it trying to access the file like:

open("/var/log/syslog-ng//.29",
O_WRONLY|O_APPEND|O_NONBLOCK|O_CREAT|O_NOCTTY|O_LARGEFILE, 0600) =3D 7

I've compared the binaries built when I compilied vs what I have in the
package and I don't see any changes.  Any input anyone has would be
greatly appreciated.

BTW I'm running syslog-ng 1.6.0rc2 compiled and installed on Solaris 8
Sparc, Ultra 2 to be exact.

Thank you

Rob


------_=_NextPart_001_01C30EA7.179BAE22
Content-Type: text/html;
	charset="US-ASCII"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV=3D"Content-Type" CONTENT=3D"text/html; =
charset=3Dus-ascii">
<META NAME=3D"Generator" CONTENT=3D"MS Exchange Server version =
6.0.6389.0">
<TITLE>Problem with built in variables in syslog-ng</TITLE>
</HEAD>
<BODY>
<!-- Converted from text/rtf format -->

<P><FONT SIZE=3D2 FACE=3D"Arial">I'm banging my head here and can't =
figure out for the life of me what happened. I had everything working, =
and after packaging up the binaries into a solaris package and =
reinstalling via package to test the package,&nbsp; some of the built in =
variables do not work.&nbsp; For example I have this destination =
statement:</FONT></P>

<P><FONT SIZE=3D2 FACE=3D"Arial">destination network_log {</FONT>

<BR><FONT SIZE=3D2 =
FACE=3D"Arial">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
file(&quot;/var/log/syslog-ng/$HOST/$FACILITY.$YEAR$MONTH$DAY&quot;</FONT=
>

<BR><FONT SIZE=3D2 =
FACE=3D"Arial">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbs=
p;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; owner(root) group(root) perm(0600) =
dir_perm(0700) create_dirs(yes)</FONT>

<BR><FONT SIZE=3D2 =
FACE=3D"Arial">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ); </FONT>

<BR><FONT SIZE=3D2 FACE=3D"Arial">};</FONT>
</P>

<P><FONT SIZE=3D2 FACE=3D"Arial">Before it worked correctly, I'd end up =
with a log entry like /var/log/syslog-ng/hostabc/auth.20030429</FONT>

<BR><FONT SIZE=3D2 FACE=3D"Arial">Now I get: =
/var/log/syslog-ng/.29</FONT>
</P>

<P><FONT SIZE=3D2 FACE=3D"Arial">Only the $DAY variable appears to be =
working, all of the others are resolving to null.</FONT>
</P>

<P><FONT SIZE=3D2 FACE=3D"Arial">When I truss the process I see it =
trying to access the file like:</FONT>
</P>

<P><FONT SIZE=3D2 =
FACE=3D"Arial">open(&quot;/var/log/syslog-ng//.29&quot;, =
O_WRONLY|O_APPEND|O_NONBLOCK|O_CREAT|O_NOCTTY|O_LARGEFILE, 0600) =3D =
7</FONT>
</P>

<P><FONT SIZE=3D2 FACE=3D"Arial">I've compared the binaries built when I =
compilied vs what I have in the package and I don't see any =
changes.&nbsp; Any input anyone has would be greatly =
appreciated.</FONT></P>

<P><FONT SIZE=3D2 FACE=3D"Arial">BTW I'm running syslog-ng 1.6.0rc2 =
compiled and installed on Solaris 8 Sparc, Ultra 2 to be exact.</FONT>
</P>

<P><FONT SIZE=3D2 FACE=3D"Arial">Thank you</FONT>
</P>

<P><FONT SIZE=3D2 FACE=3D"Arial">Rob</FONT>
</P>

</BODY>
</HTML>
------_=_NextPart_001_01C30EA7.179BAE22--