[OpenSIPS-Devel] [ opensips-Bugs-3377861 ] fifo dr_reload memory leak
SourceForge.net
noreply at sourceforge.net
Tue Jul 26 05:20:56 CEST 2011
Bugs item #3377861, was opened at 2011-07-25 23:20
Message generated for change (Tracker Item Submitted) made by davemay99
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=1086410&aid=3377861&group_id=232389
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: modules
Group: 1.6.x
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Dave May (davemay99)
Assigned to: Nobody/Anonymous (nobody)
Summary: fifo dr_reload memory leak
Initial Comment:
Using svn8195 of 1.6 branch, a steady memory leak occurs when performing multiple iterations of "opensipsctl fifo dr_reload". The DR_RULES table is stored in MySQL, and contains just under 32000 entries. The following script demonstrates the problem, and results in failure after about 519 iterations when OpenSIPS is compiled with 4MB pkg memory.
#!/bin/bash
COUNTER=0
while [ $COUNTER -lt $1 ]; do
opensipsctl fifo dr_reload
opensipsctl fifo get_statistics pkmem: | grep pkmem:3-real_used_size
let COUNTER=COUNTER+1
done
Script output on 519th iteration:
518: Mon Jul 25 22:54:05 EDT 2011
500 Failed to reload
pkmem:3-real_used_size = 3876904
output from "opensipsctl fifo get_statistics pkmem: | grep pkmem:3-"
pkmem:3-total_size = 4194304
pkmem:3-used_size = 2313144
pkmem:3-real_used_size = 4182476
pkmem:3-max_used_size = 4187992
pkmem:3-free_size = 11828
pkmem:3-fragments = 74
Failure presents itself with the following in the logs at debug=3
Jul 25 22:54:08 sipdev1 /usr/sbin/opensips[520]: INFO:drouting:dr_reload_cmd: "dr_reload" MI command received!
Jul 25 22:54:08 sipdev1 /usr/sbin/opensips[520]: ERROR:core:db_allocate_rows: no memory left
Jul 25 22:54:08 sipdev1 /usr/sbin/opensips[520]: ERROR:db_mysql:db_mysql_fetch_result: no memory left
Jul 25 22:54:08 sipdev1 /usr/sbin/opensips[520]: ERROR:drouting:dr_load_routing_info: Error fetching rows
Jul 25 22:54:08 sipdev1 /usr/sbin/opensips[520]: CRITICAL:drouting:dr_reload_data: failed to load routing info
Jul 25 22:54:08 sipdev1 /usr/sbin/opensips[520]: CRITICAL:drouting:dr_reload_cmd: failed to load routing data
Jul 25 22:54:08 sipdev1 /usr/sbin/opensips[520]: ERROR:mi_fifo:mi_open_reply_pipe: open error (/tmp/opensips_receiver_17638): No such file or directory
Jul 25 22:54:08 sipdev1 /usr/sbin/opensips[520]: ERROR:mi_fifo:mi_fifo_server: cannot open reply pipe /tmp/opensips_receiver_17638
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=1086410&aid=3377861&group_id=232389
More information about the Devel
mailing list