[asterisk-bugs] [Asterisk 0010956]: 1.4.13 lockups

noreply at bugs.digium.com noreply at bugs.digium.com
Fri Oct 12 01:00:08 CDT 2007


A NOTE has been added to this issue. 
====================================================================== 
http://bugs.digium.com/view.php?id=10956 
====================================================================== 
Reported By:                hevisko
Assigned To:                
====================================================================== 
Project:                    Asterisk
Issue ID:                   10956
Category:                   CDR/General
Reproducibility:            random
Severity:                   crash
Priority:                   normal
Status:                     new
Asterisk Version:           1.4.12.1  
SVN Branch (only for SVN checkouts, not tarball releases): N/A  
SVN Revision (number only!):  
Disclaimer on File?:        N/A 
Request Review:              
====================================================================== 
Date Submitted:             10-12-2007 00:54 CDT
Last Modified:              10-12-2007 01:00 CDT
====================================================================== 
Summary:                    1.4.13 lockups
Description: 
Okay,

 Caught one of these "lockups" on 1.4.13,

noticed the following from full log (And no, there are zillions of those
:()

[Oct 11 12:27:04] DEBUG[23386] channel.c: Triggering queue flush for
spy 'MixMonitor' on 'IAX2/192.168.124.2:4569-8'
[Oct 11 12:27:04] DEBUG[23386] channel.c: Triggering queue flush for
spy 'MixMonitor' on 'IAX2/192.168.124.2:4569-8'
[Oct 11 12:27:04] DEBUG[23386] channel.c: Triggering queue flush for
spy 'MixMonitor' on 'IAX2/192.168.124.2:4569-8'
[Oct 11 12:27:04] DEBUG[23386] channel.c: Triggering queue flush for
spy 'MixMonitor' on 'IAX2/192.168.124.2:4569-8'
[Oct 11 12:27:04] DEBUG[23386] channel.c: Triggering queue flush for
spy 'MixMonitor' on 'IAX2/192.168.124.2:4569-8'
[Oct 11 12:27:04] DEBUG[23386] channel.c: Triggering queue flush for
spy 'MixMonitor' on 'IAX2/192.168.124.2:4569-8'
[Oct 11 12:27:04] DEBUG[23386] channel.c: Triggering queue flush for
spy 'MixMonitor' on 'IAX2/192.168.124.2:4569-8'
[Oct 11 12:27:04] DEBUG[23386] channel.c: Triggering queue flush for
spy 'MixMonitor' on 'IAX2/192.168.124.2:4569-8'
[Oct 11 12:27:04] DEBUG[23386] channel.c: Triggering queue flush for
spy 'MixMonitor' on 'IAX2/192.168.124.2:4569-8'
[Oct 11 12:27:04] DEBUG[23386] channel.c: Triggering queue flush for
spy 'MixMonitor' on 'IAX2/192.168.124.2:4569-8'
[Oct 11 12:27:04] DEBUG[23386] channel.c: Triggering queue flush for
spy 'MixMonitor' on 'IAX2/192.168.124.2:4569-8'
====================================================================== 

---------------------------------------------------------------------- 
 hevisko - 10-12-07 01:00  
---------------------------------------------------------------------- 
Russell,

    The errors may be in the jb itself, but it may also be that there's 
some unusual delay in getting packets _into_ the jb which cause it to 
display those messages.  For example, if there's some single-threaded 
sections of code, or some kind of locking delays, etc.

    In the 19782 gdb output, you can see:
Thread 72 (process 19796):
http://bugs.digium.com/view.php?id=0  0xb7f82410 in __kernel_vsyscall ()
http://bugs.digium.com/view.php?id=1  0xb7e47cc6 in nanosleep () from
/lib/libc.so.6
http://bugs.digium.com/view.php?id=2  0xb7e7544c in usleep () from
/lib/libc.so.6
http://bugs.digium.com/view.php?id=3  0xb6dacbba in iax2_queue_frame (callno=40,
f=0x83eebd0) at 
chan_iax2.c:1444
http://bugs.digium.com/view.php?id=4  0xb6dad60b in __get_from_jb (p=<value
optimized out>) at 
chan_iax2.c:1804
http://bugs.digium.com/view.php?id=5  0xb6dcdd10 in iax2_process_thread
(data=0x81f3d60) at
chan_iax2.c:8259
http://bugs.digium.com/view.php?id=6  0x0812eb9d in ?? ()

Which seems to be from this code:
595 : 	matteo 	629 	static int iax2_queue_frame(int callno, struct 
ast_frame *f)
1596 : 	  	  	{
1597 : 	  	  	for (;;) {
1598 : 	  	  	if (iaxs[callno] && iaxs[callno]->owner) {
1599 : 	russell 	82728 
<http://svn.digium.com/view/asterisk/trunk/channels/chan_iax2.c?view=diff&r1=82727&r2=82728>

	if (ast_channel_trylock(iaxs[callno]->owner)) {
1600 : 	matteo 	629 	/* Avoid deadlock by pausing and trying again */
1601 : 	markster 	1310 
<http://svn.digium.com/view/asterisk/trunk/channels/chan_iax2.c?view=diff&r1=1309&r2=1310>

	ast_mutex_unlock(&iaxsl[callno]);
1602 : 	matteo 	629 	usleep(1);
1603 : 	markster 	1310 
<http://svn.digium.com/view/asterisk/trunk/channels/chan_iax2.c?view=diff&r1=1309&r2=1310>

	ast_mutex_lock(&iaxsl[callno]);
1604 : 	matteo 	629 	} else {
1605 : 	markster 	2644 
<http://svn.digium.com/view/asterisk/trunk/channels/chan_iax2.c?view=diff&r1=2643&r2=2644>

	ast_queue_frame(iaxs[callno]->owner, f);
1606 : 	russell 	82728 
<http://svn.digium.com/view/asterisk/trunk/channels/chan_iax2.c?view=diff&r1=82727&r2=82728>

	ast_channel_unlock(iaxs[callno]->owner);
1607 : 	matteo 	629 	break;
1608 : 	  	  	}
1609 : 	  	  	}


The other output shows the same deadlock avoidance pattern in thread 73, 
Thread 56 (and, they seem to be different calls..).

-SteveK 

Issue History 
Date Modified   Username       Field                    Change               
====================================================================== 
10-12-07 01:00  hevisko        Note Added: 0071861                          
======================================================================




More information about the asterisk-bugs mailing list