Page 1 of 1

pingfreq vs connfreq

Posted: Wed Aug 25, 2004 10:38 pm
by heper
i've recently joined the staff of a net of +1500 users total
and round 20 ircds (3 of them are hubs)
all leafs autoconnect to either one of the hubs
and i've noticed some weird netsplits
ircds splitting then reconnecting to another hub , but then get rejected cause they still
exist on their previous hub where they linked too

i stated 2 possible solutions for this problem

solution1: put only 1 hub on autoconnect in the leafs config

solution2: fix the pingfreq and connfreq in the server class

class server
{
pingfreq 300;
maxclients 1; /* Max servers we can have linked at a time */
sendq 1000000;
connfreq 100; /* How many seconds between each connection attempt */
};

this is what they've got now
i'm pretty much convinced that the connfreq needs to be higher then the pingfreq
otherwise hub1 wont even know when leaf disconnects before it reconnects to hub2
and i think the pingfreq should be reduced aswell

am i right ?

Posted: Wed Aug 25, 2004 11:35 pm
by w00t
Why on earth do you have them attempting to link to multiple servers on autoconnect... more to the point, why do you use autoconnect? My advice would be to get rid of autoconnect (I just dislike it totally :)), down the pingfreq a bit, and have multiple link blocks for each server, so you can route stuff etc.

Just my two cents.

Posted: Thu Aug 26, 2004 11:33 am
by heper
i just want to know if i'm not mistaken that
connfreq should be higher then pingfreq

Posted: Thu Aug 26, 2004 11:54 am
by AngryWolf
Let's say, a leaf server has been disconnected, but the hub it was connected to doesn't know about the split, and thus the whole network either. The main problem is, you are trying to link that leaf back to the network (specially, to an other hub), while none of the servers have acknowledged the disconnection with a ping timeout error message. It's already enough to connect back the leaf to its previous link, no need to change hubs. Besides that, I can't see any problems with having the leaf server automatically connect back to the hub; however it isn't a good idea to have more than one autoconnect setting in one server for the same network. So, if such a split happens, the best is to wait until the servers acknowledge the split (for example, set connfreq to the double of pingfreq in the configuration of the hub that handles the leaf's connection), or simply ignore failed connection attempts.

Posted: Thu Aug 26, 2004 1:23 pm
by heper
thank you

Posted: Thu Aug 26, 2004 8:11 pm
by aquanight
Of course, with advanced communication methods (DCC, email, the two opers are on another server, etc), an oper on the "stoned" server ("stoned" meaning disconnected but the other side hasn't been notified via the appropriate TCP packets - this is what "Ping Timeout" is, esentially) can notify an oper on the rest of the network, and they can /squit the server and the lost server can reconnect.