Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 28 Apr 1999 00:48:43 -0400 (EDT)
From:      "Crist J. Clark" <cjc@cc942873-a.ewndsr1.nj.home.com>
To:        bsd@dna-is.com (Scott Culverhouse)
Cc:        questions@FreeBSD.ORG
Subject:   Re: Named and Syslogd!
Message-ID:  <199904280448.AAA02356@cc942873-a.ewndsr1.nj.home.com>
In-Reply-To: <3726325B29F.7A8FBSD@puma.dna-is.com> from Scott Culverhouse at "Apr 27, 99 10:55:39 pm"

next in thread | previous in thread | raw e-mail | index | archive | help
Scott Culverhouse wrote,
> How do I make the syslogd log all named logs to a seperate file, is it
> possible to in the syslog.conf or is a filter script needed?
> 
> If it can be done in syslog.conf can someone give me a example!

It can be done in the syslog.conf, but you will probably need a filter
if you _really_ want to keep it out of the default 'messages' file. A
quick look at the source shows that named uses the 'LOG_DAEMON'
facility. You could send this to a new file by doing,

*.notice;kern.debug;lpr.info;mail.crit;news.err,daemon.none /var/log/messages
daemon.notice						    /var/log/named.log

In your syslog.conf, but this will also redirect all other programs
that use the daemon facility to the new file. Alternatively, you can
redirect the named to another file by adding,

!named
*.*					/var/log/named.log

Which now will log everything from named to the file. BUT anything at
notice or above will be duplicated in the messages file. To stop that,
without killing off of all of the comments from other daemon facilty
users, I believe you'll need to run a filter on the flow to messages.

Have a look again at the syslog.conf and syslog manpage now that you
know that named uses the LOG_DAEMON facility. Good luck. HTH.
-- 
Crist J. Clark                           cjclark@home.com


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




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