Secondary DNS - named won't restart

Forum for getting help with Project Gamera, Spamassassin, Clamav, qmail-scanner and other anti-spam tools.
phoenixisp
Forum User
Forum User
Posts: 76
Joined: Wed Feb 16, 2005 11:30 am

Secondary DNS - named won't restart

Unread post by phoenixisp »

I have followed the instructions for the automated secondary DNS but have a problem. Step 1 says to add the line

include "secondaries.include";

When I execute gen-secondaries.sh and xfer-config.sh all goes well, but named won't restart. Depending where in named.conf I place the above line I get different errors. If I place it at the end of the file the error is that secondaries.include can't be found. If I place it above the line that includes psaptzone.files, it will process the secondaries.include but says it can't find psaptzone.files and starting named fails due to an error in named.conf

Both Plesk servers are CentOS 4 with Plesk 7.5.4.

Any ideas? Thanks!
Sonny
scott
Atomicorp Staff - Site Admin
Atomicorp Staff - Site Admin
Posts: 8355
Joined: Wed Dec 31, 1969 8:00 pm
Location: earth
Contact:

Unread post by scott »

Take a look at /var/log/messages for output from named on what its looking for. That should point you in the right direction
vakantieman
Forum User
Forum User
Posts: 30
Joined: Mon Jan 03, 2005 6:34 am

Unread post by vakantieman »

I have the same problem. On this secondary server i haven't installed plesk because we wan't only secondary dns on the server.
My named restart says:

Starting named: /etc/named.conf:26: open: /etc/secondaries.include: file not found

Jan 24 11:20:28.223 starting BIND 9.2.4 -g
Jan 24 11:20:28.223 using 1 CPU
Jan 24 11:20:28.229 loading configuration from '/etc/named.conf'
Jan 24 11:20:28.235 listening on IPv4 interface lo, ipadress#53
Jan 24 11:20:28.236 listening on IPv4 interface eth0, ipadress#53
Jan 24 11:20:28.236 listening on IPv4 interface eth1, ipadress#53
Jan 24 11:20:28.248 command channel listening on ipadress#953
Jan 24 11:20:28.249 ignoring config file logging statement due to -g option
Jan 24 11:20:28.249 couldn't open pid file '/var/run/named/named.pid': Permission denied
Jan 24 11:20:28.249 exiting (due to early fatal error)
Error in configuration file /etc/named.conf : [FAILED]

I have tried to give the secondaries.include, gives alles permissions 777. But no luck, I have chown the file to named but no luck.

My options are out, do you have any Idea?
phoenixisp
Forum User
Forum User
Posts: 76
Joined: Wed Feb 16, 2005 11:30 am

Unread post by phoenixisp »

Hi Scott, here's what I get:

When I place include "etc/secondaries.include"; before the psaptzonefiles include line I get:
-----------------------------------------------------------------------------------------
[root@server1 ~]# /etc/init.d/named restart
Stopping named: [ OK ]
Starting named: /etc/named.conf:131: zone 'support.phoenix-inter.net': already exists
/etc/named.conf:142: zone 'access.phoenix-inter.net': already exists
/etc/named.conf:158: zone 'design.phoenix-inter.net': already exists
/etc/named.conf:168: zone 'gordysart.com': already exists
/etc/named.conf:177: zone 'hosting.phoenix-inter.net': already exists
/etc/named.conf:187: zone 'circlebchuckwagon.com': already exists
/etc/named.conf:195: zone 'circle-b-ranch.com': already exists
/etc/named.conf:203: zone 'mckenzie-harrison.com': already exists
/etc/named.conf:211: zone 'gemcuttersguild.com': already exists
/etc/named.conf:219: zone 'baltimoredialup.com': already exists
/etc/named.conf:227: zone 'housingopportunities.com': already exists

Jan 24 06:18:14.245 starting BIND 9.2.4 -g
Jan 24 06:18:14.245 using 1 CPU
Jan 24 06:18:14.257 loading configuration from '/etc/named.conf'
Jan 24 06:18:14.258 /etc/named.conf:128: open: /etc/secondaries.include: file not found
Jan 24 06:18:14.258 loading configuration: file not found
Jan 24 06:18:14.258 exiting (due to fatal error)
Error in configuration file /etc/named.conf : [FAILED]
--------------------------------------------------------------------------------------
If I put the line below the psaptzone.files include I get:
---------------------------------------------------------------------------------------
[root@server1 ~]# /etc/init.d/named restart
Stopping named: [ OK ]
Starting named: /etc/named.conf:129: open: etc/secondaries.include: file not found

Jan 24 06:28:34.632 starting BIND 9.2.4 -g
Jan 24 06:28:34.632 using 1 CPU
Jan 24 06:28:34.645 loading configuration from '/etc/named.conf'
Jan 24 06:28:34.646 /etc/named.conf:128: open: /etc/psaptzone.files: file not found
Jan 24 06:28:34.646 loading configuration: file not found
Jan 24 06:28:34.646 exiting (due to fatal error)
Error in configuration file /etc/named.conf : [FAILED]
---------------------------------------------------------------------------------------

Any ideas? I'm lost.
Sonny
vakantieman
Forum User
Forum User
Posts: 30
Joined: Mon Jan 03, 2005 6:34 am

Unread post by vakantieman »

My problems are solved.
Here are the changes I have made:

the secondaries.include must be in the: /var/named/chroot/etc/ folder
In the named.conf i have set the following entry : include "/etc/secondaries.include";

Now gives named restart no problems. But now you must made a slave folder. I have made my slave folder in te following folder: /var/named/chroot/var/named/, then chown this folder to named-named.

Done for me!
I hope also for you, if you have any problems please post.

Grtz vakantieman
phoenixisp
Forum User
Forum User
Posts: 76
Joined: Wed Feb 16, 2005 11:30 am

Unread post by phoenixisp »

I think my problem is different because it is on a Plesk machine. That's why I seem to have a problem due to the line:

include "/etc/psaptzone.files";

I wonder what type of problems it would cause if I set the DNS on my gamera server.
Sonny
vakantieman
Forum User
Forum User
Posts: 30
Joined: Mon Jan 03, 2005 6:34 am

Unread post by vakantieman »

Well I don't know what that line is doing.
On our Plesk server, the ns1 server we don't have that line.
On the second server we don't have plesk so i can't test what that files is.

I hope someone else can help you

Grtz Vakantieman
phoenixisp
Forum User
Forum User
Posts: 76
Joined: Wed Feb 16, 2005 11:30 am

Unread post by phoenixisp »

Thanks, the strange thing is that psaptzone.files is empty. There's nothing at all in the file.

Hopefully a magic turtle will come through and bail me out. :)
Sonny
scott
Atomicorp Staff - Site Admin
Atomicorp Staff - Site Admin
Posts: 8355
Joined: Wed Dec 31, 1969 8:00 pm
Location: earth
Contact:

Unread post by scott »

Like vakantieman mentioned higher in the thread, you're dealing with a chroot on a PSA box. The path to the include is /etc/<whatever> in the named.conf, but the path in the file system is whatever the chroot is set to, relative to that.
phoenixisp
Forum User
Forum User
Posts: 76
Joined: Wed Feb 16, 2005 11:30 am

Unread post by phoenixisp »

OK Scott, you lost me. How do I get the secondaries.include file in /var/named/chroot/etc? Should that be where I insert the gen-secondaries.sh and xfer-config.sh files? I am not at all up on chroot stuff.
Sonny
vakantieman
Forum User
Forum User
Posts: 30
Joined: Mon Jan 03, 2005 6:34 am

Unread post by vakantieman »

I have edited the xfer-config.sh. The last lines of this file are:

Code: Select all

else
  mv $FILE.tmp /var/named/chroot/etc/$FILE
  chmod 644 /var/named/chroot/etc/$FILE
fi
as you see, you can edit the savepath of the secondaries.include file.

Grtz vakantieman
phoenixisp
Forum User
Forum User
Posts: 76
Joined: Wed Feb 16, 2005 11:30 am

Unread post by phoenixisp »

Thanks vakantieman, your last post helped a lot. I don't know why, but the secondaries.include file was going to /root?? So I directed it to /var/named/run-root/etc/$FILE and now named restarts.

How long before the slave directory starts filling up?
Sonny
phoenixisp
Forum User
Forum User
Posts: 76
Joined: Wed Feb 16, 2005 11:30 am

Unread post by phoenixisp »

OK - I got it working, thanks to vakantieman. One last question.

Why is it that the xxx.xxx.xxx.in-addr.arpa file doesn't get transferred? Is there any way to do it?
Sonny
Post Reply