From owner-freebsd-questions@FreeBSD.ORG Sat Dec 1 12:08:41 2007 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D737516A417 for ; Sat, 1 Dec 2007 12:08:41 +0000 (UTC) (envelope-from freebsd@superhero.nl) Received: from superman.superhero.nl (superhero.nl [82.95.198.17]) by mx1.freebsd.org (Postfix) with ESMTP id 5067613C448 for ; Sat, 1 Dec 2007 12:08:41 +0000 (UTC) (envelope-from freebsd@superhero.nl) Received: (qmail 69206 invoked by uid 80); 1 Dec 2007 12:08:26 -0000 Received: from robin.ad.superhero.nl ([10.202.77.103]) (SquirrelMail authenticated user gelsemap) by webmail.superhero.nl with HTTP; Sat, 1 Dec 2007 13:08:26 +0100 (CET) Message-ID: <1774.10.202.77.103.1196510906.squirrel@webmail.superhero.nl> In-Reply-To: <226ae0c60711301111n39912b36qab8f79a9a38a7bfe@mail.gmail.com> References: <226ae0c60711301111n39912b36qab8f79a9a38a7bfe@mail.gmail.com> Date: Sat, 1 Dec 2007 13:08:26 +0100 (CET) From: "Gelsema, P \(Patrick\) - FreeBSD" To: "David Robillard" User-Agent: SquirrelMail/1.4.8 MIME-Version: 1.0 Content-Type: text/plain;charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Priority: 3 (Normal) Importance: Normal Cc: freebsd@superhero.nl, FreeBSD Questions Subject: Re: named.conf - unable to set control bit X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 01 Dec 2007 12:08:41 -0000 On Fri, November 30, 2007 20:11, David Robillard wrote: >>Hi list, >> >>I have got the following issue. I have added the following settings in >>named.conf but am unable to get it working. If I read the man page it >>seems that what I have put in is completely correct. >> >>REason to put it in is that I want the DHCP server to automatically >> update >>the DNS zone. >> >>the error I get is: >> >>Nov 30 14:09:31 hulk named[6848]: reloading configuration failed: failure >>Nov 30 14:09:45 hulk named[6848]: /etc/namedb/named.conf:20: expected >>'allow' near ';' >>Nov 30 14:09:45 hulk named[6848]: reloading configuration failed: >>unexpected token >> >>head -n 25 /etc/named/named.conf >># generated with dnssec-keygen -a HMAC-MD5 -b 128 -n USER DHCP_UPDATER >>key DHCP_UPDATER { >> algorithm HMAC-MD5.SIG-ALG.REG.INT; >> secret hashedstring==; >> }; >> >>acl "home" {10.202.77.0/24;127.0.0.1;}; >> >>options { >> // Relative to the chroot directory, if any >> directory "/etc/namedb"; >> pid-file "/var/run/named/pid"; >> dump-file "/var/dump/named_dump.db"; >> statistics-file "/var/stats/named.stats"; >> allow-query {"home"; }; >> >>}; >> >>controls { >> inet 127.0.0.1 port 953; >>allow { 127.0.0.1;10.202.77.110; } keys { "DHCP_UPDATER"; }; >>}; >> >>Line 20 is where controls start. >> >>Any help much appreciated. >> >>rgds, >> >>Patrick > > Patrick, > > When you update your named.conf file, make sure you run a syntax check > before (re)starting named. Here's how you do it: > > named-checkconf /path/to/your/named.conf && echo $? Thanks for the command. > > If echo returns zero, then you're good to go. Otherwise, fix whatever > problem is displayed. > > In your case, you need to remove one semi-colomn (";") to fix your > problem. Here's what your control statement should look like: > > controls { > inet 127.0.0.1 port 953 allow { 127.0.0.1;10.202.77.110; } > keys { "DHCP_UPDATER"; }; > }; > Ok. I was in the impression that the inet line had to be a seperate line. Changing it on one line and removing the ; solved it for me. Thanks > Cheers, > > David > -- > David Robillard > UNIX systems administrator & Oracle DBA > CISSP, RHCE & Sun Certified Security Administrator > Montreal: +1 514 966 0122 >