<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
<p>Hello,</p>
<p>do you use utils module? If yes, what is your operating system
and the compiler version (if you compiled from sources, not
installing from packages)?</p>
<p>Cheers,<br>
Daniel<br>
</p>
<div class="moz-cite-prefix">On 10.05.21 15:01, Marrold wrote:<br>
</div>
<blockquote type="cite"
cite="mid:CAC-Lcd9wRwrm5a6BFiDfKfiCGQm8=kUmD-zAd+JWtB_xEaLe6Q@mail.gmail.com">
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<div dir="ltr">
<div class="gmail_quote">
<div dir="ltr">Hi,
<div><br>
</div>
<div>We're trying to upgrade from 5.3.X to 5.4.5 however
kamailio will not start and produces the following error,
despite the db_url being set in the config and printed in
the logs:</div>
<div><br>
</div>
<div><font face="monospace">Bad config - you can not call
'handle_publish' function (db_url not set)</font><br>
</div>
<div><br>
</div>
<div>Looking at the code this error only seems plausible if
the <i>pres_library_mode</i> is set to 1 <a
href="https://github.com/kamailio/kamailio/blob/cc2a9518207e36b7b18aef5c8714f0c21da3dd95/src/modules/presence/presence.c#L296"
target="_blank" moz-do-not-send="true">here</a> but we
don't see the corresponding "switch to library mode"
message in the debug logs which leaves me a bit stuck -
I've included the grepped logs at the bottom of the
message.<br>
<br>
Does anyone have any ideas what is causing this issue?
I've seen a previous issue relating to interactions
between presence and presence_xml which we're also using,
but it looks like this was fixed in an older version.</div>
<div><br>
</div>
<div>Any suggestions appreciated.<br>
<br>
<font face="monospace"># ----- presence params -----<br>
modparam("presence", "db_url", DBURL)<br>
modparam("presence", "db_update_period", 20)<br>
modparam("presence", "clean_period", 60)<br>
modparam("presence", "local_log_facility", "LOG_LOCAL3")<br>
modparam("presence", "max_expires", 14430)<br>
<br>
# ----- presence_xml params -----<br>
modparam("presence_xml", "db_url", DBURL)<br>
modparam("presence_xml", "force_active", 1)</font><br>
</div>
<div><br>
</div>
<div><font face="monospace">root@kamailio:/etc/kamailio#
grep -i "presence" /var/log/kamailio/kamailio.log<br>
May 10 12:44:14 kamailio /sbin/kamailio[23729]: ERROR:
presence [presence.c:656]: fixup_presence(): Bad config
- you can not call 'handle_publish' function (db_url not
set)<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/cfg.y:1810]: yyparse(): loading module presence.so<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/sr_module.c:525]: load_module(): trying to load
</lib64/kamailio/modules/presence.so><br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/kemi.c:2927]: sr_kemi_modules_add(): adding
module: presence<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/sr_module.c:287]: register_module(): register PV
from: presence<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/cfg.lex:1796]: pp_define(): defining id:
MOD_presence<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/cfg.y:1810]: yyparse(): loading module
presence_xml.so<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/sr_module.c:525]: load_module(): trying to load
</lib64/kamailio/modules/presence_xml.so><br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/kemi.c:2927]: sr_kemi_modules_add(): adding
module: presence_xml<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/cfg.lex:1796]: pp_define(): defining id:
MOD_presence_xml<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/cfg.y:1810]: yyparse(): loading module
presence_mwi.so<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/sr_module.c:525]: load_module(): trying to load
</lib64/kamailio/modules/presence_mwi.so><br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/cfg.lex:1796]: pp_define(): defining id:
MOD_presence_mwi<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/cfg.y:1810]: yyparse(): loading module
presence_dialoginfo.so<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/sr_module.c:525]: load_module(): trying to load
</lib64/kamailio/modules/presence_dialoginfo.so><br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/cfg.lex:1796]: pp_define(): defining id:
MOD_presence_dialoginfo<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/modparam.c:107]: set_mod_param_regex(): 'presence'
matches module 'presence'<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/sr_module.c:744]: find_param_export(): found
<db_url> in module presence
[/lib64/kamailio/modules/presence.so]<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/modparam.c:123]: set_mod_param_regex(): found
<db_url> in module presence
[/lib64/kamailio/modules/presence.so]<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/modparam.c:107]: set_mod_param_regex(): 'presence'
matches module 'presence'<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/sr_module.c:744]: find_param_export(): found
<db_update_period> in module presence
[/lib64/kamailio/modules/presence.so]<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/modparam.c:123]: set_mod_param_regex(): found
<db_update_period> in module presence
[/lib64/kamailio/modules/presence.so]<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/modparam.c:107]: set_mod_param_regex(): 'presence'
matches module 'presence'<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/sr_module.c:744]: find_param_export(): found
<clean_period> in module presence
[/lib64/kamailio/modules/presence.so]<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/modparam.c:123]: set_mod_param_regex(): found
<clean_period> in module presence
[/lib64/kamailio/modules/presence.so]<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/modparam.c:107]: set_mod_param_regex(): 'presence'
matches module 'presence'<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/sr_module.c:744]: find_param_export(): found
<local_log_facility> in module presence
[/lib64/kamailio/modules/presence.so]<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/modparam.c:123]: set_mod_param_regex(): found
<local_log_facility> in module presence
[/lib64/kamailio/modules/presence.so]<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/modparam.c:107]: set_mod_param_regex(): 'presence'
matches module 'presence'<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/sr_module.c:744]: find_param_export(): found
<max_expires> in module presence
[/lib64/kamailio/modules/presence.so]<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/modparam.c:123]: set_mod_param_regex(): found
<max_expires> in module presence
[/lib64/kamailio/modules/presence.so]<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/modparam.c:107]: set_mod_param_regex():
'presence_xml' matches module 'presence_xml'<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/sr_module.c:744]: find_param_export(): found
<db_url> in module presence_xml
[/lib64/kamailio/modules/presence_xml.so]<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/modparam.c:123]: set_mod_param_regex(): found
<db_url> in module presence_xml
[/lib64/kamailio/modules/presence_xml.so]<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/modparam.c:107]: set_mod_param_regex():
'presence_xml' matches module 'presence_xml'<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/sr_module.c:744]: find_param_export(): found
<force_active> in module presence_xml
[/lib64/kamailio/modules/presence_xml.so]<br>
May 10 12:44:41 kamailio kamailio: DEBUG: <core>
[core/modparam.c:123]: set_mod_param_regex(): found
<force_active> in module presence_xml
[/lib64/kamailio/modules/presence_xml.so]<br>
May 10 12:44:43 kamailio kamailio: DEBUG: <core>
[core/sr_module.c:652]: find_mod_export_record(): found
export of <handle_publish> in module presence
[/lib64/kamailio/modules/presence.so]<br>
May 10 12:44:43 kamailio kamailio: DEBUG: <core>
[core/sr_module.c:652]: find_mod_export_record(): found
export of <handle_subscribe> in module presence
[/lib64/kamailio/modules/presence.so]<br>
May 10 12:44:43 kamailio kamailio: DEBUG: <core>
[core/route.c:129]: route_add(): mapping routing block
(0x560e73f9a440)[PRESENCE] to 11<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
<core> [core/sr_module.c:873]: init_mod():
presence<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
presence [presence.c:293]: mod_init():
db_url=mysql://kamailio:PASSWORD@localhost/kamailio
(len=50 addr=0x7f3a33d4e288)<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
presence [presence.c:337]: mod_init(): server_address
parameter not set in configuration file<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
presence [subscribe.c:2529]: restore_db_subs(): loading
information from database 0 records<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
<core> [core/sr_module.c:873]: init_mod():
presence_xml<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
presence_xml [presence_xml.c:170]: mod_init():
db_url=mysql://kamailio:PASSWORD@localhost/kamailio
(len=50 addr=0x7f3a33d4ef00)<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
<core> [core/sr_module.c:652]:
find_mod_export_record(): found export of
<bind_presence> in module presence
[/lib64/kamailio/modules/presence.so]<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
presence [event_list.c:324]: search_event(): start
event= [presence/1]<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
presence [event_list.c:324]: search_event(): start
event= [presence.winfo/2]<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
presence [event_list.c:239]: add_event(): successfully
added event: presence - len= 8<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
presence_xml [add_events.c:75]: xml_add_events(): added
'presence' event to presence module<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
presence [event_list.c:324]: search_event(): start
event= [presence.winfo/2]<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
presence [event_list.c:324]: search_event(): start
event= [presence/1]<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
presence [event_list.c:188]: add_event(): Found wipeer
event [presence] for event [presence.winfo]<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
presence [event_list.c:239]: add_event(): successfully
added event: presence.winfo - len= 14<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
presence_xml [add_events.c:94]: xml_add_events(): added
'presence.winfo' event to presence module<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
presence [event_list.c:324]: search_event(): start
event= [xcap-diff/0]<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
presence [event_list.c:324]: search_event(): start
event= [xcap-diff.winfo/0]<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
presence [event_list.c:239]: add_event(): successfully
added event: xcap-diff - len= 9<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
presence_xml [add_events.c:132]: xml_add_events(): added
'xcap-diff' event to presence module<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
<core> [core/sr_module.c:873]: init_mod():
presence_mwi<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
<core> [core/sr_module.c:652]:
find_mod_export_record(): found export of
<bind_presence> in module presence
[/lib64/kamailio/modules/presence.so]<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
presence [event_list.c:324]: search_event(): start
event= [message-summary/6]<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
presence [event_list.c:324]: search_event(): start
event= [message-summary.winfo/0]<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
presence [event_list.c:239]: add_event(): successfully
added event: message-summary - len= 15<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
<core> [core/sr_module.c:873]: init_mod():
presence_dialoginfo<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
<core> [core/sr_module.c:652]:
find_mod_export_record(): found export of
<bind_presence> in module presence
[/lib64/kamailio/modules/presence.so]<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
presence [event_list.c:324]: search_event(): start
event= [dialog/5]<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
presence [event_list.c:324]: search_event(): start
event= [dialog.winfo/0]<br>
May 10 12:44:45 kamailio /sbin/kamailio[23830]: DEBUG:
presence [event_list.c:239]: add_event(): successfully
added event: dialog - len= 6<br>
May 10 12:44:47 kamailio /sbin/kamailio[23830]: ERROR:
presence [presence.c:656]: fixup_presence(): Bad config
- you can not call 'handle_publish' function (db_url not
set)<br>
May 10 12:44:47 kamailio /sbin/kamailio[23830]: DEBUG:
presence_xml [presence_xml.c:295]: destroy(): start<br>
May 10 12:44:47 kamailio /sbin/kamailio[23830]: DEBUG:
presence [subscribe.c:2433]: timer_db_update():
db_update timer<br>
May 10 12:44:47 kamailio /sbin/kamailio[23830]: DEBUG:
presence [subscribe.c:2137]: update_db_subs_timer():
update_db_subs_timer: start</font><br>
</div>
<div><br>
</div>
<div><br>
</div>
<div><br>
</div>
<div><br>
</div>
</div>
</div>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<pre class="moz-quote-pre" wrap="">__________________________________________________________
Kamailio - Users Mailing List - Non Commercial Discussions
* <a class="moz-txt-link-abbreviated" href="mailto:sr-users@lists.kamailio.org">sr-users@lists.kamailio.org</a>
Important: keep the mailing list in the recipients, do not reply only to the sender!
Edit mailing list options or unsubscribe:
* <a class="moz-txt-link-freetext" href="https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users">https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users</a>
</pre>
</blockquote>
<pre class="moz-signature" cols="72">--
Daniel-Constantin Mierla -- <a class="moz-txt-link-abbreviated" href="http://www.asipto.com">www.asipto.com</a>
<a class="moz-txt-link-abbreviated" href="http://www.twitter.com/miconda">www.twitter.com/miconda</a> -- <a class="moz-txt-link-abbreviated" href="http://www.linkedin.com/in/miconda">www.linkedin.com/in/miconda</a>
Kamailio Advanced Training - Online
May 17-20, 2021 (Europe Timezone) - June 7-10, 2021 (America Timezone)
* <a class="moz-txt-link-freetext" href="https://www.asipto.com/sw/kamailio-advanced-training-online/">https://www.asipto.com/sw/kamailio-advanced-training-online/</a></pre>
</body>
</html>