Freeradius consuming a lot of memory > 1.6G
- To: "FreeRadius users mailing list" <freeradius-users@lists.freeradius.org>
- Subject: Freeradius consuming a lot of memory > 1.6G
- From: "Pshem Kowalczyk" <pshem.k@gmail.com>
- Date: Fri, 27 Oct 2006 10:46:50 +1300
- Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:mime-version:content-type:content-transfer-encoding:content-disposition; b=mbZ6t3FPXSgDlxV6GmjwZRstO/6AG97IIfjuKREGxKy/vF08Q18pdcDTblXTrlvF42SKMfnATX3DvAw1zgHxMCUDEkwvg9AXNe0BZiNakovTOjphqndJ70S+bb3r9yPpkd4Q9Abd6d7M3mR5/B0tAG75IHEs1gbXdPcedt58D04=
- Reply-to: FreeRadius users mailing list <freeradius-users@lists.freeradius.org>
Hi,
We've built a radius-proxy using freeradius and rlm_perl (with
ithreads). Currently we have the following settings:
thread pool {
start_servers = 20
max_servers = 100
min_spare_servers = 20
max_spare_servers = 50
max_requests_per_server = 500
}
perl {
module = /usr/lib/perl5/rlmPerl.pm
func_authenticate = authenticate
func_authorize = authorize
func_preacct = preacct
func_accounting = accounting
func_checksimul = checksimul
func_pre_proxy = pre_proxy
func_post_proxy = post_proxy
func_post_auth = post_auth
func_xlat = xlat
func_detach = detach
max_clones = 100
start_clones = 20
min_spare_clones = 20
max_spare_clones = 100
cleanup_delay = 5
max_request_per_clone = 100
}
The whole setup works fine (there are two machines, load-balanced).
Every single request is piped to the rlm_perl. The number of threads
(ps -eLf) oscillates around 45-50 on both machines. There are no
dealys, or any problems, except for the huge memory consumption.
Authentication request are simply proxied (with minimal changes to the
packets - filtering out some attributes and setting the others, no db
access), accounting is send to a session database (postgresql) on a
separate machine (no load problems there).
Should freeradius use that amount of memory?
The amount of memory is directly linked to the number of threads -
with 25 threads (in the middle of the night) the memory consumption
drops to about 900M.
perl useses the following modules:
use DBI;
use Digest::JHash qw(jhash);
use IPC::Shareable (':lock');
use Storable;
(all variables shared between perl threads are stored in shared memory
using perl IPC).
So the question is should freeradius use that amount of memory and how
can I decrease that?
regards
pshemko
This archive was generated by a fusion of
Pipermail (Mailman edition) and
MHonArc.