Unusual disconnects

but a software crash can e.g. codec crash ?

Possible but highly unlikely, try another phone but investigate your rtp traffic flow with tcpdump to see what is going wrong.

Try stopping your firewall service and see if that helps (not permanently, just as a test!). I was having all sorts of crazy problems, and it turned out that the root cause was some custom rules in my iptables. It took me 6 months to think to test that.

I’m still experiencing hangups on conference calls (calls to Toll Free Numbers). I don’t seem to be seeing rtp_timeout errors anymore here’s what I’m seing:

[2013-09-24 17:17:00] NOTICE[12776]: pbx_spool.c:385 attempt_thread: Call completed to Local/s@tc-maint
== Spawn extension (tc-maint, s, 5) exited non-zero on ‘Local/s@tc-maint-00000798;2’
– Attempting call on Local/s@tc-maint for application NoCDR() (Retry 1)
– Executing [s@tc-maint:1] NoCDR(“Local/s@tc-maint-00000799;2”, “”) in new stack
– Executing [s@tc-maint:2] Set(“Local/s@tc-maint-00000799;2”, “TCMAINT=RETURN”) in new stack
– Executing [s@tc-maint:3] GosubIf(“Local/s@tc-maint-00000799;2”, “0?timeconditions,1,1()”) in new stack
– Executing [s@tc-maint:4] System(“Local/s@tc-maint-00000799;2”, “/var/lib/asterisk/bin/schedtc.php 60 /var/spool/asterisk/outgoing 0”) in new stack
– Executing [s@tc-maint:5] Answer(“Local/s@tc-maint-00000799;2”, “”) in new stack
> Channel Local/s@tc-maint-00000799;1 was answered.
> Launching NoCDR() on Local/s@tc-maint-00000799;1
[2013-09-24 17:18:00] NOTICE[12781]: pbx_spool.c:385 attempt_thread: Call completed to Local/s@tc-maint
== Spawn extension (tc-maint, s, 5) exited non-zero on ‘Local/s@tc-maint-00000799;2’
– Attempting call on Local/s@tc-maint for application NoCDR() (Retry 1)
– Executing [s@tc-maint:1] NoCDR(“Local/s@tc-maint-0000079a;2”, “”) in new stack
– Executing [s@tc-maint:2] Set(“Local/s@tc-maint-0000079a;2”, “TCMAINT=RETURN”) in new stack
– Executing [s@tc-maint:3] GosubIf(“Local/s@tc-maint-0000079a;2”, “0?timeconditions,1,1()”) in new stack
– Executing [s@tc-maint:4] System(“Local/s@tc-maint-0000079a;2”, “/var/lib/asterisk/bin/schedtc.php 60 /var/spool/asterisk/outgoing 1”) in new stack
– Executing [s@tc-maint:5] Answer(“Local/s@tc-maint-0000079a;2”, “”) in new stack
> Channel Local/s@tc-maint-0000079a;1 was answered.
> Launching NoCDR() on Local/s@tc-maint-0000079a;1
[2013-09-24 17:18:01] NOTICE[12784]: pbx_spool.c:385 attempt_thread: Call completed to Local/s@tc-maint
== Spawn extension (tc-maint, s, 5) exited non-zero on ‘Local/s@tc-maint-0000079a;2’
– Executing [h@macro-dialout-trunk:1] Macro(“SIP/100-0000009f”, “hangupcall,”) in new stack
– Executing [s@macro-hangupcall:1] GotoIf(“SIP/100-0000009f”, “1?theend”) in new stack
– Goto (macro-hangupcall,s,3)
– Executing [s@macro-hangupcall:3] ExecIf(“SIP/100-0000009f”, “0?Set(CDR(recordingfile)=)”) in new stack
– Executing [s@macro-hangupcall:4] Hangup(“SIP/100-0000009f”, “”) in new stack
== Spawn extension (macro-hangupcall, s, 4) exited non-zero on ‘SIP/100-0000009f’ in macro ‘hangupcall’
== Spawn extension (macro-dialout-trunk, h, 1) exited non-zero on ‘SIP/100-0000009f’
== Spawn extension (macro-dialout-trunk, s, 22) exited non-zero on ‘SIP/100-0000009f’ in macro ‘dialout-trunk’
== Spawn extension (from-internal, 0800123456, 7) exited non-zero on ‘SIP/100-0000009f’
– Attempting call on Local/s@tc-maint for application NoCDR() (Retry 1)
– Executing [s@tc-maint:1] NoCDR(“Local/s@tc-maint-0000079b;2”, “”) in new stack
– Executing [s@tc-maint:2] Set(“Local/s@tc-maint-0000079b;2”, “TCMAINT=RETURN”) in new stack
– Executing [s@tc-maint:3] GosubIf(“Local/s@tc-maint-0000079b;2”, “0?timeconditions,1,1()”) in new stack
– Executing [s@tc-maint:4] System(“Local/s@tc-maint-0000079b;2”, “/var/lib/asterisk/bin/schedtc.php 60 /var/spool/asterisk/outgoing 0”) in new stack
– Executing [s@tc-maint:5] Answer(“Local/s@tc-maint-0000079b;2”, “”) in new stack
> Channel Local/s@tc-maint-0000079b;1 was answered.
> Launching NoCDR() on Local/s@tc-maint-0000079b;1
[2013-09-24 17:19:01] NOTICE[12789]: pbx_spool.c:385 attempt_thread: Call completed to Local/s@tc-maint
== Spawn extension (tc-maint, s, 5) exited non-zero on ‘Local/s@tc-maint-0000079b;2’
– Attempting call on Local/s@tc-maint for application NoCDR() (Retry 1)
– Executing [s@tc-maint:1] NoCDR(“Local/s@tc-maint-0000079c;2”, “”) in new stack
– Executing [s@tc-maint:2] Set(“Local/s@tc-maint-0000079c;2”, “TCMAINT=RETURN”) in new stack
– Executing [s@tc-maint:3] GosubIf(“Local/s@tc-maint-0000079c;2”, “0?timeconditions,1,1()”) in new stack
– Executing [s@tc-maint:4] System(“Local/s@tc-maint-0000079c;2”, “/var/lib/asterisk/bin/schedtc.php 60 /var/spool/asterisk/outgoing 1”) in new stack
– Executing [s@tc-maint:5] Answer(“Local/s@tc-maint-0000079c;2”, “”) in new stack
> Channel Local/s@tc-maint-0000079c;1 was answered.
> Launching NoCDR() on Local/s@tc-maint-0000079c;1
[2013-09-24 17:20:00] NOTICE[12794]: pbx_spool.c:385 attempt_thread: Call completed to Local/s@tc-maint
== Spawn extension (tc-maint, s, 5) exited non-zero on ‘Local/s@tc-maint-0000079c;2’

If anyone can shed any light on this I’d be very grateful.

I think I’ve found the answer to my problem. I found this post via Google which suggests that there is a problem with the latest version of Grandstream GXP2000 firmware where all calls drop after 17:24 minutes duration:

http://forums.grandstream.com/forums/index.php?topic=15554.0

Setting

session-timers=refuse

in Asterisk Sip Settings, seems to have fixed this issue for now.
I hope this post helps others with the same problem.

Interesting. I’ve some GXP2000 with latest Firmware too so, just in case, I’ll follow your solution to avoid (a priori) any troubles with such long calls.