Changes

Jump to navigation Jump to search
2,183 bytes added ,  07:54, 5 February 2019
no edit summary
Line 69: Line 69:  
11      IN      PTR    wiki.rra.lan.
 
11      IN      PTR    wiki.rra.lan.
 
</nowiki>
 
</nowiki>
 +
 +
== Log to /var/log ==
 +
/etc/bind/named.conf.local
 +
<nowiki>//
 +
// Do any local configuration here
 +
//
 +
 +
// Consider adding the 1918 zones here, if they are not used in your
 +
// organization
 +
//include "/etc/bind/zones.rfc1918";
 +
 +
include "/etc/bind/named.conf.log";</nowiki>
 +
/etc/bind/named.conf.log
 +
<nowiki>logging {
 +
  channel bind_log {
 +
    file "/var/log/bind/bind.log" versions 3 size 5m;
 +
    severity info;
 +
    print-category yes;
 +
    print-severity yes;
 +
    print-time yes;
 +
  };
 +
  category default { bind_log; };
 +
  category update { bind_log; };
 +
  category update-security { bind_log; };
 +
  category security { bind_log; };
 +
  category queries { bind_log; };
 +
  category lame-servers { null; };
 +
};</nowiki>
 +
 +
<source lang=bash>sudo mkdir /var/log/bind
 +
sudo chown bind:bind /var/log/bind
 +
sudo systemctl restart bind9</source>
    
== Allow remote access ==
 
== Allow remote access ==
Line 88: Line 120:  
};
 
};
 
...</nowiki>
 
...</nowiki>
 +
 +
== Forwarding ==
 +
* Edit /etc/bind/named.conf.default-zones
 +
* Add
 +
<nowiki>// prime the server with knowledge of the root servers
 +
zone "." {
 +
        type hint;
 +
        file "/usr/share/dns/root.hints";
 +
};
 +
 +
// be authoritative for the localhost forward and reverse zones, and for
 +
// broadcast zones as per RFC 1912
 +
 +
zone "localhost" {
 +
        type master;
 +
        file "/etc/bind/db.local";
 +
};
 +
 +
zone "127.in-addr.arpa" {
 +
        type master;
 +
        file "/etc/bind/db.127";
 +
};
 +
 +
zone "0.in-addr.arpa" {
 +
        type master;
 +
        file "/etc/bind/db.0";
 +
};
 +
 +
zone "255.in-addr.arpa" {
 +
        type master;
 +
        file "/etc/bind/db.255";
 +
};
 +
 +
zone "igrupobbva" {
 +
    type forward;
 +
    forward only;
 +
    forwarders {
 +
        22.0.0.1;
 +
    };
 +
};
 +
 +
zone "grupobbva.com" {
 +
    type forward;
 +
    forward only;
 +
    forwarders {
 +
        8.8.8.8;
 +
    };
 +
};
 +
 +
zone "interno.grupobbva.com" {
 +
    type forward;
 +
    forward only;
 +
    forwarders {
 +
        22.0.0.1;
 +
    };
 +
};
 +
 +
zone "ad.bbva.com" {
 +
    type forward;
 +
    forward only;
 +
    forwarders {
 +
        22.0.0.1;
 +
    };
 +
};
 +
 +
zone "rra.lan" {
 +
    type forward;
 +
    forward only;
 +
    forwarders {
 +
        10.0.232.30;
 +
    };
 +
};</nowiki>
 +
[https://www.digitalocean.com/community/tutorials/how-to-configure-bind-as-a-caching-or-forwarding-dns-server-on-ubuntu-14-04 How To Configure Bind as a Caching or Forwarding DNS Server]

Navigation menu