Jump to content
shan2batman

error in dns server

Recommended Posts

i'm currently studying DNS and have run in to the following errors in my centos6 VM. this is the tut i'm following [tutorial][1]

 

      [root@server1 named]# sudo service named start
    Starting named:
    Error in named configuration:
    zone example.tv/IN: has no NS records
    zone example.tv/IN: not loaded due to errors.
    _default/example.tv/IN: bad zone
    rev.example.tv:1: unknown RR type '1.168.192.in-addr.arpa.'
    zone 1.168.192.in-addr.arpa/IN: loading from master file rev.example.tv failed: unknown class/type
    zone 1.168.192.in-addr.arpa/IN: not loaded due to errors.
    _default/1.168.192.in-addr.arpa/IN: unknown class/type
    zone localhost.localdomain/IN: loaded serial 0
    zone localhost/IN: loaded serial 0
    zone 1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.ip6.arpa/IN: loaded serial 0
    zone 1.0.0.127.in-addr.arpa/IN: loaded serial 0
    zone 0.in-addr.arpa/IN: loaded serial 0
                                                               [FAILED]
    [root@server1 named]#


here is my fwd.example.tv file:

    

    $ORIGIN example.tv.
    $TTL 86400
    @       IN SOA server1.example.tv. root.example.tv. (
            2018021011;serial
    3600; refresh
    1800;retry
    604800; expire
    86400;min TTL
    )
    @IN     NS      server1.example.tv.
    @IN     NS      server2.example.tv.
    server1         IN      A       192.168.1.17
    server2         IN      A       192.168.1.20
    
    ~

    ~


here is my rev.example.tv file:
 

    
    @ORIGIN 1.168.192.in-addr.arpa.
    $TTL 86400
    @       IN      SOA     server1.example.tv.     root.example.tv.(
    2018021011; serial
    3600; refresh
    1800;retry
    604800; expire
    86400; minimum TTL
    )
    
    
    
    @IN NS server1.example.tv.
    @IN NS server2.example.tv.
    server1 A 192.168.1.17
    server2 A 192.168.1.20
    17 IN PTR server1.example.tv.
    20 IN PTR server2.example.tv.
    ~

    ~


here is my /etc/named.conf file:


 

  options {
           listen-on port 53 { 127.0.0.1; 192.168.1.17; };
            listen-on-v6 port 53 { ::1; };
            directory       "/var/named";
            dump-file       "/var/named/data/cache_dump.db";
            statistics-file "/var/named/data/named_stats.txt";
            memstatistics-file "/var/named/data/named_mem_stats.txt";
            allow-query     { localhost; 192.168.1.0/24; };
            allow-transfer {localhost; 192.168.1.20; };
            recursion yes;
    
            dnssec-enable yes;
            dnssec-validation yes;
            dnssec-lookaside auto;
            /* Path to ISC DLV key */
            bindkeys-file "/etc/named.iscdlv.key";
    
            managed-keys-directory "/var/named/dynamic";
    };
    
    logging {
            channel default_debug {
                    file "data/named.run";
                    severity dynamic;
            };
    };
    zone "." IN {
            type hint;
            file "named.ca";
    };
    
    
    
    
    zone "example.tv" IN{
            type master;
    
    file "fwd.example.tv";
    allow-update {none;};
    };
    
    zone "1.168.192.in-addr.arpa" IN{
    type master;
    file "rev.example.tv";
    allow-update{none;};
    };
    
    include "/etc/named.rfc1912.zones";
    include "/etc/named.root.key";


  

Share this post


Link to post
Share on other sites

Here's one of mine:

 

$ttl 38400
example.com.             IN      SOA     bsd.example.com. example.example.com. (
                                2016040801
                                10800
                                3600
                                604800
                                38400 )
example.com.             IN      NS      bsd.example.com.
example.com.             IN      NS      ns.someothersite.com.
bsd.example.com.         IN      A       11.22.33.44
www.example.com.         IN      A       11.22.33.44
mail.example.com.        IN      A       11.22.33.44
example.com.             IN      A       11.22.33.44
example.com.             IN      MX      5 bsd.example.com.
example.com.             IN      MX      10 mail.example.com.
example.com.             IN      MX      20 dallas.someothersite.com.
beal.example.com.        IN      A       11.22.33.44
ns2.example.com.         IN      A       44.33.22.11
example.com.             IN      TXT     "v=spf1 mx -all"
I've never seen nor used @IN before (and without a FQDN first) ... do you have a reference for that? (Your link seems to have disappeared if it was ever there). Edited by dalecosp

Share this post


Link to post
Share on other sites

@ refers to the zone origin, @IN is an error, there should be space between them.

    @    IN     NS      server1.example.tv.
    @    IN     NS      server2.example.tv.
  • Like 1

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.