Add slave DNS & mail server issues

16 posts / 0 new
Last post
#1 Sat, 07/14/2012 - 02:00
fakemoth
fakemoth's picture

Add slave DNS & mail server issues

Hi, I am trying to add a secondary server to my setup, and in this respect I followed this how-to http://www.virtualmin.com/documentation/dns/slave-configuration except it doesn't work and don't know why.

So, I have a master (Virtualmin) server wich runs everything and needed some redundancy. Installed on a backup system webmin and virtualmin gpl (and a fresh CentOS 6.3), changed the hostname (the hostname command shows the right name), registered the nameserver with my TLD, opened the ports 10001:10010, and the name resolves properly.

Now, when i try to add the slave server hostname to the master server in Webmin Servers Index this one doesn't let and keeps telling me "Error Failed to save server : Host does not exist". What is this non-sense of course it exists :) ?

If I add it with the IP it works, but it's useless for the later step of adding the slave to the Cluster Slave Servers... as it requires a hostname.

Thanks!

Sun, 07/15/2012 - 12:57
fakemoth
fakemoth's picture

Anyone? I'm sure it's something really simple as usual with Virtual/Webmin :)

Don't take the name of root in vain...

Mon, 07/16/2012 - 01:35
ronald
ronald's picture

I can only imagine that the dns name hasn't propagated fully yet. It can take up to 72 hours.

Mon, 07/16/2012 - 01:43
fakemoth
fakemoth's picture

Well it's not working even now so it's been like 5 days - ty, but that's not it.

Don't take the name of root in vain...

Mon, 07/16/2012 - 02:16
ronald
ronald's picture

per haps obvious but still ... just to rule out:
did you add the hostname as server.domain.tld and not http://server.domain.tld?
If you log in to a shell on the primary can you ping the secondaries hostname?
Can you telnet to port 10000 on the secondary?
Is port 10000 also open on the secondary as you speak of 10001:10010 ?

Tue, 07/17/2012 - 02:13
fakemoth
fakemoth's picture

Yes I was adding it as ns2.xxxx.yyy I use 10001 ports for the Min family on both of my servers (10000 everyone knows of :)

Problem is I didn't try a ping from the ns1.xxxx.yyy (master) to ns2.xxxx.yyy (slave)! And it dosn't work, though from my station (different connection) it works just fine... so where should i look?

Don't take the name of root in vain...

Tue, 07/17/2012 - 02:25
ronald
ronald's picture

if the incoming port is open on the ns2, then the outgoing port on the ns1 must be closed.
on the ns1 you should verify that 10001 is open in the outgoing section. You could set the Source and destination port(s) TCP on port 10001 to be accepted

oh and settng webmin to 10001 doesn't make too much sense.
If someone wants to look at your server, they will use a port scanner and then know of 10001.
These ports 10001:10010 are used by RPC Calls by webmin ...

Tue, 07/17/2012 - 06:40
fakemoth
fakemoth's picture

Pls be more specific, i don't understand what the 10ketc port has to do with not being able to ping the ns2 from ns1. And why it's working on my station and even in it's browser ns2.xxxx.yyy, but not from the other server.

As for the ports of course someone could scan, but i got rid of a all of the brute force attacks (chinese mainly) simply by changing the port :) And it works for years with no problems. Plus I don't want to annoy anyone changing them...

PS: ns1 and ns2 are on different domains, as I will attempt later a migration of the domains from ns1.whatever1.ro to ns1.whatever2.ro and ns2.whatever2.ro but for now i need them as mentioned above.

Don't take the name of root in vain...

Tue, 07/17/2012 - 07:20
ronald
ronald's picture

you are correct. I was confused with the telnet on port 10001, you probably can not telnet either from ns1 to ns2 .. telnet ns2.xxx.yyy 10001 ?
from a shell on the ns1 can you dig the domain?
dig ns2.xxx.yyy ? Just to see if resolving works ..
What I am not getting is that you can add the server on its IP but not hostname, so the ns1 server must have an issue in resolving this (or more) domain(s)

And as you can add the ns2 by IP, the ports are open so that couldn't be the issue. That these are different domains should not matter. I have added also servers with different domains.

Tue, 07/17/2012 - 07:34
fakemoth
fakemoth's picture

TY very much for clearing that, but I am begining to suspect that it is a ISP problem, as the servers are on different ISPs... I will post back after talking to them.

Don't take the name of root in vain...

Tue, 07/17/2012 - 09:54
fakemoth
fakemoth's picture

It seems something is very wrong: I can't modify Network Configuration>Hostname and DNS Client, as the old values keep on popping up after i hit the apply button? Editing resolv.conf and then restarting the service also resets the file?!?! How can this happen, it reminds me of fedora "easy-to-use-network-manager-crap"?

Also I thought to try and setup the ns1 in the webmin index of ns2, guess what, the same error?!?!!

Don't take the name of root in vain...

Tue, 07/17/2012 - 10:00
fakemoth
fakemoth's picture

Also now I see that on the System Information > Status page the BIND DNS Server is marked as stopped and I have the little play button, but the service is surely running... something is way off on this newly installed system... starting to hate centos 6.3...

Don't take the name of root in vain...

Tue, 07/17/2012 - 17:57
ronald
ronald's picture

seems you are suffering from the same issues I had when I upgraded a server to 6.x
yep, networkmanager and bind. It's all different and there are threads about this.

You can take bind out from chroot in webmin and kill the all new and improved Networkmanager for desktop users.
I went back to the normal Network (in Boot and shutdown actions) as the Fedora's Networkmanager is for desktops using some 'fake' DHCP settings.
Not even sure what it does exactly, just that it doesn't even booted eth correctly on my system.
You may need to edit some files manually though.

Fri, 07/20/2012 - 00:06 (Reply to #13)
fakemoth
fakemoth's picture

True there is something very wrong with Centos 6.3 regarding networking, I mean even after i killed network manger stupid stuff, some script is continuing to overwrite my files! So I installed again from scratch, made the settings ok from the start and it's fine but this is not a solution! I can't edit my hosts file by hand as something is screwing around with the file and keeps on overwriting it... Anyway this is a different problem.

Now, part of my initial issues was concerning the 2 ISPs I'm using and now it's solved. One had some bad setting on a router, the other one I was using some out of date DNS server... sigh. Seems fine now the new dns server, added it to the Webmin Server index, and to the Cluster Slave Servers but I am getting an error and don't see any new zones on the slave (is this what's supposed to happen I guess?)

Failed to add server : flush_file_lines called on non-loaded file /etc/named.conf

Tried this settings: View on slaves to add zones to At top level Create secondary on slave when creating locally? Yes Create all existing master zones on slave? Yes Name for NS record Same as hostname

Don't take the name of root in vain...

Fri, 07/20/2012 - 01:24
ronald
ronald's picture

I dont know this error, this may or may not have to do with the new way bind is configured in centos 6.x
For that error I would probably create a bugreport here.
Per haps the path to /etc/named.conf isn't correct ?
Are the ownerships correct on both servers? root:named or named:named ?

Mon, 07/23/2012 - 03:26
fakemoth
fakemoth's picture

This one is for CentOS 5.8 on the Virtualmin master server, that's where I can't add the CentOS 6.3 slave DNS server. The ownerships ar correct.

Failed to add server : flush_file_lines called on non-loaded file /etc/named.conf

Don't take the name of root in vain...

Topic locked