[Home]

Summary:ASTERISK-14397: [patch] No audio on calls from asterisk sip phones to nortel set until dtmf from sip phone
Reporter:Scott Milne (scottbmilne)Labels:
Date Opened:2009-06-29 13:58:26Date Closed:2009-07-13 07:17:29
Priority:MinorRegression?No
Status:Closed/CompleteComponents:General
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) bug15420-1.4.25.1-diff.txt
( 1) bug15420-1.4.25.1-diff2.txt
Description:When placing a call from an Asterick SIP phone (X-Lite) to Nortel phone set (M3903), no voice will pass until any key is pressed on the SIP phone. SIP to SIP calls - normal. SIP to external phone - normal. Nortel to SIP - normal. All permutations of calls pass audio immediately upon answer except an sip to nortel.

Asterisk is behind Nortel Option 11c via PRI
Telco -> PRI -> Nortel Option 11c -> PRI -> Asterisk

Very new to Asterisk and VOIP and don't know where to start...Any suggestions would be GREATLY appreciated.
Comments:By: Scott Milne (scottbmilne) 2009-06-29 18:57:39

Just noted that dahdi_monitor shows that audio is being received from the nortel side even though no audio can be heard on either the nortel or asterisk side prior to a keypress on the asterisk side.

By: Alec Davis (alecdavis) 2009-06-29 22:19:11

We currently have very similar problem, no Audio until a keypress on the SIP phone. But that is with 1.6.1, maybe code is similar in 1.4.25

refer https://issues.asterisk.org/view.php?id=15389

Table below shows our combinations that work or not.

PSTN -> SIP works fine.
PABX -> SIP works fine.
SIP  -> SIP works fine.
SIP  -> PSTN works fine.
SIP  -> PABX no audio until DTMF key from SIP device.

We have a different interconnection, but basically, PROCEEDING or PROGRESS ISDN indicators are not seen from PABX, only ALERTING.



By: Alec Davis (alecdavis) 2009-06-30 03:53:46

uploaded bug15420-1.4.25.1-diff.txt

Assuming only ALTERTING has been received during a callsetup, and no PRI PROCEEDING or PROGRESS indicators have been received, no audio is heard.
This patch set 'dialing=0' when PRI_EVENT_ANSWER is triggered, thus will allow audio.

It's working our 1.6.1 system.
I checked out 1.4.25.1, applied the patch, and compiled. But have not tested.
Code in 1.4.25.1 is nearly identical to 1.6.1, so have no reason to doubt whether it should work.

By: Scott Milne (scottbmilne) 2009-06-30 10:38:26

Yes...I'm a noob to both Asterisk and Linux.

Did the below actions....Now what?

[root@1531ASTERISK01 asterisk-1.4.25.1]# wget 'https://issues.asterisk.org/file_download.php?file_id=23142&type=bug' -O - | patch -p0
--12:18:00--  https://issues.asterisk.org/file_download.php?file_id=23142&type=bug
Resolving issues.asterisk.org... 76.164.171.231
Connecting to issues.asterisk.org|76.164.171.231|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 771 [text/plain]
Saving to: `STDOUT'

100%[=======================================>] 771         --.-K/s   in 0s

12:18:01 (6.75 MB/s) - `-' saved [771/771]

patching file channels/chan_dahdi.c
[root@1531ASTERISK01 asterisk-1.4.25.1]#



By: Alec Davis (alecdavis) 2009-06-30 14:38:10

normally I'd do it like this, (typed not copied so please excuse errors)

cd /usr/src
svn checkout http://svn.digium.com/svn/asterisk/tags/1.4.25.1 asterisk
cd asterisk
wget "https://issues.asterisk.org/file_download.php?file_id=23142&type=bug"
you may have to rename the downloaded file to  bug15420-1.4.25.1.diff.txt
patch -p0 < bug15420-1.4.25.1.diff.txt
make
make install

shutdown -r now

By: Scott Milne (scottbmilne) 2009-06-30 18:12:28

No success. I had to do "./configure" before it would let me execute make or make install

patch -p0 < bug15420-1.4.25.1.diff.txt completed
make completed
make install completed

I noticed that chan_dahdi.c was never part of the make or make install. So I did make menuselect and under channel drivers, chan_dahdi has XXX next to it so the patched chan_dahdi.c never compiled.

I'll keep trying...Thanks!

By: Alec Davis (alecdavis) 2009-07-01 05:25:27

You need to have the source for DAHDI also.

It will perhaps pay to find out your version, on a 1.6x system the asterisk CLI command is 'dahdi show version'
or from outside of asterisk  dahdi_cfg --help

I hope this isn't a production box, or you know how to recover:
If you don't, then I don't suggest that you continue.

Below, guideline instructions:

cd /usr/src
svn checkout http://svn.digium.com/svn/dahdi/linux/tags/2.2.0 dahdi-linux
svn checkout http://svn.digium.com/svn/dahdi/tools/tags/2.2.0 dahdi-tools
cd /usr/src/dahdi-linux
make
make install

cd /usr/src/dahdi-tools
./configure
make menuselect
make
make install

Now you need to do asterisk again, the patched chan_dahdi.c should still be there. And when you get to run 'make menuselect' DAHDI channels drivers should be there.

cd /usr/src/asterisk
./configure
make menuselect #####  dahdi channel drivers should be there  ####
make
make install

then
stop asterisk
restart dahdi
start asterisk
or just reboot the whole box

By: Alec Davis (alecdavis) 2009-07-01 05:46:18

I've just been browsing release notes for 1.4.25, http://www.asterisk.org/node/48596

" Delay signalling progress until a PRI channel really signals progress.
- Closes issue ASTERISK-12346. Reported, patched, and tested by klaus3000."

This above mentioned fix, is causing this issue.
Klaus mentioned in his later notes https://issues.asterisk.org/view.php?id=13034#102009, that he believed, "dialing=0" should also be in the event PRI_EVENT_RINGING, but it never made it.

I also agree with klaus, and think it should also be there, but I'm covering all basis. But I don't have access for a few days, only web access.

klaus3000: are you reading this, or can someone bring it to his attention.

By: Leif Madsen (lmadsen) 2009-07-01 07:23:17

Hey klaus3000!

You have been mentioned on this issue, and if you could provide a response, that would be fantastic.

Thanks!
Leif.

By: klaus3000 (klaus3000) 2009-07-01 08:22:31

sorry - I do not read all the new bug reports.

Looks like in my testing I never had that issue - in my test cases PROGRESS was always sent.

The problem is that the B channel is not opened until dialing=0. Thus, when ANSWER is received, dialing should be set to 0.

Probably in pri_dchannel() in section "case: PRI_EVENT_ANSWER" there should be

 pri->pvts[chanpos]->dialing = 0;

somewhere.

By: Alec Davis (alecdavis) 2009-07-01 15:13:21

klaus: bug15420-1.4.25.1-diff.txt already does that.

So if we're in agreeance, seems ready to go, as it fixed our problem, and hopefully will fix scottmilne's.

By: Scott Milne (scottbmilne) 2009-07-02 12:41:51

All looked like it went normally by the instructions for the dahdi-linux, dahdi-tools and patch but during the make for asterisk:

make[1]: Entering directory `/usr/src/asterisk/channels'
  [CC] chan_dahdi.c -> chan_dahdi.o
chan_dahdi.c: In function âpri_dchannelâ:
chan_dahdi.c:9676: warning: implicit declaration of function âast_debugâ
  [LD] chan_dahdi.o -> chan_dahdi.so
make[1]: Leaving directory `/usr/src/asterisk/channels'

By: Scott Milne (scottbmilne) 2009-07-02 16:24:14

Got it!!!!!

I was afraid to make install with the warning above so I commented out the "ast_debug" line then ran make again. No errors compiling. Then, again out of fear of breaking the whole install, I simply copied the recompiled chan_dahdi.so file to overwrite the production file.

Thanks much for all your help!!!

By: Alec Davis (alecdavis) 2009-07-02 17:09:49

Please report back as to wheter you now have audio to the NORTEL from a call originated from an Asterisk Connected SIP phone.

By: Scott Milne (scottbmilne) 2009-07-02 17:14:41

Yes. All appears to be working properly now. I get audio as soon as the set on the Nortel answers.

By: Alec Davis (alecdavis) 2009-07-02 17:33:39

please remove bug15420-1.4.25.1-diff.txt it doesn't compile!!

uploaded bug15420-1.4.25.1-diff2.txt

now only has esential line with no 'incorrect' debug statement.
 pri->pvts[chanpos]->dialing = 0;

Scott: Sorry about the mistake, I hadn't run make menuselect, to ensure chan_dahdi was compiled in. Done it now.

Bug marshals:
refer https://issues.asterisk.org/view.php?id=15389
We are using this patch on a SVN-branch-1.6.1-r202764M production box, and a SVN-branch-1.6.2-r203077M test box. Both had exactly the same problem as Scott had.



By: Alec Davis (alecdavis) 2009-07-03 07:27:54

Below others with possibly related issues, that I'm very sure this will fix, including my bug ASTERISK-14368, but this bug report has progressed further.

Fixed ASTERISK-14397 1.4.25.1 asterisk -> Nortel reported by scottbmilne, tested by scottbmilne
Fixed ASTERISK-14393 1.4.25.1 asterisk -> Avaya  reported by avinoash, tested by avinoash
Fixed ASTERISK-14368 1.6.1.0  asterisk -> Fujitsu, reported bu alecdavis, tested by alecdavis
ASTERISK-14212 1.6.1.0 awaiting response.

This patch is confirmed to fix the NoAudio problem, by both ScottMilne and myself.



By: Digium Subversion (svnbot) 2009-07-09 18:37:54

Repository: asterisk
Revision: 205728

U   branches/1.4/channels/chan_dahdi.c

------------------------------------------------------------------------
r205728 | rmudgett | 2009-07-09 18:37:53 -0500 (Thu, 09 Jul 2009) | 21 lines

No audio on calls from Asterisk to various ISDN devices until DTMF sent by caller.

Add missing clearing of the dialing flag when the ISDN call is CONNECTED.
(i.e. When libpri generates the event PRI_EVENT_ANSWER.)

(closes issue ASTERISK-14397)
Reported by: scottbmilne
Patches:
     bug15420-1.4.25.1-diff2.txt uploaded by alecdavis (license 585)
Tested by: scottbmilne, alecdavis

(closes issue ASTERISK-14393)
Reported by: avinoash

(closes issue ASTERISK-14368)
Reported by: alecdavis

This patch should also fix the following issue:
(issue ASTERISK-14212)
Reported by: vinsik

------------------------------------------------------------------------

http://svn.digium.com/view/asterisk?view=rev&revision=205728

By: Digium Subversion (svnbot) 2009-07-09 18:46:23

Repository: asterisk
Revision: 205729

U   branches/1.6.0/channels/chan_dahdi.c

------------------------------------------------------------------------
r205729 | rmudgett | 2009-07-09 18:46:22 -0500 (Thu, 09 Jul 2009) | 28 lines

Merged revisions 205728 via svn merge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
 r205728 | rmudgett | 2009-07-09 18:37:53 -0500 (Thu, 09 Jul 2009) | 21 lines
 
 No audio on calls from Asterisk to various ISDN devices until DTMF sent by caller.
 
 Add missing clearing of the dialing flag when the ISDN call is CONNECTED.
 (i.e. When libpri generates the event PRI_EVENT_ANSWER.)
 
 (closes issue ASTERISK-14397)
 Reported by: scottbmilne
 Patches:
       bug15420-1.4.25.1-diff2.txt uploaded by alecdavis (license 585)
 Tested by: scottbmilne, alecdavis
 
 (closes issue ASTERISK-14393)
 Reported by: avinoash
 
 (closes issue ASTERISK-14368)
 Reported by: alecdavis
 
 This patch should also fix the following issue:
 (issue ASTERISK-14212)
 Reported by: vinsik
........

------------------------------------------------------------------------

http://svn.digium.com/view/asterisk?view=rev&revision=205729

By: Digium Subversion (svnbot) 2009-07-09 18:51:51

Repository: asterisk
Revision: 205730

U   branches/1.6.1/channels/chan_dahdi.c

------------------------------------------------------------------------
r205730 | rmudgett | 2009-07-09 18:51:50 -0500 (Thu, 09 Jul 2009) | 28 lines

Merged revisions 205728 via svn merge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
 r205728 | rmudgett | 2009-07-09 18:37:53 -0500 (Thu, 09 Jul 2009) | 21 lines
 
 No audio on calls from Asterisk to various ISDN devices until DTMF sent by caller.
 
 Add missing clearing of the dialing flag when the ISDN call is CONNECTED.
 (i.e. When libpri generates the event PRI_EVENT_ANSWER.)
 
 (closes issue ASTERISK-14397)
 Reported by: scottbmilne
 Patches:
       bug15420-1.4.25.1-diff2.txt uploaded by alecdavis (license 585)
 Tested by: scottbmilne, alecdavis
 
 (closes issue ASTERISK-14393)
 Reported by: avinoash
 
 (closes issue ASTERISK-14368)
 Reported by: alecdavis
 
 This patch should also fix the following issue:
 (issue ASTERISK-14212)
 Reported by: vinsik
........

------------------------------------------------------------------------

http://svn.digium.com/view/asterisk?view=rev&revision=205730

By: Digium Subversion (svnbot) 2009-07-09 18:56:22

Repository: asterisk
Revision: 205731

U   branches/1.6.2/channels/chan_dahdi.c

------------------------------------------------------------------------
r205731 | rmudgett | 2009-07-09 18:56:21 -0500 (Thu, 09 Jul 2009) | 28 lines

Merged revisions 205728 via svn merge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
 r205728 | rmudgett | 2009-07-09 18:37:53 -0500 (Thu, 09 Jul 2009) | 21 lines
 
 No audio on calls from Asterisk to various ISDN devices until DTMF sent by caller.
 
 Add missing clearing of the dialing flag when the ISDN call is CONNECTED.
 (i.e. When libpri generates the event PRI_EVENT_ANSWER.)
 
 (closes issue ASTERISK-14397)
 Reported by: scottbmilne
 Patches:
       bug15420-1.4.25.1-diff2.txt uploaded by alecdavis (license 585)
 Tested by: scottbmilne, alecdavis
 
 (closes issue ASTERISK-14393)
 Reported by: avinoash
 
 (closes issue ASTERISK-14368)
 Reported by: alecdavis
 
 This patch should also fix the following issue:
 (issue ASTERISK-14212)
 Reported by: vinsik
........

------------------------------------------------------------------------

http://svn.digium.com/view/asterisk?view=rev&revision=205731