Summary: | ASTERISK-09974: chan_skinny randomly crashing asterisk | ||
Reporter: | sbisker (sbisker) | Labels: | |
Date Opened: | 2007-07-27 13:54:41 | Date Closed: | 2007-08-02 15:05:57 |
Priority: | Critical | Regression? | No |
Status: | Closed/Complete | Components: | Channels/chan_skinny |
Versions: | Frequency of Occurrence | ||
Related Issues: | |||
Environment: | Attachments: | ( 0) chan_skinny_bt.txt | |
Description: | This is the fifth time in as many days that asterisk has core dumped. Every time the backtrace looks mangled like this one. I'll upload just after I post. | ||
Comments: | By: sbisker (sbisker) 2007-07-27 13:58:06 This crash occurred with versions 77112, and 76784 with and without the callstate patches. By: dea (dea) 2007-07-27 15:31:54 Actually the BT is fine. Is this server running any of the patches to address the 7921 issues? I don't think they could cause this, but it is worth asking. You have a device that is trying to place a call but is not fully registered, so there is no session. The crash is in skinny_indicate, and that function blindly assumes that it has access to a valid session. We can prevent the crash by testing for s in that function and exiting if it does not exist. You'll still have a phone with issues until it properly registers, but at least your server will not crash. By: Damien Wedhorn (wedhorn) 2007-07-27 17:04:10 Your issues seems to be this at about line 1550: if (skinnydebug) ast_verbose("Setting Callinfo to %s(%s) from %s(%s) on %s(%d)\n", fromname, fromnum, toname, tonum, s->device->name, instance); That reference to s->device->name is not valid as s=NULL. If you turn skinnydebug off, it should stop these crashes, or you could replace s->device->name in the above line to (s?s->device->name:"unregistered_device"). However, there is still the underlying issue that your unregistered phone is making a call. More generally, rather than sending s to all the transmit_ procs, why don't we send d as it would generally be more useful and we can allocate s (d->s) in transmit_response. By: sbisker (sbisker) 2007-07-29 14:26:30 I've got debug turned off for now, until it's decided how to proceed on the debug stuff. It is a production system, but all of my chan_skinny stuff is isolated on a separate server. By: Digium Subversion (svnbot) 2007-08-02 15:05:57 Repository: asterisk Revision: 77994 ------------------------------------------------------------------------ r77994 | qwell | 2007-08-02 15:05:57 -0500 (Thu, 02 Aug 2007) | 14 lines Merged revisions 77993 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 (closes issue ASTERISK-9974) ........ r77993 | qwell | 2007-08-02 15:22:40 -0500 (Thu, 02 Aug 2007) | 5 lines If a device disconnects, the session will go away. If this happens during call setup, we need to give up. Issue 10325. ........ ------------------------------------------------------------------------ |