Strange DNS Issues

7 posts / 0 new
Last post
#1 Mon, 01/17/2011 - 23:13
Craigs

Strange DNS Issues

Hey everyone, new Virtualmin user here.

I am trying to set up a new dedicated server instance wrapped up with Virtualmin, and the software looks great, but I am having some strange issues that don't seem to make a lot of sense.

So here is the series of steps that I am going through here.

1) let's take a domain that I own, registered at godaddy. At godaddy, i changed my configuration to create ns1 and ns2 for the new server that I have (pointed them at the proper ips). Then i changed my domain to use ns1 and ns2 as my new name servers.

2) installed a new centos 5 and webmin and virtualmin on the new host. Install finished properly.

3) I can re-check my install as I need and. . . .

Checking Configuration
The status of your system is being checked to ensure that all enabled features are available, that the mail server is properly configured, and that quotas are active .. BIND DNS server is installed, and the system is configured to use it. Mail server Postfix is installed and configured.

Apache is installed.

Webalizer is installed.

Apache is configured to host SSL websites.

MySQL is installed and running.

ProFTPd is installed.

Logrotate is installed.

SpamAssassin and Procmail are installed and configured for use.

ClamAV is installed and assumed to be running.

Plugin DAV Login is installed OK.

Plugin AWstats reporting is installed OK.

Plugin Mailman is installed OK.

Plugin Protected web directories is installed OK.

Using network interface eth0 for virtual IPs.

IPv6 addresses are available, using interface eth0.

Default IP address for virtual servers is 65.18.196.122.

Default IP address is set to 65.18.196.122, which matches the detected external address.

Both user and group quotas are enabled for home and email directories.

All commands needed to create and restore backups are installed.

.. your system is ready for use by Virtualmin.

Ok so all good so far.

4) Ok let's check DNS that is being advertised for my new virtual server so head over to intodns and run a check on the zone, the first issue is:

ok so server1.potsnobs.co is the name of the server, so it makes sense that it's the default. However I need to get ns1 and ns2 working. So let's add the two nameservers, and remove server1 as teh default. So edit the zone and click on zone paramaters, then change the following:

change the master server from server1.potsnobs.co to ns1.potsnobs.co and then save it back now the SOA looks like this.

$ttl 38400 potsnobs.co. IN SOA ns1.potsnobs.co root.server1.potsnobs.co. ( 1295297879 10800 3600 604800 38400 ) @ IN NS server1.potsnobs.co.

ok the SOA is correct, but I need to remove the NS record and then add the proper ones. So click on name servers and remove the default one, then add ns1 and ns2.

Added the NS and A records, applied the zone and bounded named. Ok rerun the scan.

All looks ok, now here is the intereting part, let's add the MX records.

Select all. | Invert selection.

Name TTL Priority Mail Server potsnobs.co. Default 1 ASPMX.L.GOOGLE.COM potsnobs.co. Default 5 ALT1.ASPMX.L.GOOGLE.COM

Name TTL Priority Mail Server potsnobs.co. Default 5 ALT2.ASPMX.L.GOOGLE.COM Select all. | Invert selection.

Return to zone list | Return to record types

ok now save, publish and bounce bind and.

[root@server1 ~]# dig mx potsnobs.co

; <<>> DiG 9.3.6-P1-RedHat-9.3.6-4.P1.el5_5.3 <<>> mx potsnobs.co ;; global options: printcmd ;; Got answer: ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 46542 ;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 0

;; QUESTION SECTION: ;potsnobs.co. IN MX

;; ANSWER SECTION: potsnobs.co. 4599 IN MX 5 mail.potsnobs.co.

;; Query time: 1 msec ;; SERVER: 69.94.100.24#53(69.94.100.24) ;; WHEN: Tue Jan 18 00:12:01 2011 ;; MSG SIZE rcvd: 50

it's the DEFAULT MX BACK AGAIN. The ui shows my changes, but for the life of me I can't get DNS to hand out the right mail exchangers.

Any thoughts?

TIA Craig

Tue, 01/18/2011 - 01:43
ronald
ronald's picture

I thought that if you want to use the google mail service, you have to disable mail for that domain all together.

Tue, 01/18/2011 - 04:06
Locutus

@ronald: Disabling "mail" just disables the configuration of his local mail server, but he still needs proper MX entries on his system to point to Google.

@Craigs: Which nameserver did you query with your dig? There's caching times and stuff, it's possible that the previous value was still in a cache. Did you apply the zone change correctly? Check the zone file directly in Webmin. Try digging directly at the authoritative nameserver using the @servername parameter.

Tue, 01/18/2011 - 10:21 (Reply to #3)
Craigs

@Locutus: It looks like you were right. I thought that I was allowing time for everything to work it's way out. Quick dig on my machine shows:

;; ANSWER SECTION: potsnobs.co. 38400 IN MX 5 ALT2.ASPMX.L.GOOGLE.COM.potsnobs.co. potsnobs.co. 38400 IN MX 1 ASPMX.L.GOOGLE.COM.potsnobs.co. potsnobs.co. 38400 IN MX 5 ALT1.ASPMX.L.GOOGLE.COM.potsnobs.co.

Which is now, sorta right. However, now I have the .potsnobs.co on the end of each mx record that I am advertising. That now obviously breaks ip resolution.

Any thoughts on now to remove the ends of the names?

Thanks Craig

Tue, 01/18/2011 - 10:26 (Reply to #4)
Craigs

Ok just checked the zonefiles and i forgot my trailing dots on the mx dns names. That should fix my last problem.

I'll update everyone, thanks for the continued help

Craig

Tue, 01/18/2011 - 15:14 (Reply to #5)
ronald
ronald's picture

I sometimes forget that not every one always realise that propagation of dns changes can take up to 72 hrs (to be on the safe side.)
However to have a 100% failsafe mailsystem it is advised to also disable the local mailservice for the domain in question. So it is always a combination of proper MX records and disabling local mailservive.

Tue, 01/18/2011 - 12:53
Locutus

Yep, the trailing dots are easy to forget and can break things really good in DNS. ;)

Topic locked