I am having an issue that many people seem to have had but can’t seem to resolve the problem. So apologies in advance as it is something I have missed.
I have FreePBX 15.0.17.24 configured with;
1 Outbound route, outbound route configured with Route CID , Override Extension set to No
1 Outbound trunk PJSIP, trunk configured with Outbound CallerID , CID Options set to Allow Any CID
Several Extensions configured with Outbound CID set to
The provider. If they are messing with your CID, you are stuck.
This is not an issue as I can set the on the outbound route and it displays correctly on the receiving party’s phone
The trunk definition. If you set an overriding CID here, nothing you put below will be honored.
I have tried a blank CID but there is no change
The Outbound Route definition. Here, if you set the Caller ID, it’s because a phone/outbound combination has led you to overriding the extensions’ default CIDs.
I have tried a blank CID and there is no change but as mentioned in point 1 if I set the as the CID it display correctly
The Extension definition. This is the CID associated with the extension. Usually, it’s the easiest way “back” to this phone, which could be a personal extension DID or an Extension Number for local calls.
I have configured the Extension CID as but it doesn’t change the outbound CID
5?> The phone app itself. Some technologies allow you to set a CID at the actual phone (my PY-90 phone at the Farm, for example).
I am using Yealink T46S
I there any where else in the settings I need to look at or change to allow extensions to determine the CID?
Interestingly when I run the CDR report indicated in the link you posted Lorne the outbound caller ID reported in the Call Detail Report is as configured for the extension.
The call leaves the system bearing the CID number as set on line 113. It that’s not what’s showing up at the far end, I would say this is a provider issue.
If I set the CID on the outgoing route to 0855511777 it does display correctly as 0855511777 on the receiver’s handset - is that still possible if the provider is the issue?
I have spoken to the provider and they said that the out going CID can be set to any of the DIDs on their trunk.
The recent bug in core could be affecting you; see
If that’s not it, at the Asterisk command prompt type pjsip set logger on
make a test call, paste the log (which will now include a sip trace) and post the link here. Make it clear what the extension, outbound route and trunk CID values are.
There is no one onsite at the moment, so I couldn’t get them to ring from a hand set but I used the cli command channel originate local/00777766550@from-internal extension 350@from-internal which I’m hoping will replicate a handset call from ext 350
I believe that the channel originate command did exactly what you wanted.
Line 105: [2021-02-26 06:47:21] VERBOSE[15246][C-00005fed] pbx.c: Executing [s@macro-outbound-callerid:32] ExecIf("Local/00777766550@from-internal-000000f1;2", "1?Set(CALLERID(all)=ABCDEFG <0866668307>)") in new stack
is AFAICT the last update of caller ID prior to the Dial on line 147: [2021-02-26 06:47:21] VERBOSE[15246][C-00005fed] app_dial.c: Called PJSIP/0777766550@Simtex
So I’m guessing that the problem is with the trunk settings or number format. Unfortunately, the pjsip logger info is missing, so we can’t see what actually went wrong.
When you issue at the Asterisk command prompt: pjsip set logger on
you should see a response of PJSIP Logging enabled
If not, post details.
Also, note that Apply Config or any restart or reload of Asterisk will cancel the logger setting, so you would have to issue it again.
Please try to re-enable pjsip logger, make another test call, paste the log and post the link.
Somehow the SIP trace did not appear. I don’t know how to troubleshoot that. Possibly, it will appear on the console even if it doesn’t appear in the log. With the Asterisk command prompt open and logger enabled, see whether it shows up on a new test call.
If we can’t see a SIP trace, here are two guesses:
The caller ID format is incorrect. If your number is 7654 3210 in Sydney, Engin probably wants 0276543210, 61276543210 or +61276543210. Find out from their documentation. If lacking a good bet is to send it in the same format as they send you on incoming calls.
It’s in the wrong header. If you have From User set for the trunk and it’s not required, turning that off may work. If From User is required, then you probably need to set Send RPID/PAI appropriately. Again, see their documentation or see what gets sent on incoming calls.
Thanks Stewart I will have a go on the weekend to see if changes on the trunk setting make a difference.
I have spoken to simtex support but they couldn’t really provide any further information other than the main DID number was being presented at their end for outbound calls.
That should not make any difference. If the extension is chan_sip and sip set debug on
was not issued, then you won’t see the SIP trace for the extension, but requests to and responses from the pjsip trunk should still be present.
In the most recent log, an outside call was not made at all. You called ext. 350 and I presume it was intended to make an outside call (follow-me, forwarding, etc.) but it didn’t and I did not take the effort to find out exactly why, as it doesn’t seem relevant to the problem at hand.
I have no idea why pjsip logger is not writing to the Asterisk log. in Settings → Asterisk Logfile Settings → Log Files, my system shows for ‘full’: Debug, Error, Notice, Verbose and Warning are On. If you have one or more of these off, see whether turning them on (and turning pjsip logger back on after Submit and Apply Config) makes a difference.
If not, after turning pjsip logger on, leave the Asterisk command prompt open, make a test call and see whether the SIP trace appears on the console. If it’s not there, either, you should still be able to run sngrep to see the outbound INVITE sent to the trunk.