BIND Problems with connection refused

5,305

OK so the answer is simple: When using the host command with the -l option you do not use a host name as the parameter. You use a fully qualified domain name and then it returns all of the hosts. Once I entered the command as follows, everything worked as expected:

host -l mycity.example.com

server1.mycity.example.com
server2.mycity.example.com
Share:
5,305

Related videos on Youtube

Peter S
Author by

Peter S

Updated on September 18, 2022

Comments

  • Peter S
    Peter S over 1 year
    host -l mycity.example.com
    ;; Connection to 10.0.1.12#53(10.0.1.12) for mycity.example.com failed: connection refused.
    

    Here is my named.conf.options file:

    acl "trusted" {
        10.0.1.0/16; 
        localhost;
        localnets;
    };
    
    options {
        directory "/var/cache/bind";
    
        recursion yes;
        allow-recursion { trusted; };
        allow-query { any; }
        allow-query-cache { trusted; }
        listen-on { 10.0.1.12; };
        allow-transfer {trusted; };
    
    // If there is a firewall between you and nameservers you want
    // to talk to, you may need to fix the firewall to allow multiple
    // ports to talk.  See http://www.kb.cert.org/vuls/id/800113
    
    // If your ISP provided one or more IP addresses for stable 
    // nameservers, you probably want to use them as forwarders.  
    // Uncomment the following block, and insert the addresses replacing 
    // the all-0's placeholder.
    
    forwarders {    
        10.0.1.1;
        8.8.8.8;
        8.8.4.4;
    };
    
    //========================================================================
    // If BIND logs error messages about the root key being expired,
    // you will need to update your keys.  See https://www.isc.org/bind-keys
    //========================================================================
    dnssec-validation no;
    
    
    auth-nxdomain no;    # conform to RFC1035
    listen-on-v6 { any; };
    };
    

    FYI, only internal servers can get at this nameserver.

    What am I doing wrong?? :(

    More info from Bind9 status:

    Apr 26 00:37:12 myserver1 named[15933]: client 10.0.1.12#38844
    (myserver2.mycity.example.com): bad zone transfer request:
    'myserver2.mycity.example.com/IN': non-authoritative zone (NOTAUTH)
    
    • Siriss
      Siriss about 7 years
      What were your other files set to?