From owner-freebsd-isdn@FreeBSD.ORG Mon Nov 12 10:23:42 2012 Return-Path: Delivered-To: freebsd-isdn@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id C9C8FF6 for ; Mon, 12 Nov 2012 10:23:42 +0000 (UTC) (envelope-from freebsd@psconsult.nl) Received: from mx1.psconsult.nl (unknown [IPv6:2001:7b8:30f:e0::5059:ee8a]) by mx1.freebsd.org (Postfix) with ESMTP id 2B69B8FC08 for ; Mon, 12 Nov 2012 10:23:41 +0000 (UTC) Received: from mx1.psconsult.nl (mx1.hvnu.psconsult.nl [46.44.189.154]) by mx1.psconsult.nl (8.14.5/8.14.4) with ESMTP id qACANWxQ014035 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Mon, 12 Nov 2012 11:23:37 +0100 (CET) (envelope-from freebsd@psconsult.nl) Received: (from paul@localhost) by mx1.psconsult.nl (8.14.5/8.14.4/Submit) id qACANW0d014034; Mon, 12 Nov 2012 11:23:32 +0100 (CET) (envelope-from freebsd@psconsult.nl) X-Authentication-Warning: mx1.psconsult.nl: paul set sender to freebsd@psconsult.nl using -f Date: Mon, 12 Nov 2012 11:23:32 +0100 From: Paul Schenkeveld To: freebsd-isdn@freebsd.org Subject: Re: ISDN4BSD (HPS version) is going into ports Message-ID: <20121112102332.GA13575@psconsult.nl> References: <509E87EF.9070607@incore.de> <201211112246.44683.hselasky@c2i.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201211112246.44683.hselasky@c2i.net> User-Agent: Mutt/1.5.21 (2010-09-15) X-BeenThere: freebsd-isdn@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Using ISDN with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Nov 2012 10:23:42 -0000 On Sun, Nov 11, 2012 at 10:46:44PM +0100, Hans Petter Selasky wrote: > On Saturday 10 November 2012 17:59:27 Andreas Longwitz wrote: > > Hi, > > > > I am runnung FreeBSD 8.3 with isdn4bsd 2.0.4 + chan_capi 2.0.2 from > > ports and asterisk 1.8.16. On my production system with two HFC-4S > > adapters (one in NT-mode, the other in TE-mode) and some SIP-phones I > > have the following problem: asterisk runs in a deadlock two or three > > times a week, nothing but kill -9 helps. > > > > During looking for a possible reason for the deadlock I found that > > asterisk never destroys a channel from a call initiated inbound by i4b. > > > > On the asterisk console the command "capi show" always gives the correct > > infos about busy isdn channels, but "core show channels verbose" lists > > more and more channels. For every call incoming via i4b the channel > > remains in the list of active asterisk channels. Outgoing isdn channels > > and all sip channels disappear after hangup. > > > > For a call incoming via i4b I see on hangup that chan_capi_hangup() is > > called and then cd_free() with state=6 (CAPI_STATE_CONNECTED), > > send_release_complete=1, causeOut=0x3490 and hangup_what=0. Afterwards I > > see the call of capi_send_disconnect_req. > > > > In the case of dir_incoming I can see nothing that informs asterisk > > about the free channel. I suppose in the case dir_outgoing this is done > > by "ast_setstate(pbx_chan, AST_STATE_DOWN)" in cd_free(). > > Hi, > > I'll have a look at this issue this week. Sounds like reproducible. We > probably should compare with other channel drivers what they are doing. > > Do you see this problem using older versions of asterisk? I still have one asterisk 1.8.8.1 server on FreeBSD 8.2 with a single HFC card connected to the public ISDN network. It's only used to receive calls. Seems my channels hang till next restart of asterisk too: pbx*CLI> core show channels verbose Channel Context Extension Prio State Application Data CallerID Duration Accountcode PeerAccount BridgedTo CAPI/isdn/30 isdn-in xxxxxxxxx 5 Ring (None) (None) yyyyyyyyyy - (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Ring (None) (None) yyyyyyyyyy - (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Ring (None) (None) yyyyyyyyyy - (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Ring (None) (None) yyyyyyyyyy - (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Ring (None) (None) yyyyyyyyyy - (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Ring (None) (None) yyyyyyyyyy - (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Ring (None) (None) yyyyyyyyyy - (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) yyyyyyyyyy 351:59:4 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) yyyyyyyyyy 336:01:3 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 7 Up (None) (None) yyyyyyyyyy - (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) 331:27:2 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) yyyyyyyyyy 315:21:5 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) 302:36:1 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) yyyyyyyyyy 290:39:1 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) yyyyyyyyyy 280:28:1 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) 278:20:4 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) 277:53:5 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) 277:45:4 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) yyyyyyyyyy 264:39:5 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) yyyyyyyyyy 264:24:5 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) yyyyyyyyyy 254:25:3 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) yyyyyyyyyy 239:24:1 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) yyyyyyyyyy 234:59:0 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) yyyyyyyyyy 232:32:3 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) yyyyyyyyyy 231:07:1 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) yyyyyyyyyy 210:29:1 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) yyyyyyyyyy 187:45:1 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) yyyyyyyyyy 167:34:1 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) yyyyyyyyyy 167:10:2 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) yyyyyyyyyy 147:33:0 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) 142:21:1 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) yyyyyyyyyy 140:36:1 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) yyyyyyyyyy 113:32:1 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 10 Up (None) (None) - (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) yyyyyyyyyy 88:15:20 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Up (None) (None) yyyyyyyyyy 64:05:35 (None) CAPI/isdn/30 isdn-in xxxxxxxxx 5 Ring (None) (None) yyyyyyyyyy - (None) 37 active channels 0 active calls 111 calls processed The asterisk process was started on Oct 28, 2012 which matches the oldest channel. HTH Paul Schenkeveld