[Dundi] dundi lookup in a other tree

DUNDi Peering dundi at swissirc.net
Sun Apr 4 16:43:14 CDT 2010


Hello Jonathan,

okay i have updatet my Asterisk to

asterisk*CLI> core show version
Asterisk SVN-branch-1.6.2-r256020 built by root @  
asterisk.swissirc.net on a x86_64 running Linux on 2010-04-04  
21:20:22 UTC
asterisk*CLI>

But still the same Problem with both version see output

     -- Executing [00041xxxxxxxxx at sip-41yyyyyyyyy:3] Gosub("SIP/ 
+41yyyyyyyyy-00000001", "sNE-PSTN,00041xxxxxxxxx,1") in new stack
     -- Executing [00041xxxxxxxxx at sNE-PSTN:1] NoOp("SIP/ 
+41yyyyyyyyy-00000001", "DOING DUNDi sNE-PSTN LOOKUP") in new stack
     -- Executing [00041xxxxxxxxx at sNE-PSTN:2] Set("SIP/ 
+41yyyyyyyyy-00000001", "sNE-dundiresult=") in new stack
     -- Executing [00041xxxxxxxxx at sNE-PSTN:3] GotoIf("SIP/ 
+41yyyyyyyyy-00000001", "1?no-dundi") in new stack
     -- Goto (sNE-PSTN,00041xxxxxxxxx,8)
     -- Executing [00041xxxxxxxxx at sNE-PSTN:8] NoOp("SIP/ 
+41yyyyyyyyy-00000001", "DUNDi sNE-PSTN Failed") in new stack
     -- Executing [00041xxxxxxxxx at sNE-PSTN:9] Return("SIP/ 
+41yyyyyyyyy-00000001", "") in new stack
     -- Executing [00041xxxxxxxxx at sip-41yyyyyyyyy:4] Hangup("SIP/ 
+41yyyyyyyyy-00000001", "") in new stack
   == Spawn extension (sip-41yyyyyyyyy, 00041xxxxxxxxx, 4) exited non- 
zero on 'SIP/+41yyyyyyyyy-00000001'

     -- Executing [00041xxxxxxxxx at sNE-PSTN:1] NoOp("SIP/ 
+41yyyyyyyyy-00000002", "DOING DUNDi sNE-PSTN LOOKUP") in new stack
     -- Executing [00041xxxxxxxxx at sNE-PSTN:2] Set("SIP/ 
+41yyyyyyyyy-00000002", "sNE-dundiresult=") in new stack
     -- Executing [00041xxxxxxxxx at sNE-PSTN:3] NoOp("SIP/ 
+41yyyyyyyyy-00000002", "EXTEN Ausgabe 00041xxxxxxxxx") in new stack
     -- Executing [00041xxxxxxxxx at sNE-PSTN:4] NoOp("SIP/ 
+41yyyyyyyyy-00000002", "Dundi Ausgabe ") in new stack
     -- Executing [00041xxxxxxxxx at sNE-PSTN:5] GotoIf("SIP/ 
+41yyyyyyyyy-00000002", "1?:30") in new stack
     -- Executing [00041xxxxxxxxx at sNE-PSTN:6] GotoIf("SIP/ 
+41yyyyyyyyy-00000002", "1?20:30") in new stack
     -- Goto (sNE-PSTN,00041xxxxxxxxx,20)
     -- Executing [00041xxxxxxxxx at sNE-PSTN:20] NoOp("SIP/ 
+41yyyyyyyyy-00000002", "DUNDi sNE-PSTN Failed") in new stack
     -- Executing [00041xxxxxxxxx at sNE-PSTN:21] Return("SIP/ 
+41yyyyyyyyy-00000002", "") in new stack
     -- Executing [00041xxxxxxxxx at sip-41yyyyyyyyy:4] Hangup("SIP/ 
+41yyyyyyyyy-00000002", "") in new stack
   == Spawn extension (sip-41yyyyyyyyy, 00041xxxxxxxxx, 4) exited non- 
zero on 'SIP/+41yyyyyyyyy-00000002'

It's realy Strange why it not works ...

best regards

	Marcel


Am 04.04.2010 um 22:04 schrieb Jonathan Thurman:

> On Sun, Apr 4, 2010 at 11:45 AM, DUNDi Peering <dundi at swissirc.net>  
> wrote:
>
>> I'm Using Asterisk 1.6.2.0~rc2-0ubuntu1.2 built by buildd @ crested
>> on a x86_64 running Linux on 2010-01-04 02:36:22 UTC on a Ubuntu
>
> You might want to try this on a newer version.  1.6.2.6 is out now and
> might have resolved an issue (but I don't know if it did)
>
>
>> This i was also trying but it dont work,
>>
>>     -- Executing [00041xxxxxxxxx at sNE-PSTN:1] NoOp("SIP/ 
>> +41yyyyyyyyy-ebbb3038", "DOING DUNDi sNE-PSTN LOOKUP") in new stack
>>     -- Executing [00041xxxxxxxxx at sNE-PSTN:2] Set("SIP/+41yyyyyyyyy- 
>> ebbb3038", "dundiresult=") in new stack
>
> The query returned an empty string, which means it failed.
>
> Did you make sure to reload the dialplan after making your changes?
>
>>     -- Executing [00041xxxxxxxxx at sNE-PSTN:3] NoOp("SIP/ 
>> +41yyyyyyyyy-ebbb3038", "EXTEN Ausgabe 00041xxxxxxxxx") in new stack
>>     -- Executing [00041xxxxxxxxx at sNE-PSTN:4] NoOp("SIP/ 
>> +41yyyyyyyyy-ebbb3038", "Dundi Ausgabe ") in new stack
>>     -- Executing [00041xxxxxxxxx at sNE-PSTN:5] GotoIf("SIP/ 
>> +41yyyyyyyyy-ebbb3038", "1?:30") in new stack
>>     -- Executing [00041xxxxxxxxx at sNE-PSTN:6] GotoIf("SIP/ 
>> +41yyyyyyyyy-ebbb3038", "1?20:30") in new stack
>
> You probably don't need to check for an empty result twice, but this
> isn't hurting anything.
>
>>     -- Goto (sNE-PSTN,00041xxxxxxxxx,20)
>>     -- Executing [00041xxxxxxxxx at sNE-PSTN:20] NoOp("SIP/ 
>> +41yyyyyyyyy-ebbb3038", "DUNDi sNE-PSTN Failed") in new stack
>>     -- Executing [00041xxxxxxxxx at sNE-PSTN:21] Return("SIP/ 
>> +41yyyyyyyyy-ebbb3038", "") in new stack
>>     -- Executing [00041xxxxxxxxx at sip-41yyyyyyyyy:4] Hangup("SIP/ 
>> +41yyyyyyyyy-ebbb3038", "") in new stack
>>   == Spawn extension (sip-41yyyyyyyyy, 00041xxxxxxxxx, 4) exited  
>> non-zero on 'SIP/+41yyyyyyyyy-ebbb3038'
>
> ----
>
> Here is an example of what works for me on Asterisk 1.6.1, NOT  
> tested on 1.6.2:
>
> ; DUNDi Lookup
> exten => _1NXXNXXXXXX,n,Set(DUNDI_GW=${DUNDILOOKUP(${EXTEN}|not- 
> e164-context)})
> exten => _1NXXNXXXXXX,n,GotoIf($[${ISNULL(${DUNDI_GW})}]?no-dundi)
> exten => _1NXXNXXXXXX,n,Dial(${DUNDI_GW})
> exten => _1NXXNXXXXXX,n(no-dundi),Verbose(3,outbound: No DUNDi peer  
> available)
>
> ----
> Here it is adapted for you (using a label for the gotoif), again  
> NOT TESTED:
>
> exten => _000XXX.,1,NoOp(DOING DUNDi sNE-PSTN LOOKUP)
> exten => _000XXX.,n,Set(dundiresult=${DUNDILOOKUP(${EXTEN}|dundi- 
> sNE)})
> exten => _000XXX.,n,GotoIf($[${ISNULL(${dundiresult})}]?no-dundi)
>
> exten => _000XXX.,n,NoOp(DUNDi sNE-PSTN Successful)
> exten => _000XXX.,n,NoOp(Call from ${CALLERID(name)} over DUNDi out)
>
> exten => _000XXX.,n,macro(call,${dundiresult})
> exten => _000XXX.,n,Return
>
> exten => _000XXX.,n(no-dundi),NoOp(DUNDi sNE-PSTN Failed)
> exten => _000XXX.,n,Return
>
> ----
>
> The CHANGES file for 1.6.2 also mentioned:
>
>   * Added two new dialplan functions, DUNDIQUERY and DUNDIRESULT.   
> These
>      functions will allow you to initiate a DUNDi query from the  
> dialplan,
>      find out how many results there are, and access each one.
>
> So you might want to take a look at those to see if they work.  You
> might also get more responses from the Asterisk Users mailing list.
>
> -Jonathan
>
> -- 
> _____________________________________________________________________
> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
>
> Dundi mailing list
> To UNSUBSCRIBE or update options visit:
>    http://lists.digium.com/mailman/listinfo/dundi
>




More information about the Dundi mailing list