View Full Version : Nameserver Problem
marm26
10th February 2009, 17:06
Hi guys.
I am trying to add a new domain on my server. I want it to have its own nameserver ns.mydomain.com
I followed the steps outlined here:
http://www.howtoforge.com/ispconfig_dns_godaddy
However I can't get my newly set up nameserver to resolve the domain correctly.
dig @ns1.mydomain.com any mydomain.com
never returns this line:
mydomain.com. 86400 IN SOA ns1.mydomain.com. hostmaster.mydomain.com. 2006060705 28800 7200 604800 86400
So I guess the domain is not properly resolved by my nameserver.
I have read somewhere that ISPConfig only allows two nameservers. Well I got another domain on an add on ip using its own nameservers. Might this be causing the problem?
Any help with this is greatly appreciated.
Thanks in advance.
falko
11th February 2009, 20:07
dig @ns1.mydomain.com any mydomain.com
never returns this line:
mydomain.com. 86400 IN SOA ns1.mydomain.com. hostmaster.mydomain.com. 2006060705 28800 7200 604800 86400
What does it return?
What's in the zone file and in named.conf?
marm26
12th February 2009, 17:19
dig @ns1.mydomain.com any mydomain.com returns the following:
; <<>> DiG 9.3.4-P1 <<>> @ns1.mydomain.com any mydomain.com
; (1 server found)
;; global options: printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 3024
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 13, ADDITIONAL: 0
;; QUESTION SECTION:
;mydomain.com. IN ANY
;; ANSWER SECTION:
mydomain.com. 11893 IN SOA ns51.domaincontrol.com. dns.jomax.net. 2009020600 28800 7200 604800 86400
;; AUTHORITY SECTION:
com. 172570 IN NS I.GTLD-SERVERS.net.
com. 172570 IN NS J.GTLD-SERVERS.net.
com. 172570 IN NS K.GTLD-SERVERS.net.
com. 172570 IN NS L.GTLD-SERVERS.net.
com. 172570 IN NS M.GTLD-SERVERS.net.
com. 172570 IN NS A.GTLD-SERVERS.net.
com. 172570 IN NS B.GTLD-SERVERS.net.
com. 172570 IN NS C.GTLD-SERVERS.net.
com. 172570 IN NS D.GTLD-SERVERS.net.
com. 172570 IN NS E.GTLD-SERVERS.net.
com. 172570 IN NS F.GTLD-SERVERS.net.
com. 172570 IN NS G.GTLD-SERVERS.net.
com. 172570 IN NS H.GTLD-SERVERS.net.
;; Query time: 1 msec
;; SERVER: XXX.XXX.XXX.XXX#53(XXX.XXX.XXX.XXX)
;; WHEN: Thu Feb 12 07:10:26 2009
;; MSG SIZE rcvd: 324
/etc/named.conf contains the following
options {
pid-file "/var/named/chroot/var/run/named/named.pid";
directory "/var/named";
auth-nxdomain no;
/*
* If there is a firewall between you and nameservers you want
* to talk to, you might need to uncomment the query-source
* directive below. Previous versions of BIND always asked
* questions using port 53, but BIND 8.1 uses an unprivileged
* port by default.
*/
// query-source address * port 53;
};
//
// a caching only nameserver config
//
zone "." {
type hint;
file "named.root";
};
zone "0.0.127.in-addr.arpa" {
type master;
file "named.local";
};
zone "somedomain.net" {
type master;
file "pri.somedomain.net";
};
zone "mydomain.com" {
type master;
file "pri.mydomain.com";
};
//// MAKE MANUAL ENTRIES BELOW THIS LINE! ////
the zone file for mydomain.com in /var/named/pri.mydomain.com looks like this:
$TTL 86400
@ IN SOA ns1.mydomain.com. name.mydomain.com. (
2009021009 ; serial, todays date + todays serial #
28800 ; refresh, seconds
7200 ; retry, seconds
604800 ; expire, seconds
86400 ) ; minimum, seconds
;
NS ns1.mydomain.com. ; Inet Address of name server 1
NS server1.mydomain.com. ; Inet Address of name server 2
;
MX 10 mail.mydomaina.com.
mydomain.com. A XXX.XXX.XXX.XXX
mail A XXX.XXX.XXX.XXX
www A XXX.XXX.XXX.XXX
mydomain.com. A XXX.XXX.XXX.XXX
mydomain.com. TXT "v=spf1 a mx ptr ~all"
;;;; MAKE MANUAL ENTRIES BELOW THIS LINE! ;;;;
I hope that helps.
marm26
12th February 2009, 17:27
after I added ns1.mydomain.com as an A record again the dig command now returns this:
; <<>> DiG 9.3.4-P1 <<>> @ns1.mydomain.com any mydomain.com
; (1 server found)
;; global options: printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 32646
;; flags: qr rd ra; QUERY: 1, ANSWER: 2, AUTHORITY: 2, ADDITIONAL: 2
;; QUESTION SECTION:
;mydomain.com. IN ANY
;; ANSWER SECTION:
mydomain.com. 172800 IN NS ns1.mydomain.com.
mydomain.com. 172800 IN NS ns52.domaincontrol.com.
;; AUTHORITY SECTION:
mydomain.com. 172800 IN NS ns52.domaincontrol.com.
mydomain.com. 172800 IN NS ns1.mydomain.com.
;; ADDITIONAL SECTION:
ns1.mydomain.com. 172800 IN A XXX.XXX.XXX.XXX
ns52.domaincontrol.com. 172800 IN A 208.109.255.26
;; Query time: 101 msec
;; SERVER: XXX.XXX.XXX.XXX#53(XXX.XXX.XXX.XXX)
;; WHEN: Thu Feb 12 07:23:00 2009
;; MSG SIZE rcvd: 146
Still doesnt look like this is right.
falko
13th February 2009, 15:00
What do
dig @ns1.mydomain.com mydomain.com
dig @ns1.mydomain.com www.mydomain.com
dig @ns1.mydomain.com mail.mydomain.com
display?
marm26
13th February 2009, 16:13
dig @ns1.mydomain.com mydomain.com
; (1 server found)
;; global options: printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 33098
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 1, ADDITIONAL: 1
;; QUESTION SECTION:
;mydomain.com. IN A
;; ANSWER SECTION:
mydomain.com. 3600 IN A 68.178.232.100
;; AUTHORITY SECTION:
mydomain.com. 3600 IN NS ns52.domaincontrol.com.
;; ADDITIONAL SECTION:
ns52.domaincontrol.com. 90904 IN A 208.109.255.26
;; Query time: 42 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Fri Feb 13 06:07:56 2009
;; MSG SIZE rcvd: 100
dig @ns1.mydomain.com www.mydomain.com
; (1 server found)
;; global options: printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 40015
;; flags: qr rd ra; QUERY: 1, ANSWER: 2, AUTHORITY: 1, ADDITIONAL: 1
;; QUESTION SECTION:
;www.mydomain.com. IN A
;; ANSWER SECTION:
www.mydomain.com. 3600 IN CNAME mydomain.com.
mydomain.com. 3487 IN A 68.178.232.100
;; AUTHORITY SECTION:
mydomain.com. 3487 IN NS ns52.domaincontrol.com.
;; ADDITIONAL SECTION:
ns52.domaincontrol.com. 90791 IN A 208.109.255.26
;; Query time: 41 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Fri Feb 13 06:09:49 2009
;; MSG SIZE rcvd: 118
dig @ns1.mydomain.com mail.mydomain.com
; (1 server found)
;; global options: printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 64837
;; flags: qr rd ra; QUERY: 1, ANSWER: 3, AUTHORITY: 3, ADDITIONAL: 0
;; QUESTION SECTION:
;mail.mydomain.com. IN A
;; ANSWER SECTION:
mail.mydomain.com. 3600 IN CNAME pop.secureserver.net.
pop.secureserver.net. 3600 IN CNAME pop.where.secureserver.net.
pop.where.secureserver.net. 300 IN A 64.202.165.92
;; AUTHORITY SECTION:
where.secureserver.net. 3600 IN NS gns3.secureserver.net.
where.secureserver.net. 3600 IN NS gns1.secureserver.net.
where.secureserver.net. 3600 IN NS gns2.secureserver.net.
;; Query time: 359 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Fri Feb 13 06:11:24 2009
;; MSG SIZE rcvd: 171
The all seem to refer to the godaddy nameserver not my own???
falko
14th February 2009, 14:51
Did you tell GoDaddy that you want to use your own nameservers for that domain?
marm26
15th February 2009, 13:10
Yes I did. I made added the new nameserver in a record. I added them in Host Summary, then pointed the domain to this new nameserver.
After this didnt work i tried something else. I have reset all the abouve changes. Now i am simply pointing the domain to an already established nameserver on ISPConfig. (I use this for another domain, actually I wanted those domains to be complety sepertated, hence I tried to add another nameserver)
But I am getting the same result. The nameserver does not properly resolve the new domain. Why is this not working? Everything in ISPCOnfig is set up 100% correctly. At least the things I can see inside the graphical interface...
marm26
16th February 2009, 14:05
Ok I seem to have found the problem but I have no idea how to fix it.
I restarted BIND and checked my server logs. BIND is loading the zone file for the first domain on my server but not the zone file for the new domain I wanted to add.
Any ideas on how to fix this?
falko
16th February 2009, 18:39
Any errors or warnings in /home/admispconfig/ispconfig/ispconfig.log?
What's the output of ls -la /root/ispconfig?
marm26
16th February 2009, 19:39
There are two warnings in /home/admispconfig/ispconfig/ispconfig.log
15.02.2009 - 15:13:07 => WARN - /root/ispconfig/scripts/lib/config.lib.php, Line 2102: WARNING: could not groupadd -g 12006 web6_anonftp &> /dev/null
15.02.2009 - 15:13:07 => WARN - /root/ispconfig/scripts/lib/config.lib.php, Line 2103: WARNING: could not useradd -d /var/www/web6/ftp -g web6_anonftp -m -s /bin/false -u 12006 web6_anonftp &> /dev/null
ls -la /root/ispconfig outputs the following
total 108
drwxr-xr-x 10 root root 4096 Feb 15 18:29 .
drwxr-x--- 5 root root 4096 Jan 31 13:24 ..
-rwxr-xr-x 1 root root 33074 Dec 31 08:43 cronolog
-rwxr-xr-x 1 root root 9673 Dec 31 08:43 cronosplit
drwxr-xr-x 12 root root 4096 Dec 31 08:36 httpd
drwxr-xr-x 16 root root 4096 Dec 31 08:43 isp
drwxr-xr-x 7 root root 4096 Dec 31 08:36 libmcrypt
-rw-r--r-- 1 root root 8 Feb 15 18:29 .old_path_httpd_root
drwxr-xr-x 6 root root 4096 Dec 31 08:35 openssl
drwxr-xr-x 6 root root 4096 Jan 31 14:01 php
drwxr-xr-x 4 root root 4096 Dec 31 08:43 scripts
drwxr-xr-x 4 root root 4096 Dec 31 08:43 standard_cgis
drwxr-xr-x 2 root root 4096 Dec 31 08:43 sv
-rwx------ 1 root root 9389 Dec 31 08:43 uninstall
falko
17th February 2009, 16:31
Ok I seem to have found the problem but I have no idea how to fix it.
I restarted BIND and checked my server logs. BIND is loading the zone file for the first domain on my server but not the zone file for the new domain I wanted to add.
Any ideas on how to fix this?
Is that zone listed in your named.conf? Can you post your named.conf here?
marm26
17th February 2009, 16:49
Yes this zone is contained in /etc/named.conf
options {
pid-file "/var/named/chroot/var/run/named/named.pid";
directory "/var/named";
auth-nxdomain no;
/*
* If there is a firewall between you and nameservers you want
* to talk to, you might need to uncomment the query-source
* directive below. Previous versions of BIND always asked
* questions using port 53, but BIND 8.1 uses an unprivileged
* port by default.
*/
// query-source address * port 53;
};
//
// a caching only nameserver config
//
zone "." {
type hint;
file "named.root";
};
zone "0.0.127.in-addr.arpa" {
type master;
file "named.local";
};
zone "domain1.com" {
type master;
file "pri.domain.com";
};
zone "mydomain.com" {
type master;
file "pri.mydomain.com";
};
//// MAKE MANUAL ENTRIES BELOW THIS LINE! ////
marm26
17th February 2009, 18:25
I also checked the files in /var/named/
The file pri.domain1.com and pri.mydomain.com look the same to me. However the file pri.mydomain.com is shown in green color inside the named folder whereas the file pri.domain1.com is shown in white? Don't know what this is supposed to mean but its about the only thing that looks strange to me here.
falko
18th February 2009, 21:25
What's the output of ls -la /var/named/? Sounds as if the permissions differ...
marm26
19th February 2009, 01:05
ls -la /var/named/ outputs the following:
total 48
drwxr-xr-x 5 root named 4096 Feb 17 07:29 .
drwxr-xr-x 23 root root 4096 Feb 2 11:45 ..
drwxrwxr-x 6 root named 4096 Dec 26 09:12 chroot
drwxrwx--- 2 named named 4096 Jul 11 2008 data
-rw-r--r-- 1 root root 256 Jan 31 07:40 named.local
-rw-r--r-- 1 root root 2516 Jan 31 07:40 named.root
-rw-r--r-- 1 named named 959 Feb 16 09:43 pri.mydomain.com
-rw-r--r-- 1 named named 959 Feb 16 09:43 pri.mydomain.com~
-rw-r--r-- 1 named named 1291 Feb 5 13:53 pri.domain1.com
-rw-r--r-- 1 named named 1253 Feb 5 13:53 pri.domain1.com~
drwxrwx--- 2 named named 4096 Jul 11 2008 slaves
falko
19th February 2009, 21:35
Hm, both zone files have the same permissions...
marm26
23rd February 2009, 06:23
Ok the nameserver problem is solved. I hired somebody to solve it. Don't ask me how. I would really like to share but i didn't quite understand what he did.
The thing is now that the domain is resolved correctly there is another problem. I cant point mydomain.com to any IP other then the IP of domain1.com.
Any other domain I choose in ISPconfig will go to the shared ip page and not to the root of mydomain.com. Can't use the Server IP, Can't use a third domain i added, I can only use the IP of domain1.com.(all domains I am talking about here are up and running)
Really I am kind of losing it here. I feel like winning the lottery twice on the same day in a negative way (better make this sitting in a plane crash twice on the same day). Unbelievable how those micro baby steps can fail two work.
Any help with this would be greatly appreciated.
Thanks...
falko
24th February 2009, 20:08
For the website settings, you must use one of the IP addresses that you see in the output of ifconfig, or you will get the Shared-IP page.
marm26
24th February 2009, 20:14
Sure that's what I did. Still it's not working.
There are three IPs in ifconfig. However It only works if I choose the IP of my nameserver. Using one of the other two IPs gets the shared IP error.
falko
25th February 2009, 18:59
I have no idea why this is happening...
marm26
25th February 2009, 19:07
Hi Falko.
Ya no worries. I was kind of expecting that already.
Still I wanna thank you for you help. I am gone hire somebody again to troubleshoot this. I will post the results later. Maybe it can help somebody at a later point.
vBulletin® v3.8.7, Copyright ©2000-2012, vBulletin Solutions, Inc.