LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 12-10-2009, 01:45 PM   #1
terrastorm
LQ Newbie
 
Registered: Dec 2009
Location: Texas
Distribution: RHEL
Posts: 5

Rep: Reputation: 0
RHEL5 Bind 9.3.4 slave zones not axfr-ing automatically but manual axfr works fine


I'm having an issue with one of our slave nameservers, for some reason it's not updating any zones automatically. There are 5 servers total, 1 master and 4 slaves(all with identical /etc/named.conf). 3 of these slaves are working correctly but one is giving me problems and I'm not quite sure why. I've been replicating the issue is by restarting the named service on the master which then issues notifies to the slaves servers. On the the working slaves I can tail the log and see that they are getting the notifies to verify everything is up to date.

On the slave with the problem nothing is appended to the log when named on the master is restarted, although if I attempt to do a manual axfr of any zone from dig on the slave it updates fine. Also if I restart the named service on the slave it updates the zone files as well.

Since these servers are all virtualized I was able to make an identical copy of one of the correctly working slaves and replaced the non-working one, this still didn't resolve the issue. Frankly, I'm unsure as to what could be causing it, has anyone experienced something similar to this or possibly have some ideas as to what could be causing it?

I don't think it's a configuration error within bind since 3 other slaves with identical configs are working fine and I can manually update the zone whenever. The following configs have been condensed for simplicity's sake.

Master /etc/named.conf
Code:
acl internals           { 10.0.0.0/24; 10.0.6.0/24; 10.0.7.0/24; 10.0.12.0/24; };
acl slave-internal      { 10.0.6.1; 10.0.6.2; 10.0.0.3; 10.0.0.4; };
acl slave-external      { 12.234.242.197; 12.234.242.198; 74.213.13.115; 74.213.13.116; };
acl master-internal     { 10.0.6.5; };
acl master-external     { 12.234.242.199; };

options
{
        // Put files that named is allowed to write in the data/ directory:
        directory "/var/named";         // the default
        dump-file                       "data/cache_dump.db";
        statistics-file                 "data/named_stats.txt";
        memstatistics-file              "data/named_mem_stats.txt";
};

logging
{
category "default" { "debug"; };
category "general" { "debug"; };
category "database" { "debug"; };
category "security" { "debug"; };
category "config" { "debug"; };
category "resolver" { "debug"; };
category "xfer-in" { "debug"; };
category "xfer-out" { "debug"; };
category "notify" { "debug"; };
category "client" { "debug"; };
category "unmatched" { "debug"; };
category "network" { "debug"; };
category "update" { "debug"; };
category "queries" { "debug"; };
category "dispatch" { "debug"; };
category "dnssec" { "debug"; };
category "lame-servers" { "debug"; };
channel "debug" {
file "data/named.run" versions 2 size 50m;
print-time yes;
print-category yes;
};
};

view "internal"
{
        match-clients { !slave-external; !master-external; internals; };
        recursion yes;
        allow-query { internals; };

        // all views must contain the root hints zone:
        include "/etc/named.root.hints";

//
        zone "0.0.127.in-addr.arpa" in {
                type master;
                file "db.internal.127.0.0";
                allow-transfer { slave-internal; };
        };
//
        zone "0.0.10.in-addr.arpa" in {
                type master;
                file "db.internal.10.0.0";
                allow-transfer { slave-internal; };
        };
//
        zone "1.0.10.in-addr.arpa" in {
                type master;
                file "db.internal.10.0.1";
                allow-transfer { slave-internal; };
        };
//
        zone "2.0.10.in-addr.arpa" in {
                type master;
                file "db.internal.10.0.2";
                allow-transfer { slave-internal; };
        };
//
        zone "example.com" in {
                type master;
                file "db.internal.example.com";
                allow-transfer { slave-internal; };
        };
};

view    "external"
{
        match-clients { !slave-internal; !master-internal; any; };
        recursion no;

         // all views must contain the root hints zone:
        include "/etc/named.root.hints";

//
        zone "example.com" in {
                type master;
                file "db.external.example.com";
                allow-transfer { slave-external; };
        };
};
Slaves /etc/named.conf
Code:
acl internals           { 10.0.0.0/24; 10.0.6.0/24; 10.0.7.0/24; 10.0.12.0/24; };
acl slave-internal      { 10.0.6.1; 10.0.6.2; 10.0.0.3; 10.0.0.4; };
acl slave-external      { 12.234.242.197; 12.234.242.198; 74.213.13.115; 74.213.13.116; };
acl master-internal     { 10.0.6.5; };
acl master-external     { 12.234.242.199; };

options
{
        // Put files that named is allowed to write in the data/ directory:
        directory "/var/named";         // the default
        dump-file                       "data/cache_dump.db";
        statistics-file                 "data/named_stats.txt";
        memstatistics-file              "data/named_mem_stats.txt";
};

logging
{
        channel default_debug {
                file "data/named.run";
                severity dynamic;
        };
};

view "internal"
{
        match-clients { !slave-external; !master-external; internals; };
        recursion yes;
        allow-query { internals; };

        // all views must contain the root hints zone:
        include "/etc/named.root.hints";

//
        zone "0.0.127.in-addr.arpa" in {
                type slave;
                file "slaves/db.internal.127.0.0";
                masters { master-internal; };
        };
//
        zone "0.0.10.in-addr.arpa" in {
                type slave;
                file "slaves/db.internal.10.0.0";
                masters { master-internal; };
        };
//
        zone "1.0.10.in-addr.arpa" in {
                type slave;
                file "slaves/db.internal.10.0.1";
                masters { master-internal; };
        };
//
        zone "2.0.10.in-addr.arpa" in {
                type slave;
                file "slaves/db.internal.10.0.2";
                masters { master-internal; };
        };
//
        zone "example.com" in {
                type slave;
                file "slaves/db.internal.example.com";
                masters { master-internal; };
        };
};

view    "external"
{
        match-clients { !slave-internal; !master-internal; any; };
        recursion no;

         // all views must contain the root hints zone:
        include "/etc/named.root.hints";

//
        zone "example.com" in {
                type slave;
                file "slaves/db.external.example.com";
                masters { master-external; };
        };
};
 
Old 12-10-2009, 02:16 PM   #2
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Make sure that the problematic slave is among the NS records and there is an A record for it. I.e. for example.com:
Code:
...
 NS master.example.com.
 NS slave1.example.com. ; works
 NS slave2.example.com. ; works
 NS slave3.example.com. ; works
 NS slave4.example.com. ; not work

master IN A 1.1.1.1
slave1 IN A 2.2.2.2
slave2 IN A 3.3.3.3
slave3 IN A 4.4.4.4
slave4 IN A 5.5.5.5
...
Regards
 
Old 12-10-2009, 02:31 PM   #3
terrastorm
LQ Newbie
 
Registered: Dec 2009
Location: Texas
Distribution: RHEL
Posts: 5

Original Poster
Rep: Reputation: 0
The nameservers are set like this in all the zone files:

Code:
...
@               IN NS ns1.example.com. ; doesn't work
@               IN NS ns2.example.com. ; works
@               IN NS ns3.example.com. ; works
@               IN NS ns4.example.com. ; works
...
The A records for the name servers are correct and lookup is fine.

Last edited by terrastorm; 12-10-2009 at 02:35 PM.
 
Old 12-10-2009, 05:30 PM   #4
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Are you sure that ns1.example.com is not used in the SOA record of the zone file?
I cannot think for any other reason, as it does not look a firewall problem, since you can do axfr manually.
As a workaround you can use also-notify in master and allow-notify in slave.
 
Old 12-10-2009, 06:56 PM   #5
terrastorm
LQ Newbie
 
Registered: Dec 2009
Location: Texas
Distribution: RHEL
Posts: 5

Original Poster
Rep: Reputation: 0
I believe you've narrowed the problem down! ns1.example.com is set as the SOA because we wanted to hide the master from the outside world.

I guess this poses another question, is it possbile to set ns0.example.com as the SOA and only have ns1, ns2, ns3, and ns4 active as NS in the zone file or will this cause issues?

Thanks for the help!
 
Old 12-11-2009, 12:25 AM   #6
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Hi,

IIRC the name server in the SOA record, must also appear in a NS record.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
how to run "tcpclient and axfr-get" PhillipHuang Linux - Networking 1 07-12-2009 07:52 PM
axfr? axfr-get? treebug Linux - Networking 2 06-29-2009 10:18 AM
Bind doesn't show it's zones? freakin'me Linux - Server 2 03-03-2007 10:28 AM
Tranferring Zones, Master to Slave, DNS - BIND newpylong Linux - Networking 0 09-02-2004 08:01 AM
DNS Slave not getting zones from master tysonh04 Fedora 1 06-06-2004 05:10 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 09:20 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration