Subject: Re: adding logfiles
To: Carl Libra <calibra_2@hotmail.com>
From: Jeremy C. Reed <reed@reedmedia.net>
List: netbsd-help
Date: 03/08/2002 07:57:50
On Fri, 8 Mar 2002, Carl Libra wrote:
> I want put logging for two deamons in to their own logfile. Now they are
> inserted into the messages.
Look at the manual pages for syslog.conf and syslogd.
> pptp.* /var/log/pptp
> popa3d.* /var/log/popa3d
You can't just make up your own facility names like that. Maybe you could
configure or patch these two programs to use some "local" facility; look
in the source code for "openlog" and change to something like:
openlog("popa3d", LOG_PID, LOG_LOCAL3);
openlog("pptp", LOG_PID, LOG_LOCAL4);
And then your config:
local3.* /var/log/popa3d
local4.* /var/log/pptp
I'd just let them log where they normally log to. They are clearly
labled and grep works fine.
Also, I believe there are syslog alternatives that you could use that can
separate log files by the "identifiers".
Jeremy C. Reed
http://www.reedmedia.net/