Summary:ASTERISK-21996: chan_iax2 fails to process network packets after a while
Reporter:Heiko Wundram (modelnine)Labels:
Date Opened:2013-07-02 06:04:37Date Closed:2015-07-28 14:35:51
Versions:11.2.2 11.3.0 11.4.0 11.5.0 Frequency of
Environment:Gentoo ebuild Asterisk without additional patchesAttachments:( 0) threads-bt.txt
Description:After a while, chan_iax2 fails to accept new networking packets. The initial symptom is visible when enabling IAX2-debugging: outgoing packets are shown, but all incoming packets (directed to the correct port) are no longer visible inside Asterisk, even tough they do show up with an appropriate tcpdump on the corresponding network interface they arrive at. All IAX2 peers become unreachable, and IAX2 calls stop working.

I've core-dumped a running Asterisk executable while it was in this state, and it seems that the IAX2 networking thread (chan_iax2.c:network_thread) isn't running anymore. The issue doesn't seem to affect any other areas of networking/SIP telephony in the Asterisk core, and the IAX2 module seems to be running fine otherwise (i.e., all threads are "idle") even though the networking thread is "gone".

I've not yet tried additional debugging while Asterisk is running yet.
Comments:By: Alec Davis (alecdavis) 2013-07-02 06:25:37.020-0500

There have been a number of chan_iax fixes since 11.4.0
refer to http://svnview.digium.com/svn/asterisk/branches/11/channels/chan_iax2.c?view=log

please try http://svnview.digium.com/svn/asterisk/tags/11.5.0-rc1/

By: Heiko Wundram (modelnine) 2013-07-02 07:28:05.097-0500

Backtrace of all running threads at the time of core dump, with iax processing threads, without IAX network thread (gone).

By: Heiko Wundram (modelnine) 2013-07-02 07:30:49.489-0500

I've tried a few of the patches posted for chan_iax2 from this Jira, but none of them actually fixed the issue. I'll try to get 11.5.0-rc1 running on the corresponding machine, though, and get back.

By: Rusty Newton (rnewton) 2013-07-09 09:00:39.688-0500

If the issue still occurs in 11.5.0-rc1 be sure to gather an Asterisk log showing the time when the issue beings to occur. That is a log (see logger.conf) with VERBOSE, DEBUG types enabled at level 5 or higher.

Please also include a pcap of the IAX traffic happening up to that point, just in case a particular packet is triggering or stimulating the problem.

By: Rusty Newton (rnewton) 2013-07-24 18:16:32.444-0500

Suspended due to lack of activity. Please request a bug marshal in #asterisk-bugs on the IRC network irc.freenode.net to reopen the issue should you have the additional information requested.  Further information can be found at http://www.asterisk.org/developers/bug-guidelines

By: Heiko Wundram (modelnine) 2013-08-21 08:14:20.960-0500

I've now had 11.5.0 running for quite some time, and initially, I though that the issue was fixed, but that doesn't seem to be the case. It has now resurfaced twice (i.e., IAX network packets simply stopping) in a row. I'm currently setting up Asterisk to be able to get the requested logs, and will get back then.

By: rsw686 (rsw686) 2015-07-28 14:31:59.565-0500

I'm having this same issue on two different servers after upgrading them both from 1.8.15-cert5 to 11.6-cert11. After awhile I am not able to place or receive an iax call. If I issue a module unload chan_iax2.so and module load chan_iax2.so it will start processing inbound calls again.

By: Asterisk Team (asteriskteam) 2015-07-28 14:32:00.361-0500

This issue has been reopened as a result of your commenting on it as the reporter. It will be triaged once again as applicable.

By: Joshua C. Colp (jcolp) 2015-07-28 14:35:51.543-0500

Automation mistakenly reopened this issue. Please file a new one.