[asterisk-dev] 'IAX2 call variable passing between servers '

Andrew Kohlsmith akohlsmith-asterisk at benshaw.com
Fri Aug 11 11:38:42 MST 2006


On Friday 11 August 2006 13:55, Douglas Garstang wrote:
> Aren't dnid and rdnis set by/when phone-B sends 'Moved Temporarily' back to
> Asterisk? If so, I don't understand how setting those variables on
> Asterisk-A is going to help. I thought rdnis was plucked out of the
> 'Diverted' header by Asterisk.

Depends on what you were looking at; On my PRI I get RDNIS from the switch, 
and IIRC I am not able to send RDNIS to redirect.  I have never tried, 
though.

In that case, are you using 'g' in your Box-B dialplan and moving on from 
there?

i.e.

exten => foo,n,Dial(SIP/500,,g)
exten => foo,n,GotoIf("${DIALSTATUS}" = "ANSWERED"?done)
exten => foo,n,NoOp(Call did not complete, RDNIS is ${RDNIS})
exten => foo,n,Goto(incoming,${EXTEN},1)
exten => foo,n(done),Macro(handle-hangup)

It's a little convoluted there, you could just check for a failure instead and 
goto the appropriate place instead of a double-goto there, but the concept 
should be clear...

Does RDNIS not get set correctly there?  What's a SIP DEBUG look like of a 
redirected call?  Is "Redirected" seen?

-A.



More information about the asterisk-dev mailing list