LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
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 04-16-2013, 05:37 AM   #1
nas123
LQ Newbie
 
Registered: May 2012
Posts: 29

Rep: Reputation: Disabled
Migrate/Copy DNS server to a new Centos Box


Hi Friends,

I have been running into some issues

Currently we have a internal DNS server which contains detail of local area machine - it has no issues and is working well.

it lives on a centos vm runnind bind-chroot

question.

i have created a new centos box and installed bind-chroot

i want to copy all settings from old server to this new server.

i was thinking of copying across all /var/named*

will this work?

thanks

regards,

Nas
 
Old 04-16-2013, 07:28 AM   #2
TenTenths
Senior Member
 
Registered: Aug 2011
Location: Dublin
Distribution: Centos 5 / 6
Posts: 1,549

Rep: Reputation: 481Reputation: 481Reputation: 481Reputation: 481Reputation: 481
Also check original /etc/named.conf to see if any other config files are referenced.
 
Old 04-16-2013, 10:49 AM   #3
Habitual
Senior Member
 
Registered: Jan 2011
Distribution: Undecided
Posts: 3,566
Blog Entries: 1

Rep: Reputation: Disabled
Quote:
Originally Posted by nas123 View Post
Hi Friends,

I have been running into some issues

Currently we have a internal DNS server which contains detail of local area machine - it has no issues and is working well.

it lives on a centos vm runnind bind-chroot

question.

i have created a new centos box and installed bind-chroot

i want to copy all settings from old server to this new server.

i was thinking of copying across all /var/named*

will this work?

thanks

regards,

Nas
I did exactly this but I used scp from old_dns to new_dns hosts and bounced named.
http://www.linuxquestions.org/questi...os-4175446650/
 
Old 04-17-2013, 09:11 AM   #4
nas123
LQ Newbie
 
Registered: May 2012
Posts: 29

Original Poster
Rep: Reputation: Disabled
Hi sorry for the late reply:
so when you copied across your named directory did you encounter any issues?

regards
 
Old 04-17-2013, 01:18 PM   #5
Habitual
Senior Member
 
Registered: Jan 2011
Distribution: Undecided
Posts: 3,566
Blog Entries: 1

Rep: Reputation: Disabled
0 issues AFAICT.
 
Old 04-18-2013, 10:45 AM   #6
nas123
LQ Newbie
 
Registered: May 2012
Posts: 29

Original Poster
Rep: Reputation: Disabled
Hi,

just to clarfiy what do you mean by Bounced named??

also i am trying to use scp -ar /var/named/ ipaddress:/var/named

but it does not seem to be working correctly:

keep getting the following file being copied 100's of time over:

smp_affinity 100% 0 0.0KB/s 00:00
smp_affinity 100% 0 0.0KB/s 00:00
smp_affinity 100% 0 0.0KB/s 00:00

any ideas??

regards
 
Old 04-18-2013, 01:12 PM   #7
Habitual
Senior Member
 
Registered: Jan 2011
Distribution: Undecided
Posts: 3,566
Blog Entries: 1

Rep: Reputation: Disabled
Quote:
Originally Posted by nas123 View Post
Hi,

just to clarfiy what do you mean by Bounced named??
service named restart

and you are scp'ing incorrectly.

new host:
Code:
cd /var/named 
scp user@Old_IP_Address:/var/named/* .

Last edited by Habitual; 04-18-2013 at 01:15 PM.
 
Old 04-26-2013, 05:38 AM   #8
nas123
LQ Newbie
 
Registered: May 2012
Posts: 29

Original Poster
Rep: Reputation: Disabled
I have did the copy just getting the following error!!!


[root@host data]# service named start
Starting named:
Error in named configuration:
zone 0.0.127.in-addr.arpa/IN: loaded serial 11
zone test.test.com/IN: loaded serial **********
zone 100.100.10.in-addr.arpa/IN: NS 'ns.100.100.10.in-addr.arpa' has no address records (A or AAAA)
zone 100.100.10.in-addr.arpa/IN: not loaded due to errors.
_default/100.100.10.in-addr.arpa/IN: bad zone

any ideas?
 
Old 04-26-2013, 05:49 AM   #9
chrism01
Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.5, Centos 5.10
Posts: 16,311

Rep: Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040
Yep, check the files mentioned .

You can check syntax
Code:
service named configtest
 
Old 04-26-2013, 01:15 PM   #10
bathory
Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 10,951

Rep: Reputation: 1341Reputation: 1341Reputation: 1341Reputation: 1341Reputation: 1341Reputation: 1341Reputation: 1341Reputation: 1341Reputation: 1341Reputation: 1341
Quote:
zone 100.100.10.in-addr.arpa/IN: NS 'ns.100.100.10.in-addr.arpa' has no address records (A or AAAA)
From the above looks like you miss the FQDN of the NS RR in the 100.100.10.in-addr.arpa zone file.
I guess it's something like:
Code:
      NS ns
instead of:
Code:
      NS ns.test.com.
So bind adds the zone name after the hostname, resulting in ns.100.100.10.in-addr.arpa, that of course is not valid and does not have an A (or AAAA) RR

Regards
 
Old 04-29-2013, 04:23 AM   #11
nas123
LQ Newbie
 
Registered: May 2012
Posts: 29

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by bathory View Post
From the above looks like you miss the FQDN of the NS RR in the 100.100.10.in-addr.arpa zone file.
I guess it's something like:
Code:
      NS ns
instead of:
Code:
      NS ns.test.com.
So bind adds the zone name after the hostname, resulting in ns.100.100.10.in-addr.arpa, that of course is not valid and does not have an A (or AAAA) RR

Regards

hi thanks for the reply.

i made the change and now i get no issues - but named service fails on start ???

regards.
 
Old 04-29-2013, 05:49 AM   #12
bathory
Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 10,951

Rep: Reputation: 1341Reputation: 1341Reputation: 1341Reputation: 1341Reputation: 1341Reputation: 1341Reputation: 1341Reputation: 1341Reputation: 1341Reputation: 1341
Quote:
i made the change and now i get no issues - but named service fails on start ???
Any logs?
 
Old 04-29-2013, 06:49 AM   #13
nas123
LQ Newbie
 
Registered: May 2012
Posts: 29

Original Poster
Rep: Reputation: Disabled
Apr 29 19:41:35 ns named[15312]: starting BIND 9.8.2rc1-RedHat-9.8.2-0.17.rc1.el6_4.4 -u named -t /var/named/chroot
Apr 29 19:41:35 ns named[15312]: built with '--build=x86_64-redhat-linux-gnu' '--host=x86_64-redhat-linux-gnu' '--target=x86_64-redhat-linux-gnu' '--program-prefix=' '--prefix=/usr' '--exec-prefix=/usr' '--bindir=/usr/bin' '--sbindir=/usr/sbin' '--sysconfdir=/etc' '--datadir=/usr/share' '--includedir=/usr/include' '--libdir=/usr/lib64' '--libexecdir=/usr/libexec' '--sharedstatedir=/var/lib' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--with-libtool' '--localstatedir=/var' '--enable-threads' '--enable-ipv6' '--with-pic' '--disable-static' '--disable-openssl-version-check' '--with-dlz-ldap=yes' '--with-dlz-postgres=yes' '--with-dlz-mysql=yes' '--with-dlz-filesystem=yes' '--with-gssapi=yes' '--disable-isc-spnego' '--with-docbook-xsl=/usr/share/sgml/docbook/xsl-stylesheets' '--enable-fixed-rrset' 'build_alias=x86_64-redhat-linux-gnu' 'host_alias=x86_64-redhat-linux-gnu' 'target_alias=x86_64-redhat-linux-gnu' 'CFLAGS= -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic' 'CPPFLAGS= -DDIG_SIGCHASE'
Apr 29 19:41:35 ns named[15312]: ----------------------------------------------------
Apr 29 19:41:35 ns named[15312]: BIND 9 is maintained by Internet Systems Consortium,
Apr 29 19:41:35 ns named[15312]: Inc. (ISC), a non-profit 501(c)(3) public-benefit
Apr 29 19:41:35 ns named[15312]: corporation. Support and training for BIND 9 are
Apr 29 19:41:35 ns named[15312]: available at https://www.isc.org/support
Apr 29 19:41:35 ns named[15312]: ----------------------------------------------------
Apr 29 19:41:35 ns named[15312]: adjusted limit on open files from 4096 to 1048576
Apr 29 19:41:35 ns named[15312]: found 1 CPU, using 1 worker thread
Apr 29 19:41:35 ns named[15312]: using up to 4096 sockets
Apr 29 19:41:35 ns named[15312]: loading configuration from '/etc/named.conf'
Apr 29 19:41:35 ns named[15312]: using default UDP/IPv4 port range: [1024, 65535]
Apr 29 19:41:35 ns named[15312]: using default UDP/IPv6 port range: [1024, 65535]
Apr 29 19:41:35 ns named[15312]: listening on IPv4 interface lo, 127.0.0.1#53
Apr 29 19:41:35 ns named[15312]: listening on IPv4 interface eth0, 10.100.100.100#53
Apr 29 19:41:35 ns named[15312]: generating session key for dynamic DNS
Apr 29 19:41:35 ns named[15312]: sizing zone task pool based on 4 zones
Apr 29 19:41:35 ns named[15312]: could not configure root hints from '/var/named/named.root': permission denied
Apr 29 19:41:35 ns named[15312]: loading configuration: permission denied
Apr 29 19:41:35 ns named[15312]: exiting (due to fatal error)


sorry totally forgot to attach log.

regards
 
Old 04-29-2013, 07:28 AM   #14
chrism01
Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.5, Centos 5.10
Posts: 16,311

Rep: Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040
Code:
Apr 29 19:41:35 ns named[15312]: could not configure root hints from '/var/named/named.root': permission denied
Apr 29 19:41:35 ns named[15312]: loading configuration: permission denied
So, look at ownerships/perms/SELinux to start with.
 
Old 04-29-2013, 08:20 AM   #15
nas123
LQ Newbie
 
Registered: May 2012
Posts: 29

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by chrism01 View Post
Code:
Apr 29 19:41:35 ns named[15312]: could not configure root hints from '/var/named/named.root': permission denied
Apr 29 19:41:35 ns named[15312]: loading configuration: permission denied
So, look at ownerships/perms/SELinux to start with.
Hi

well i have got selinux disabled.

and here is the output of directory

[root@]# pwd
/var/named/chroot/var/named
[root@]# ls -ll
total 40
drwxrwx---. 2 root root 4096 Apr 26 20:00 data
-rw-r-----. 1 root root 198 Apr 22 22:04 localdomain.zone
-rw-r-----. 1 root root 195 Apr 22 22:04 localhost.zone
-rw-r-----. 1 root root 427 Apr 22 22:04 named.broadcast
-rw-r-----. 1 root root 1892 Apr 22 22:04 named.ca
-rw-r-----. 1 root root 424 Apr 22 22:04 named.ip6.local
-rw-r-----. 1 root root 426 Apr 22 22:04 named.local
-rw-r-----. 1 root root 1892 Apr 22 22:04 named.root
-rw-r-----. 1 root root 427 Apr 22 22:04 named.zero
drwxrwx---. 2 root root 4096 Jul 27 2004 slaves
[root@ns named]#
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Migrate DNS Records from Old Server to New Server OThankHeaven Linux - Server 2 11-03-2009 02:23 PM
migrate / transfer / copy unix users from true 64 to CentOS 5.0 ytd Linux - General 2 01-17-2009 10:27 AM
Copy files from server 1 to local box? 2639 Linux - Newbie 4 12-16-2008 09:16 PM
Trying to copy files from a RHL server with puTTY through ssh to my XP box dave247 Linux - Networking 3 05-29-2008 08:45 PM
Migrate my hosted DNS to my RH9 box wazab Linux - Newbie 2 05-09-2004 06:40 AM


All times are GMT -5. The time now is 04:18 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration