RE: Nameserver

From: Cowles, Steve (steve_at_stevecowles.com)
Date: 03/08/04

  • Next message: Robert Canary: "Re: cron.daily script is failing"
    To: "'redhat-list@redhat.com'" <redhat-list@redhat.com>
    Date: Sun, 7 Mar 2004 18:19:48 -0600
    
    

    Alejandro Calbazana wrote:
    > Thanks! I was able to get things set up and working so far
    > as I can tell. I spent some time with the HOW TO along w/
    > your docs.
    >
    > I set up 2 zones. The local zone and the zone for my
    > internal network.

    Did you also setup your reverse zone? i.e. in-addr.arpa zone.

    > After adding the proper hosts and NS entries, everything else
    > fell into place.
    >
    > A few questions remain though... If I am running a nameserver locally,
    > does resolv.conf become irrelevant on the machine running named?

    No! The system running named still needs to resolve addresses. On the system
    I run named on, I edit resolv.conf and point it to localhost.
     
    > Since this machine is also my gateway to the Internet, do I
    > still need to specify entries in /etc/resolv.conf for external
    > names or can I point it to itself?

    If your named.conf file is loading the root hints file, then your name
    server will be able to resolve both locally defined zones and all external
    requests without using your ISP's name server.

    If your still wanting to use your ISP's name server for address resolution
    outside your name space, then look at adding the "forwarders" and "forward
    only" statements to your named.conf file. See "man named.conf"

    > (I know I must do this on the client end, but what about the
    > server end)? Still fuzzy on this one... Also, how do things
    > work if the host entry in the zone file has a dynamic IP (not
    > likely, just curious how this works out...)?

    If your running dhcpd on your LAN behind your firewall, then one option
    would be to enable DDNS. You would need to enable DDNS in both dhcpd and
    named. See "man dhcpd.conf" for a good example on how to enable DDNS. Search
    for DYNAMIC DNS.

    Another option is to configure dhcpd to hand out static IP addresses for the
    MAC addresses you define. Then add these hosts to your zones files. Ex:
    cut/paste from my dhcpd.conf

    host enterprise {
            
       hardware ethernet 00:0d:a1:b2:8f:a4;
       fixed-address 192.168.9.21;
       ddns-hostname enterprise;
       ddns-rev-domainname "21.9.168.192";
    }

    ...and even another option (without enabling DDNS) is to have bind/named
    generate a range of names in your zone files. Ex:

    ; Assign DHCP address range
    $GENERATE 25-254 dhcp-8-$ A 192.168.8.$

    ; Assign Auto-Generated DHCP reverse address ranges. If your
    ; using DDNS, you will need to comment these.
    $GENERATE 25-254 $ PTR dhcp-8-$.mydomain.tld.

    >
    > Some security questions immediately come to mind as I type :)
    > I am wondering how I can block external traffic using my
    > machine as a resolver. I suppose I can control this through
    > iptables, but I was wondering if named provided anything
    > special for this. No big deal... I'll research this one
    > later...

    Again, read "man named.conf". In particular the "allow-query" and "recursion
    on/off" statements. FWIW: I define an ACL for my LAN's and then reference
    them in the allow-query. Ex:

    acl "trusted-nets" {
            192.168.8.0/22;
            127.0.0.1;
    };

    options {

            // Listen ONLY on the following interfaces
            listen-on { 127.0.0.1 ; 192.168.8.2; };

            allow-query {
                    trusted-nets;
            };
    };

    Also, since your running a caching-only name server, stopping inbound TCP
    and UDP port 53 requests at your firewall will insure no one will use your
    system as their DNS server.

    BTW: There is a great template you can use to secure bind. This is what I
    started from. Checkout:

    http://www.cymru.com/Documents/secure-bind-template.html

    Steve Cowles

    -- 
    redhat-list mailing list
    unsubscribe mailto:redhat-list-request@redhat.com?subject=unsubscribe
    https://www.redhat.com/mailman/listinfo/redhat-list
    

  • Next message: Robert Canary: "Re: cron.daily script is failing"

    Relevant Pages

    • Re: The DNS server could not find or open zone file dns
      ... the server ran out of hard drive space showing only ... The DNS server could not find or open zone file ... Verify that the zone file is located in this directory and that it ...
      (microsoft.public.win2000.dns)
    • Re: view function of bind 9
      ... Transfer Master Internal Zone file to Salve Internal Zone. ... And you can't have a slave server without ...
      (Fedora)
    • Re: named / bind problem
      ... notify msgs are sent when a zone the server is authoritative for ... So check that u have more than one NS rec in ur zone file ...
      (Fedora)
    • RE: exchange server cannot mount mailbox store
      ... What's the exact detailed DNS Events ... Type desired internal IP address of your SBS server. ... it will delete the reverse lookup zone if the zone no longer ... Microsoft CSS Online Newsgroup Support ...
      (microsoft.public.windows.server.sbs)
    • Re: Simple DNS For Private LAN -- SOLVED
      ... I used your examples and the "view" statement mentioned my Mathew Seaman to build a BIND 9 DNS server that is authoritative for mykitchentable.net. ... a local "master zone" visible only to my private LAN as you describe ... internal home network. ... which points to the root DNS servers. ...
      (freebsd-questions)