Summary:ASTERISK-05508: eyeBeam presence service makes Asterisk crash
Reporter:alexb (alexb)Labels:
Date Opened:2005-11-08 11:23:32.000-0600Date Closed:2011-06-07 14:01:08
Versions:Frequency of
Environment:Attachments:( 0) gdbdump.txt
Description:Asterisk randomly crashes, I think it may be related to eyeBeam presence service.


#0  0xb67e8845 in reqprep (req=0xb67d9a80, p=0x81d7758, sipmethod=4, seqno=1266043745, newbranch=1) at strings.h:35
       orig = (struct sip_request *) 0x81d8f90
       stripped = "ô/vKM\016\000\000¯\001\000\000X\231}¶\036\034iKG\236}¶M\016\000\000\233\222\201¶ô/vK\000\000\000\000\200\232}¶x\231}¶\036\034iK\\\236}¶<\016\000\000\201x~¶\\\236}¶ä#\202¶\\\236}¶ä#\202¶"
       tmp = "103 \000*vK\000\000\000\000ÿÿÿÿ0\231}¶\b\000\000\000p#\035\bp#\035\bSIP\000\000*vK\000\000\000\000Ò\001\f\b0\232}¶", '\0' <repeats 17 times>, "*vK\000\000\000\000\004\231}¶"
       newto = "<sip:206 °jKô/vKP\230}¶\034\230}¶\225ÀjKP\230}¶G\236}¶\223¬}¶ °jKô/vKp\230}¶<\230}¶\225ÀjKp\230}¶\\\236}¶\227¬}¶\000\000\000\000\227¬}¶ô/vK<\016\000\000\\\236}¶\\\231}¶ysjKp\230}¶ô/vK<\016\000\000\\\236}¶\\\231}¶\215sjKp\230}¶´\224\201¶\220\231}¶\020\231}¶p\230}¶\001\200­û\\\236}¶\\\236}¶\\\236}¶\\\236}¶\\\236}¶\227¬}¶\\\236}¶\227¬}¶", '\0' <repeats 20 times>, ")\232}¶\000\000\000\000)\232"...
       c = 0x65746e6f <Address 0x65746e6f out of bounds>
       ot = 0xb67d97e0 "<sip:206 °jKô/vKP\230}¶\034\230}¶\225ÀjKP\230}¶G\236}¶\223¬}¶ °jKô/vKp\230}¶<\230}¶\225ÀjKp\230}¶\\\236}¶\227¬}¶"
       is_strict = 0
#1  0xb67efcf9 in transmit_state_notify (p=0xb68197bb, state=-1233020994, full=34, substate=136148824) at chan_sip.c:5012
       tmp = '\0' <repeats 3999 times>
       from = '\0' <repeats 16 times>, "\"anna\"<sip:203@\000;tag=cd297368", '\0' <repeats 199 times>
       to = '\0' <repeats 16 times>, "<sip:211@", '\0' <repeats 219 times>
       t = 0x0
       a = 0x35 <Address 0x35 out of bounds>
       maxbytes = 3061946288
       req = {rlPart1 = 0x0, rlPart2 = 0x0, len = 0, headers = 0, method = 0, header = {0x0 <repeats 64 times>},
 lines = 0, line = {0x0 <repeats 64 times>}, data = '\0' <repeats 4095 times>, debug = 0, flags = 0}
       hint = "0", '\0' <repeats 15 times>, "SIP/206", '\0' <repeats 56 times>
       statestring = 0xb6822180 ""
       local_state = 3061689800
       pidfstate = 0x0
       pidfnote = 0xb67dada7 "sip:203@"
       __PRETTY_FUNCTION__ = "transmit_state_notify"
#2  0xb67f0569 in __sip_autodestruct (data=0x81d7758) at chan_sip.c:1287
       __PRETTY_FUNCTION__ = "__sip_autodestruct"
#3  0x0805630c in ast_sched_runq (con=0x816b0f0) at sched.c:373
       tv = warning: Unhandled dwarf expresion opcode DW_OP_piece
{tv_sec = 53, tv_usec = 1702129267}
       x = 0
       res = 34
#4  0x0816b0f0 in ?? ()
No symbol table info available.
ASTERISK-1  0x0000000a in ?? ()
No symbol table info available.
ASTERISK-2  0x0816b0f0 in ?? ()
No symbol table info available.
ASTERISK-3  0x0816b0f0 in ?? ()
No symbol table info available.
ASTERISK-4  0x00000000 in ?? ()
No symbol table info available.
Comments:By: Kevin P. Fleming (kpfleming) 2005-11-08 15:02:24.000-0600

This backtrace is useless without Asterisk being built without optimizations and without a corresponding console trace. Please read the backtrace guidelines document in the doc directory and see if you can provide something we can work with.

By: alexb (alexb) 2005-11-08 16:11:44.000-0600

1) Asterisk was built with K6OPT+=-DK6OPT in Makefile; should I recompile it, then? Do I have to set any other option in Makefile?
2) Somewhere here in the Mantis it was required only the output of 'bt full'; however, now I've also added the output for 'thread apply all bt', sorry.
3) Verbose level was set to 3 and debug to 0, but nothing was logged in /var/log/asterisk/full when it crashed; the following one is the last line it logged:

Nov  8 16:47:39 ERROR[10600] chan_sip.c: Got SUBSCRIBE for extensions without hint. Please add hint to 348******* in context sip-kleis-in

However, today it was already reported several times before but it's somehow strange 'cause 348******* is a mobile number I dialled early this morning from my eyeBeam client. It was still being reported even after:
a) I closed eyeBeam
b) and rebooted my pc
c) and rebooted the Asterisk

Finally, please note that today is the first day we're using eyeBeam and presence service.

By: alexb (alexb) 2005-11-08 16:22:58.000-0600

I've just checked that today I've been the only one who called 348*******.

Nov  8 12:10:19 VERBOSE[6668] logger.c:     -- Executing NoOp("mISDN/1-1", "348*******") in new stack
Nov  8 12:10:45 ERROR[6643] chan_sip.c: Got SUBSCRIBE for extensions without hint. Please add hint to 348******* in context sip-kleis-in

Last line is repetead every 5 minutes, which are eyeBeam's poll time and refresh interval in peer-to-peer presence mode settings.

By: BJ Weschke (bweschke) 2005-11-11 07:58:05.000-0600

what does your extensions.conf look like?

By: alexb (alexb) 2005-11-11 14:04:55.000-0600

All SIP clients enter the same context, sip-kleis-in, in extensions.conf.
I think the following one is the relevant part (I've only slightly modified it to make it easier for you):

exten => s,2,Dial(${TRUNK}/${ARG1}${TRUNKOPTIONS}||gTW)
exten => s,3,Goto(s-${DIALSTATUS},1)
exten => s-NOANSWER,1,Playtones(congestion)
exten => s-BUSY,1,Playtones(busy)
exten => _s-.,1,Goto(s-NOANSWER,1)

; --------------------------------------------> calls to mobile 348******* went here
exten => _3NXXXXXXX,1,Macro(dialout,${EXTEN})
exten => _3NXXXXXXXX,1,Macro(dialout,${EXTEN})

include => pstn-servizi_comunicazioni_mobili-out

include => pstn-out

; hints
exten => 200,hint,SIP/200
exten => 201,hint,SIP/201
exten => 202,hint,SIP/202
exten => 203,hint,SIP/203
exten => 204,hint,SIP/204
exten => 205,hint,SIP/205
exten => 206,hint,SIP/206
exten => 211,hint,SIP/211
exten => 212,hint,SIP/212
exten => 301,hint,SIP/301
exten => 302,hint,SIP/302
exten => 303,hint,SIP/303
exten => 304,hint,SIP/304

; RealTime
switch => Realtime/@extensions

Note: for each extension a record like the following one is defined in the db table

INSERT INTO `extensions_table` VALUES (1, 'sip-kleis-in', '201', 1, 'Macro', 'stdexten|${EXTEN}|SIP/${EXTEN}');
INSERT INTO `extensions_table` VALUES (2, 'sip-kleis-in', 'Luciano', 1, 'Goto', '201|1');

I think there's nothing particularly strange.

By: Kevin P. Fleming (kpfleming) 2005-11-11 20:47:37.000-0600

We will need to see a 'sip debug' showing the SUBSCRIBE request coming from the softphone as well, please.

By: BJ Weschke (bweschke) 2005-11-11 20:55:58.000-0600

I know it sounds wierd, but put your hints above the extensions that you're dialing out to them on in your dial plan and see if that resolves the messages about getting a subscribe for an extension without a hint.

By: Olle Johansson (oej) 2005-11-15 15:04:26.000-0600

Gentle reminder, we're waiting for feedback from you.


By: alexb (alexb) 2005-11-15 15:53:58.000-0600

Sorry, you wrote me on Friday and now I'll be out of office till next monday.

However I have an idea about what maybe happened. I _suppose_ that some colleague had added that mobile number clicking on "Add to contact" in the "Received and missed calls" list. Clearly this is not a bug, but repeating more and more that SUBSCRIBE request made asterisk randomly crash - this is a matter of fact.
Unfortunately I can't investigate it till next week, but if you are in hurry I presume you can reproduce the situation subscribing for an extension without hint in extensions.conf and waiting...

kpfleming, BTW you didn't answer my question: what options should I recompile Asterisk with, please?

bweschke, it didn't help. Anyway I think it's a non-sense because the include already places the context for outgoing calls (-> 348*******) down in the priority order, that is hints are already evaluated before.

By: alexb (alexb) 2005-11-15 15:55:17.000-0600

Please note I'm GMT +0100.

By: Kevin P. Fleming (kpfleming) 2005-11-15 16:12:11.000-0600

AlexB: I requested that you read the backtrace guidelines document that comes with the source tree, as it tells you exactly how to build Asterisk for this sort of problem...

By: alexb (alexb) 2005-11-15 16:27:52.000-0600

kpfleming, could you be so kind to tell me where is explained "how to build asterisk for this sort of problem" in /usr/src/asterisk/doc/README.backtrace? There are info only about how to use gdb.

By: Serge Vecher (serge-v) 2005-11-15 16:55:40.000-0600

AlexB: you do that by "make valgrind" instead of "make install". You are right, it doesn't say this in README.backtrace.

By: Kevin P. Fleming (kpfleming) 2005-11-15 20:06:38.000-0600

You are correct; that file did not have the required instructions. I have just added them :-)

By: alexb (alexb) 2005-11-25 02:20:58.000-0600

Hi all, I updated to CVS HEAD on last Monday and I've been testing the machine so far, but it has never crashed anymore. Maybe it was resolved...

What about closing this issue, then? I will re-open it if there is any changes.

By: Olle Johansson (oej) 2005-11-25 02:24:53.000-0600

Not an issue with 1.2.

Thank you for confirming this!