Summary: | ASTERISK-14455: [patch] mISDN rejects incoming calls (reopened) | ||
Reporter: | Stefano Lucchetti (slutec18) | Labels: | |
Date Opened: | 2009-07-13 04:04:09 | Date Closed: | 2009-10-01 20:38:27 |
Priority: | Major | Regression? | No |
Status: | Closed/Complete | Components: | Channels/chan_misdn |
Versions: | Frequency of Occurrence | ||
Related Issues: | |||
Environment: | Attachments: | ( 0) issue15490_channel_alloc_reentrancy.patch | |
Description: | have a trixbox installation with a b800p with 6 ISDN lines configured in PTP mode. The asterisk version is 1.4.25.1 and misdn 1.1.7 The system works well but I Sometimes, usually twice a week the system gives me a dial out failure. That happens usually when pbx is under heavy load In this circumsance I can receive calls as before but I cannot perform outbound calls. The only solution is to reach the ssh console in the system and give an "mISDN restart", after that the system returns to normal operation and i can perform outbound calls again. The misdn log file reports a problem related to issue [asterisk-bugs] [Asterisk 0013488]: mISDN rejects incoming calls but the asterisk changelog states that bug 13488 was fixed in 1.4.25.1 version Fri Jul 10 17:09:25 2009: P[ 1] **** Received CAUSE:44, so not cleaning up channel 1 Fri Jul 10 17:09:25 2009: P[ 1] **** This channel is now no longer available, please try to restart it with 'misdn send restart <port> <channel>' Fri Jul 10 17:09:25 2009: P[ 1] Sending Restarts on this port. Fri Jul 10 17:09:25 2009: P[ 1] Restarting and cleaning channel 1 Fri Jul 10 17:09:25 2009: P[ 1] Restarting channel 1 Fri Jul 10 17:09:33 2009: P[ 1] Requested Channel Already in Use releasing this call with cause 34!!!! Fri Jul 10 17:09:33 2009: P[ 1] couldn't handle event Fri Jul 10 17:09:33 2009: P[ 1] CC_RELEASE_COMPLETE|CONFIRM [TE] Fri Jul 10 17:09:46 2009: P[ 1] Requested Channel Already in Use releasing this call with cause 34!!!! Fri Jul 10 17:09:46 2009: P[ 1] couldn't handle event Fri Jul 10 17:09:46 2009: P[ 1] CC_RELEASE_COMPLETE|CONFIRM [TE] Fri Jul 10 17:09:57 2009: P[ 1] Requested Channel Already in Use releasing this call with cause 34!!!! Fri Jul 10 17:09:57 2009: P[ 1] couldn't handle event Fri Jul 10 17:09:57 2009: P[ 1] CC_RELEASE_COMPLETE|CONFIRM [TE] Fri Jul 10 17:10:43 2009: P[ 1] Requested Channel Already in Use releasing this call with cause 34!!!! Fri Jul 10 17:10:43 2009: P[ 1] couldn't handle event Fri Jul 10 17:10:43 2009: P[ 1] CC_RELEASE_COMPLETE|CONFIRM [TE] Fri Jul 10 17:11:17 2009: P[ 1] Requested Channel Already in Use releasing this call with cause 34!!!! Fri Jul 10 17:11:17 2009: P[ 1] couldn't handle event Fri Jul 10 17:11:17 2009: P[ 1] CC_RELEASE_COMPLETE|CONFIRM [TE] Fri Jul 10 17:12:59 2009: P[ 1] Requested Channel Already in Use releasing this call with cause 34!!!! Fri Jul 10 17:12:59 2009: P[ 1] couldn't handle event Fri Jul 10 17:12:59 2009: P[ 1] CC_RELEASE_COMPLETE|CONFIRM [TE] Fri Jul 10 17:14:01 2009: P[ 1] Requested Channel Already in Use releasing this call with cause 34!!!! Fri Jul 10 17:14:01 2009: P[ 1] couldn't handle event Fri Jul 10 17:14:01 2009: P[ 1] CC_RELEASE_COMPLETE|CONFIRM [TE] Fri Jul 10 17:14:29 2009: P[ 1] Requested Channel Already in Use releasing this call with cause 34!!!! Fri Jul 10 17:14:29 2009: P[ 1] couldn't handle event Fri Jul 10 17:14:29 2009: P[ 1] CC_RELEASE_COMPLETE|CONFIRM [TE] Fri Jul 10 17:18:17 2009: P[ 0] -- mISDN Channel Driver Registered -- I also checked the .c file to see if the patch reported in 13488 is included. As expected I found the code regarding the patch. Regards ****** ADDITIONAL INFORMATION ****** Versions are Trixbox 2.6.2, mISDN 1.1.7, asterisk 1.4.25.1 B800P board is configured with --------------- in mISDN script i have the following settings HFCMULTI_protocol[${i}]="0x22,0x22,0x22,0x22,0x22,0x22,0x22,0x22" HFCMULTI_layermask[${i}]="0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf" ---------------- ---------------- the mISDN.conf in /etc <mISDNconf> <module poll="128" debug="0" timer="no">hfcmulti</module> <module debug="0" options="0">mISDN_dsp</module> <devnode user="root" group="root" mode="644">mISDN</devnode> <card type="BN8S0"> <port mode="te" link="ptp">1</port> <port mode="te" link="ptp">2</port> <port mode="te" link="ptp">3</port> <port mode="te" link="ptp">4</port> <port mode="te" link="ptp">5</port> <port mode="te" link="ptp">6</port> <port mode="te" link="ptp">7</port> <port mode="te" link="ptp">8</port> </card> </mISDNconf> ------------------ Accordig to misdn.org instructions I have pmp_l1_check=no, ports configured individually in misdn and when I perform outbound calls I use trunks sequentilly from 1 to 6 and not a group of trunks in order to avoid telco's power off. Also in misdn show config I have block_on_alarm=no | ||
Comments: | By: Richard Mudgett (rmudgett) 2009-07-15 19:47:46 The patch in 13488 will have no effect if the te_choose_channel option in /etc/asterisk/misdn.conf is set to yes or the line is a PRI. (The default for te_choose_channel is no.) By: Stefano Lucchetti (slutec18) 2009-07-15 21:48:13 The te_choose_channel is set to no in my case. I'm trying to find if it is a hardware oriented issue. The only different thing in my case is that I have a board with 8 BRI channels and I have configured and running only 6, I didn't put any terminal resistor in the beginning and the end on the cable connecting the board with the NT (approx 1,5m length) and that B800p from openvox uses a patched misdn (hfc_multi.c) and maybe there is a policy related with the patch (or a policy based issue). Anyway I opened a similar ticket at openvox's forum and they say to downgrate to asterisk 1.4.20. By: Richard Mudgett (rmudgett) 2009-08-18 13:25:14 I have not been able to reproduce the problem of losing channels. However, I have seen in the code a reentrancy problem that might give these symptoms. The reentrancy patch does several things: 1) Guards B channel and B channel structure allocation. 2) Makes the B channel structure find routines more precise in locating records. 3) Never leave a B channel allocated if we received cause 44. The last item may cause temporary outgoing call problems, but they should clear when the line becomes idle. By: Stefano Lucchetti (slutec18) 2009-08-19 13:55:02 Yesterday, after 20 days, I received a cause 44 and I had to restart misdn again. I will try your patch tomorrow. Hope that will fix my problem since it's a production environment. Many thanks By: Stefano Lucchetti (slutec18) 2009-08-20 07:18:52 I patched succesfully asterisk few minutes ago. I saw some new entries in misdn.log after patching and restarting amportal and mISDN Thu Aug 20 14:08:40 2009 P[ 0] -- mISDN Channel Driver Registered -- Thu Aug 20 14:09:04 2009: P[ 0] received 1k Unhandled Bchannel Messages: prim 120282 len 128 from addr 52010101, dinfo ffffffff on this port. Thu Aug 20 14:18:56 2009: P[ 0] -- mISDN Channel Driver Registered -- Thu Aug 20 14:19:23 2009: P[ 0] received 1k Unhandled Bchannel Messages: prim 20081 len 0 from addr 52010101, dinfo 0 on this port. By: Richard Mudgett (rmudgett) 2009-08-20 09:27:44 The unhandled Bchannel messages message can be ignored. It does not seem to cause a problem. By: Stefano Lucchetti (slutec18) 2009-10-01 04:02:29 after 40 days with patched asterisk I didn't receive any CAUSE 44 and everything works ok. thanks By: Digium Subversion (svnbot) 2009-10-01 18:21:20 Repository: asterisk Revision: 221769 U branches/1.4/channels/misdn/isdn_lib.c U branches/1.4/channels/misdn/isdn_lib_intern.h ------------------------------------------------------------------------ r221769 | rmudgett | 2009-10-01 18:21:19 -0500 (Thu, 01 Oct 2009) | 26 lines Occasionally losing use of B channels in chan_misdn. I have not been able to reproduce the problem of losing channels. However, I have seen in the code a reentrancy problem that might give these symptoms. The reentrancy patch does several things: 1) Guards B channel and B channel structure allocation. 2) Makes the B channel structure find routines more precise in locating records. 3) Never leave a B channel allocated if we received cause 44. The last item may cause temporary outgoing call problems, but they should clear when the line becomes idle. (closes issue ASTERISK-14455) Reported by: slutec18 Patches: issue15490_channel_alloc_reentrancy.patch uploaded by rmudgett (license 664) Tested by: rmudgett, slutec18 (closes issue ASTERISK-14426) Reported by: FabienToune Patches: issue15458_channel_alloc_reentrancy.patch uploaded by rmudgett (license 664) Tested by: FabienToune, rmudgett, slutec18 ------------------------------------------------------------------------ http://svn.digium.com/view/asterisk?view=rev&revision=221769 By: Digium Subversion (svnbot) 2009-10-01 20:12:24 Repository: asterisk Revision: 221844 _U trunk/ U trunk/channels/misdn/isdn_lib.c U trunk/channels/misdn/isdn_lib_intern.h ------------------------------------------------------------------------ r221844 | rmudgett | 2009-10-01 20:12:24 -0500 (Thu, 01 Oct 2009) | 33 lines Merged revisions 221769 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r221769 | rmudgett | 2009-10-01 18:18:28 -0500 (Thu, 01 Oct 2009) | 26 lines Occasionally losing use of B channels in chan_misdn. I have not been able to reproduce the problem of losing channels. However, I have seen in the code a reentrancy problem that might give these symptoms. The reentrancy patch does several things: 1) Guards B channel and B channel structure allocation. 2) Makes the B channel structure find routines more precise in locating records. 3) Never leave a B channel allocated if we received cause 44. The last item may cause temporary outgoing call problems, but they should clear when the line becomes idle. (closes issue ASTERISK-14455) Reported by: slutec18 Patches: issue15490_channel_alloc_reentrancy.patch uploaded by rmudgett (license 664) Tested by: rmudgett, slutec18 (closes issue ASTERISK-14426) Reported by: FabienToune Patches: issue15458_channel_alloc_reentrancy.patch uploaded by rmudgett (license 664) Tested by: FabienToune, rmudgett, slutec18 ........ ------------------------------------------------------------------------ http://svn.digium.com/view/asterisk?view=rev&revision=221844 By: Digium Subversion (svnbot) 2009-10-01 20:23:03 Repository: asterisk Revision: 221853 _U branches/1.6.0/ U branches/1.6.0/channels/misdn/isdn_lib.c U branches/1.6.0/channels/misdn/isdn_lib_intern.h ------------------------------------------------------------------------ r221853 | rmudgett | 2009-10-01 20:23:03 -0500 (Thu, 01 Oct 2009) | 40 lines Merged revisions 221844 via svnmerge from https://origsvn.digium.com/svn/asterisk/trunk ................ r221844 | rmudgett | 2009-10-01 20:09:31 -0500 (Thu, 01 Oct 2009) | 33 lines Merged revisions 221769 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r221769 | rmudgett | 2009-10-01 18:18:28 -0500 (Thu, 01 Oct 2009) | 26 lines Occasionally losing use of B channels in chan_misdn. I have not been able to reproduce the problem of losing channels. However, I have seen in the code a reentrancy problem that might give these symptoms. The reentrancy patch does several things: 1) Guards B channel and B channel structure allocation. 2) Makes the B channel structure find routines more precise in locating records. 3) Never leave a B channel allocated if we received cause 44. The last item may cause temporary outgoing call problems, but they should clear when the line becomes idle. (closes issue ASTERISK-14455) Reported by: slutec18 Patches: issue15490_channel_alloc_reentrancy.patch uploaded by rmudgett (license 664) Tested by: rmudgett, slutec18 (closes issue ASTERISK-14426) Reported by: FabienToune Patches: issue15458_channel_alloc_reentrancy.patch uploaded by rmudgett (license 664) Tested by: FabienToune, rmudgett, slutec18 ........ ................ ------------------------------------------------------------------------ http://svn.digium.com/view/asterisk?view=rev&revision=221853 By: Digium Subversion (svnbot) 2009-10-01 20:29:39 Repository: asterisk Revision: 221871 _U branches/1.6.1/ U branches/1.6.1/channels/misdn/isdn_lib.c U branches/1.6.1/channels/misdn/isdn_lib_intern.h ------------------------------------------------------------------------ r221871 | rmudgett | 2009-10-01 20:29:39 -0500 (Thu, 01 Oct 2009) | 40 lines Merged revisions 221844 via svnmerge from https://origsvn.digium.com/svn/asterisk/trunk ................ r221844 | rmudgett | 2009-10-01 20:09:31 -0500 (Thu, 01 Oct 2009) | 33 lines Merged revisions 221769 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r221769 | rmudgett | 2009-10-01 18:18:28 -0500 (Thu, 01 Oct 2009) | 26 lines Occasionally losing use of B channels in chan_misdn. I have not been able to reproduce the problem of losing channels. However, I have seen in the code a reentrancy problem that might give these symptoms. The reentrancy patch does several things: 1) Guards B channel and B channel structure allocation. 2) Makes the B channel structure find routines more precise in locating records. 3) Never leave a B channel allocated if we received cause 44. The last item may cause temporary outgoing call problems, but they should clear when the line becomes idle. (closes issue ASTERISK-14455) Reported by: slutec18 Patches: issue15490_channel_alloc_reentrancy.patch uploaded by rmudgett (license 664) Tested by: rmudgett, slutec18 (closes issue ASTERISK-14426) Reported by: FabienToune Patches: issue15458_channel_alloc_reentrancy.patch uploaded by rmudgett (license 664) Tested by: FabienToune, rmudgett, slutec18 ........ ................ ------------------------------------------------------------------------ http://svn.digium.com/view/asterisk?view=rev&revision=221871 By: Digium Subversion (svnbot) 2009-10-01 20:38:26 Repository: asterisk Revision: 221879 _U branches/1.6.2/ U branches/1.6.2/channels/misdn/isdn_lib.c U branches/1.6.2/channels/misdn/isdn_lib_intern.h ------------------------------------------------------------------------ r221879 | rmudgett | 2009-10-01 20:38:26 -0500 (Thu, 01 Oct 2009) | 40 lines Merged revisions 221844 via svnmerge from https://origsvn.digium.com/svn/asterisk/trunk ................ r221844 | rmudgett | 2009-10-01 20:09:31 -0500 (Thu, 01 Oct 2009) | 33 lines Merged revisions 221769 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r221769 | rmudgett | 2009-10-01 18:18:28 -0500 (Thu, 01 Oct 2009) | 26 lines Occasionally losing use of B channels in chan_misdn. I have not been able to reproduce the problem of losing channels. However, I have seen in the code a reentrancy problem that might give these symptoms. The reentrancy patch does several things: 1) Guards B channel and B channel structure allocation. 2) Makes the B channel structure find routines more precise in locating records. 3) Never leave a B channel allocated if we received cause 44. The last item may cause temporary outgoing call problems, but they should clear when the line becomes idle. (closes issue ASTERISK-14455) Reported by: slutec18 Patches: issue15490_channel_alloc_reentrancy.patch uploaded by rmudgett (license 664) Tested by: rmudgett, slutec18 (closes issue ASTERISK-14426) Reported by: FabienToune Patches: issue15458_channel_alloc_reentrancy.patch uploaded by rmudgett (license 664) Tested by: FabienToune, rmudgett, slutec18 ........ ................ ------------------------------------------------------------------------ http://svn.digium.com/view/asterisk?view=rev&revision=221879 |