Hello,
We are using FreePBX 2.11.0.0beta2.2 with Asterisk 11.1.2
We encountered a weird error with the outbound CID when we wanted to perform an outgoing call whose target is another asterisk PBX, it actually showed the first allowed outgoing DID specified in our SIP provider trunk specifications.
Please note that when we call an external number (like a gsm or analog line) it shows the outbound CID set in our sip trunk (set to “Allow any CID”), not the extension outbound CID.
We found that even if we set the outbound CID we want on the extension, FreePBX just set the outbound CID by using the extension instead of the outbound CID that was specified.
Please find below the corresponding logs that will (I hope) enlighten you about our current problematic :
-- Executing [[email protected]:3] ExecIf("SIP/10001-00000169", "1?Set(REALCALLERIDNUM=10001)") in new stack -- Executing [[email protected]:8] Set("SIP/10001-00000169", "__DIAL_OPTIONS=Ttr") in new stack -- Executing [[email protected]:9] Set("SIP/10001-00000169", "CALLERID(all)="iPFix Gilles" <123>") in new stack -- Executing [[email protected]:27] Set("SIP/10001-00000169", "CALLERID(number)=123") in new stack
And here are the extention config:
Here is the complete log file:
Connected to Asterisk 11.1.2 currently running on ip-188-118-19-51 (pid = 7545)
== Using SIP RTP TOS bits 184
== Using SIP RTP CoS mark 5
– Executing [[email protected]:1] Macro(“SIP/10001-00000169”, “user-callerid,LIMIT,”) in new stack
– Executing [[email protected]:1] Set(“SIP/10001-00000169”, “AMPUSER=10001”) in new stack
– Executing [[email protected]:2] GotoIf(“SIP/10001-00000169”, “0?report”) in new stack
– Executing [[email protected]:3] ExecIf(“SIP/10001-00000169”, “1?Set(REALCALLERIDNUM=10001)”) in new stack
– Executing [[email protected]:4] Set(“SIP/10001-00000169”, “AMPUSER=123”) in new stack
– Executing [[email protected]:5] Set(“SIP/10001-00000169”, “AMPUSERCIDNAME=iPFix Gilles”) in new stack
– Executing [[email protected]:6] GotoIf(“SIP/10001-00000169”, “0?report”) in new stack
– Executing [[email protected]:7] Set(“SIP/10001-00000169”, “AMPUSERCID=123”) in new stack
– Executing [[email protected]:8] Set(“SIP/10001-00000169”, “__DIAL_OPTIONS=Ttr”) in new stack
– Executing [[email protected]:9] Set(“SIP/10001-00000169”, “CALLERID(all)=“iPFix Gilles” <123>”) in new stack
– Executing [[email protected]:10] GotoIf(“SIP/10001-00000169”, “0?limit”) in new stack
– Executing [[email protected]:11] ExecIf(“SIP/10001-00000169”, “1?Set(GROUP(concurrency_limit)=123)”) in new stack
– Executing [[email protected]:12] GosubIf(“SIP/10001-00000169”, “7?sub-ccss,s,1(ipfixCtx,0476476513)”) in new stack
– Executing [[email protected]:1] ExecIf(“SIP/10001-00000169”, “0?Return()”) in new stack
– Executing [[email protected]:2] Set(“SIP/10001-00000169”, “CCSS_SETUP=TRUE”) in new stack
– Executing [[email protected]:3] GosubIf(“SIP/10001-00000169”, “0?monitor_config,1(ipfixCtx,0476476513):monitor_default,1(ipfixCtx,0476476513)”) in new stack
– Executing [[email protected]:1] GotoIf(“SIP/10001-00000169”, “0?is_exten”) in new stack
– Executing [[email protected]:2] StackPop(“SIP/10001-00000169”, “”) in new stack
– Executing [[email protected]:3] Return(“SIP/10001-00000169”, “FALSE”) in new stack
– Executing [[email protected]:13] ExecIf(“SIP/10001-00000169”, “1?Set(CHANNEL(language)=fr)”) in new stack
– Executing [[email protected]:14] GotoIf(“SIP/10001-00000169”, “1?continue”) in new stack
– Goto (macro-user-callerid,s,27)
– Executing [[email protected]:27] Set(“SIP/10001-00000169”, “CALLERID(number)=123”) in new stack
– Executing [[email protected]:28] Set(“SIP/10001-00000169”, “CALLERID(name)=iPFix Gilles”) in new stack
– Executing [[email protected]:29] Set(“SIP/10001-00000169”, “CDR(cnum)=123”) in new stack
– Executing [[email protected]:30] Set(“SIP/10001-00000169”, “CDR(cnam)=iPFix Gilles”) in new stack
– Executing [[email protected]:31] Set(“SIP/10001-00000169”, “CHANNEL(language)=fr”) in new stack
– Executing [[email protected]:2] Set(“SIP/10001-00000169”, “INTRACOMPANYROUTE=YES”) in new stack
– Executing [[email protected]:3] Set(“SIP/10001-00000169”, “MOHCLASS=default”) in new stack
– Executing [[email protected]:4] ExecIf(“SIP/10001-00000169”, “0?Set(TRUNKCIDOVERRIDE=3228882448)”) in new stack
– Executing [[email protected]:5] Set(“SIP/10001-00000169”, “_NODEST=”) in new stack
– Executing [[email protected]:6] Gosub(“SIP/10001-00000169”, “sub-record-check,s,1(out,0476476513,)”) in new stack
– Executing [[email protected]:1] GotoIf(“SIP/10001-00000169”, “1?check”) in new stack
– Goto (sub-record-check,s,6)
– Executing [[email protected]:6] Set(“SIP/10001-00000169”, “__MON_FMT=wav”) in new stack
– Executing [[email protected]:7] GotoIf(“SIP/10001-00000169”, “1?next”) in new stack
– Goto (sub-record-check,s,10)
– Executing [[email protected]:10] ExecIf(“SIP/10001-00000169”, “0?Return()”) in new stack
– Executing [[email protected]:11] GotoIf(“SIP/10001-00000169”, “0?out,1”) in new stack
– Executing [[email protected]:12] Set(“SIP/10001-00000169”, “__REC_STATUS=INITIALIZED”) in new stack
– Executing [[email protected]:13] ExecIf(“SIP/10001-00000169”, “0?Set(__REC_POLICY_MODE=)”) in new stack
– Executing [[email protected]:14] Set(“SIP/10001-00000169”, “NOW=1358854048”) in new stack
– Executing [[email protected]:15] Set(“SIP/10001-00000169”, “__DAY=22”) in new stack
– Executing [[email protected]:16] Set(“SIP/10001-00000169”, “__MONTH=01”) in new stack
– Executing [[email protected]:17] Set(“SIP/10001-00000169”, “__YEAR=2013”) in new stack
– Executing [[email protected]:18] Set(“SIP/10001-00000169”, “__TIMESTR=20130122-122728”) in new stack
– Executing [[email protected]:19] Set(“SIP/10001-00000169”, “__FROMEXTEN=123”) in new stack
– Executing [[email protected]:20] Set(“SIP/10001-00000169”, “__CALLFILENAME=out-0476476513-123-20130122-122728-1358854048.1193”) in new stack
– Executing [[email protected]:21] Goto(“SIP/10001-00000169”, “out,1”) in new stack
– Goto (sub-record-check,out,1)
– Executing [[email protected]:1] ExecIf(“SIP/10001-00000169”, “1?Set(__REC_POLICY_MODE=dontcare)”) in new stack
– Executing [[email protected]:2] GosubIf(“SIP/10001-00000169”, “0?record,1(exten,0476476513,123)”) in new stack
– Executing [[email protected]:3] Return(“SIP/10001-00000169”, “”) in new stack
– Executing [[email protected]:7] Macro(“SIP/10001-00000169”, “dialout-trunk,2,0476476513,off”) in new stack
– Executing [[email protected]:1] Set(“SIP/10001-00000169”, “DIAL_TRUNK=2”) in new stack
– Executing [[email protected]:2] GosubIf(“SIP/10001-00000169”, “0?sub-pincheck,s,1()”) in new stack
– Executing [[email protected]:3] GotoIf(“SIP/10001-00000169”, “0?disabletrunk,1”) in new stack
– Executing [[email protected]:4] Set(“SIP/10001-00000169”, “DIAL_NUMBER=0476476513”) in new stack
– Executing [[email protected]:5] Set(“SIP/10001-00000169”, “DIAL_TRUNK_OPTIONS=Ttr”) in new stack
– Executing [[email protected]:6] Set(“SIP/10001-00000169”, “OUTBOUND_GROUP=OUT_2”) in new stack
– Executing [[email protected]:7] GotoIf(“SIP/10001-00000169”, “1?nomax”) in new stack
– Goto (macro-dialout-trunk,s,9)
– Executing [[email protected]:9] GotoIf(“SIP/10001-00000169”, “1?skipoutcid”) in new stack
– Goto (macro-dialout-trunk,s,12)
– Executing [[email protected]:12] GosubIf(“SIP/10001-00000169”, “0?sub-flp-2,s,1()”) in new stack
– Executing [[email protected]:13] Set(“SIP/10001-00000169”, “OUTNUM=0476476513”) in new stack
– Executing [[email protected]:14] Set(“SIP/10001-00000169”, “custom=SIP/ipfixTrunk”) in new stack
– Executing [[email protected]:15] ExecIf(“SIP/10001-00000169”, “0?Set(DIAL_TRUNK_OPTIONS=M(setmusic^default)Ttr)”) in new stack
– Executing [[email protected]:16] ExecIf(“SIP/10001-00000169”, “0?Set(DIAL_TRUNK_OPTIONS=TtrM(confirm))”) in new stack
– Executing [[email protected]:17] Macro(“SIP/10001-00000169”, “dialout-trunk-predial-hook,”) in new stack
– Executing [[email protected]:1] MacroExit(“SIP/10001-00000169”, “”) in new stack
– Executing [[email protected]:18] GotoIf(“SIP/10001-00000169”, “0?bypass,1”) in new stack
– Executing [[email protected]:19] ExecIf(“SIP/10001-00000169”, “1?Set(CONNECTEDLINE(num,i)=0476476513)”) in new stack
– Executing [[email protected]:20] ExecIf(“SIP/10001-00000169”, “1?Set(CONNECTEDLINE(name,i)=CID:123)”) in new stack
– Executing [[email protected]:21] GotoIf(“SIP/10001-00000169”, “0?customtrunk”) in new stack
– Executing [[email protected]:22] Dial(“SIP/10001-00000169”, “SIP/ipfixTrunk/0476476513,300,Ttr”) in new stack
== Using SIP RTP TOS bits 184
== Using SIP RTP CoS mark 5
– Called SIP/ipfixTrunk/0476476513
– SIP/ipfixTrunk-0000016a is making progress passing it to SIP/10001-00000169
== Spawn extension (macro-dialout-trunk, s, 22) exited non-zero on ‘SIP/10001-00000169’ in macro ‘dialout-trunk’
== Spawn extension (ipfixCtx, 0476476513, 7) exited non-zero on ‘SIP/10001-00000169’
– Executing [[email protected]:1] Macro(“SIP/10001-00000169”, “hangupcall,”) in new stack
– Executing [[email protected]:1] GotoIf(“SIP/10001-00000169”, “1?theend”) in new stack
– Goto (macro-hangupcall,s,3)
– Executing [[email protected]:3] ExecIf(“SIP/10001-00000169”, “0?Set(CDR(recordingfile)=)”) in new stack
– Executing [[email protected]:4] Hangup(“SIP/10001-00000169”, “”) in new stack
== Spawn extension (macro-hangupcall, s, 4) exited non-zero on ‘SIP/10001-00000169’ in macro ‘hangupcall’
== Spawn extension (ipfixCtx, h, 1) exited non-zero on ‘SIP/10001-00000169’
Thanks in advance for your help.