CentOS7 - não é possível iniciar o BIND

0

Eu tentei várias vezes, mas ainda não consigo iniciar o BIND depois de adicionar minha primeira zona.

  1. Meu /etc/named.conf se parece com:

    options {
    listen-on port 53 { any; };
    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;172.19.0.0/24; };
    
    recursion no;
    
    dnssec-enable yes;
    dnssec-validation yes;
    
    /* Path to ISC DLV key */
    bindkeys-file "/etc/named.iscdlv.key";
    
    managed-keys-directory "/var/named/dynamic";
    
    pid-file "/run/named/named.pid";
    session-keyfile "/run/named/session.key";
    };
    
    logging {
        channel default_debug {
                file "data/named.run";
                severity dynamic;
            };
    };
    
    zone "." IN {
        type hint;
        file "named.ca";
    };
    
    zone "netlabbuilder.net" IN {
        type master;
        file "netlabbuilder.net.zone";
        allow-update { none; };
    };
    
    include "/etc/named.rfc1912.zones";
    include "/etc/named.root.key";
    

    "systemctl status named" mostra o erro " fim inesperado de entrada " na zona do netlabbuilder.net.

    named.service - Berkeley Internet Name Domain (DNS)
    Loaded: loaded (/usr/lib/systemd/system/named.service; enabled; vendor       preset: disabled)
    Active: failed (Result: exit-code) since Wed 2017-08-09 15:57:05 CEST; 3s  ago
     Process: 15912 ExecStop=/bin/sh -c /usr/sbin/rndc stop > /dev/null 2>&1 || /bin/kill -TERM $MAINPID (code=exited, status=0/SUCCESS)
     Process: 15939 ExecStartPre=/bin/bash -c if [ ! "$DISABLE_ZONE_CHECKING" == "yes" ]; then /usr/sbin/named-checkconf -z /etc/named.conf; else echo "Checking of zone files is disabled"; fi (code=exited, status=1/FAILURE)
    Main PID: 15763 (code=exited, status=0/SUCCESS)
    
    _default/netlabbuilder.net/IN: unexpected end of input
    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....l 0
    zone 1.0.0.127.in-addr.arpa/IN: loaded serial 0
    zone 0.in-addr.arpa/IN: loaded serial 0
    named.service: control process exited, code=exited...s=1
    Failed to start Berkeley Internet Name Domain (DNS).
    Unit named.service entered failed state.
    named.service failed.
    Hint: Some lines were ellipsized, use -l to show in full.
    
  2. Quando eu removo a seção da zona "netlabbuilder.net", ela funciona bem:

    ● named.service - Berkeley Internet Name Domain (DNS)
    Loaded: loaded (/usr/lib/systemd/system/named.service; enabled; vendor preset: disabled)
    Active: active (running) since Wed 2017-08-09 15:50:50 CEST; 7s ago
    Main PID: 15763 (named)
    CGroup: /system.slice/named.service
           └─15763 /usr/sbin/named -u named
    
  3. O netlabbuilder.net.zone definido em / var / named /

    $ORIGIN netlabbuilder.net.
    $TTL 86400
    @   IN  SOA     netlab.netlabbuilder.net. (
            2014071001  ;Serial
            3600        ;Refresh
            1800        ;Retry
            604800      ;Expire
            86400       ;Minimum TTL
    )
    
    @       IN  NS      netlab.netlabbuilder.net.
            IN  A       172.19.0.100
    
    netlab  IN  A       172.19.0.100
    
    r1      IN  A       172.19.0.1
    r2      IN  A       172.19.0.2
    r3      IN  A       172.19.0.3
    r4      IN  A       172.19.0.4
    
por Hung Tran 09.08.2017 / 16:28

0 respostas

Tags