Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 30 Sep 2009 16:56:13 -0500
From:      Austin Friestman <austin.friestman@gmail.com>
To:        freebsd-questions@freebsd.org
Subject:   syslog-ng.conf.sample from port sysutils/syslog-ng3 errors
Message-ID:  <96f71bae0909301456w4136b2aao2d3bb5112f42a9ef@mail.gmail.com>

next in thread | raw e-mail | index | archive | help
The sample config file for syslog-ng3 does not work.
When I install sysutils/syslog-ng3 from ports, the sample config file
/usr/local/etc/syslog-ng/syslog-ng.conf.sample seems to have a number
of things wrong with it.
First, the port is looking for it in /usr/local/etc not
/usr/local/etc/syslog-ng contrary to what most of the tutorials on
it's installation indicate.
Once you've moved the file to the right location, this happens

[afriestman@monolith /usr/local/etc]$ sudo /usr/local/etc/rc.d/syslog-ng start
Starting syslog_ng.
Configuration file has no version number, assuming syslog-ng 2.1
format. Please add @version: maj.min to the beginning of the file;
WARNING: global: the default value of chain_hostnames is changing to
'no' in version 3.0, please update your configuration accordingly;
Your configuration file uses an obsoleted keyword, please update your
configuration; keyword='sync', change='flush_lines'
WARNING: input: sources do not remove new-line characters from
messages by default in version 3.0, please add 'no-multi-line' flag to
your configuration if you want to retain this functionality;
WARNING: file source: default value of follow_freq in file sources is
changing in 3.0 to '1' for all files except /proc/kmsg;
WARNING: template: the default value for template-escape is changing
to 'no' in version 3.0, please update your configuration file
accordingly;
Unknown facility; facility='console'

Adding @version3.0 to the first line of the file helps quite a bit
[afriestman@monolith /usr/local/etc]$ sudo /usr/local/etc/rc.d/syslog-ng start
Starting syslog_ng.
Your configuration file uses an obsoleted keyword, please update your
configuration; keyword='sync', change='flush_lines'
Unknown facility; facility='console'

Changing
options { long_hostnames(off); sync(0); };
to
options { long_hostnames(off); flush_lines(0); };
takes care of all but that last line.

While searching for answers to this problem, I came across
http://dbaspot.com/forums/solaris/240478-syslog-ng-warning-unknown-facility-facility-authpriv.html
which suggests mapping of the facilities seems to be done in eventlog
(which syslog-ng is based on)
Neither of the two files in /usr/local/include/eventlog (evtlog.h and
evtmaps.h) mention a thing about a console facility
However, there is a LOG_CONSOLE definition in /usr/include/syslog.h,
which is included in the above evtlog.h.  see next line
#define LOG_CONSOLE     (14<<3) /* /dev/console output */

I feel like I'm close to getting syslog-ng working, I just need a
little help now that I'm getting into parts of the system I'm not
familiar with.

[afriestman@monolith ~]$ uname -a
FreeBSD monolith.vertive.local 7.2-STABLE FreeBSD 7.2-STABLE #0: Mon
Sep 21 16:40:02 CDT 2009



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?96f71bae0909301456w4136b2aao2d3bb5112f42a9ef>