[RADIATOR] Memory leak in Radiator 4.5-1

Francisco Rodrigo Cortinas Maseda francisco.cortinas at jazztel.com
Mon Jan 25 11:30:13 CST 2010


Hi Hugh,

I think i have found where the problem is; i have made this test:

1º Operating system: Fedora Core 12
2º Radiator software: 4.5.1

The config i have used is:

DefineFormattedGlobalVar operaciones 192.168.2.3
DefineFormattedGlobalVar gestion 10.0.255.67
DefineFormattedGlobalVar i2p 192.168.2.3

BindAddress %{GlobalVar:operaciones}
FarmSize 6
DbDir /opt/etc/radiator
LogDir /var/log/radiator
DictionaryFile %D/dictionary
LogFile
Trace 3
AuthPort 1850
AcctPort
PidFile /var/run/radiusd_1850.pid
<Log FILE>
        Filename %L/proxy2g-auth-%Y%m%d
        Trace 3
</Log>
<AuthBy INTERNAL>
        Identifier RAD2GDEF
        DefaultResult ACCEPT
</AuthBy>
<Handler Realm=/^adsl$/>
        AuthBy RAD2GDEF
</Handler>
<Handler>
        RewriteUsername s/(.*)@(.*)/$1/
        AuthBy RAD2GDEF
</Handler>

<Client 192.168.2.1>
        Secret radius-2G-local
</Client>
<Client 192.168.2.2>
        Secret radius-2G-local
</Client>
<Client 192.168.2.3>
        Secret radius-2G-local
</Client>
<Client 192.168.2.4>
        Secret radius-2G-local
        UseContentsForDuplicateDetection
</Client>
<Client 192.168.2.5>
        Secret radius-2G-local
        UseContentsForDuplicateDetection
</Client>
<Client 192.168.2.7>
        Secret radius-2G-local
        UseContentsForDuplicateDetection
</Client>
<Client 192.168.2.8>
        Secret radius-2G-local
        UseContentsForDuplicateDetection
</Client>


The memory is going off because the config of this clauses on the configuration of the clients:

        DupInterval 0
        NoIgnoreDuplicates Access-Request

When removed, the process is not consuming memory. I have configured the option "UseContentsForDuplicateDetection" and randomize the username in order to confirm that launching the tests again the process is managing memory normally.

Can you confirm that my tests can be reproduced by you?

Regards,

Francisco Rodrigo Cortiñas

-----Mensaje original-----
De: Francisco Rodrigo Cortinas Maseda
Enviado el: viernes 22 de enero de 2010 11:09
Para: 'Hugh Irvine'
Asunto: RE: [RADIATOR] Memory leak in Radiator 4.5-1


Hi,

I have commented the FarmSize option on the config, and i had made another set of tests with this results:

1º On the first set of tests, the radiator process have consumed the 29% of the memory of the server:

top - 10:27:35 up 3 days, 14:55,  3 users,  load average: 0.04, 0.11, 0.12
Tasks: 168 total,   1 running, 167 sleeping,   0 stopped,   0 zombie
Cpu(s):  0.0%us,  0.0%sy,  0.0%ni, 99.9%id,  0.1%wa,  0.0%hi,  0.0%si,  0.0%st
Mem:   4148640k total,  2105336k used,  2043304k free,   120344k buffers
Swap:  5406712k total,        0k used,  5406712k free,   608076k cached

  PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND
23354 root      15   0 1208m 1.2g 1708 S  0.0 29.7   4:03.17 perl
 3180 root      15   0 43612  11m 5048 S  0.0  0.3   0:00.26 setroubleshootd
 3616 root      34  19 25656  10m 2152 S  0.0  0.3   0:00.02 yum-updatesd
 3001 root      15   0 11584 9960  240 S  0.0  0.2   0:00.00 restorecond

2º We dont do any more tests; we wait 1 hour to check if the process is freeing memory. 3º After this, the process has not reduced his memory footprint:

top - 11:24:48 up 3 days, 15:53,  3 users,  load average: 0.07, 0.02, 0.00
Tasks: 168 total,   1 running, 167 sleeping,   0 stopped,   0 zombie
Cpu(s):  0.8%us,  0.0%sy,  0.0%ni, 99.2%id,  0.0%wa,  0.0%hi,  0.0%si,  0.0%st
Mem:   4148640k total,  2110544k used,  2038096k free,   122512k buffers
Swap:  5406712k total,        0k used,  5406712k free,   611904k cached

  PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND
23354 root      15   0 1208m 1.2g 1708 S  0.0 29.7   4:05.45 perl
 3180 root      15   0 43612  11m 5048 S  0.0  0.3   0:00.26 setroubleshootd
 3616 root      34  19 25656  10m 2152 S  0.0  0.3   0:00.02 yum-updatesd
 3001 root      15   0 11584 9960  240 S  0.0  0.2   0:00.00 restorecond
 3316 haldaemo  17   0  6008 4208 1688 S  0.0  0.1   0:00.65 hald


4º We made another set of test, and after this, we see that the process has consumed another 33% of the memory, to a total of 63%:

top - 11:32:12 up 3 days, 16:00,  2 users,  load average: 0.65, 0.65, 0.31
Tasks: 167 total,   1 running, 166 sleeping,   0 stopped,   0 zombie
Cpu(s):  0.0%us,  0.0%sy,  0.0%ni,100.0%id,  0.0%wa,  0.0%hi,  0.0%si,  0.0%st
Mem:   4148640k total,  3507532k used,   641108k free,   122792k buffers
Swap:  5406712k total,        0k used,  5406712k free,   612416k cached

  PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND
23354 root      15   0 2570m 2.5g 1708 S  0.0 63.3  10:28.36 perl
 3180 root      15   0 43612  11m 5048 S  0.0  0.3   0:00.26 setroubleshootd
 3616 root      34  19 25656  10m 2152 S  0.0  0.3   0:00.02 yum-updatesd



5º I have made another thing, stop the process, clean up the config, and run another test; with this new configuration (attached to this email) it shows that the process is very "hungry":

top - 11:54:29 up 3 days, 16:22,  2 users,  load average: 0.03, 0.29, 0.24
Tasks: 167 total,   1 running, 166 sleeping,   0 stopped,   0 zombie
Cpu(s):  0.0%us,  0.0%sy,  0.0%ni,100.0%id,  0.0%wa,  0.0%hi,  0.0%si,  0.0%st
Mem:   4148640k total,  2228344k used,  1920296k free,   123340k buffers
Swap:  5406712k total,        0k used,  5406712k free,   613092k cached

  PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND
23582 root      15   0 1322m 1.3g 1200 S  0.0 32.5   4:19.90 perl
 3180 root      15   0 43612  11m 5048 S  0.0  0.3   0:00.26 setroubleshootd
 3616 root      34  19 25656  10m 2152 S  0.0  0.3   0:00.02 yum-updatesd



What else can we do to see why is it consuming so much memory and not freeing it?

Thanks,

Francisco Rodrigo Cortiñas

-----Mensaje original-----
De: Hugh Irvine [mailto:hugh at open.com.au]
Enviado el: jueves 21 de enero de 2010 23:56
Para: Francisco Rodrigo Cortinas Maseda
Asunto: Re: [RADIATOR] Memory leak in Radiator 4.5-1



Hello Francisco -

Can you remind me whether you have the same problem without the FarmSize parameter enabled?

Ie. is it only a problem with multiple processes?

regards

Hugh


On 19 Jan 2010, at 22:00, Francisco Rodrigo Cortinas Maseda wrote:

> Hi hugh,
>
> I have the debug output of 1 test, inserting 210K auth requests; the
> compressed file is a 33MB file!! I have also recorded the output of
> "vmstat 1", showing that the processes are not freeing the memory they
> reclaim (attached to this email). The test is made with Perl 5.10.
>
> Where can in upload the debug file?
>
> Also, we can do whatever check or test you want, we are doing the
> tests in a "closed" enviroment, similar to a Lab.
>
> -----Mensaje original-----
> De: radiator-bounces at open.com.au [mailto:radiator-bounces at open.com.au]
> En nombre de Francisco Rodrigo Cortinas Maseda Enviado el: martes 19
> de enero de 2010 10:06
> Para: 'Hugh Irvine'
> CC: radiator at open.com.au
> Asunto: Re: [RADIATOR] Memory leak in Radiator 4.5-1
>
>
> Hi Hugh,
>
> Find attached my configuration; ill send you the traces as soon as i
> finish some other test i have arranged today with other platforms and
> services.
>
> Regards,
>
> -----Mensaje original-----
> De: Hugh Irvine [mailto:hugh at open.com.au]
> Enviado el: lunes 18 de enero de 2010 22:35
> Para: Francisco Rodrigo Cortinas Maseda
> CC: radiator at open.com.au
> Asunto: Re: [RADIATOR] Memory leak in Radiator 4.5-1
>
>
>
> Hello Francisco -
>
> Without seeing a copy of your configuration file and a corresponding
> trace 4 debug it is impossible to say what might be happening.
>
> Please send us the additional information and we'll take a look.
>
> regards
>
> Hugh
>
>
> On 19 Jan 2010, at 02:01, Francisco Rodrigo Cortinas Maseda wrote:
>
>> Hi everybody,
>>
>> im suffering a memory leak on Radiator 4.5-1. My enviroment:
>>
>> RHEL AS 5.4 i386
>>
>> Installed perl stuff (from the default installation):
>>
>> perl-5.8.8-27.el5
>> perl-String-CRC32-1.4-2.fc6
>>
>> Radiator has been installed as an RPM.
>>
>> Is there any memory leak bug detected on this version of Radiator?
>>
>> Note:: i have tested this also with RHEL AS 4.6 i386
>>
>>
>> ---------------------------------------------------------------------
>> -
>> ----------
>>
>> Este mensaje es privado y CONFIDENCIAL y se dirige exclusivamente a
>> su destinatario. Si usted ha recibido este mensaje por error, no debe
>> revelar, copiar, distribuir o usarlo en ningún sentido. Le rogamos lo
>> comunique al remitente y borre dicho mensaje y cualquier documento
>> adjunto que pudiera contener. El correo electrónico via Internet no
>> permite asegurar la confidencialidad de los mensajes que se
>> transmiten ni su integridad o correcta recepción. JAZZTEL no asume
>> responsabilidad por estas circunstancias. Si el destinatario de este
>> mensaje no consintiera la utilización del correo electrónico via
>> Internet y la grabación de los mensajes, rogamos lo ponga en nuestro
>> conocimiento de forma inmediata.Cualquier opinión expresada en este
>> mensaje pertenece únicamente al autor remitente, y no representa
>> necesariamente la opinión de JAZZTEL, a no ser que expresamente se
>> diga y el remitente esté autorizado para hacerlo.
>>
>>
>> ---------------------------------------------------------------------
>> -
>> ----------
>>
>>
>> This message is private and CONFIDENTIAL and it is intended
>> exclusively for its addressee. If you receive this message in error,
>> you should not disclose, copy, distribute this e-mail or use it in
>> any other way. Please inform the sender and delete the message and
>> attachments from your system.Internet e-mail neither guarantees the
>> confidentiality nor the integrity or proper receipt of the messages
>> sent. JAZZTEL does not assume any liability for those circumstances.
>> If the addressee of this message does not consent to the use of
>> Internet e-mail and message recording, please notify us
>> immediately.Any views or opinions contained in this message are
>> solely those of the author, and do not necessarily represent those of
>> JAZZTEL, unless otherwise specifically stated and the sender is
>> authorised to do so.
>>
>>
>> ---------------------------------------------------------------------
>> -
>> ----------
>> _______________________________________________
>> radiator mailing list
>> radiator at open.com.au http://www.open.com.au/mailman/listinfo/radiator
>
>
>
> NB:
>
> Have you read the reference manual ("doc/ref.html")?
> Have you searched the mailing list archive
> (www.open.com.au/archives/radiator)?
> Have you had a quick look on Google (www.google.com)?
> Have you included a copy of your configuration file (no secrets), together with a trace 4 debug showing what is happening?
>
> --
> Radiator: the most portable, flexible and configurable RADIUS server
> anywhere. Available on *NIX, *BSD, Windows, MacOS X. Includes support for reliable RADIUS transport (RadSec), and DIAMETER translation agent.
> -
> Nets: internetwork inventory and management - graphical, extensible, flexible with hardware, software, platform and database independence.
> -
> CATool: Private Certificate Authority for Unix and Unix-like systems.
>
>
>
>
> Antes de imprimir este e-mail piense bien si es necesario hacerlo.
>
>
> ----------------------------------------------------------------------
> ----------
>
> Este mensaje es privado y CONFIDENCIAL y se dirige exclusivamente a su
> destinatario. Si usted ha recibido este mensaje por error, no debe
> revelar, copiar, distribuir o usarlo en ningún sentido. Le rogamos lo
> comunique al remitente y borre dicho mensaje y cualquier documento
> adjunto que pudiera contener. El correo electrónico via Internet no
> permite asegurar la confidencialidad de los mensajes que se transmiten
> ni su integridad o correcta recepción. JAZZTEL no asume
> responsabilidad por estas circunstancias. Si el destinatario de este
> mensaje no consintiera la utilización del correo electrónico via
> Internet y la grabación de los mensajes, rogamos lo ponga en nuestro
> conocimiento de forma inmediata.Cualquier opinión expresada en este
> mensaje pertenece únicamente al autor remitente, y no representa
> necesariamente la opinión de JAZZTEL, a no ser que expresamente se
> diga y el remitente esté autorizado para hacerlo.
>
>
> ----------------------------------------------------------------------
> ----------
>
>
> This message is private and CONFIDENTIAL and it is intended
> exclusively for its addressee. If you receive this message in error,
> you should not disclose, copy, distribute this e-mail or use it in any
> other way. Please inform the sender and delete the message and
> attachments from your system.Internet e-mail neither guarantees the
> confidentiality nor the integrity or proper receipt of the messages
> sent. JAZZTEL does not assume any liability for those circumstances.
> If the addressee of this message does not consent to the use of
> Internet e-mail and message recording, please notify us
> immediately.Any views or opinions contained in this message are solely
> those of the author, and do not necessarily represent those of
> JAZZTEL, unless otherwise specifically stated and the sender is
> authorised to do so.
>
>
> ----------------------------------------------------------------------
> ----------
>
> Antes de imprimir este e-mail piense bien si es necesario hacerlo.
>
>
> ----------------------------------------------------------------------
> ----------
>
> Este mensaje es privado y CONFIDENCIAL y se dirige exclusivamente a su
> destinatario. Si usted ha recibido este mensaje por error, no debe
> revelar, copiar, distribuir o usarlo en ningún sentido. Le rogamos lo
> comunique al remitente y borre dicho mensaje y cualquier documento
> adjunto que pudiera contener. El correo electrónico via Internet no
> permite asegurar la confidencialidad de los mensajes que se transmiten
> ni su integridad o correcta recepción. JAZZTEL no asume
> responsabilidad por estas circunstancias. Si el destinatario de este
> mensaje no consintiera la utilización del correo electrónico via
> Internet y la grabación de los mensajes, rogamos lo ponga en nuestro
> conocimiento de forma inmediata.Cualquier opinión expresada en este
> mensaje pertenece únicamente al autor remitente, y no representa
> necesariamente la opinión de JAZZTEL, a no ser que expresamente se
> diga y el remitente esté autorizado para hacerlo.
>
>
> ----------------------------------------------------------------------
> ----------
>
>
> This message is private and CONFIDENTIAL and it is intended
> exclusively for its addressee. If you receive this message in error,
> you should not disclose, copy, distribute this e-mail or use it in any
> other way. Please inform the sender and delete the message and
> attachments from your system.Internet e-mail neither guarantees the
> confidentiality nor the integrity or proper receipt of the messages
> sent. JAZZTEL does not assume any liability for those circumstances.
> If the addressee of this message does not consent to the use of
> Internet e-mail and message recording, please notify us
> immediately.Any views or opinions contained in this message are solely
> those of the author, and do not necessarily represent those of
> JAZZTEL, unless otherwise specifically stated and the sender is
> authorised to do so.
>
>
> ----------------------------------------------------------------------
> ----------
> <vmstat_output.txt>



NB:

Have you read the reference manual ("doc/ref.html")?
Have you searched the mailing list archive (www.open.com.au/archives/radiator)?
Have you had a quick look on Google (www.google.com)?
Have you included a copy of your configuration file (no secrets), together with a trace 4 debug showing what is happening?

--
Radiator: the most portable, flexible and configurable RADIUS server anywhere. Available on *NIX, *BSD, Windows, MacOS X. Includes support for reliable RADIUS transport (RadSec), and DIAMETER translation agent.
-
Nets: internetwork inventory and management - graphical, extensible, flexible with hardware, software, platform and database independence.
-
CATool: Private Certificate Authority for Unix and Unix-like systems.




Antes de imprimir este e-mail piense bien si es necesario hacerlo.


--------------------------------------------------------------------------------

Este mensaje es privado y CONFIDENCIAL y se dirige exclusivamente a su destinatario. Si usted ha recibido este mensaje por error, no debe revelar, copiar, distribuir o usarlo en ningún sentido. Le rogamos lo comunique al remitente y borre dicho mensaje y cualquier documento adjunto que pudiera contener. El correo electrónico via Internet no permite asegurar la confidencialidad de los mensajes que se transmiten ni su integridad o correcta recepción. JAZZTEL no asume responsabilidad por estas circunstancias. Si el destinatario de este mensaje no consintiera la utilización del correo electrónico via Internet y la grabación de los mensajes, rogamos lo ponga en nuestro conocimiento de forma inmediata.Cualquier opinión expresada en este mensaje pertenece únicamente al autor remitente, y no representa necesariamente la opinión de JAZZTEL, a no ser que expresamente se diga y el remitente esté autorizado para hacerlo.


--------------------------------------------------------------------------------


This message is private and CONFIDENTIAL and it is intended exclusively for its addressee. If you receive this message in error, you should not disclose, copy, distribute this e-mail or use it in any other way. Please inform the sender and delete the message and attachments from your system.Internet e-mail neither guarantees the confidentiality nor the integrity or proper receipt of the messages sent. JAZZTEL does not assume any liability for those circumstances. If the addressee of this message does not consent to the use of Internet e-mail and message recording, please notify us immediately.Any views or opinions contained in this message are solely those of the author, and do not necessarily represent those of JAZZTEL, unless otherwise specifically stated and the sender is authorised to do so.


--------------------------------------------------------------------------------


More information about the radiator mailing list