allow {
ip *@XXX.XXX.XXX.XXX;
hostname *@XXX.XXX.XXX.XXX;
class clients;
redirect-server my.second.server;
};
allow {
ip *@*;
hostname *@*;
class clients;
};
allow {
ip *@*;
hostname *@*;
class clients;
};
allow {
ip *@XXX.XXX.XXX.XXX;
hostname *@XXX.XXX.XXX.XXX;
class clients;
redirect-server irc2.myserver.com;
};
You need to make another class that is always full. The redirect-server ONLY works when that class is full, otherwise, clients will be able to connect.
checkout the module "m_jumpserver" ... with that you can redirect user, either new connections, all connections ... you can specify the new server with port and ssl-instructions ...
we're using that when upgrading servers to redirect users in the IRC on another server before the shutdown ... works great
The allow block that is redirecting users MUST BE THE LAST ALLOW BLOCK IN THE CONF! You obviously did NOT read the documentation about matching like we told you, and you said.
Also, a class with maxclients set to 0 is illegal.
I'm afraid you are trying to (ab)using a feature for something it wasn't designed for ;). The redirect-server stuff is meant for when a class or server is full, not some means for users to choose the closest server or anything.
You are aware of DNS round robin? (irc.blah.net pointing to several ips)
Use different DNS pools (eu.irc.yourdomain.com, usa.irc.yourdomain.com).
You could also use "views" in BIND 9, i guess (see the documentation of BIND).
BIND 9 Administrator Reference Manual wrote:The view statement is a powerful new feature of BIND 9 that lets a name server answer a DNS query
differently depending on who is asking.
If you don't make mistakes, you aren't really trying. - Coleman Hawkins