epike on Fri, 17 May 2002 17:10:15 +0200


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: [PLUG] dns questions


> 
> No need to worry. Set it up and tell us your woes. I doubt you'll have
> any.
> 


Ok I'm reporting back...I spent 3 hours last nite to learn to write
my own DNS zone.  My woes are basically setting up the config
files (1st time for me) and a lot of minor mistakes in config
(i.e., I'm using the older BIND book, no mention that
$TTL is now required for the zone files...).

I'm also welcome for criticisms, if theres
anything wrong with my setup. If anybody notice anything 
out of place let me know!  Here is how I set up my own local 
dns service:

BASIC ISSUES

1. my domain is xxx.dyndns.org (note, "xxx" is not my real domain name)
2. I'm on comcast cable, so IP is dynamic
3. dyndns.org will not delegate the xxx.dyndns.org zone --- they
   just provide the service to place an "A" record on their dns
   and thats it.  So basically I'm settling with local name
   service only.
4. I have one only 1 ethernet segment (the linksys router and
   a few PC's)..all are on 192.168.1.0/24.

MY SETUP

1. LINUX SERVER (192.168.1.2) - authorative for 192.168.1.0/24, and 
      it can also forward queries to the ISP's name servers ("forward 
      first" option).  So /etc/resolv.conf contains:

           search xxx.dyndns.org
           nameserver 127.0.0.1

2. LINKSYS ROUTER 

      To propagate the DNS I put in the following

           DOMAIN NAME (needed for some ISP's): xxx.dyndns.org
           NAME SERVERS: 192.168.1.2
                         68.80.0.5
                         68.80.0.6

     where 68.80.0.5 & 68.80.0.6 are the ISP's name servers.
     I added them so that if my linux box drops (as it does
     sometimes) the rest of the network can still function.  The
     disadvantage is that I have to watch out for the ISPs dns server
     changes, also if they require the DOMAIN NAME in DHCP then
     I'll have to remove my custom xxx.dyndns.org


3. WINDOWS/LINUX CLIENTS - no change since theyre all DHCP

     They also pick up xxx.dynds.org nicely!  and they do use the
     192.168.1.2 dns server...it works great.  I can actually
     now ping single hosts such as yyy and they map correctly
     to local yyy.xxx.dyndns.org...


-------------actual config----------------------------

/etc/named.conf relevant parts
------------------------------

options {
       // ...... some stuff here
       forward first;
       forwarders { 68.80.0.5; 68.80.0.6; };
       allow-query { localhost; 192.168.1.0/24; };
};
 


zone "xxx.dyndns.org" in {
     type master;
     file "pz/db.xxx";
     allow-update { none; };
};

zone "1.168.192.in-addr.arpa" IN {
     type master;
     file "pz/db.192.168.1";
     allow-update { none; } ;
};

/var/named/pz/db.xxx 
--------------------
$TTL 86400

@ IN SOA ns.xxx.dyndns.org. waver.xxx.dyndns.org. (
                           1         ; serial
                           10800     ; refresh
                           3600     ; retry 
                           604800   ; expire
                           86400   ) ; minimum ttl

  IN NS ns.xxx.dyndns.org.
  IN MX 10 mail.xxx.dyndns.org.

; server

xxx.dyndns.org.     IN A  192.168.1.2
ns                  IN CNAME xxx.dyndns.org.
morpheus            IN CNAME xxx.dyndns.org.
www                 IN CNAME xxx.dyndns.org.
mail                IN CNAME xxx.dyndns.org.

; router

gate                IN A 192.168.1.1

; PCs

local-1-001         IN A 192.168.1.1
local-1-002         IN A 192.168.1.2
local-1-003         IN A 192.168.1.3
...
...
and so on

/var/named/pz/db.192.168.1 relevant parts
-----------------------------------------

;
; name servers

@ IN NS ns.xxx.dyndns.org.

1  IN PTR gate.xxx.dyndns.org.
2  IN PTR xxx.dyndns.org.
3  IN PTR local-1-003.xxx.dyndns.org.
4  IN PTR local-1-004.xxx.dyndns.org.
5  IN PTR local-1-005.xxx.dyndns.org.
...
...and so on





<endofmessage>

______________________________________________________________________
Philadelphia Linux Users Group       -      http://www.phillylinux.org
Announcements-http://lists.phillylinux.org/mail/listinfo/plug-announce
General Discussion  -  http://lists.phillylinux.org/mail/listinfo/plug