Page 1 of 1

whats the reason for looping a inbound call to a local trunk

PostPosted: Wed Oct 01, 2014 9:59 pm
by bobbymc
i use the latest svn trunk of vicidial, with asterisk 1.8

i was wondering what the reason is for this specific dial plan?

exten => _90009.,1,Answer() ; Answer() the li$
exten => _90009.,2,Dial(${TRUNKloop}/9${EXTEN},,to)
exten => _90009.,3,Hangup()

i dont see a reason why to waste another channel to send the call back to ourselves?

Re: whats the reason for looping a inbound call to a local t

PostPosted: Thu Oct 02, 2014 3:10 am
by geoff3dmg
Sending a call via the Trunkloop causes the NVA-recording.agi script to be called.

Re: whats the reason for looping a inbound call to a local t

PostPosted: Thu Oct 02, 2014 10:06 am
by bobbymc
I don't see that agi script called anywhere in that dialplan ?

Re: whats the reason for looping a inbound call to a local t

PostPosted: Thu Oct 02, 2014 10:12 am
by bobbymc
matt can you possibly comment on this post?

Re: whats the reason for looping a inbound call to a local t

PostPosted: Thu Oct 02, 2014 11:13 am
by geoff3dmg
You are sort of right. The TRUNKloop global points to IAX2/ASTloop (check /etc/asterisk/iax2-vicidial.conf). This goes out to the ip_relay (see /usr/share/astguiclient/ip_relay/relay_control) and comes straight back into the system again on the default context. There's quite a few reasons you'd want to have a server be able to send a call back to itself. One, as I've touched on is to record 3-way transfers after the agent has hungup. Another reason is to generate a ringing tone when dialling. Thirdly you can use the TRUNKloop for load testing.

Edit: Also might be used for blind monitoring. Not sure though.

Re: whats the reason for looping a inbound call to a local t

PostPosted: Thu Oct 02, 2014 1:20 pm
by bobbymc
Those all make sense but it would be a waste to send inbound calls from agents to ingroups via the loop correct ?

Re: whats the reason for looping a inbound call to a local t

PostPosted: Fri Oct 03, 2014 2:53 am
by geoff3dmg
There's no need to do that afaik. The agents can just transfer to a local closer which ends up in an ingroup? At least that is what I have setup here.

Re: whats the reason for looping a inbound call to a local t

PostPosted: Fri Oct 03, 2014 5:01 am
by mflorell
The problem that this solves is related to Local/ channels and their inconsistent behavior in different versions of Asterisk. Sending the call through the IAX2 loop gives a proper resolved channel pointer that doesn't change or go away after it's answered, which is why it is set up to work the way it does.

Re: whats the reason for looping a inbound call to a local t

PostPosted: Wed Oct 08, 2014 7:47 pm
by bobbymc
yea i know exacly what you mean, sometimes the channel is kept as local when it should be sip/...

Re: whats the reason for looping a inbound call to a local t

PostPosted: Wed Oct 14, 2020 8:00 am
by Kabis
Without Trunkloop(ASTloop) can we generate Ring back tone on 3 way call?

Else without IAX trunk can we do?