Summary:ASTERISK-06262: MixMonitor causes segfault on Free BSD 5.4
Reporter:Bill Neely (billn)Labels:
Date Opened:2006-02-06 11:52:34.000-0600Date Closed:2006-03-24 23:41:14.000-0600
Versions:Frequency of
Environment:Attachments:( 0) 20060206__bug6424.diff.txt
( 1) output_1.txt
( 2) output.txt
Description:from extensions.conf

exten => 299,1,Answer()
exten => 299,n,MixMonitor(manuel.gsm)
exten => 299,n,Wait(5)
exten => 299,n,SayDigits(12345670)
exten => 299,n,StopMonitor()
exten => 299,n,Wait(2)
exten => 299,n,Hangup()

Execution of this sequence always causes asterisk to terminate with a sig11 (seg fault) This has been true on 1.2.0, 1.2.3, and 1.2.4 versions of Asterisk. This condition is 100% reproducable.

OS FreeBsd 5.4 and 5.2.1 (two different boxes.)


Here is the tail of the messages log at the time of the crash

Feb  6 18:50:34 VERBOSE[51713] logger.c: set_destination: Parsing <sip:101@67.18
8.231.188:10086> for address/port to send to
Feb  6 18:50:34 VERBOSE[51713] logger.c: set_destination: set destination to 67.
188.231.188, port 10086
Feb  6 18:50:34 VERBOSE[51713] logger.c: Reliably Transmitting (no NAT) to 67.18
BYE sip:101@ SIP/2.0
Via: SIP/2.0/UDP;branch=z9hG4bK137c3ff0;rport
From: <sip:299@>;tag=as782493e9
To: "Bill"<sip:101@>;tag=f52a244f
Contact: <sip:299@>
Call-ID: da00a54789756108@ajRiMXkw
CSeq: 102 BYE
User-Agent: Asterisk PBX
Max-Forwards: 70
Content-Length: 0
Comments:By: Tilghman Lesher (tilghman) 2006-02-06 13:09:29.000-0600

Since you're getting a reliable segfault, please follow the instructions in doc/README.backtrace on creating a stack backtrace.

By: Bill Neely (billn) 2006-02-06 16:01:28.000-0600

bt file uploaded

By: Tilghman Lesher (tilghman) 2006-02-06 16:37:11.000-0600

Despite not uploading a trace from a non-optimized build, I was able to track down a possible cause.  Please download the attached patch, apply it to your source, and reinstall.  Then let me know if this fixes your crash.

In the future, it would be helpful if you would compile a non-optimized build before creating your stack backtrace.

By: Bill Neely (billn) 2006-02-06 21:55:41.000-0600

hmm, I did a gmake dont-optimize to build the test version before inducing the core dump. Was there something else I should have done first?

At any rate, applied the patch and recompiled. Does not seem to fix the problem.

Let me know what else I can do.

By: Bill Neely (billn) 2006-02-06 22:13:02.000-0600

Ok, this time I did a gmake clean followed by a gmake dont-optimize, then ran the test and copied the bt info. Hope this is the right stuff this time.

By: Tilghman Lesher (tilghman) 2006-02-09 16:51:37.000-0600

Can't reproduce on FreeBSD 6.0

By: Tilghman Lesher (tilghman) 2006-03-06 14:08:02.000-0600

Could I get you to also try to reproduce this on FreeBSD 6.0?

By: Bill Neely (billn) 2006-03-06 16:22:33.000-0600

Unfortunately, I don't have a 6.0 machine available. Since all of our boxes are production level, we only upgrade the OS when absolutely necessary or when installing a new box.

I put something on the support forum under the BSD section, asking for someone else to try to reproduce this on various BDS boxes, but no reply out of 100 reads.

BTW, was there anything unusual about the kernel of the machine that you tried it on?

By: Tilghman Lesher (tilghman) 2006-03-06 16:37:47.000-0600

No, it was the stock 6.0 kernel.

By: Tilghman Lesher (tilghman) 2006-03-24 23:41:14.000-0600

As I'm unable to reproduce this issue, I'm going to close this out.  If you can find another developer who is willing and able to track this down on FreeBSD, then we'll reopen this, but for right now, it appears to be an issue that FreeBSD has fixed in the 6.x series.