Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > ISPConfig 2 > General

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 3rd November 2005, 16:29
_ronnie_ _ronnie_ is offline
Junior Member
 
Join Date: Nov 2005
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default DNS records fail to be created

Hi

I have ISPConfig version 2.0.9 installed on FC4, with a pretty standard installation.

I have previously managed to successfully set up websites using the 'Crete DNS' option. Until today, the sites and the DNS settings have been set up flawlessly.

Since the last sucessful DNS update, I have made 2 changes to the server, which might be of note:-

1. I have disabled IPv6 since it was slowing down DNS resolution.
2. I have updated server packages using yum.

The following packages related to BIND were included in the update:-
bind-utils.i386 24:9.3.1-14_FC4
bind.i386 24:9.3.1-14_FC4
bind-chroot.i386 24:9.3.1-14_FC4

I have done some further digging in the database and in ispconfig.log.

I can confirm that the DNS records added are in that database, with the status flag set as 'n'.

The ispconfig log shows a corresponding 'Signalfile Set: insert' when I add the domain. The site is set up as a vhost in httpd, but there is no reference in the log to ispconfig_bind.lib.php being called.

I am at a loss as to why DNS is not being set up, but the site is. Can anybody shed some light on it?

Thanks in advance
--
Ronnie Davies
Reply With Quote
Sponsored Links
  #2  
Old 3rd November 2005, 16:37
till till is online now
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 36,801
Thanks: 840
Thanked 5,613 Times in 4,424 Posts
Default

Is the status of the DNS record still 'n' after the website was setup? Are the DNS records being written when you change anything in the DNS-Record in DNS-Manager , e.g. the ttl + 1 second, and save it?
Reply With Quote
  #3  
Old 3rd November 2005, 16:46
_ronnie_ _ronnie_ is offline
Junior Member
 
Join Date: Nov 2005
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by till
Is the status of the DNS record still 'n' after the website was setup? Are the DNS records being written when you change anything in the DNS-Record in DNS-Manager , e.g. the ttl + 1 second, and save it?
The DNS record status field remains as 'n' after the website is setup.

If I add an A record to an existing zone, it does not update. If I modify any of the zone header, it does not update the file either (but it does update the DB).

Thanks for your speedy reply!
--
Ronnie
Reply With Quote
  #4  
Old 3rd November 2005, 18:48
_ronnie_ _ronnie_ is offline
Junior Member
 
Join Date: Nov 2005
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Not sure if it helps, but I've gone to line 226 of writeconf.php, which contains the query:-

select dns_isp_dns.doc_id from dns_nodes,dns_isp_dns WHERE dns_nodes.doc_id = dns_isp_dns.doc_id AND dns_nodes.doctype_id = '".$isp_web->dns_doctype_id."' AND dns_isp_dns.status != ''

I have replaced $isp_web->dns_doctype_id with the value listed in the file (1016) and run that query through MySQL. It does return results when I do it manually, meaning that there is either a problem when the query runs in the program or one of the following lines is not working:-

if(!empty($dns_write)){
$bind_restart = 0;
foreach($dns_write as $write){
$doc_id = $write["doc_id"];
$bind_restart += $mod->dns->make_zonefile($doc_id);
$mod->db->query("UPDATE dns_isp_dns SET status = '' where doc_id = '$doc_id'");
}
}

It is not running the query 'UPDATE dns_isp_dns SET status = '' where doc_id = '$doc_id'' as the status is not changing. Therefore, it is likely that if(!empty($dns_write)) is returning false or the foreach loop is not being entered, perhaps because $dns_write is not an array. If the foreach loop was being entered, the status would be reset.

My question, therefore, is whether I could invoke the code manually from the shell and output the query.

Thanks in advance
--
Ronnie
Reply With Quote
  #5  
Old 3rd November 2005, 19:06
till till is online now
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 36,801
Thanks: 840
Thanked 5,613 Times in 4,424 Posts
Default

You can execute the script manually on the shell as root user:

/root/42go/php/php -q /root/ispconfig/scripts/writeconf.php
Reply With Quote
  #6  
Old 3rd November 2005, 19:23
_ronnie_ _ronnie_ is offline
Junior Member
 
Join Date: Nov 2005
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks

I've been having a play and have found that the script is exiting when it comes to setting up the zones with a segfault.

Having looked further, the line it's failing on is in ispconfig_bind.lib.php. The line reads:-

$mod->file->mkdirs($mod->system->server_conf["server_bind_zonefile_dir"]);

When I try to echo the contents of $mod->system->server_conf["server_bind_zonefile_dir"], I get a null result. The server_bind_zonefile_dir value in the isp_server table is empty. Should that be the case?

Kind regards
--
Ronnie
Reply With Quote
  #7  
Old 3rd November 2005, 19:29
till till is online now
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 36,801
Thanks: 840
Thanked 5,613 Times in 4,424 Posts
Default

Quote:
Originally Posted by _ronnie_
When I try to echo the contents of $mod->system->server_conf["server_bind_zonefile_dir"], I get a null result. The server_bind_zonefile_dir value in the isp_server table is empty. Should that be the case?
No. In DEBIAN it is /etc/bind
Check where your zonefiles are and put this directory in the isp_server table (without trailing slash).
Reply With Quote
  #8  
Old 3rd November 2005, 19:53
_ronnie_ _ronnie_ is offline
Junior Member
 
Join Date: Nov 2005
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks

I've now reinstated the BIND zonefile directory in the DB. It is strange that the value got deleted. There is no log of any user apart from the ispconfig user accessing the DB and all access correlates with modification of site values. The only person using the system was a reseller who does not have access to system settings.

On a separate note, one of my resellers has (inadvertently) found another way to break BIND through ispconfig. When entering a new site, if you trail the domain by a period '.', it will not create the primary record and will prevent named from loading.

Kind regards
--
Ronnie
Reply With Quote
  #9  
Old 4th November 2005, 00:35
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,748 Times in 2,579 Posts
Default

Quote:
Originally Posted by _ronnie_
On a separate note, one of my resellers has (inadvertently) found another way to break BIND through ispconfig. When entering a new site, if you trail the domain by a period '.', it will not create the primary record and will prevent named from loading.
We'll check that.
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #10  
Old 2nd December 2007, 12:35
smartcall smartcall is offline
Senior Member
 
Join Date: Nov 2006
Posts: 116
Thanks: 10
Thanked 7 Times in 3 Posts
 
Default I can confirm that both of these bugs still exist in 2.2.18

1. When one tries to change and save Server Settings all is fine, but the Zonefiles Dir field empties. I use FC6 and my path is /var/named/chroot/var/named
I could see /etc/bind in the form field (which is not correct in my case), but the corresponding field in the database is empty and not updating from ISPConfig.
I had to manually enter the correct path into the database field.

2. One of my clients accidentally entered host name with a .(dot), like 'host.', instead of 'host'. It broke named configuration.
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

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 On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Look up DNS records xtothez Technical 3 23rd August 2012 16:04
Deleting DNS master records jernis Installation/Configuration 1 22nd September 2005 13:11
DNS - call script to created named.conf entries on secondaries cstone Installation/Configuration 4 15th September 2005 02:16
More robust default dns records jnoble Feature Requests 0 31st August 2005 19:41
ftp uploads fail ajajaj Installation/Configuration 1 21st August 2005 18:50


All times are GMT +2. The time now is 17:04.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.