[Home]

Summary:ASTERISK-23160: Fax CNG detection when no apparent CNG present in inbound audio stream
Reporter:David Cunningham (dcunningham)Labels:
Date Opened:2014-01-20 01:08:52.000-0600Date Closed:
Priority:MinorRegression?
Status:Open/NewComponents:Applications/app_fax Resources/res_fax_spandsp
Versions:1.8.22.0 13.18.4 Frequency of
Occurrence
Related
Issues:
Environment:CentOS release 5.6 32 bit. Attachments:( 0) 000065d0_ticket_2312.txt
( 1) rtp_ssrc_4D7.raw.tar.gz
Description:We have an Asterisk system with "faxdetect = yes" in sip.conf and sometimes a call is suddenly redirected to the 'fax' extension even though there's no fax tone in the audio. Eg:

[Jan 13 12:47:52] VERBOSE[12712] chan_sip.c:   == Redirecting 'SIP/product-local-000065d0' to fax extension due to CNG detection

We can provide a PCAP with audio and an Asterisk full log if required. Thanks.
Comments:By: Matt Jordan (mjordan) 2014-01-22 16:39:29.378-0600

Yes, we're going to need the pcap and the log file. That statement is indicating that Asterisk believes it has received a CNG tone.

Most likely, an audio analysis would have to be done to determine if it is the DSP code in Asterisk that is off, or if something is actually transmitting what could be interpreted to be a CNG tone.

By: David Cunningham (dcunningham) 2014-01-22 16:43:14.140-0600

Hi Matt,

No problem, we'll get those. Does Digium do the audio analysis? Listening to the audio, we don't hear a fax tone.


By: Rusty Newton (rnewton) 2014-02-10 08:02:08.414-0600

Yes we can take a look at the audio.

By: David Cunningham (dcunningham) 2014-02-11 22:41:55.532-0600

Extract of Asterisk log.

By: David Cunningham (dcunningham) 2014-02-11 22:43:04.424-0600

Here is the audio. It's 16Mb so not attached to this report:
64.124.219.166/local/200600103-0-1465022714.pcap.gz

The Asterisk trace is only an extract of the channel in question, as the full log is quite a large file (busy system). In any case, I think it's the audio that's really important for this problem.
Thanks.


By: Rusty Newton (rnewton) 2014-02-26 14:04:26.678-0600

Thanks David. Did you have notice,warning,error,debug,verbose,dtmf,fax type messages enabled for your log?

By: David Cunningham (dcunningham) 2014-02-26 15:48:03.739-0600

Hi Rusty, it would have been:
full => notice,warning,error,debug,verbose,dtmf


By: Rusty Newton (rnewton) 2014-02-26 17:19:04.546-0600

Scott Griepentrog assisted me in looking at the audio you provided. We didn't see a fax CNG tone anywhere in the audio. Also, the parties involved finish the conversation without interruption, and then we see SIP BYEs and 200OKs.  Basically it doesn't look like that was the right call that got interrupted by fax detection and then redirected.

Due to the scrubbing in the log I wasn't able to match up the call exactly with the log. Are you sure you have the right pcap?

If it isn't, can you provide

* another example pcap - make sure to check the pcap and see if the call gets redirected or interrupted
* a log with notice,warning,error,debug,verbose,dtmf,fax type messages enabled
* be sure that the VERBOSE and DEBUG level are both turned up to 5 as I didn't see any DEBUG messages in your log despite you having that type message enabled. (you might just set it in asterisk.conf before starting Asterisk to make sure it gets turned up)
* "fax set debug on" before reloading the logger

Let me know if we are confused about anything.


By: Rusty Newton (rnewton) 2014-02-26 17:20:20.253-0600

Remember to hit Send Back or Enter Feedback when you have a response so that the issue moves out of the Waiting On Feedback state. Thanks!

By: David Cunningham (dcunningham) 2014-02-26 19:11:20.003-0600

Hi Rusty,

The redirection happened about 12 minutes into the call. At that time in the audio you hear the conversation get interrupted, and then the caller is connected to the destination again (since the 'fax' extension routed to the same place) with the participants saying "what happened?".

I agree there is no audible fax tone, which is why we can't figure out why Asterisk records "CNF detection".

The call started at 12:35:10, and you'll see in the trace that at 12:47:52 the CNG detection was recorded.

I can ask the customer for another trace but want to be sure in advance that it's going to be useful.
Thanks for your help!


By: Rusty Newton (rnewton) 2014-02-27 09:08:38.808-0600

Thanks, we'll take another look to be sure. We'll let you know what we find.

By: Rusty Newton (rnewton) 2014-02-27 17:55:37.151-0600

Yup somehow we skipped the important part before. It was definitely useful to have the time the issue occurs pointed out specifically.

We hear where the users react to the issue. We don't see a clear CNG tone, but further analysis on the audio will be necessary to know what is going on for sure.

I'm going to open the issue up so it'll be in the queue, but one thing that may really help is getting another full log with the additional debug, message types and verbosity levels that I mentioned.

For future reference I've attached the file rtp_ssrc_4D7.raw.tar.gz. That is the inbound audio where we would expect to see a CNG tone. The time in that file corresponding to issue shown in the log is at approximately 12:36 or twelve minutes and thirty six seconds into the file.



By: David Cunningham (dcunningham) 2014-02-27 18:10:48.008-0600

Thank you. I'll ask the customer to get a trace with those options if they can.