[RADIATOR] Memory leak with Perl Script to get via SNMP the client IP from Cisco AP 1100

Gerard Alcorlo Bofill galcorlo at cesca.cat
Fri Feb 25 07:32:09 CST 2011


Sorry,

the error I'm receiving by mail is:


Your program

   /usr/local/bin/radiusd -config_file
/etc/radiator/radiuscesca/radiuscesca.cfg -foreground

exited unexpectedly with exit status 25,
signal number 0 and dump indication 0.

The STDERR output was Not a HASH reference at (eval 135) line 28.
.

The program will be restarted again by /sbin/restartWrapper in 2 seconds.

I'm sure it's a good tip.

Thanks!

Al 25/02/11 14:23, En/na Gerard Alcorlo Bofill ha escrit:
> Hello,
> 
> thanks Christian and Heikki for your advise.
> 
> I've done some short code with the timeout but every time this code is
> executed Radiator restarts.
> 
> I'm trying to remove the timeout at the end of the "important things".
> 
> Do you know why when I execute this Radiator exits?
> 
> 
> sub {
> 
> &main::log($main::LOG_DEBUG, "||| wait 5 segons |||" . time);
> 
> my $referencia={};
> $referencia->{moment} = &Radius::Select::add_timeout(time + 5,
>    sub {
>       my ($mimateix) = @_;
> 
>       &main::log($main::LOG_DEBUG, "== do important things ==");
> 
>       &Radius::Select::remove_timeout($mimateix->{moment});
>       &main::log($main::LOG_DEBUG, time. ">>> Finished <<<");
>    }
> , $referencia);
> }
> 
> 
> --
> Gerard
> 
> Al 24/02/11 23:27, En/na Heikki Vatiainen ha escrit:
>> On 02/24/2011 11:00 AM, Gerard Alcorlo Bofill wrote:
>>
>>> sorry for resending the same question. But I sent this question at the
>>> end of another mail with a not related subject, (Re: [RADIATOR]
>>> Assigning IP's directly from the Radius server), and maybe that's de
>>> reason because no one could help me.
>>
>> Or maybe we got scared of threads :)
>>
>>> I'm using a home made PostProcessingHook. But it's suffering a memory
>>> leak. Could someone take a look at my script? I'm not an expert on perl
>>> and I'm using a thread to do non active waiting...
>>
>> I would try replacing the thread with add_timeout function. Then you do
>> not have to use threads and can use the same timing support that rest of
>> Radiator uses.
>>
>> grep for add_timeout in Radius/ directory for examples. The function
>> lives in Select.pm.
>>
>>> What's wrong on this script?
>>
>> Hard to say. If you can replace threads with add_timeout, then we could
>> at least know if the leak is a side effect from using threads or not. I
>> really do not know how Perl's memory management works with threads.
>>
>> Thanks!
>>
> _______________________________________________
> radiator mailing list
> radiator at open.com.au
> http://www.open.com.au/mailman/listinfo/radiator


More information about the radiator mailing list