From owner-freebsd-isp@FreeBSD.ORG Wed Jul 11 07:04:30 2007 Return-Path: X-Original-To: freebsd-isp@freebsd.org Delivered-To: freebsd-isp@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 9088C16A400 for ; Wed, 11 Jul 2007 07:04:30 +0000 (UTC) (envelope-from dougb@FreeBSD.org) Received: from mail2.fluidhosting.com (mx21.fluidhosting.com [204.14.89.4]) by mx1.freebsd.org (Postfix) with SMTP id 499D313C46A for ; Wed, 11 Jul 2007 07:04:30 +0000 (UTC) (envelope-from dougb@FreeBSD.org) Received: (qmail 4592 invoked by uid 399); 11 Jul 2007 06:37:47 -0000 Received: from localhost (HELO ?192.168.0.6?) (dougb@dougbarton.us@127.0.0.1) by localhost with SMTP; 11 Jul 2007 06:37:47 -0000 X-Originating-IP: 127.0.0.1 Message-ID: <46947AB8.809@FreeBSD.org> Date: Tue, 10 Jul 2007 23:37:44 -0700 From: Doug Barton Organization: http://www.FreeBSD.org/ User-Agent: Thunderbird 2.0.0.4 (Windows/20070604) MIME-Version: 1.0 To: freebsd-isp@freebsd.org References: <410648.39042.qm@web54303.mail.re2.yahoo.com> <20070710174548.GE1810@dwpc.dwlabs.ca> In-Reply-To: <20070710174548.GE1810@dwpc.dwlabs.ca> X-Enigmail-Version: 0.95.2 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: Patrick Dung Subject: Re: FreeBSD 6.2 default bind9, question about customize logging [re-post] X-BeenThere: freebsd-isp@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Internet Services Providers List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 11 Jul 2007 07:04:30 -0000 > On Sunday, 8 July 2007 at 12:06:26 -0700, Patrick Dung wrote: >> I am using FreeBSD 6.2 with the default bind (not ports). >> By default chroot is used. It's not a major issue, but it's probably worth pointing out that whatever code base you use (base or ports) the behavior such as chroot, logging, etc. is controlled by the combination of /etc/rc.d/named and your named.conf options. Therefore this discussion applies equally well either way. >> When named start or stop, it does have log in /var/log/messages. >> But for example, when some do domain transfer successfully, that is not >> logged (zone transfer denied is logged). I have intentionally avoided adding more complex logging to the default named.conf because it's very hard to decide which way to land on this to make the most people happy (and/or the least people mad). I am of course always open to suggestions. :) >> So I tried to add this part in named.conf (enabled local0.* in >> syslog.conf) , but still no luck. Any suggestions? The obvious ones, did you HUP the daemon after you changed the conf, and did you pre-create any new files that syslogd is supposed to write to for the local0 facility? Can you share your syslog.conf line for this? Do you get any joy when you try 'logger -plocal0.info blah' ? >> logging { >> channel named-log { While I don't see that it's explicitly forbidden to use a - in a channel name, every example I've ever seen or used myself uses an underscore instead (named_log). >> //syslog daemon; >> syslog local0; >> severity info; >> print-category yes; >> }; >> category default { named-log; }; >> category xfer-in { named-log; }; >> category xfer-out { named-log; }; >> category unmatched { null; }; >> }; This all looks good (modulo the - issue I mentioned above), and I use something similar myself, so once you're sure you can write to the syslog facility, you should be able to get this to work. I should probably also point out that unless you really need this to go to syslog, you're probably better off writing to a file channel instead (less overhead, especially on a busy server). Either way there is information in the ARM that will help you, /usr/share/doc/bind9/arm. hth, Doug -- This .signature sanitized for your protection