<div dir="ltr"><div><div><div><div><div>Hello,<br></div>Right now I'm using registrar functions only in request_route.<br><br></div><div>At first i had disabled both, after received your email, I disabled one by one and I see that the only the parameter that is affecting this, is modparam("registrar", "xavp_rcd", "ulrcd")<br></div><br></div>Let me know if do you need more information.<br><br></div>Regards<br></div>José<br></div><div class="gmail_extra"><br><div class="gmail_quote">2016-07-04 13:20 GMT+01:00 Daniel-Constantin Mierla <span dir="ltr"><<a href="mailto:miconda@gmail.com" target="_blank">miconda@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000">
<p>Hello,</p>
<p>very useful information -- are you using the registrar functions
only inside request_route, or you have them also in failure_route
or other type of routes?</p>
<p>Were you able to detect if both cause the leak or you disabled
both of them without trying each one?<br>
</p>
<p>Cheers,<br>
Daniel<br>
</p><div><div class="h5">
<br>
<div>On 04/07/16 14:01, José Seabra wrote:<br>
</div>
<blockquote type="cite">
<div dir="ltr">
<div>
<div>
<div>
<div>
<div>
<div>
<div>Hello Daniel,<br>
<br>
</div>
I think that the issue is on registrar module.<br>
<br>
</div>
I'm using the following parameters:<br>
<ul>
<li>modparam("registrar", "xavp_cfg", "regcfg")</li>
<li>modparam("registrar", "xavp_rcd", "ulrcd")</li>
</ul>
</div>
If I disable it there isn't memory leak.<br>
<br>
</div>
Let me know if you need more information.<br>
<br>
</div>
Thank you <br>
</div>
Regards<br>
</div>
José<br>
</div>
<div class="gmail_extra"><br>
<div class="gmail_quote">2016-07-04 11:27 GMT+01:00
Daniel-Constantin Mierla <span dir="ltr"><<a href="mailto:miconda@gmail.com" target="_blank"></a><a href="mailto:miconda@gmail.com" target="_blank">miconda@gmail.com</a>></span>:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000">
<p>Hello,</p>
<p>can you provide more details about where you use xavps
in the configuration file? Do you use them in some route
block executed by rtimer or via asyn framework (e.g.,
via t_continue() or async module)?</p>
<p>Cheers,<br>
Daniel<br>
</p>
<div>
<div> <br>
<div>On 03/07/16 20:35, José Seabra wrote:<br>
</div>
<blockquote type="cite">
<div dir="ltr">Hello,
<div>I'm monitoring these testes with
"corex.shm_summary" provided by kamcmd.</div>
<div><br>
</div>
<div>I'm noticing that the core module - xavp.c
is consuming lot of memory and it is increasing.</div>
<div><br>
</div>
<div>result of command corex.shm_summary is:</div>
<div><br>
</div>
<div>
<div>
<div> fm_status: summarizing all alloc'ed.
fragments:</div>
<div> fm_status: count= 2 size= 1120
bytes from tm: t_reply.c: _reply_light(542)</div>
<div> fm_status: count= 2 size= 896
bytes from tm: t_msgbuilder.c:
build_uac_req(1543)</div>
<div> fm_status: count= 2182 size= 231088
bytes from tm: t_fwd.c: prepare_new_uac(479)</div>
<div> fm_status: count= 12488 size= 12050808
bytes from tm: t_reply.c: relay_reply(1884)</div>
<div> fm_status: count= 12490 size= 14564656
bytes from core: msg_translator.c:
build_req_buf_from_sip_req(2149)</div>
<div> fm_status: count= 12492 size= 71366536
bytes from tm: h_table.c: build_cell(317)</div>
<div> fm_status: count= 12490 size= 75086184
bytes from core: sip_msg_clone.c:
sip_msg_shm_clone(494)</div>
<div> fm_status: count= 2 size= 96
bytes from tm: t_hooks.c: insert_tmcb(137)</div>
<div> fm_status: count= 2182 size= 17800
bytes from tm: t_fwd.c: prepare_new_uac(524)</div>
<div> fm_status: count= 3 size= 512
bytes from htable: ht_api.c:
ht_cell_new(183)</div>
<div> fm_status: count= 12490 size= 10586712
bytes from core: sip_msg_clone.c:
msg_lump_cloner(978)</div>
<div> fm_status: count= 56508 size= 3457904
bytes from core: usr_avp.c: create_avp(175)</div>
<div> fm_status: count= 4 size= 600
bytes from tmx: tmx_pretran.c:
tmx_check_pretran(250)</div>
<div> fm_status: count= 4 size= 1008
bytes from usrloc: ucontact.c:
new_ucontact(98)</div>
<div> fm_status: count= 4 size= 1320
bytes from tmx: tmx_pretran.c:
tmx_check_pretran(271)</div>
<div> fm_status: count= 4 size= 144
bytes from usrloc: urecord.c:
new_urecord(65)</div>
<div> fm_status: count= 4 size= 328
bytes from usrloc: urecord.c:
new_urecord(58)</div>
<div> fm_status: count= 24 size= 952
bytes from usrloc: ../../ut.h:
shm_str_dup(723)</div>
<div> fm_status: count= 2182 size= 53040
bytes from tm: t_fwd.c: prepare_new_uac(509)</div>
<div> fm_status: count=12545409
size=1420184592 bytes from core: xavp.c:
xavp_new_value(94)</div>
<div> fm_status: count= 4 size= 128
bytes from dmq: worker.c:
alloc_job_queue(229)</div>
<div> fm_status: count= 1 size= 13440
bytes from core: counters.c:
counters_prefork_init(207)</div>
<div> fm_status: count= 1 size= 4032
bytes from sl: sl_stats.c:
init_sl_stats_child(125)</div>
<div> fm_status: count= 1 size= 256
bytes from tmx: tmx_pretran.c:
tmx_init_pretran_table(90)</div>
<div> fm_status: count= 1 size= 5376
bytes from tm: t_stats.c:
init_tm_stats_child(60)</div>
<div> fm_status: count= 1 size= 1008
bytes from kex: pkg_stats.c:
pkg_proc_stats_init(79)</div>
<div> fm_status: count= 3 size= 88
bytes from core: cfg/cfg_struct.c:
cfg_clone_str(130)</div>
<div> fm_status: count= 1 size= 744
bytes from core: cfg/cfg_struct.c:
cfg_shmize(217)</div>
<div> fm_status: count= 3 size= 64
bytes from usrloc: udomain.c:
build_stat_name(51)</div>
<div> fm_status: count= 1 size= 40960
bytes from usrloc: udomain.c:
new_udomain(93)</div>
<div> fm_status: count= 1 size= 48
bytes from usrloc: udomain.c:
new_udomain(86)</div>
<div> fm_status: count= 1 size= 16
bytes from usrloc: dlist.c: new_dlist(573)</div>
<div> fm_status: count= 1 size= 32
bytes from usrloc: dlist.c: new_dlist(565)</div>
<div> fm_status: count= 1 size= 8
bytes from core: pt.c: init_pt(110)</div>
<div> fm_status: count= 1 size= 8
bytes from core: pt.c: init_pt(105)</div>
<div> fm_status: count= 1 size= 2944
bytes from core: pt.c: init_pt(104)</div>
<div> fm_status: count= 1 size= 32
bytes from usrloc: ul_callback.c:
register_ulcb(94)</div>
<div> fm_status: count= 1 size= 24
bytes from dmq: ../../ut.h: shm_str_dup(723)</div>
<div> fm_status: count= 1 size= 448
bytes from dmq: dmqnode.c:
build_dmq_node(156)</div>
<div> fm_status: count= 2 size= 168
bytes from dmq: peer.c: add_peer(67)</div>
<div> fm_status: count= 1 size= 8
bytes from dmq: dmq.c: mod_init(243)</div>
<div> fm_status: count= 1 size= 96
bytes from dmq: dmq.c: mod_init(237)</div>
<div> fm_status: count= 1 size= 24
bytes from dmq: dmqnode.c:
init_dmq_node_list(66)</div>
<div> fm_status: count= 1 size= 24
bytes from dmq: peer.c: init_peer_list(33)</div>
<div> fm_status: count= 1 size= 16
bytes from usrloc: ul_callback.c:
init_ulcb_list(45)</div>
<div> fm_status: count= 1 size= 4112
bytes from usrloc: ../../lock_alloc.h:
lock_set_alloc(70)</div>
<div> fm_status: count= 1 size= 8
bytes from carrierroute: cr_data.c:
rule_fixup_recursor(584)</div>
<div> fm_status: count= 5 size= 56
bytes from carrierroute: ../../ut.h:
shm_str_dup(723)</div>
<div> fm_status: count= 1 size= 152
bytes from carrierroute: cr_rule.c:
add_route_rule(74)</div>
<div> fm_status: count= 3 size= 240
bytes from core: dtrie.c: dtrie_insert(157)</div>
<div> fm_status: count= 3 size= 48
bytes from core: dtrie.c: dtrie_insert(148)</div>
<div> fm_status: count= 1 size= 48
bytes from carrierroute: cr_rule.c:
add_route_flags(225)</div>
<div> fm_status: count= 2 size= 160
bytes from core: dtrie.c: dtrie_init(60)</div>
<div> fm_status: count= 2 size= 32
bytes from core: dtrie.c: dtrie_init(51)</div>
<div> fm_status: count= 1 size= 32
bytes from carrierroute: cr_domain.c:
create_domain_data(83)</div>
<div> fm_status: count= 1 size= 8
bytes from carrierroute: cr_carrier.c:
create_carrier_data(59)</div>
<div> fm_status: count= 1 size= 64
bytes from carrierroute: cr_carrier.c:
create_carrier_data(50)</div>
<div> fm_status: count= 1 size= 8
bytes from carrierroute: cr_db.c:
load_route_data_db(295)</div>
<div> fm_status: count= 5 size= 1008
bytes from dispatcher: dispatch.c:
reindex_dests(600)</div>
<div> fm_status: count= 1 size= 48
bytes from carrierroute: cr_db.c:
load_domain_map(182)</div>
<div> fm_status: count= 1 size= 24
bytes from carrierroute: cr_db.c:
load_domain_map(171)</div>
<div> fm_status: count= 1 size= 48
bytes from carrierroute: cr_db.c:
load_carrier_map(126)</div>
<div> fm_status: count= 1 size= 24
bytes from carrierroute: cr_db.c:
load_carrier_map(115)</div>
<div> fm_status: count= 7 size= 168
bytes from dispatcher: dispatch.c:
add_dest2list(350)</div>
<div> fm_status: count= 1 size= 64
bytes from carrierroute: cr_data.c:
reload_route_data(172)</div>
<div> fm_status: count= 1 size= 8
bytes from carrierroute: cr_data.c:
init_route_data(74)</div>
<div> fm_status: count= 5 size= 4200
bytes from dispatcher: dispatch.c:
add_dest2list(324)</div>
<div> fm_status: count= 1 size= 16
bytes from dispatcher: dispatch.c:
init_data(204)</div>
<div> fm_status: count= 1 size= 16
bytes from dispatcher: dispatch.c:
init_data(195)</div>
<div> fm_status: count= 1 size= 8
bytes from dispatcher: dispatcher.c:
mod_init(309)</div>
<div> fm_status: count= 1 size= 8
bytes from dispatcher: dispatcher.c:
mod_init(307)</div>
<div> fm_status: count= 1 size= 8
bytes from dispatcher: dispatch.c:
ds_ping_active_init(102)</div>
<div> fm_status: count= 1 size= 256
bytes from db_text: dbt_lib.c:
dbt_init_cache(81)</div>
<div> fm_status: count= 1 size= 8
bytes from db_text: dbt_lib.c:
dbt_init_cache(69)</div>
<div> fm_status: count= 1 size= 8
bytes from db_text: dbt_lib.c:
dbt_init_cache(54)</div>
<div> fm_status: count= 3 size= 288
bytes from core: timer.c:
register_timer(1011)</div>
<div> fm_status: count= 4 size= 8388608
bytes from htable: ht_api.c:
ht_init_tables(381)</div>
<div> fm_status: count= 1 size= 8
bytes from sl: sl_funcs.c: sl_startup(83)</div>
<div> fm_status: count= 1 size= 8
bytes from sl: sl_stats.c:
init_sl_stats(110)</div>
<div> fm_status: count= 1 size= 16
bytes from tm: t_hooks.c:
init_tmcb_lists(74)</div>
<div> fm_status: count= 1 size= 16
bytes from tm: t_hooks.c:
init_tmcb_lists(72)</div>
<div> fm_status: count= 1 size= 2097152
bytes from tm: h_table.c:
init_hash_table(467)</div>
<div> fm_status: count= 2 size= 64
bytes from core: cfg/cfg_ctx.c:
cfg_register_ctx(47)</div>
<div> fm_status: count= 1 size= 80
bytes from db_postgres: ../../lock_alloc.h:
lock_set_alloc(70)</div>
<div> fm_status: count= 1 size= 8192
bytes from core: tcp_main.c: init_tcp(4635)</div>
<div> fm_status: count= 1 size= 32768
bytes from core: tcp_main.c: init_tcp(4629)</div>
<div> fm_status: count= 1 size= 8
bytes from core: tcp_main.c: init_tcp(4621)</div>
<div> fm_status: count= 1 size= 8
bytes from core: tcp_main.c: init_tcp(4614)</div>
<div> fm_status: count= 1 size= 8
bytes from core: tcp_main.c: init_tcp(4607)</div>
<div> fm_status: count= 1 size= 8
bytes from core: tcp_main.c: init_tcp(4601)</div>
<div> fm_status: count= 1 size= 8
bytes from core: tcp_main.c: init_tcp(4589)</div>
<div> fm_status: count= 1 size= 8
bytes from core: usr_avp.c: init_avps(90)</div>
<div> fm_status: count= 1 size= 8
bytes from core: usr_avp.c: init_avps(89)</div>
<div> fm_status: count= 1 size= 16384
bytes from core: dst_blacklist.c:
init_dst_blacklist(437)</div>
<div> fm_status: count= 1 size= 8
bytes from core: dst_blacklist.c:
init_dst_blacklist(430)</div>
<div> fm_status: count= 2 size= 96
bytes from core: timer.c: timer_alloc(514)</div>
<div> fm_status: count= 1 size= 8
bytes from core: dns_cache.c:
init_dns_cache(366)</div>
<div> fm_status: count= 1 size= 16384
bytes from core: dns_cache.c:
init_dns_cache(358)</div>
<div> fm_status: count= 1 size= 16
bytes from core: dns_cache.c:
init_dns_cache(351)</div>
<div> fm_status: count= 1 size= 8
bytes from core: dns_cache.c:
init_dns_cache(345)</div>
<div> fm_status: count= 1 size= 8
bytes from core: timer.c: init_timer(283)</div>
<div> fm_status: count= 1 size= 16384
bytes from core: timer.c: init_timer(282)</div>
<div> fm_status: count= 1 size= 8
bytes from core: timer.c: init_timer(281)</div>
<div> fm_status: count= 1 size= 8
bytes from core: timer.c: init_timer(280)</div>
<div> fm_status: count= 1 size= 8
bytes from core: timer.c: init_timer(269)</div>
<div> fm_status: count= 1 size= 8
bytes from core: timer.c: init_timer(237)</div>
<div> fm_status: count= 1 size= 278544
bytes from core: timer.c: init_timer(220)</div>
<div> fm_status: count= 1 size= 8
bytes from core: timer.c: init_timer(219)</div>
<div> fm_status: count= 1 size= 8
bytes from core: timer.c: init_timer(206)</div>
<div> fm_status: count= 1 size= 64
bytes from core: cfg/cfg_struct.c:
cfg_child_cb_new(830)</div>
<div> fm_status: count= 1 size= 8
bytes from core: cfg/cfg_struct.c:
sr_cfg_init(361)</div>
<div> fm_status: count= 1 size= 8
bytes from core: cfg/cfg_struct.c:
sr_cfg_init(354)</div>
<div> fm_status: count= 1 size= 8
bytes from core: cfg/cfg_struct.c:
sr_cfg_init(347)</div>
<div> fm_status: count= 1 size= 8
bytes from core: cfg/cfg_struct.c:
sr_cfg_init(335)</div>
<div> fm_status: count= 1 size= 8
bytes from core: cfg/cfg_struct.c:
sr_cfg_init(323)</div>
<div> fm_status: count= 4 size= 928
bytes from htable: ht_api.c:
ht_add_table(278)</div>
<div> fm_status: count= 1 size= 8
bytes from core: mem/shm.c:
shm_core_lock_init(153)</div>
<div> fm_status: -----------------------------</div>
</div>
</div>
<div><br>
</div>
<div>
<div>If i stop these tests and after few
minutes, run again the command
"corex.shm_summary" the entry that contains
the memory consume for xavp.c doesn't
decrease.</div>
<div><br>
</div>
<div>It seems that there is a memory leak in
this module xavp.c.</div>
</div>
<div><br>
</div>
<div>Thank you for your help.</div>
<div>Regards</div>
<div>José</div>
</div>
<div class="gmail_extra"><br>
</div>
</blockquote>
<br>
<blockquote type="cite"> </blockquote>
<br>
</div>
</div>
<span><font color="#888888">
<pre cols="72">--
Daniel-Constantin Mierla
<a href="http://www.asipto.com" target="_blank">http://www.asipto.com</a> - <a href="http://www.kamailio.org" target="_blank">http://www.kamailio.org</a>
<a href="http://twitter.com/#%21/miconda" target="_blank">http://twitter.com/#!/miconda</a> - <a href="http://www.linkedin.com/in/miconda" target="_blank">http://www.linkedin.com/in/miconda</a></pre>
</font></span></div>
<br>
_______________________________________________<br>
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users
mailing list<br>
<a href="mailto:sr-users@lists.sip-router.org" target="_blank">sr-users@lists.sip-router.org</a><br>
<a href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users" rel="noreferrer" target="_blank">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users</a><br>
<br>
</blockquote>
</div>
<br>
<br clear="all">
<br>
-- <br>
<div data-smartmail="gmail_signature">Cumprimentos
<div>José Seabra</div>
</div>
</div>
</blockquote>
<br>
<pre cols="72">--
Daniel-Constantin Mierla
<a href="http://www.asipto.com" target="_blank">http://www.asipto.com</a> - <a href="http://www.kamailio.org" target="_blank">http://www.kamailio.org</a>
<a href="http://twitter.com/#!/miconda" target="_blank">http://twitter.com/#!/miconda</a> - <a href="http://www.linkedin.com/in/miconda" target="_blank">http://www.linkedin.com/in/miconda</a></pre>
</div></div></div>
</blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature" data-smartmail="gmail_signature">Cumprimentos<div>José Seabra</div></div>
</div>