DNS and BIND

Posted by: andym

DNS and BIND - 15/06/2003 12:44

I'm have a FreeBSD box running BIND9 to provide caching internet DNS queries but also to provide DNS for our imaginary internal domain (shocknet.all). Now, I've got the forwarding working so I look for www.bbc.co.uk it resolves correctly as does the reverse. If I do my lookup for andymlaptop.shocknet.all it resolves to 192.168.1.10. Now here's the problem if I try to do a lookup on 192.168.1.10 it fails.........

included here are the configurations files....


================named.conf====================

options
{
directory "/etc/namedb";

listen-on
{
127.0.0.1;
192.168.1.1;
};

//forward only;

forwarders
{
10.0.0.2;
};
};

zone "shocknet.all"
{
type master;
file "shocknet.all";
};

zone "."
{
type hint;
file "named.root";
};

zone "1.168.192.IN_ADDR.ARPA"
{
type master;
file "1.168.192.in_addr.arpa";
};

zone "0.0.127.IN-ADDR.ARPA"
{
type master;
file "localhost.rev";
};


==============shocknet.all====================

$TTL 3600

shocknet.all. IN SOA ns1.shocknet.all. admin.shockradio.co.uk (
1
10800
3600
604800
86400 )

;DNS Servers
@ IN NS ns1.shocknet.all.

;Machine Names

localhost IN A 127.0.0.1
ns1 IN A 192.168.1.1
andymlaptop IN A 192.168.1.10

;Aliases
www IN CNAME @

;MX Record
@ IN MX 10 ns1.shocknet.all.

==============1.168.192.inn_addr.arpa====================

$TTL 3600

@ IN SOA ns1.shocknet.all. admin.shockradio.co.uk (
20030615
3600
900
3600000
3600 )

;DNS Servers
IN NS ns1.shocknet.all.

;Machine Names

1 IN PTR brendan.shocknet.all.
10 IN PTR andymlaptop.shocknet.all.

======================named.root========================

;
; formerly NIC.NORDU.NET
;
;
; $FreeBSD: src/etc/namedb/named.root,v 1.9.2.1 2002/11/06 09:24:12 dougb Exp $
;

; This file holds the information on root name servers needed to
; initialize cache of Internet domain name servers
; (e.g. reference this file in the "cache . <file>"
; configuration file of BIND domain name servers).
;
; This file is made available by InterNIC
; under anonymous FTP as
; file /domain/named.root
; on server FTP.INTERNIC.NET
;
; last update: Nov 5, 2002
; related version of root zone: 2002110501
;
;
; formerly NS.INTERNIC.NET
;
. 3600000 IN NS A.ROOT-SERVERS.NET.
A.ROOT-SERVERS.NET. 3600000 A 198.41.0.4
;
; formerly NS1.ISI.EDU
;
. 3600000 NS B.ROOT-SERVERS.NET.
B.ROOT-SERVERS.NET. 3600000 A 128.9.0.107
;
; formerly C.PSI.NET
;
. 3600000 NS C.ROOT-SERVERS.NET.
C.ROOT-SERVERS.NET. 3600000 A 192.33.4.12
;
; formerly TERP.UMD.EDU
;
. 3600000 NS D.ROOT-SERVERS.NET.
D.ROOT-SERVERS.NET. 3600000 A 128.8.10.90
;
; formerly NS.NASA.GOV
;
. 3600000 NS E.ROOT-SERVERS.NET.
E.ROOT-SERVERS.NET. 3600000 A 192.203.230.10
;
; formerly NS.ISC.ORG
;
. 3600000 NS F.ROOT-SERVERS.NET.
F.ROOT-SERVERS.NET. 3600000 A 192.5.5.241
;
; formerly NS.NIC.DDN.MIL
;
. 3600000 NS G.ROOT-SERVERS.NET.
G.ROOT-SERVERS.NET. 3600000 A 192.112.36.4
;
; formerly AOS.ARL.ARMY.MIL
;
. 3600000 NS H.ROOT-SERVERS.NET.
H.ROOT-SERVERS.NET. 3600000 A 128.63.2.53
;
; formerly NIC.NORDU.NET
;
. 3600000 NS I.ROOT-SERVERS.NET.
I.ROOT-SERVERS.NET. 3600000 A 192.36.148.17
;
; operated by VeriSign, Inc.
;
. 3600000 NS J.ROOT-SERVERS.NET.
J.ROOT-SERVERS.NET. 3600000 A 192.58.128.30
;
; housed in LINX, operated by RIPE NCC
;
. 3600000 NS K.ROOT-SERVERS.NET.
K.ROOT-SERVERS.NET. 3600000 A 193.0.14.129
;
; operated by IANA
;
. 3600000 NS L.ROOT-SERVERS.NET.
L.ROOT-SERVERS.NET. 3600000 A 198.32.64.12
;
; housed in Japan, operated by WIDE
;
. 3600000 NS M.ROOT-SERVERS.NET.
M.ROOT-SERVERS.NET. 3600000 A 202.12.27.33
; End of File
(END)

==========localhost.rev===============


. 3600000 NS I.ROOT-SERVERS.NET.
I.ROOT-SERVERS.NET. 3600000 A 192.36.148.17
;
; operated by VeriSign, Inc.
;
. 3600000 NS J.ROOT-SERVERS.NET.
J.ROOT-SERVERS.NET. 3600000 A 192.58.128.30
;
; housed in LINX, operated by RIPE NCC
;
. 3600000 NS K.ROOT-SERVERS.NET.
K.ROOT-SERVERS.NET. 3600000 A 193.0.14.129
;
; operated by IANA
;
. 3600000 NS L.ROOT-SERVERS.NET.
L.ROOT-SERVERS.NET. 3600000 A 198.32.64.12
;
; housed in Japan, operated by WIDE
;
. 3600000 NS M.ROOT-SERVERS.NET.
M.ROOT-SERVERS.NET. 3600000 A 202.12.27.33
; End of File

================localhost.rev==============================

; From: @(#)localhost.rev 5.1 (Berkeley) 6/30/90
; $FreeBSD: src/etc/namedb/PROTO.localhost.rev,v 1.6 2000/01/10 15:31:40 peter E
xp $
;
; This file is automatically edited by the `make-localhost' script in
; the /etc/namedb directory.
;

$TTL 3600

@ IN SOA brendan.salford.ac.uk. root.brendan.salford.ac.uk. (
20030615 ; Serial
3600 ; Refresh
900 ; Retry
3600000 ; Expire
3600 ) ; Minimum
IN NS brendan.salford.ac.uk.
1 IN PTR localhost.
2 IN PTR monkey.
~
~
~
~
(END)


Any ideas?
Posted by: peter

Re: DNS and BIND - 15/06/2003 12:57

1.168.192.inn_addr.arpa
Is the file really so named, with the extra "n", or is that the typo you're looking for?

Peter
Posted by: andym

Re: DNS and BIND - 15/06/2003 13:03

You're right, I changed it and now it throws up an error when I start the server.
Posted by: genixia

Re: DNS and BIND - 15/06/2003 13:15

Did you change the serial?
Posted by: jimhogan

Re: DNS and BIND - 15/06/2003 22:13

1.168.192.inn_addr.arpa

Is the file really so named, with the extra "n", or is that the typo you're looking for?

The "nn" typo aside, what happens if you replace the underscore with a hyphen? Hmmm, later BIND no worky with underscores in domains, true? (Or so I remembered...I think...)
Posted by: andym

Re: DNS and BIND - 16/06/2003 06:09

I'll have a tweak, a kind soul in my office has lent me a copy of the O'Reilly BIND book so I've got some light bedtime reading tonight! I'll let you know how I get on....
Posted by: andy

Re: DNS and BIND - 16/06/2003 07:23

the O'Reilly BIND book

That should ensure a good night's sleep tonight ;-)
Posted by: andym

Re: DNS and BIND - 19/06/2003 10:15

Well joint first prize went to Peter and Jim, typo with the extra n and the underscore instead of an hyphen It now works a treat, thanks!