CID Num Alias ignored with calling over Outbound route with Intra-Company enabled

Hello,

Since the upgrade to FreePBX 13, I have noticed that the CID Number alias is ignored for when calling out an outbound route with Intra-Company enabled.

Extension Settings:

Outbound route:

Is there something else I must do or enable to get this working? Internal calls within the same system show the CID Alias number.

I am experencing this on 3 different FreePBX 13 installs and its causing some confusion with our users.

Many thanks,
Fraser

have you checked if a CID is set on your trunk? this may override the alias.

Yes, The IAX2 trunk is set to “Allow Any CID” and Hide CallerID is set to “No”

When a call is placed over an IAX2 trunk, the receiving end see the actual extension number of caller and not the CID alias as expected.

if you Outbound CallerID is left empty in your IAX trunk (which should be if the caller id is that of the extension rather than always the same) you should be fine! did you look at the verbose output of asterisk during a call? asterisk -r -vvvv

Hi,

Sorry for the late reply.

I have made a test call from Exten 2199 from SERVER_A (which has the CID Num Alias set to 1200) to 1300 on SERVER_B however the true extension number of 2199 was passed over the IAX2 trunk and not the desired 1200 number.

The IAX2 trunk has no outbound CallerID and CID Options is set to Allow Any CID. The outbound route has Intra-Company Enabled.

Internal calls to other extensions on SERVER_A display the CID Num Alais of 1200.

This worked as expected before I upgraded to FreePBX 13.

Any ideas?

thanks,
Fraser.

Originating Server:

[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [1300@from-internal:1] Macro("SIP/2199-00001733", "user-callerid,LIMIT,EXTERNAL,") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-user-callerid:1] Set("SIP/2199-00001733", "TOUCH_MONITOR=SERVER_A-1484834427.7228") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-user-callerid:2] Set("SIP/2199-00001733", "AMPUSER=2199") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-user-callerid:3] GotoIf("SIP/2199-00001733", "0?report") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-user-callerid:4] ExecIf("SIP/2199-00001733", "1?Set(REALCALLERIDNUM=2199)") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-user-callerid:5] Set("SIP/2199-00001733", "AMPUSER=2199") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-user-callerid:6] GotoIf("SIP/2199-00001733", "0?limit") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-user-callerid:7] Set("SIP/2199-00001733", "AMPUSERCIDNAME=Fraser Allan") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-user-callerid:8] GotoIf("SIP/2199-00001733", "0?report") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-user-callerid:9] Set("SIP/2199-00001733", "AMPUSERCID=2199") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-user-callerid:10] Set("SIP/2199-00001733", "__DIAL_OPTIONS=Ttr") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-user-callerid:11] Set("SIP/2199-00001733", "CALLERID(all)="Fraser Allan" <2199>") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-user-callerid:12] GotoIf("SIP/2199-00001733", "0?limit") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-user-callerid:13] ExecIf("SIP/2199-00001733", "1?Set(GROUP(concurrency_limit)=2199)") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-user-callerid:14] ExecIf("SIP/2199-00001733", "0?Set(CHANNEL(language)=)") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-user-callerid:15] GotoIf("SIP/2199-00001733", "1?continue") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Goto (macro-user-callerid,s,29)
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-user-callerid:29] Set("SIP/2199-00001733", "CALLERID(number)=2199") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-user-callerid:30] Set("SIP/2199-00001733", "CALLERID(name)=Fraser Allan") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-user-callerid:31] GotoIf("SIP/2199-00001733", "0?cnum") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-user-callerid:32] Set("SIP/2199-00001733", "CDR(cnam)=Fraser Allan") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-user-callerid:33] Set("SIP/2199-00001733", "CDR(cnum)=2199") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-user-callerid:34] Set("SIP/2199-00001733", "CHANNEL(language)=en") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [1300@from-internal:2] Gosub("SIP/2199-00001733", "sub-record-check,s,1(out,1300,dontcare)") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@sub-record-check:1] GotoIf("SIP/2199-00001733", "0?initialized") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@sub-record-check:2] Set("SIP/2199-00001733", "__REC_STATUS=INITIALIZED") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@sub-record-check:3] Set("SIP/2199-00001733", "NOW=1484834427") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@sub-record-check:4] Set("SIP/2199-00001733", "__DAY=19") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@sub-record-check:5] Set("SIP/2199-00001733", "__MONTH=01") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@sub-record-check:6] Set("SIP/2199-00001733", "__YEAR=2017") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@sub-record-check:7] Set("SIP/2199-00001733", "__TIMESTR=20170119-140027") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@sub-record-check:8] Set("SIP/2199-00001733", "__FROMEXTEN=2199") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@sub-record-check:9] Set("SIP/2199-00001733", "__MON_FMT=wav") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@sub-record-check:10] NoOp("SIP/2199-00001733", "Recordings initialized") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@sub-record-check:11] ExecIf("SIP/2199-00001733", "0?Set(ARG3=dontcare)") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@sub-record-check:12] Set("SIP/2199-00001733", "REC_POLICY_MODE_SAVE=") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@sub-record-check:13] ExecIf("SIP/2199-00001733", "0?Set(REC_STATUS=NO)") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@sub-record-check:14] GotoIf("SIP/2199-00001733", "3?checkaction") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Goto (sub-record-check,s,17)
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@sub-record-check:17] GotoIf("SIP/2199-00001733", "1?sub-record-check,out,1") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Goto (sub-record-check,out,1)
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [out@sub-record-check:1] NoOp("SIP/2199-00001733", "Outbound Recording Check from 2199 to 1300") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [out@sub-record-check:2] Set("SIP/2199-00001733", "RECMODE=yes") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [out@sub-record-check:3] ExecIf("SIP/2199-00001733", "0?Goto(routewins)") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [out@sub-record-check:4] ExecIf("SIP/2199-00001733", "0?Goto(routewins)") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [out@sub-record-check:5] Gosub("SIP/2199-00001733", "recordcheck,1(yes,out,1300)") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [recordcheck@sub-record-check:1] NoOp("SIP/2199-00001733", "Starting recording check against yes") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [recordcheck@sub-record-check:2] Goto("SIP/2199-00001733", "yes") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Goto (sub-record-check,recordcheck,9)
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [recordcheck@sub-record-check:9] ExecIf("SIP/2199-00001733", "0?Return()") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [recordcheck@sub-record-check:10] Set("SIP/2199-00001733", "__REC_POLICY_MODE=YES") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [recordcheck@sub-record-check:11] Goto("SIP/2199-00001733", "startrec") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Goto (sub-record-check,recordcheck,16)
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [recordcheck@sub-record-check:16] NoOp("SIP/2199-00001733", "Starting recording: out, 1300") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [recordcheck@sub-record-check:17] Set("SIP/2199-00001733", "AUDIOHOOK_INHERIT(MixMonitor)=yes") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [recordcheck@sub-record-check:18] Set("SIP/2199-00001733", "__CALLFILENAME=out-1300-2199-20170119-140027-SERVER_A-1484834427.7228") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [recordcheck@sub-record-check:19] MixMonitor("SIP/2199-00001733", "2017/01/19/out-1300-2199-20170119-140027-SERVER_A-1484834427.7228.wav,ai(LOCAL_MIXMON_ID),") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [recordcheck@sub-record-check:20] Set("SIP/2199-00001733", "__MIXMON_ID=0x7f1a345fc4c0") in new stack
[2017-01-19 14:00:27] VERBOSE[138457][C-00000c51] app_mixmonitor.c: Begin MixMonitor Recording SIP/2199-00001733
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [recordcheck@sub-record-check:21] Set("SIP/2199-00001733", "__RECORD_ID=SIP/2199-00001733") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [recordcheck@sub-record-check:22] Set("SIP/2199-00001733", "__REC_STATUS=RECORDING") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [recordcheck@sub-record-check:23] Set("SIP/2199-00001733", "CDR(recordingfile)=out-1300-2199-20170119-140027-SERVER_A-1484834427.7228.wav") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [recordcheck@sub-record-check:24] Return("SIP/2199-00001733", "") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [out@sub-record-check:6] Return("SIP/2199-00001733", "") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [1300@from-internal:3] ExecIf("SIP/2199-00001733", "0 ?Set(CDR(accountcode)=)") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [1300@from-internal:4] Set("SIP/2199-00001733", "INTRACOMPANYROUTE=YES") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [1300@from-internal:5] Set("SIP/2199-00001733", "MOHCLASS=default") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [1300@from-internal:6] Set("SIP/2199-00001733", "_NODEST=") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [1300@from-internal:7] Macro("SIP/2199-00001733", "dialout-trunk,12,1300,,off") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-dialout-trunk:1] Set("SIP/2199-00001733", "DIAL_TRUNK=12") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-dialout-trunk:2] GosubIf("SIP/2199-00001733", "0?sub-pincheck,s,1()") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-dialout-trunk:3] GotoIf("SIP/2199-00001733", "0?disabletrunk,1") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-dialout-trunk:4] Set("SIP/2199-00001733", "DIAL_NUMBER=1300") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-dialout-trunk:5] Set("SIP/2199-00001733", "DIAL_TRUNK_OPTIONS=Ttr") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-dialout-trunk:6] Set("SIP/2199-00001733", "OUTBOUND_GROUP=OUT_12") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-dialout-trunk:7] GotoIf("SIP/2199-00001733", "1?nomax") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Goto (macro-dialout-trunk,s,9)
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-dialout-trunk:9] GotoIf("SIP/2199-00001733", "1?skipoutcid") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Goto (macro-dialout-trunk,s,12)
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-dialout-trunk:12] GosubIf("SIP/2199-00001733", "0?sub-flp-12,s,1()") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-dialout-trunk:13] Set("SIP/2199-00001733", "OUTNUM=1300") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-dialout-trunk:14] Set("SIP/2199-00001733", "custom=IAX2/IAX_SERVER_B") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-dialout-trunk:15] ExecIf("SIP/2199-00001733", "0?Set(DIAL_TRUNK_OPTIONS=M(setmusic^default)Ttr)") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-dialout-trunk:16] ExecIf("SIP/2199-00001733", "0?Set(DIAL_TRUNK_OPTIONS=TtrM(confirm))") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-dialout-trunk:17] Macro("SIP/2199-00001733", "dialout-trunk-predial-hook,") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-dialout-trunk-predial-hook:1] MacroExit("SIP/2199-00001733", "") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-dialout-trunk:18] GotoIf("SIP/2199-00001733", "0?bypass,1") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-dialout-trunk:19] ExecIf("SIP/2199-00001733", "1?Set(CONNECTEDLINE(num,i)=1300)") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-dialout-trunk:20] ExecIf("SIP/2199-00001733", "1?Set(CONNECTEDLINE(name,i)=CID:2199)") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-dialout-trunk:21] ExecIf("SIP/2199-00001733", "0?Set(CONNECTEDLINE(name,i)=CID:(Hidden)2199)") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-dialout-trunk:22] GotoIf("SIP/2199-00001733", "0?customtrunk") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] pbx.c: Executing [s@macro-dialout-trunk:23] Dial("SIP/2199-00001733", "IAX2/IAX_SERVER_B/1300,300,Ttr") in new stack
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] app_dial.c: Called IAX2/IAX_SERVER_B/1300
[2017-01-19 14:00:27] VERBOSE[9412][C-00000c51] chan_iax2.c: Call accepted by x.x.y.y:4569 (format ulaw)
[2017-01-19 14:00:27] VERBOSE[9412][C-00000c51] chan_iax2.c: Format for call is (ulaw)
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] app_dial.c: IAX2/IAX_SERVER_B-24158 answered SIP/2199-00001733
[2017-01-19 14:00:27] VERBOSE[138458][C-00000c51] bridge_channel.c: Channel IAX2/IAX_SERVER_B-24158 joined 'simple_bridge' basic-bridge <07292c0a-30f4-420c-b2ce-f27cf58aa0d8>
[2017-01-19 14:00:27] VERBOSE[138456][C-00000c51] bridge_channel.c: Channel SIP/2199-00001733 joined 'simple_bridge' basic-bridge <07292c0a-30f4-420c-b2ce-f27cf58aa0d8>

Receiving Server:

[2017-01-19 14:00:27] VERBOSE[1892] chan_iax2.c:     -- Accepting AUTHENTICATED call from x.x.x.x:
   > requested format = ulaw,
   > requested prefs = (ulaw|alaw|gsm),
   > actual format = ulaw,
   > host prefs = (ulaw|alaw|gsm),
   > priority = mine
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:1] Macro("IAX2/SERVER_A-13082", "user-callerid,") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@macro-user-callerid:1] Set("IAX2/SERVER_A-13082", "TOUCH_MONITOR=SERVER_B-1484834427.15022") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@macro-user-callerid:2] Set("IAX2/SERVER_A-13082", "AMPUSER=2199") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@macro-user-callerid:3] GotoIf("IAX2/SERVER_A-13082", "0?report") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@macro-user-callerid:4] ExecIf("IAX2/SERVER_A-13082", "1?Set(REALCALLERIDNUM=2199)") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@macro-user-callerid:5] Set("IAX2/SERVER_A-13082", "AMPUSER=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@macro-user-callerid:6] GotoIf("IAX2/SERVER_A-13082", "0?limit") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@macro-user-callerid:7] Set("IAX2/SERVER_A-13082", "AMPUSERCIDNAME=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@macro-user-callerid:8] GotoIf("IAX2/SERVER_A-13082", "1?report") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Goto (macro-user-callerid,s,16)
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@macro-user-callerid:16] GotoIf("IAX2/SERVER_A-13082", "0?continue") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@macro-user-callerid:17] Set("IAX2/SERVER_A-13082", "__TTL=64") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@macro-user-callerid:18] GotoIf("IAX2/SERVER_A-13082", "1?continue") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Goto (macro-user-callerid,s,29)
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@macro-user-callerid:29] Set("IAX2/SERVER_A-13082", "CALLERID(number)=2199") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@macro-user-callerid:30] Set("IAX2/SERVER_A-13082", "CALLERID(name)=Fraser Allan") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@macro-user-callerid:31] Set("IAX2/SERVER_A-13082", "CDR(cnum)=2199") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@macro-user-callerid:32] Set("IAX2/SERVER_A-13082", "CDR(cnam)=Fraser Allan") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@macro-user-callerid:33] Set("IAX2/SERVER_A-13082", "CHANNEL(language)=en") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:2] Answer("IAX2/SERVER_A-13082", "") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:3] Macro("IAX2/SERVER_A-13082", "blkvm-set,reset") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@macro-blkvm-set:1] ExecIf("IAX2/SERVER_A-13082", "1?Set(__BLKVM_CHANNEL=IAX2/SERVER_A-13082)") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@macro-blkvm-set:2] Set("IAX2/SERVER_A-13082", "SHARED(BLKVM,IAX2/SERVER_A-13082)=TRUE") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@macro-blkvm-set:3] Set("IAX2/SERVER_A-13082", "GOSUB_RETVAL=TRUE") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@macro-blkvm-set:4] MacroExit("IAX2/SERVER_A-13082", "") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:4] ExecIf("IAX2/SERVER_A-13082", "1?Set(_DIAL_OPTIONS=trM(auto-blkvm))") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:5] Set("IAX2/SERVER_A-13082", "__NODEST=1300") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:6] Set("IAX2/SERVER_A-13082", "QCIDPP=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:7] Set("IAX2/SERVER_A-13082", "VQ_CIDPP=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:8] ExecIf("IAX2/SERVER_A-13082", "0?Macro(prepend-cid,)") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:9] Set("IAX2/SERVER_A-13082", "QAINFO=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:10] Set("IAX2/SERVER_A-13082", "VQ_AINFO=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:11] ExecIf("IAX2/SERVER_A-13082", "0?Set(__ALERT_INFO=)") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:12] Set("IAX2/SERVER_A-13082", "QJOINMSG=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:13] Set("IAX2/SERVER_A-13082", "VQ_JOINMSG=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:14] Set("IAX2/SERVER_A-13082", "QRINGOPTS=r") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:15] Set("IAX2/SERVER_A-13082", "QRETRY=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:16] Set("IAX2/SERVER_A-13082", "VQ_RETRY=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:17] Set("IAX2/SERVER_A-13082", "QOPTIONS=tr") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:18] Set("IAX2/SERVER_A-13082", "VQ_OPTIONS=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:19] Set("IAX2/SERVER_A-13082", "QGOSUB=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:20] Set("IAX2/SERVER_A-13082", "VQ_GOSUB=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:21] Set("IAX2/SERVER_A-13082", "QAGI=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:22] Set("IAX2/SERVER_A-13082", "VQ_AGI=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:23] Set("IAX2/SERVER_A-13082", "QRULE=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:24] Set("IAX2/SERVER_A-13082", "VQ_RULE=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:25] Set("IAX2/SERVER_A-13082", "QPOSITION=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:26] Set("IAX2/SERVER_A-13082", "VQ_POSITION=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:27] Gosub("IAX2/SERVER_A-13082", "sub-record-check,s,1(q,1300,dontcare)") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@sub-record-check:1] GotoIf("IAX2/SERVER_A-13082", "0?initialized") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@sub-record-check:2] Set("IAX2/SERVER_A-13082", "__REC_STATUS=INITIALIZED") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@sub-record-check:3] Set("IAX2/SERVER_A-13082", "NOW=1484834427") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@sub-record-check:4] Set("IAX2/SERVER_A-13082", "__DAY=19") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@sub-record-check:5] Set("IAX2/SERVER_A-13082", "__MONTH=01") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@sub-record-check:6] Set("IAX2/SERVER_A-13082", "__YEAR=2017") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@sub-record-check:7] Set("IAX2/SERVER_A-13082", "__TIMESTR=20170119-140027") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@sub-record-check:8] Set("IAX2/SERVER_A-13082", "__FROMEXTEN=2199") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@sub-record-check:9] Set("IAX2/SERVER_A-13082", "__MON_FMT=wav") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@sub-record-check:10] NoOp("IAX2/SERVER_A-13082", "Recordings initialized") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@sub-record-check:11] ExecIf("IAX2/SERVER_A-13082", "0?Set(ARG3=dontcare)") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@sub-record-check:12] Set("IAX2/SERVER_A-13082", "REC_POLICY_MODE_SAVE=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@sub-record-check:13] ExecIf("IAX2/SERVER_A-13082", "0?Set(REC_STATUS=NO)") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@sub-record-check:14] GotoIf("IAX2/SERVER_A-13082", "1?checkaction") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Goto (sub-record-check,s,17)
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@sub-record-check:17] GotoIf("IAX2/SERVER_A-13082", "0?sub-record-check,q,1") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@sub-record-check:18] NoOp("IAX2/SERVER_A-13082", "Generic q Recording Check - 2199 1300") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@sub-record-check:19] Gosub("IAX2/SERVER_A-13082", "recordcheck,1(dontcare,q,1300)") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [recordcheck@sub-record-check:1] NoOp("IAX2/SERVER_A-13082", "Starting recording check against dontcare") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [recordcheck@sub-record-check:2] Goto("IAX2/SERVER_A-13082", "dontcare") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Goto (sub-record-check,recordcheck,3)
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [recordcheck@sub-record-check:3] Return("IAX2/SERVER_A-13082", "") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [s@sub-record-check:20] Return("IAX2/SERVER_A-13082", "") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:28] Set("IAX2/SERVER_A-13082", "__CWIGNORE=TRUE") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:29] ExecIf("IAX2/SERVER_A-13082", "0?Playback(, )") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:30] QueueLog("IAX2/SERVER_A-13082", "1300,SERVER_B-1484834427.15022,NONE,DID,") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:31] Set("IAX2/SERVER_A-13082", "QAANNOUNCE=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:32] Set("IAX2/SERVER_A-13082", "VQ_AANNOUNCE=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:33] Set("IAX2/SERVER_A-13082", "QMOH=default") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:34] Set("IAX2/SERVER_A-13082", "VQ_MOH=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:35] ExecIf("IAX2/SERVER_A-13082", "1?Set(__MOHCLASS=default)") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:36] ExecIf("IAX2/SERVER_A-13082", "1?Set(CHANNEL(musicclass)=default)") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:37] Set("IAX2/SERVER_A-13082", "QMAXWAIT=20") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:38] Set("IAX2/SERVER_A-13082", "VQ_MAXWAIT=") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:39] Set("IAX2/SERVER_A-13082", "QUEUENUM=1300") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:40] Set("IAX2/SERVER_A-13082", "QUEUEJOINTIME=1484834427") in new stack
[2017-01-19 14:00:27] VERBOSE[11466] pbx.c:     -- Executing [1300@from-internal:41] Queue("IAX2/SERVER_A-13082", "1300,tr,,,20,,,,,") in new stack
....

Fraser, did you resolve this? … I’m seeing the same behaviour. version 13.0.192.16
thanks
Mike

No - It still causes great confusion to our users :frowning:

The issue only appeared with FreePBX13 so fingers cross FreePBX14 resolves it. I am waiting for the FreePBX13 to 14 upgrade script to come out of beta before attempting to upgrade my servers.

Thanks
Fraser

Unlikely unless you filed a ticket at the time with details. From what I can see, the callerid macro is being called with the EXTERNAL argument. I think intracompany routes should not have this.

The issue is currently “on deck” so hopefully will be picked up soon.

Thanks

For anyone having the same Issue, i hace found the solution here:
https://issues.freepbx.org/browse/FREEPBX-10065

The problem came from the outbound route:

This Route wont use the CID Alias
[outrt-7] ; Internal_SVG
include => outrt-7-custom
_exten => 78[01]X,1,Macro(user-callerid,LIMIT,EXTERNAL)

But this will
[outrt-7] ; Internos_SVG
include => outrt-7-custom
_exten => 78[01]X,1,Macro(user-callerid,LIMIT,)

The diference is on the Macro dialout, that althoug we set “intra company” it wont remove the “EXTERNNAL” Part, if you change this manuali on

/etc/asterisk/extensions_additional.conf

It will work. For a more permanent solution you have to change this php

/var/www/html/admin/modules/core/functions.inc.php

Find the line “if ($fpattern[‘base_pattern’] != $exten) {” near the line 2253 and exhcange this code

      if (!isset($add_extra_pri1[$fpattern['base_pattern']])) {
       $ext->add($context, $fpattern['base_pattern'], '', new ext_macro('user-callerid,LIMIT,EXTERNAL'));
         $add_extra_pri1[$fpattern['base_pattern']] = true;
                 }
      if ($fpattern['base_pattern'] != $exten) {
                            else {  $ext->add($context, $fpattern['base_pattern'], '', new ext_macro('user-callerid,LIMIT,EXTERNAL'));
                 }

for this

      if (!isset($add_extra_pri1[$fpattern['base_pattern']])) {
             if ($route['intracompany_route'] != '') {
             $ext->add($context, $fpattern['base_pattern'], '', new ext_macro('user-callerid,LIMIT'));
             $add_extra_pri1[$fpattern['base_pattern']] = true;
            }
            else { $ext->add($context, $fpattern['base_pattern'], '', new ext_macro('user-callerid,LIMIT,EXTERNAL'));
            $add_extra_pri1[$fpattern['base_pattern']] = true;
            }
      }
      if ($fpattern['base_pattern'] != $exten) {
             if ($route['intracompany_route'] != '') {
             $ext->add($context, $fpattern['base_pattern'], '', new ext_macro('user-callerid,LIMIT'));
            }
            else {  $ext->add($context, $fpattern['base_pattern'], '', new ext_macro('user-callerid,LIMIT,EXTERNAL'));
            }
      }

This will make the fix permanent, tested on Freepbx 13, 11 and on Elastix too.

After this, change one route “intra company” status, and change it back, it will apply on all routes, you can check it on /etc/asterisk/extensions_additional.conf

I’m using Freepbx 14 distro updated to the latest version

Current PBX Version:14.0.5.5
Current System Version:12.7.5-1807-1.sng7

and have the same problem in current version