Hello,
can you send the backtrace with gdb from the core file? The logs say the corefile was generated -- it should beeiter in / or in the workind directory you set for kamailio.
Cheers,
Daniel
My configuration when applying load balancing and failover is detailed here:This happens just when i stop one of the asterisk and make a call that is being load balanced to the same asterisk box that i stopped before, when trying to go to failure_route and dispatch it to the other box then Kamailio just crashes. I have debug=4 in the config file and it really doesnt say much about the error. This is the relative logging i could found:Dear listIm quite new to Kamailio and i found something while trying to see the failover behaviour in Kamailio. I have a kamailio v4.3.5 load balancing two Asterisk boxes.
Jul 18 16:30:13 kam2 /usr/sbin/kamailio[69548]: INFO: <script>: UBICAR: Forwarding non-registrar requests to Asterisk
Jul 18 16:30:13 kam2 /usr/sbin/kamailio[69548]: INFO: <script>: UBICAR: Dispatching to Asterisk Box sip:10.0.1.201:5060
Jul 18 16:30:13 kam2 /usr/sbin/kamailio[69550]: INFO: <script>: UBICAR: requestm=INVITE reply=<null> SIP packet comes from the Asterisk Box duid=PBX2;my=pbx2;maxload=10000 callid=4d52095c6f2ed1ab2de2d6c70340a126@10.0.1.201:5060
Jul 18 16:30:13 kam2 /usr/sbin/kamailio[69550]: INFO: <script>: UBICAR: requestm=INVITE reply=<null> SIP packet comes from the Asterisk Box duid=PBX2;my=pbx2;maxload=10000 callid=4d52095c6f2ed1ab2de2d6c70340a126@10.0.1.201:5060
Jul 18 16:30:18 kam2 /usr/sbin/kamailio[69547]: INFO: <script>: UBICAR: setting call load requesturi=<null> callid=896175650@192.168.14.76
Jul 18 16:30:20 kam2 /usr/sbin/kamailio[69550]: INFO: <script>: UBICAR: delete call load requesturi=sip:10005@10.0.1.201:5060 callid=896175650@192.168.14.76
Jul 18 16:30:38 kam2 /usr/sbin/kamailio[69548]: INFO: <script>: UBICAR: Forwarding non-registrar requests to Asterisk
Jul 18 16:30:38 kam2 /usr/sbin/kamailio[69548]: INFO: <script>: UBICAR: Dispatching to Asterisk Box sip:10.0.1.201:5060
Jul 18 16:30:42 kam2 /usr/sbin/kamailio[69559]: ALERT: <script>: UBICAR: Asterisk sip:10.0.1.201:5060 failed to answer, selecting other one!
Jul 18 16:30:42 kam2 /usr/sbin/kamailio[69559]: INFO: <script>: UBICAR: Dispatching to Asterisk Box sip:10.0.1.200:5060
Jul 18 16:30:43 kam2 /usr/sbin/kamailio[69546]: ALERT: <core> [main.c:728]: handle_sigs(): child process 69559 exited by a signal 11
Jul 18 16:30:43 kam2 /usr/sbin/kamailio[69546]: ALERT: <core> [main.c:731]: handle_sigs(): core was generated
Jul 18 16:30:43 kam2 /usr/sbin/kamailio[69546]: INFO: <core> [main.c:743]: handle_sigs(): terminating due to SIGCHLD
Jul 18 16:30:43 kam2 /usr/sbin/kamailio[69563]: INFO: <core> [main.c:798]: sig_usr(): signal 15 received
Jul 18 16:30:43 kam2 /usr/sbin/kamailio[69562]: INFO: <core> [main.c:798]: sig_usr(): signal 15 received
Jul 18 16:30:43 kam2 /usr/sbin/kamailio[69561]: INFO: <core> [main.c:798]: sig_usr(): signal 15 received
Jul 18 16:30:43 kam2 /usr/sbin/kamailio[69558]: INFO: <core> [main.c:798]: sig_usr(): signal 15 received
Jul 18 16:30:43 kam2 /usr/sbin/kamailio[69557]: INFO: <core> [main.c:798]: sig_usr(): signal 15 received
Jul 18 16:30:43 kam2 /usr/sbin/kamailio[69556]: INFO: <core> [main.c:798]: sig_usr(): signal 15 received
Jul 18 16:30:43 kam2 /usr/sbin/kamailio[69555]: INFO: <core> [main.c:798]: sig_usr(): signal 15 received
Jul 18 16:30:43 kam2 /usr/sbin/kamailio[69554]: INFO: <core> [main.c:798]: sig_usr(): signal 15 received
Jul 18 16:30:43 kam2 /usr/sbin/kamailio[69553]: INFO: <core> [main.c:798]: sig_usr(): signal 15 received
Jul 18 16:30:43 kam2 /usr/sbin/kamailio[69552]: INFO: <core> [main.c:798]: sig_usr(): signal 15 received
Jul 18 16:30:43 kam2 /usr/sbin/kamailio[69551]: INFO: <core> [main.c:798]: sig_usr(): signal 15 received
Jul 18 16:30:43 kam2 /usr/sbin/kamailio[69548]: INFO: <core> [main.c:798]: sig_usr(): signal 15 received
Jul 18 16:30:43 kam2 /usr/sbin/kamailio[69547]: INFO: <core> [main.c:798]: sig_usr(): signal 15 received
Jul 18 16:30:43 kam2 /usr/sbin/kamailio[69549]: INFO: <core> [main.c:798]: sig_usr(): signal 15 received
Jul 18 16:30:43 kam2 /usr/sbin/kamailio[69550]: INFO: <core> [main.c:798]: sig_usr(): signal 15 received
Jul 18 16:30:43 kam2 /usr/sbin/kamailio[69560]: INFO: <core> [main.c:798]: sig_usr(): signal 15 received
Jul 18 16:30:43 kam2 /usr/sbin/kamailio[69546]: INFO: <core> [sctp_core.c:53]: sctp_core_destroy(): SCTP API not initialized
# Send to Asterisk
route[TOASTERISK] {
#!ifdef WITH_LOADBALANCE
xlog("L_INFO","UBICAR: Forwarding non-registrar requests to Asterisk \n");
if(!ds_select_dst("0", "10")) {
sl_send_reply("500", "Service Unavailable");
xlog("L_ERROR","UBICAR: No destinations available for $rd \n");
exit;
}
xlog("L_INFO","UBICAR: Dispatching to Asterisk Box $du\n");
t_set_fr(0,4000);
t_on_failure("MANAGE_FAILURE");
route(RELAY);
exit;
#!endif
# manage failure routing cases
failure_route[MANAGE_FAILURE] {
#xlog("L_ALERT","UBICAR: failure requestm=$rm requesturi=$ru callid=$ci\n");
if (t_is_canceled()) {
exit;
}
#!ifdef WITH_LOADBALANCE
xlog("L_ALERT","UBICAR: Asterisk $du failed to answer, selecting other one!");
# next DST - only for 500 reply or local timeout (set by t_set_fr())
if (t_check_status("500") || t_branch_timeout() || !t_branch_replied())
{
#we mark the destination Inactive and Probing
ds_mark_dst("ip");
#select the new destination
if(ds_next_dst())
{
t_set_fr(0,4000);
t_on_failure("MANAGE_FAILURE");
xlog("L_INFO","UBICAR: Dispatching to Asterisk Box $du\n");
route(RELAY);
exit;
}else{
#last available node failed to reply, no other destinations available
send_reply("404", "No destination");
exit;
}
#!endif
}
}
It may be a bug in that Kamailio version because i used Kamailio v4.2 before and i didnt have that inconvenient, still i had to upgrade to v4.3 because i needed the default_socket modparam that wasnt implemented in Kamailio v4.2
Any hint about this issue would be appreciate it
Best Regards
Alejandro
_______________________________________________ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
-- Daniel-Constantin Mierla http://www.asipto.com - http://www.kamailio.org http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda