From owner-freebsd-current Tue May 2 06:43:34 1995 Return-Path: current-owner Received: (from majordom@localhost) by freefall.cdrom.com (8.6.10/8.6.6) id GAA05330 for current-outgoing; Tue, 2 May 1995 06:43:34 -0700 Received: from gndrsh.aac.dev.com (gndrsh.aac.dev.com [198.145.92.241]) by freefall.cdrom.com (8.6.10/8.6.6) with ESMTP id GAA05323 for ; Tue, 2 May 1995 06:43:26 -0700 Received: (from rgrimes@localhost) by gndrsh.aac.dev.com (8.6.11/8.6.9) id GAA01194; Tue, 2 May 1995 06:39:51 -0700 From: "Rodney W. Grimes" Message-Id: <199505021339.GAA01194@gndrsh.aac.dev.com> Subject: Re: Named in /etc/{rc,sysconfig} and named.restart To: nnd@gw.itfs.nsk.su (Nickolay N. Dudorov) Date: Tue, 2 May 1995 06:39:50 -0700 (PDT) Cc: FreeBSD-current@FreeBSD.org (FreeBSD current) In-Reply-To: <199505021131.SAA10623@gw.itfs.nsk.su> from "Nickolay N. Dudorov" at May 2, 95 06:31:31 pm X-Mailer: ELM [version 2.4 PL24] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Content-Length: 2732 Sender: current-owner@FreeBSD.org Precedence: bulk > > >> /etc/sysconfig says that "for most hosts" > >> named should be started as > >> named -b /etc/namedb/named.boot > >> but scripts such as named.restart provided "for all hosts" > >> restarts named without any args (assuming /etc/named.boot). > >> > >> We'll either modify named sources to look at > >> /etc/namedb/named.boot or modify scripts (named.restart etc), > >> or upgarde to bind.4.9.3-BETA17 and use (modified) ndc.sh > >> for named control. > > > >Here is my current solution to this, it will be commited after > >you review it and tell me that it does just what you want it > >to do. > > Yes, it solves my problem. Great, thanks for testing it for me, I always like to have the original problem reporter check my fix just incase I screwed it up someplace along the road. > > > >It fixes the problem you pointed out, and a few others that > >I found along the way (like errors if no named has ever been > >started). It also will *not* start a named if /etc/sysconfig > >says to not start one, just like /etc/rc :-) > > I can imagine just one situation in wich this > may be not so suitable: > if/when I began to configure 'named' first time > in my life, write/edit my named.boot etc. run named manually, > discover some errors, correct them and try 'named.restart' ;-) > (Yes, I must change named flags in /etc/sysconfig before > starting experiments with named, but we (you?) MUST say > about that in some doc/FAQ ). How about right in the man page for named.restart: Index: named.restart.8 =================================================================== RCS file: /home/ncvs/src/usr.sbin/named/tools/named.restart/named.restart.8,v retrieving revision 1.2 diff -c -r1.2 named.restart.8 *** 1.2 1994/11/19 13:41:26 --- named.restart.8 1995/05/02 13:36:45 *************** *** 59,65 **** named.restart \- stop and restart the name server .SH DESCRIPTION This command sends a \s-1SIGKILL\s+1 to the running name server and then ! starts a new one. .SH BUGS Does not check to see if the name server is actually running, and could use a stale PID cache file which may result in the death of an unrelated --- 59,67 ---- named.restart \- stop and restart the name server .SH DESCRIPTION This command sends a \s-1SIGKILL\s+1 to the running name server and then ! starts a new one if ! .IR /etc/sysconfig ! states that one should be running on this system. .SH BUGS Does not check to see if the name server is actually running, and could use a stale PID cache file which may result in the death of an unrelated -- Rod Grimes rgrimes@gndrsh.aac.dev.com Accurate Automation Company Custom computers for FreeBSD