Dear List
I have run into an issue which i have tried to resolve for over 2 weeks now. I am running Elastix 2.4.0 with a2billing 1.9.4 i am trying to create wholesale voip through a2billing. I have created the following under /etc/asterisk/extensions_custom.conf
[custom-a2billing] exten => _X.,1,deadAGI(a2billing.php,1) exten => _X.,n,Hangup
and under elastix pbx i have created a custom trunk and set a dial custom string to be handed over to a2billing:
Local/$OUTNUM$@custom-a2billing/n
i also created an inbound route to use this custom trunk.
However, when an inbound call comes in i get the following output on my debug and call is dropped.
elastix*CLI> == Using SIP RTP TOS bits 184 == Using SIP RTP CoS mark 5 -- Executing [24000010@from-trunk:1] Set("SIP/SIP-out-00000b64", "__FROM_DID=24000010") in new stack -- Executing [24000010@from-trunk:2] Gosub("SIP/SIP-out-00000b64", "app-blacklist-check,s,1") in new stack -- Executing [s@app-blacklist-check:1] GotoIf("SIP/SIP-out-00000b64", "0?blacklisted") in new stack -- Executing [s@app-blacklist-check:2] Set("SIP/SIP-out-00000b64", "CALLED_BLACKLIST=1") in new stack -- Executing [s@app-blacklist-check:3] Return("SIP/SIP-out-00000b64", "") in new stack -- Executing [24000010@from-trunk:3] ExecIf("SIP/SIP-out-00000b64", "0 ?Set(CALLERID(name)=22421082)") in new stack -- Executing [24000010@from-trunk:4] Set("SIP/SIP-out-00000b64", "__CALLINGPRES_SV=allowed_not_screened") in new stack -- Executing [24000010@from-trunk:5] Set("SIP/SIP-out-00000b64", "CALLERPRES()=allowed_not_screened") in new stack -- Executing [24000010@from-trunk:6] Goto("SIP/SIP-out-00000b64", "ext-trunk,2,1") in new stack -- Goto (ext-trunk,2,1) -- Executing [2@ext-trunk:1] Set("SIP/SIP-out-00000b64", "TDIAL_STRING=Local/\\$\\{OUTNUM\\}@custom-a2billing/n") in new stack -- Executing [2@ext-trunk:2] Set("SIP/SIP-out-00000b64", "DIAL_TRUNK=2") in new stack -- Executing [2@ext-trunk:3] Goto("SIP/SIP-out-00000b64", "ext-trunk,tcustom,1") in new stack -- Goto (ext-trunk,tcustom,1) -- Executing [tcustom@ext-trunk:1] Set("SIP/SIP-out-00000b64", "OUTBOUND_GROUP=OUT_2") in new stack -- Executing [tcustom@ext-trunk:2] GotoIf("SIP/SIP-out-00000b64", "1?nomax") in new stack -- Goto (ext-trunk,tcustom,4) -- Executing [tcustom@ext-trunk:4] ExecIf("SIP/SIP-out-00000b64", "1?Set(CALLERPRES()=allowed_not_screened)") in new stack -- Executing [tcustom@ext-trunk:5] Set("SIP/SIP-out-00000b64", "DIAL_NUMBER=24000010") in new stack -- Executing [tcustom@ext-trunk:6] GosubIf("SIP/SIP-out-00000b64", "0?sub-flp-2,s,1") in new stack -- Executing [tcustom@ext-trunk:7] Set("SIP/SIP-out-00000b64", "OUTNUM=24000010") in new stack -- Executing [tcustom@ext-trunk:8] Set("SIP/SIP-out-00000b64", "CALLERID(number)=22421082") in new stack -- Executing [tcustom@ext-trunk:9] Set("SIP/SIP-out-00000b64", "CALLERID(name)=22421082") in new stack -- Executing [tcustom@ext-trunk:10] Dial("SIP/SIP-out-00000b64", "Local/\\$\\{OUTNUM\\}@custom-a2billing/n,300,") in new stack -- Couldn't call Local/\$\{OUTNUM\}@custom-a2billing/n == Everyone is busy/congested at this time (0:0/0/0) -- Executing [tcustom@ext-trunk:11] Hangup("SIP/SIP-out-00000b64", "") in new stack == Spawn extension (ext-trunk, tcustom, 11) exited non-zero on 'SIP/SIP-out-00000b64'
You can see above that the OUTNUM variable is not showing the number 24000010 as it should but instead coming up as "Local/\\$\\{OUTNUM\\}@custom-a2billing/n,300,")
When i set the custom dial string as Local/24000010@custom-a2billing/n the call works perfectly as shown below:
elastix*CLI> == Using SIP RTP TOS bits 184 == Using SIP RTP CoS mark 5 -- Executing [24000010@from-trunk:1] Set("SIP/SIP-out-00000b65", "__FROM_DID=24000010") in new stack -- Executing [24000010@from-trunk:2] Gosub("SIP/SIP-out-00000b65", "app-blacklist-check,s,1") in new stack -- Executing [s@app-blacklist-check:1] GotoIf("SIP/SIP-out-00000b65", "0?blacklisted") in new stack -- Executing [s@app-blacklist-check:2] Set("SIP/SIP-out-00000b65", "CALLED_BLACKLIST=1") in new stack -- Executing [s@app-blacklist-check:3] Return("SIP/SIP-out-00000b65", "") in new stack -- Executing [24000010@from-trunk:3] ExecIf("SIP/SIP-out-00000b65", "0 ?Set(CALLERID(name)=22421082)") in new stack -- Executing [24000010@from-trunk:4] Set("SIP/SIP-out-00000b65", "__CALLINGPRES_SV=allowed_not_screened") in new stack -- Executing [24000010@from-trunk:5] Set("SIP/SIP-out-00000b65", "CALLERPRES()=allowed_not_screened") in new stack -- Executing [24000010@from-trunk:6] Goto("SIP/SIP-out-00000b65", "ext-trunk,2,1") in new stack -- Goto (ext-trunk,2,1) -- Executing [2@ext-trunk:1] Set("SIP/SIP-out-00000b65", "TDIAL_STRING=Local/24000010@custom-a2billing/n") in new stack -- Executing [2@ext-trunk:2] Set("SIP/SIP-out-00000b65", "DIAL_TRUNK=2") in new stack -- Executing [2@ext-trunk:3] Goto("SIP/SIP-out-00000b65", "ext-trunk,tcustom,1") in new stack -- Goto (ext-trunk,tcustom,1) -- Executing [tcustom@ext-trunk:1] Set("SIP/SIP-out-00000b65", "OUTBOUND_GROUP=OUT_2") in new stack -- Executing [tcustom@ext-trunk:2] GotoIf("SIP/SIP-out-00000b65", "1?nomax") in new stack -- Goto (ext-trunk,tcustom,4) -- Executing [tcustom@ext-trunk:4] ExecIf("SIP/SIP-out-00000b65", "1?Set(CALLERPRES()=allowed_not_screened)") in new stack -- Executing [tcustom@ext-trunk:5] Set("SIP/SIP-out-00000b65", "DIAL_NUMBER=24000010") in new stack -- Executing [tcustom@ext-trunk:6] GosubIf("SIP/SIP-out-00000b65", "0?sub-flp-2,s,1") in new stack -- Executing [tcustom@ext-trunk:7] Set("SIP/SIP-out-00000b65", "OUTNUM=24000010") in new stack -- Executing [tcustom@ext-trunk:8] Set("SIP/SIP-out-00000b65", "CALLERID(number)=22421082") in new stack -- Executing [tcustom@ext-trunk:9] Set("SIP/SIP-out-00000b65", "CALLERID(name)=22421082") in new stack -- Executing [tcustom@ext-trunk:10] Dial("SIP/SIP-out-00000b65", "Local/24000010@custom-a2billing/n,300,") in new stack -- Called Local/24000010@custom-a2billing/n -- Executing [24000010@custom-a2billing:1] DeadAGI("Local/24000010@custom-a2billing-000005bd;2", "a2billing.php,1") in new stack -- Launched AGI Script /var/lib/asterisk/agi-bin/a2billing.php
Could someone please point me in the right direction if im doing something wrong??
Your help is much appreciated!
Regards
|