Hello Daniel,
yes, with the production config I still get a core, not with the testing
config, though. The last line in log with testing config is:
Dec 4 13:28:06 lvm-centos-kamailio1 /sbin/kamailio[8045]: ERROR: <core>
[action.c:1572]: run_actions(): WARNING: too many recursive routing table
lookups (101) giving up!
Dec 4 13:28:06 lvm-centos-kamailio1 /sbin/kamailio[8045]: WARNING: <core>
[receive.c:214]: receive_msg(): WARNING: receive_msg: error while trying
script
But I have 2 cores, each 52M in size from production config. I will bzip
them and send them via email.
Kind regards,
Timo Klecker
Von: Daniel-Constantin Mierla [mailto:miconda@gmail.com]
Gesendet: Donnerstag, 4. Dezember 2014 15:18
An: Timo Klecker; 'Kamailio (SER) - Users Mailing List'
Betreff: Re: AW: [SR-Users] Kamailio Crash when modifying username of
Request Uri
Hello,
do you still get a core file? The easiest to troubleshoot is to get the
backtrace from the core with gdb. Setting up a testbed requires more
resources, not trivial when out of the office.
Cheers,
Daniel
On 04/12/14 14:21, Timo Klecker wrote:
Hi Daniel,
I was able to recreate the Issue with the newer version (4.1.6). Please find
attached Kamailio configuration and sip-invite. (Please change modules path
according to installation)
The attached Kamailio configuration is a (very) simplified configuration we
are running in production.
10.10.207.20 is a server running the attached Kamailio configuration.
10.10.210.71 is a server running sipsak, sending the attached invite.
sipsak -s sip:10.10.207.20:5060 -f invite.txt
The crash seems to occur due to a missing exit of the configuration loop. So
to get rid of the crash I would break the loop if $rU equals null after
modification in MODIFY_NUMBER.
The issue now simplifies to:
You cannot empty $rU when a password is set, because the URI becomes invalid
due to missing @: bad uri <sip::pass10.10.207.20> <sip::pass10.10.207.20>
Dec 4 13:27:50 /sbin/kamailio[8043]: NOTICE: <script>: ru initial:
sip:123456:pass@10.10.207.20
Dec 4 13:27:50 /sbin/kamailio[8043]: ERROR: pv [pv_core.c:304]:
pv_get_ruri_attr(): failed to parse the R-URI
Dec 4 13:27:50 /sbin/kamailio[8043]: NOTICE: <script>: rU set to: <null>
Dec 4 13:27:50 /sbin/kamailio[8043]: ERROR: pv [pv_core.c:236]:
pv_get_ruri(): failed to parse the R-URI
Dec 4 13:27:50 /sbin/kamailio[8043]: NOTICE: <script>: ru set to: <null>
Dec 4 13:27:50 /sbin/kamailio[8043]: ERROR: pv [pv_core.c:304]:
pv_get_ruri_attr(): failed to parse the R-URI
Dec 4 13:27:50 /sbin/kamailio[8043]: ERROR: <core> [action.c:805]:
do_action(): ERROR: do_action: bad uri <sip::pass10.10.207.20>
<sip::pass10.10.207.20>, dropping packet
Dec 4 13:27:50 /sbin/kamailio[8043]: ERROR: <core> [action.c:1553]:
do_action(): run action error at: :0
Dec 4 13:27:50 /sbin/kamailio[8043]: ERROR: pv [pv_core.c:2080]:
pv_set_ruri_user(): do action failed
Dec 4 13:27:50 /sbin/kamailio[8043]: ERROR: <core> [lvalue.c:363]:
lval_pvar_assign(): setting pvar failed
Dec 4 13:27:50 /sbin/kamailio[8043]: ERROR: <core> [lvalue.c:416]:
lval_assign(): assignment failed at pos: (49,11-49,21)
This loops:
Dec 4 13:27:50 /sbin/kamailio[8043]: ERROR: pv [pv_core.c:304]:
pv_get_ruri_attr(): failed to parse the R-URI
Dec 4 13:27:50 /sbin/kamailio[8043]: NOTICE: <script>: rU set to: <null>
Dec 4 13:27:50 /sbin/kamailio[8043]: ERROR: pv [pv_core.c:236]:
pv_get_ruri(): failed to parse the R-URI
Dec 4 13:27:50 /sbin/kamailio[8043]: NOTICE: <script>: ru set to: <null>
Dec 4 13:27:50 /sbin/kamailio[8043]: ERROR: pv [pv_core.c:304]:
pv_get_ruri_attr(): failed to parse the R-URI
Dec 4 13:27:50 /sbin/kamailio[8043]: ERROR: pv [pv_core.c:304]:
pv_get_ruri_attr(): failed to parse the R-URI
Dec 4 13:27:50 /sbin/kamailio[8043]: ERROR: <core> [lvalue.c:356]:
lval_pvar_assign(): non existing right pvar
Dec 4 13:27:50 /sbin/kamailio[8043]: ERROR: <core> [action.c:805]:
do_action(): ERROR: do_action: bad uri <sip::pass10.10.207.20>
<sip::pass10.10.207.20>, dropping packet
Dec 4 13:27:50 /sbin/kamailio[8043]: ERROR: <core> [action.c:1553]:
do_action(): run action error at: :0
Dec 4 13:27:50 /sbin/kamailio[8043]: ERROR: pv [pv_core.c:2059]:
pv_set_ruri_user(): do action failed)
Dec 4 13:27:50 /sbin/kamailio[8043]: ERROR: <core> [lvalue.c:363]:
lval_pvar_assign(): setting pvar failed
Dec 4 13:27:50 /sbin/kamailio[8043]: ERROR: <core> [lvalue.c:416]:
lval_assign(): assignment failed at pos: (46,11-46,26)
Kind regards
Timo Klecker
Von: sr-users-bounces(a)lists.sip-router.org
[mailto:sr-users-bounces@lists.sip-router.org] Im Auftrag von
Daniel-Constantin Mierla
Gesendet: Montag, 1. Dezember 2014 23:35
An: Kamailio (SER) - Users Mailing List
Betreff: Re: [SR-Users] Kamailio Crash when modifying username of Request
Uri
Hello,
the version is indeed very old -- however, you got a core dump, according to
the logs, maybe you can send over the backtrace to see where it crashed.
Cheers,
Daniel
On 28/11/14 18:05, Timo Klecker wrote:
Hi all!
Our Kamailio (3.1.4) crashed when modifying the username-Part of a Request
URI using:
$rU = $(rU{s.strip,6});
Initial Request URI:
/sbin/kamailio[40658]: NOTICE: <script>: [ INVITE ] Got new Packet to
sip:123456:pass@sip.custom.com
The config-script now removed the first 6 chars from the username part and
would replace them in one of the following lines, but Kamailio had problems
here:
/sbin/kamailio[40658]: ERROR: pv [pv_core.c:251]: failed to parse the R-URI
/sbin/kamailio[40658]: NOTICE: <script>: Strip from Head: Request Username:
<null> // $rU
/sbin/kamailio[40658]: ERROR: pv [pv_core.c:251]: failed to parse the R-URI
/sbin/kamailio[40658]: ERROR: <core> [action.c:801]: ERROR: do_action: bad
uri <sip::passsip.custom.com> <sip::passsip.custom.com>, dropping packet
Is there maybe a error when modifying a uri with password this way? Do we
have to change this?
Ultimately Kamailio crashed:
/sbin/kamailio[40658]: ERROR: <core> [action.c:1513]: run action error at:
:0
/sbin/kamailio[40658]: ERROR: pv [pv_core.c:1761]: do action failed
/sbin/kamailio[40658]: ERROR: <core> [lvalue.c:358]: setting pvar failed
/sbin/kamailio[40658]: ERROR: <core> [lvalue.c:411]: assignment failed at
pos: (319,10-319,34)
/sbin/kamailio[40658]: ERROR: pv [pv_core.c:251]: failed to parse the R-URI
Like 5000 lines more of
/sbin/kamailio[40658]: ERROR: pv [pv_core.c:251]: failed to parse the R-URI
Due to rerouting internal and trying to remove more parts of the request Uri
using $rU = $(rU{s.strip,6});
Which then concluded to the following:
/sbin/kamailio[40656]: ALERT: <core> [main.c:741]: child process 40660
exited by a signal 11
/sbin/kamailio[40656]: ALERT: <core> [main.c:744]: core was generated
/sbin/kamailio[40656]: INFO: <core> [main.c:756]: INFO: terminating due to
SIGCHLD
/sbin/kamailio[40659]: ERROR: pv [pv_core.c:251]: failed to parse the R-URI
/sbin/kamailio[40682]: INFO: <core> [main.c:807]: INFO: signal 15 received
/sbin/kamailio[40677]: INFO: <core> [main.c:807]: INFO: signal 15 received
/sbin/kamailio[40676]: INFO: <core> [main.c:807]: INFO: signal 15 received
/sbin/kamailio[40678]: INFO: <core> [main.c:807]: INFO: signal 15 received
[...]
I will try to recreate this using the new version (4.1.6) on monday.
Kind regards
Timo Klecker
_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users(a)lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
--
Daniel-Constantin Mierla
http://twitter.com/#!/miconda <http://twitter.com/#%21/miconda> -
http://www.linkedin.com/in/miconda
--
Daniel-Constantin Mierla
http://twitter.com/#!/miconda -
http://www.linkedin.com/in/miconda