Call finish after 30 seconds on Hold (simple Hold and on transfers)

Hi,

I’m having this problem with hold and on transfers (assuming that the hold is the one that cuts the calls on transfers as well).

When an extension puts the call on hold, the call finish after 30 seconds. The same on a transfer. In an attended transfer, after 30 seconds (and before transferring the call to the final destination) the call is dropped.

It’s driving me crazy because I can’t find where those 30 seconds of hold are.

Thanks in advance.

Only devices, not extensions, are involved in Asterisk holds.

You should look at he logs to see what is disconnecting the call, and if it is Asterisk, what is being timed out.

You also need to tell us what channel technology you are using. DAHDI analogue holds may be very different from SIP ones, and chan_sip ones may differ from chan_psjip ones.
If SIP, 30 seconds is fairly typical of failing to get an expected SIP reply, after multiple retransmissions, but it could also be related to RTP timeouts.

Also, there is more than one way for a device to initiate a SIP hold.

Thanks david,

Maybe if I show the log can help.

There is no dahdi involved. Only SIP.

[C-00000e16] res_agi.c: AGI Script Executing Application: (Progress) Options: ()
[C-00000e16] res_agi.c: AGI Script Executing Application: (dial) Options: (SIP/301845,300,TtRr)
[C-00000e16] netsock2.c: Using SIP RTP CoS mark 5
[C-00000e16] app_dial.c: Called SIP/301845
[C-00000e16] app_dial.c: SIP/301845-00001c51 is ringing
[C-00000e16] app_dial.c: SIP/301845-00001c51 answered SIP/301700-00001c50
[C-00000e16] bridge_channel.c: Channel SIP/301845-00001c51 joined 'simple_bridge' basic-bridge <ded765d9-f18a-4fbf-909a-de7c9799ff51>
[C-00000e16] bridge_channel.c: Channel SIP/301700-00001c50 joined 'simple_bridge' basic-bridge <ded765d9-f18a-4fbf-909a-de7c9799ff51>
[Feb 25 12:43:01][C-00000e16] res_musiconhold.c: Started music on hold, class 'default', on channel 'SIP/301700-00001c50'
[C-00000e16] bridge_channel.c: Channel SIP/301845-00001c51 left 'simple_bridge' basic-bridge <ded765d9-f18a-4fbf-909a-de7c9799ff51>
[C-00000e16] bridge_channel.c: Channel SIP/301700-00001c50 left 'simple_bridge' basic-bridge <ded765d9-f18a-4fbf-909a-de7c9799ff51>
[Feb 25 12:43:33][C-00000e16] res_musiconhold.c: Stopped music on hold on SIP/301700-00001c50
[C-00000e16] res_agi.c: <SIP/301700-00001c50>AGI Script agi://smatecor-vip.bancocredicoop.coop:6038/ExtensionRouting completed, returning 0
[C-00000e16] pbx.c: Executing [301845@outtrextensions:3] Hangup("SIP/301700-00001c50", "") in new stack
[C-00000e16] pbx.c: Spawn extension (outtrextensions, 301845, 3) exited non-zero on 'SIP/301700-00001c50'

That’s showing a controlled hangup, requested by the dialplan. I think you need to look at your AGI script to find out why it is terminating prematurely. It doesn’t seem to be as the result of a hangup.

You are using chan_sip.

Ok David, no agi then (same behavior)

Really, it’s driving me crazy. Only on Holds.

[Feb 25 14:19:44] VERBOSE[10814][C-00000ed0] pbx.c: Executing [1845@from-operador:1] Set("SIP/301700-00001de0", "ESTADO=NOT_INUSE") in new stack
[Feb 25 14:19:44] VERBOSE[10814][C-00000ed0] pbx.c: Executing [1845@from-operador:2] GotoIf("SIP/301700-00001de0", "1?disponible") in new stack
[Feb 25 14:19:44] VERBOSE[10814][C-00000ed0] pbx_builtins.c: Goto (from-operador,1845,4)
[Feb 25 14:19:44] VERBOSE[10814][C-00000ed0] pbx.c: Executing [1845@from-operador:4] Dial("SIP/301700-00001de0", "SIP/301845,300,tT") in new stack
[Feb 25 14:19:44] VERBOSE[10815] app_mixmonitor.c: Begin MixMonitor Recording SIP/301700-00001de0
[Feb 25 14:19:44] VERBOSE[10814][C-00000ed0] netsock2.c: Using SIP RTP CoS mark 5
[Feb 25 14:19:44] VERBOSE[10814][C-00000ed0] app_dial.c: Called SIP/301845
[Feb 25 14:19:45] VERBOSE[10814][C-00000ed0] app_dial.c: SIP/301845-00001de1 is ringing
[Feb 25 14:19:54] VERBOSE[10814][C-00000ed0] app_dial.c: SIP/301845-00001de1 answered SIP/301700-00001de0
[Feb 25 14:19:54] VERBOSE[10817][C-00000ed0] bridge_channel.c: Channel SIP/301845-00001de1 joined 'simple_bridge' basic-bridge <87cad27f-8b6d-4b40-9d0f-053fb00c1965>
[Feb 25 14:19:54] VERBOSE[10814][C-00000ed0] bridge_channel.c: Channel SIP/301700-00001de0 joined 'simple_bridge' basic-bridge <87cad27f-8b6d-4b40-9d0f-053fb00c1965>
[Feb 25 14:20:10] VERBOSE[10814][C-00000ed0] res_musiconhold.c: Started music on hold, class 'default', on channel 'SIP/301700-00001de0'
[Feb 25 14:20:44] VERBOSE[10817][C-00000ed0] bridge_channel.c: Channel SIP/301845-00001de1 left 'simple_bridge' basic-bridge <87cad27f-8b6d-4b40-9d0f-053fb00c1965>
[Feb 25 14:20:44] VERBOSE[10814][C-00000ed0] bridge_channel.c: Channel SIP/301700-00001de0 left 'simple_bridge' basic-bridge <87cad27f-8b6d-4b40-9d0f-053fb00c1965>
[Feb 25 14:20:44] VERBOSE[10814][C-00000ed0] res_musiconhold.c: Stopped music on hold on SIP/301700-00001de0
[Feb 25 14:20:44] VERBOSE[10814][C-00000ed0] pbx.c: Spawn extension (from-operador, 1845, 4) exited non-zero on 'SIP/301700-00001de0'

Dialplan:

exten => _18XX,1,SET(ESTADO=${DEVICE_STATE(SIP/30${EXTEN})})
same => n,GotoIf($["${ESTADO}"="NOT_INUSE"]?disponible)
same => n,Busy()
same => n(disponible),Dial(SIP/30${EXTEN},300,tT)

One thing:
Extension 1845 is an extension from a queue. In this case I’m calling directly to the extension. I mean, I’m using the diaplan showed above.

I’d turn on SIP debugging and determine which side is clearing the call.

1845 is who put on hold the call.
Is it possible that I cut the call when I do not receive or send RTP?
How do I modify that?


The call wasn’t cleared by Asterisk, but by the device that initially requested the hold.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.