Execution of rlm code when remote server is not responding.
Phil Mayers
p.mayers at imperial.ac.uk
Thu Sep 27 12:59:53 CEST 2012
On 27/09/12 11:22, Arka Sharma wrote:
> Hi,
>
> I have a remote PPS server where I am proxying radius
> requests coming from the NAS. I have a requirement like when that remote
> PPS goes down(which I am simulating by setting a wrong ip in proxy.conf
> realm configuration) then I have to perform a certain task in rlm
What task? Does it have to be in "rlm" code? Because "rlm" code only
runs in response to packets, not server-down events.
> code.But my observation is when I am setting a dummy ip for PPS, the
> radius server running on my machine is marking that remote server as
> zombie after 3 retries,now I want in this case that my rlm code to
> execute and handle the scenario when remote server is down.Any help will
> be highly appreciated.Also I may have used some naive terminology being
> a newbie apologizing for that.
You've got a couple of options to respond to a down proxy.
1. In the "master" branch, there is support for "triggers" - see
raddb/trigger.conf. This can execute a script when a home server goes
down or up, and can obviously do anything you want
2. In all recent versions, you can use "radmin" from cron to poll home
server status, and respond based on status change e.g.
radmin -n eduroam -e 'show home_server list'
...you can run this in a loop
It's possible you could do something in the "post-proxy" section like so:
post-proxy {
Post-Proxy-Type Fail {
}
}
...but I think this only runs for *real* requests, not the internal
server probes, so you'll need to inject frequent test requests using
"radclient" or similar. You also don't know *which* home server failed,
so will still need to use "radmin" in a script to find this out (maybe
it would be useful for this to be a control attribute added to the
failing request).
More information about the Freeradius-Users
mailing list