From owner-freebsd-questions@FreeBSD.ORG Mon Mar 28 04:54:11 2011 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 48A04106564A for ; Mon, 28 Mar 2011 04:54:11 +0000 (UTC) (envelope-from bonomi@mail.r-bonomi.com) Received: from mail.r-bonomi.com (mx-out.r-bonomi.com [204.87.227.120]) by mx1.freebsd.org (Postfix) with ESMTP id 0B68B8FC13 for ; Mon, 28 Mar 2011 04:54:10 +0000 (UTC) Received: (from bonomi@localhost) by mail.r-bonomi.com (8.14.4/rdb1) id p2S56S5i052834; Mon, 28 Mar 2011 00:06:28 -0500 (CDT) Date: Mon, 28 Mar 2011 00:06:28 -0500 (CDT) From: Robert Bonomi Message-Id: <201103280506.p2S56S5i052834@mail.r-bonomi.com> To: bluethundr@gmail.com, freebsd-questions@freebsd.org In-Reply-To: Cc: Subject: Re: reverse dns in bind9 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: Mon, 28 Mar 2011 04:54:11 -0000 > Date: Mon, 28 Mar 2011 00:19:26 -0400 > From: Tim Dunphy > Subject: reverse dns in bind9 > > Hello, > > I am attempting to setup reverse dns in bind 9 under freebsd... this is > in an attempt to allow mysql to work a little easier with DNS > resolution. > > In my /etc/named/named.conf file I have the following: > > // RFC 1912 > zone "localhost" { type master; file "master/localhost-forward.db"; }; > zone "127.in-addr.arpa" { type master; ile "master/localhost-reverse.db"; }; > zone "255.in-addr.arpa" { type master; file "master/empty.db"; }; > zone "192.in-addr.arpa" { type master; file "master/summitjnhome-reverse.db"; }; > zone "summitnjhome.com" { type master; file "master/summitnjhome.db"; }; > > > My master/summitnjhome.com looks like the following: For starters, this should be in "master/summitnjhome-reerse.db" > > $TTL 3D > @ IN SOA ns1.summitnjhome.com. bluethundr.gmail.com. ( > 201103271 ; Serial, todays date + todays serial > 8H ; Refresh > 2H ; Retry > 4W ; Expire > 1D) ; Minimum TTL > NS ns1.summitnjhome.com. > > summitnjhome.com. > 42 PTR LCENT01.summitnjhome.com. > 43 PTR LCENT02.summitnjhome.com. > 44 PTR LBSD2.summitnjhome.com. > 45 PTR LCENT02.summitnjhome.com. > 46 PTR LCENT03.summitnjhome.com. > 47 PTR LCENT04.summitnjhome.com. > 23 PTR virtcent01.summitnjhome.com. > 24 PTR virtcent02.summitnjhome.com. > 21 PTR virtcent03.summitnjhome.com. > 26 PTR virtcent04.summitnjhome.com. > 27 PTR virtcent05.summitnjhome.com. > 28 PTR virtcent06.summitnjhome.com. > 29 PTR virtcent07.summitnjhome.com. > 30 PTR virtcent08.summitnjhome.com. > 31 PTR virtcent09.summitnjhome.com. > 32 PTR virtcent10.summitnjhome.com. > 33 PTR virtcent11.summitnjhome.com. > 34 PTR virtcent12.summitnjhome.com. > 35 PTR virtcent13.summitnjhome.com. > 36 PTR virtcent14.summitnjhome.com. > 37 PTR virtcent15.summitnjhome.com. > 38 PTR virtcent16.summitnjhome.com. > 39 PTR virtcent17.summitnjhome.com. > 40 PTR virtcent18.summitnjhome.com. > 41 PTR virtcent19.summitnjhome.com. > > > and my /etc/resolv.conf looks like this: > > domain summitnjhome.com > nameserver 192.168.1.44 > nameserver 4.2.2.2 > > zone "1.168.192.in-addr.arpa" { type master; file > "/etc/named/master/summitnjhome-reverse.db" > }; the 'zone' line you show should *NOT* be in resolv.conf at all. this line should be in the named.conf file *instead* of the one for the '192.in-addr.arpa' zone. > then I restart both named and the network service > > and yet if I were to try forward resolution: > > LBSD2# host sum1 > sum1.summitnjhome.com is an alias for LCENT01.summitnjhome.com. > LCENT01.summitnjhome.com has address 192.168.1.42 > > > and then reverse resolution: > > LBSD2# host 192.168.1.42 > Host 42.1.168.192.in-addr.arpa. not found: 3(NXDOMAIN) > > I have no luck. Any thoughts on this? see above.