dns zone transfert

i have two bind server, but the slave cannot get the config form the master

master config
zone "rentsellbuy.com" {
      type master;
      file "/var/lib/bind/rentsellbuy.com.hosts";
      allow-transfer {
            192.168.1.9;
            };
      also-notify {
            192.168.1.9;
            };
      notify yes;
      };

slave config

zone "rentsellbuy.com" {
      type slave;
      masters {
            192.168.1.8;
            };
      file "/var/lib/bind/rentsellbuy.com.hosts";
      allow-update {
            192.168.1.8;
            };
      };

why it doesnt work?
GCI_SUPPORTAsked:
Who is Participating?
 
PapertripCommented:
OK that is what I was expecting to see -- basically you are configuring RNDC twice, once in named.conf and again from /etc/bind.

I suggest moving /etc/bind/rndc.* to /tmp and then restarting BIND, after that run "rndc status" again and see if the warning message pops again or not.
0
 
LinuxNinjaCommented:
My first thought would be to check the ownership/permissions on the /var/lib/bind/rentsellbuy.com.hosts file on the slave. Be sure the UID of the BIND process has rights to write to this file.
0
 
rabbid_dogCommented:
To help diagnose the problem try
dig axfr rentsellbuy.com @192.168.1.8
Do that from 192.168.1.9 to check if the server is actually allowing the transfer.
If it is then you know to focus your troubleshooting on 192.168.1.9.

Let us know what happens.
0
How do you know if your security is working?

Protecting your business doesn’t have to mean sifting through endless alerts and notifications. With WatchGuard Total Security Suite, you can feel confident that your business is secure, meaning you can get back to the things that have been sitting on your to-do list.

 
GCI_SUPPORTAuthor Commented:
the dig return all the record in the dns with no error
0
 
GCI_SUPPORTAuthor Commented:
here what i get for a specific domain
Testing transfer of slave zone from 192.168.1.8 ..
.. from 192.168.1.8 : Failed : ; <<>> DiG 9.7.3 <<>> IN AXFR gcilogistic.net @192.168.1.8 ;; global options: +cmd ; Transfer failed.
0
 
GCI_SUPPORTAuthor Commented:
ok everything is fixed exept one

i get this error on the apply zone

NDC command failed : WARNING: key file (/etc/bind/rndc.key) exists, but using default configuration file (/etc/bind/rndc.conf) rndc: 'reload' failed: bad zone
0
 
PapertripCommented:
What exactly did you type to get that last error?
0
 
GCI_SUPPORTAuthor Commented:
i did the apply zone in webmin
0
 
PapertripCommented:
I'm not familiar with webmin, do you see any errors in the messages file (or custom BIND logs) from running that command?  What happens when you restart BIND?  Do you have rndc.key and the config options in named.conf AND in /etc/bind/ ?  What does the command 'rndc status' give back?
0
 
GCI_SUPPORTAuthor Commented:
im not familiar to with manual command, it just start to learn linux
so can you help me about what to type

thanks
0
 
PapertripCommented:
First just type the following
rndc status

Open in new window


Pasting your named.conf and any files that may be included is always a good thing to do to help us find the correct answers to your questions.
0
 
GCI_SUPPORTAuthor Commented:
WARNING: key file (/etc/bind/rndc.key) exists, but using default configuration f                                                        ile (/etc/bind/rndc.conf)
version: 9.7.3
CPUs found: 1
The program 'worker' is currently not installed.  You can install it by typing:
apt-get install worker
root@ubuntudns1:~# number of zones: 25
worker threads: 1
number of zones: 25
debug level: 0
xfers running: 0
xfers deferred: 0
soa queries in progress: 0
query logging is OFF
recursive clients: 0/0/1000
0
 
GCI_SUPPORTAuthor Commented:
here the named.conf

// This is the primary configuration file for the BIND DNS server named.
//
// Please read /usr/share/doc/bind9/README.Debian.gz for information on the
// structure of BIND configuration files in Debian, *BEFORE* you customize
// this configuration file.
//
// If you are just adding zones, please do that in /etc/bind/named.conf.local

include "/etc/bind/named.conf.options";
include "/etc/bind/named.conf.local";
include "/etc/bind/named.conf.default-zones";
key rndc-key {
      algorithm hmac-md5;
      secret "W6hWYcEuqpoWMUsM4rIKbQ==";
      };
controls {
      inet 127.0.0.1 port 953 allow { 127.0.0.1; } keys { rndc-key; };
      };
server 192.168.1.9 {
      };
0
 
GCI_SUPPORTAuthor Commented:
i did what you said and i got this error message

NDC command failed : rndc: neither /etc/bind/rndc.conf nor /etc/bind/rndc.key was found
0
 
rabbid_dogCommented:
Best to just move them back and remove

key rndc-key {
      algorithm hmac-md5;
      secret "W6hWYcEuqpoWMUsM4rIKbQ==";
      };

From your named.conf file.

 If you want to use that secret for some reason then edit your  /etc/bind/rndc.conf or /etc/bind/rndc.key  file.
0
 
GCI_SUPPORTAuthor Commented:
if i do that, when i start bind it fail
there is log somewhere
0
 
GCI_SUPPORTAuthor Commented:
found the error have to remove keys { rndc-key; };


controls {
      inet 127.0.0.1 port 953 allow { 127.0.0.1; } keys { rndc-key; };
      };

but now i get this error

NDC command failed : WARNING: key file (/etc/bind/rndc.key) exists, but using default configuration file (/etc/bind/rndc.conf) rndc: connection to remote host closed This may indicate that * the remote server is using an older version of the command protocol, * this host is not authorized to connect, * the clocks are not synchronized, or * the key is invalid.
0
 
GCI_SUPPORTAuthor Commented:
ok some modification has been made

now i got this message
NDC command failed : rndc: connect failed: 127.0.0.1#953: connection refused
0
 
GCI_SUPPORTAuthor Commented:
ok this also has been fix but now when i do named check conf

/var/lib/bind/rentsellbuy.com.hosts:3: ignoring out-of-zone data (192.168.1.8)
/var/lib/bind/gcilogistics.net.hosts:3: ignoring out-of-zone data (ns1.gcilogistic.com)
/var/lib/bind/gcilogistics.net.hosts:4: ignoring out-of-zone data (ns2.gcilogistic.com)
/var/lib/bind/goudreau-cargo.com.hosts:3: ignoring out-of-zone data (ns1.gcilogistic.com)
/var/lib/bind/goudreau-cargo.com.hosts:4: ignoring out-of-zone data (ns2.gcilogistic.com)
/var/lib/bind/gcilogistic.net.hosts:3: ignoring out-of-zone data (ns1.gcilogistic.com)
/var/lib/bind/gcilogistic.net.hosts:4: ignoring out-of-zone data (ns2.gcilogistic.com)
/var/lib/bind/gcilogistique.com.hosts:3: ignoring out-of-zone data (ns1.gcilogistic.com)
/var/lib/bind/gcilogistique.com.hosts:4: ignoring out-of-zone data (ns2.gcilogistic.com)
/var/lib/bind/infosb.ca.hosts:19: ignoring out-of-zone data (ns1.gcilogistic.com)
/var/lib/bind/infosb.ca.hosts:20: ignoring out-of-zone data (ns2.gcilogistic.com)
/var/lib/bind/gcilogistic.com.hosts:15: html_webservice.gcilogistic.com: bad owner name (check-names)
zone gcilogistic.com/IN: loading from master file /var/lib/bind/gcilogistic.com.hosts failed: bad owner name (check-names)
zone gcilogistic.com/IN: not loaded due to errors.
_default/gcilogistic.com/IN: bad owner name (check-names)
0
 
GCI_SUPPORTAuthor Commented:
ok forget about my question, everything has been solved

the reason is inside my gcilogistic.com i had a A record with a underscore

removing that has corrected the problem
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.