Angelos Karageorgiou wrote:
Well here is my wish , when the proxy module decides to mark a server as dead , it should mark
the pair (server:port) not the server as an entity . This way if a GRIC server is not reponding in time
another radius server , authenticating local hosts will not be marked dead.
Any ideas on where I could start looking into the code ?
Another idea is to have some servers never marked as dead.
BTW where is the load balancing configuration DOCs?
- List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
OK I admit it , I am quick at the gun , so I am replying to myself
I ma proxying for a server that is authenticating both for NULL realm and another domain call it users.gr
what is happening that this server sometimes loses packets so freeradius is marking it as dead. The server is still
ok and keeps sending packets but they are not credited to the NULL realm which is by far the hugest!
They are creditted to the USERS.GR domain which is activated upon receipt of a packet in the rad_recv
function.
The solution was easy fix realm_findbyaddr to NOT stop at the first realm it finds , but to go through ALL the
realms and activate those for which the originating server is active.
Net result : flip flopping of the primary and secondary radius dropped to zilch !!
/*
* Find a realm for a proxy reply by proxy's IP
*/
REALM *realm_findbyaddr(uint32_t ipaddr, int port)
{
REALM *cl;
REALM *first=NULL;
/*
* Note that we do NOT check for inactive realms!
*
* If we get a packet from an end server, then we mark it
* as active, and return the realm.
*/
/* note by angelos karageorgiou
* we should loop through all realms that have this server and mark all as active
* else we stop at the first realm in the proxy.conf file
*/
for(cl = realms; cl != NULL; cl = cl->next)
if ((ipaddr == cl->ipaddr) && (port == cl->auth_port)) {
cl->active = TRUE;
first=cl;
} else if ((ipaddr == cl->acct_ipaddr) && (port == cl->acct_port)) {
cl->acct_active = TRUE;
first=cl;
}
return first;
}
- List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
