<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
I did a fix for it several days ago, not sure you noticed it, since
I was mostly unavailable to reply on mailing list. Here is the link:<br>
<a class="moz-txt-link-freetext" href="http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=0f5e21c668e46492fb9f9ec69e5b5aafe41bd272">http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=0f5e21c668e46492fb9f9ec69e5b5aafe41bd272</a><br>
<br>
If you can try the patch and report if it is working will be great.
It is for master, but I will backport to stable banrches as well.<br>
<br>
Btw, do you need use_default? I is something quite unmaintained
(read untested together with latest additions), so my plan was to
remove it since many people were confused by its necessity.<br>
<br>
Cheers,<br>
Daniel<br>
<br>
On 12/3/10 9:54 PM, Eric Hiller wrote:
<blockquote cite="mid:BLU112-W29AE614C107D1C445AD6A3DB280@phx.gbl"
type="cite">
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Tahoma
}
--></style>
Yes, I do.<br>
<br>
<hr id="stopSpelling">Date: Fri, 3 Dec 2010 10:31:51 +0100<br>
From: <a class="moz-txt-link-abbreviated" href="mailto:miconda@gmail.com">miconda@gmail.com</a><br>
To: <a class="moz-txt-link-abbreviated" href="mailto:mrraptor98@hotmail.com">mrraptor98@hotmail.com</a><br>
CC: <a class="moz-txt-link-abbreviated" href="mailto:sr-users@lists.sip-router.org">sr-users@lists.sip-router.org</a><br>
Subject: Re: [SR-Users] Dispatcher Crash when all hosts are
invalid<br>
<br>
<meta http-equiv="Content-Type" content="text/html;
charset=ISO-8859-1">
<meta name="Generator" content="Microsoft SafeHTML">
<title>Message body</title>
Hello,<br>
<br>
do you have parameter use_default set to 1?<br>
<br>
Cheers,<br>
Daniel<br>
<br>
On 12/3/10 6:47 AM, Eric Hiller wrote:
<blockquote cite="mid:BLU112-W17B87F2BC460AFC28FCC3ADB280@phx.gbl">
<style>
.ExternalClass .ecxhmmessage P
{padding:0px;}
.ExternalClass body.ecxhmmessage
{font-size:10pt;font-family:Tahoma;}
</style> Dispatcher crashes everytime guaranteed if there is a single
dead host kamailio exits with a core dump (see below). If there
are two dead hosts entire kamailio locks up (no core dump). Any
ideas on this one? The invalid flag is never marked in the DB
btw.<br>
<br>
Crashes at ds_select_dst having never reached "COMPLETED FIRST
DST LOOKUP"<br>
<br>
# ------------------------- request routing logic
-------------------<br>
# main routing logic<br>
# ------------------<br>
route{<br>
# initial checks<br>
if (!mf_process_maxfwd_header("10")) {<br>
sl_send_reply("483","Too Many Hops");<br>
exit;<br>
};<br>
if (msg:len >= 2048 ) {<br>
sl_send_reply("513", "Message too big");<br>
exit;<br>
};<br>
xlog("[$TF] VALID RECV $rm\n $fu ($si:$sp) to
$ru\n");<br>
$avp(orig_du) = $du;<br>
if($(fU{s.select,1,-})){<br>
# from a user-formed message<br>
$avp(user) = $(fU{s.select,0,-});<br>
xlog(" USER $avp(user) DETECTED\n");<br>
}<br>
if(pv_isset("$avp(user)") &&
!ds_is_from_list()){<br>
# from client<br>
# route to client PBX<br>
if(method == "REGISTER"){<br>
route(3);<br>
} else {<br>
route(1);<br>
}<br>
}<br>
if(ds_is_from_list()){<br>
# from client, outbound from pbx<br>
xlog(" IS FROM PBX\n");<br>
if(is_e164($rU)){<br>
xlog(" IS E164");<br>
# all pbx-pbx traffic should be in user
format<br>
# since this is pbx-non-pbx send it to
gateway<br>
# gateway only takes E164<br>
route(2);<br>
}<br>
if($(rU{s.select,0,-})){<br>
# send directly from pbx to client<br>
route(4);<br>
}<br>
}<br>
if($si == "GATEWAY_IP_ADDRESS"){<br>
# lookup enum<br>
# route to appropriate pbx via DISPATCHER based
on user returned<br>
xlog(" CALL FROM GATEWAY\n");<br>
}<br>
}<br>
route[1]{<br>
route(3);<br>
xlog(" ROUTED to $avp(user) PBX\n");<br>
ds_select_dst($avp(user),"7");<br>
xlog(" COMPLETED FIRST DST LOOKUP\n");<br>
if($avp(orig_rd) == $rd){<br>
exec("kamctl dispatcher reload");<br>
ds_select_dst($avp(user),"9");<br>
}<br>
xlog(" host is now $rd; all is $ru || $du\n");<br>
if($avp(orig_du) != $du){<br>
t_on_failure("1");<br>
if(!t_relay()){<br>
xlog(" T_RELAY() FAILED\n");<br>
sl_reply_error();<br>
}<br>
} else {<br>
xlog(" RELOAD STILL YIELDED NOTHING\n");<br>
}<br>
}<br>
route[2]{<br>
xlog(" Sending to gateway...");<br>
#$rd = "GATEWAY";<br>
}<br>
route[3]{<br>
#register<br>
if(!www_authorize("domain.net","subscriber")){<br>
www_challenge("domain.net","0");<br>
return;<br>
} else {<br>
xlog(" AUTHENTICATED $avp(user)\n");<br>
save("location");<br>
return;<br>
}<br>
}<br>
route[4]{<br>
$rU = "2-1";<br>
#$rd = "10.1.40.7";<br>
#$rp = "16314";<br>
lookup("location");<br>
xlog(" ROUTING TO USER $rU\n");<br>
forward();<br>
}<br>
failure_route[1]{<br>
xlog(" FAILED FAILURE_ROUTE[1]\n");<br>
if(t_any_timeout()){<br>
xlog(" MARKING DEAD HOST $du\n");<br>
ds_mark_dst();<br>
xlog(" TIMEOUT!\n");<br>
}<br>
}<br>
<br>
<br>
0(2934) ERROR: <script>: [Thu Dec 2 20:15:34 2010] VALID
RECV REGISTER<br>
<a moz-do-not-send="true" class="ecxmoz-txt-link-freetext"
target="_blank">sip:3-1@domain.com</a> (10.1.40.7:43899) to <a
moz-do-not-send="true" class="ecxmoz-txt-link-freetext"
target="_blank">sip:domain.com</a><br>
0(2934) ERROR: <script>: USER 3 DETECTED<br>
0(2934) ERROR: <script>: ROUTED to 3 PBX<br>
0(2934) ERROR: <script>: mark#1<br>
0(2934) ERROR: <script>: host is now domain.com; all
is <a moz-do-not-send="true" class="ecxmoz-txt-link-freetext"
target="_blank">sip:domain.com</a> || <a
moz-do-not-send="true" class="ecxmoz-txt-link-freetext"
target="_blank">sip:xxx.xxx.xxx.166:5060</a><br>
0(2934) ERROR: <script>: [Thu Dec 2 20:15:35 2010] VALID
RECV REGISTER<br>
<a moz-do-not-send="true" class="ecxmoz-txt-link-freetext"
target="_blank">sip:3-1@domain.com</a> (10.1.40.7:43899) to <a
moz-do-not-send="true" class="ecxmoz-txt-link-freetext"
target="_blank">sip:domain.com</a><br>
0(2934) ERROR: <script>: USER 3 DETECTED<br>
0(2934) ERROR: <script>: ROUTED to 3 PBX<br>
0(2934) ERROR: <script>: mark#1<br>
0(2934) ERROR: <script>: host is now domain.com; all
is <a moz-do-not-send="true" class="ecxmoz-txt-link-freetext"
target="_blank">sip:domain.com</a> || <a
moz-do-not-send="true" class="ecxmoz-txt-link-freetext"
target="_blank">sip:xxx.xxx.xxx.166:5060</a><br>
1(2935) ERROR: <script>: FAILED FAILURE_ROUTE[1]<br>
1(2935) ERROR: <script>: MARKING DEAD HOST <a
moz-do-not-send="true" class="ecxmoz-txt-link-freetext"
target="_blank">sip:xxx.xxx.xxx.166:5060</a><br>
1(2935) ERROR: <script>: TIMEOUT!<br>
0(2934) ERROR: <script>: [Thu Dec 2 20:15:50 2010] VALID
RECV REGISTER<br>
<a moz-do-not-send="true" class="ecxmoz-txt-link-freetext"
target="_blank">sip:3-1@domain.com</a> (10.1.40.7:29372) to <a
moz-do-not-send="true" class="ecxmoz-txt-link-freetext"
target="_blank">sip:domain.com</a><br>
0(2934) ERROR: <script>: USER 3 DETECTED<br>
0(2934) ERROR: <script>: ROUTED to 3 PBX<br>
0(2934) ERROR: <script>: mark#1<br>
0(2934) ERROR: <script>: host is now domain.com; all
is <a moz-do-not-send="true" class="ecxmoz-txt-link-freetext"
target="_blank">sip:domain.com</a> || <a
moz-do-not-send="true" class="ecxmoz-txt-link-freetext"
target="_blank">sip:xxx.xxx.xxx.165:5060</a><br>
0(2934) ERROR: <script>: [Thu Dec 2 20:15:50 2010] VALID
RECV REGISTER<br>
<a moz-do-not-send="true" class="ecxmoz-txt-link-freetext"
target="_blank">sip:3-1@domain.com</a> (10.1.40.7:29372) to <a
moz-do-not-send="true" class="ecxmoz-txt-link-freetext"
target="_blank">sip:domain.com</a><br>
0(2934) ERROR: <script>: USER 3 DETECTED<br>
0(2934) ERROR: <script>: ROUTED to 3 PBX<br>
0(2934) ERROR: <script>: mark#1<br>
0(2934) ERROR: <script>: host is now domain.com; all
is <a moz-do-not-send="true" class="ecxmoz-txt-link-freetext"
target="_blank">sip:domain.com</a> || <a
moz-do-not-send="true" class="ecxmoz-txt-link-freetext"
target="_blank">sip:xxx.xxx.xxx.165:5060</a><br>
1(2935) ERROR: <script>: FAILED FAILURE_ROUTE[1]<br>
1(2935) ERROR: <script>: MARKING DEAD HOST <a
moz-do-not-send="true" class="ecxmoz-txt-link-freetext"
target="_blank">sip:xxx.xxx.xxx.165:5060</a><br>
1(2935) ERROR: <script>: TIMEOUT!<br>
0(2934) ERROR: <script>: [Thu Dec 2 20:15:55 2010] VALID
RECV REGISTER<br>
<a moz-do-not-send="true" class="ecxmoz-txt-link-freetext"
target="_blank">sip:3-1@domain.com</a> (10.1.40.7:29373) to <a
moz-do-not-send="true" class="ecxmoz-txt-link-freetext"
target="_blank">sip:domain.com</a><br>
0(2934) ERROR: <script>: USER 3 DETECTED<br>
0(2934) ERROR: <script>: ROUTED to 3 PBX<br>
<br>
<br>
:::::Core file from crash with 1 invalid host:::::<br>
Program terminated with signal 8, Arithmetic exception.<br>
#0 0x0069e92b in ds_select_dst (msg=0x82ffb00, set=2, alg=7,
mode=0)<br>
at dispatch.c:1720<br>
1720 i = (i+1)%(idx->nr-1);<br>
<br>
<br>
<br>
Thanks for any help on this one!<br>
-Eric<br>
<pre><fieldset class="ecxmimeAttachmentHeader"></fieldset>
_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
<a moz-do-not-send="true" class="ecxmoz-txt-link-abbreviated" href="mailto:sr-users@lists.sip-router.org">sr-users@lists.sip-router.org</a>
<a moz-do-not-send="true" class="ecxmoz-txt-link-freetext" href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users" target="_blank">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users</a>
</pre>
</blockquote>
<br>
<pre class="ecxmoz-signature">--
Daniel-Constantin Mierla
Kamailio (OpenSER) Advanced Training
Jan 24-26, 2011, Irvine, CA, USA
<a moz-do-not-send="true" class="ecxmoz-txt-link-freetext" href="http://www.asipto.com" target="_blank">http://www.asipto.com</a></pre>
<pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:sr-users@lists.sip-router.org">sr-users@lists.sip-router.org</a>
<a class="moz-txt-link-freetext" href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users</a>
</pre>
</blockquote>
<br>
<pre class="moz-signature" cols="72">--
Daniel-Constantin Mierla
Kamailio (OpenSER) Advanced Training
Jan 24-26, 2011, Irvine, CA, USA
<a class="moz-txt-link-freetext" href="http://www.asipto.com">http://www.asipto.com</a></pre>
</body>
</html>