KPN VoIP settings changed, trunk can not call out

About a year back we managed to configure FreePBX for KPN (Dutch telecom provider) using Asterisk information available on the KPN forum (see link).
In december last year, KPN may have changed their settings which broke the installation.
We can call in, but not call out.
We’ve been fighting with this over the last months and have not been able to fix the configuration in such a way that we can call out again as well.

This configuration worked until December.
One other error we see is related to AMPUSER account code does not exists. Not sure if this has any relevance, the AMP module is not installed as we don’t have a need for it.
We also tried to add ;hide on the proxy url, no difference.
Internal calls work fine (CISCO 8861 desk phones) and inbound works fine as well.
System is behind a NAT modem, KPN notes in their configuration documentation that they have implemented NAT facilities in their network so STUN and/or any port forwarding is not necessary. OUr IP address is fixed and since the FreePBX is on an internal system (very small office network) we have disabled the firewall.
System is a compiled version of Asterisk 20.7 (Raspberry PI) with FreePBX 16.
Modem: Fritzbox 7581 with all telephony disabled, KPN auto-configure disabled (as otherwise they will configure the phone number there, breaking our setup).
Logs: KPN trunk setup failure log - FreePBX Pastebin
If any more details are required to assist, let me know.

The pastebin shows no OK coming back to the OPTIONS, so the PBX probably sees the trunk as unreachable. You can disable the qualify on the trunk and see if that resolves the issue.

Will check that and report back.
Just so I have the correct setting, I don’t remember seeing a qualify option in the trunk settings but may have missed it (PJSIP).
I did look for the relevant info on the forum first but no direct luck.
If you can provide a pointer to the setting, I would appreciate that.

Probably true, but we also don’t see OPTIONS being retransmitted, nor do we see OPTIONS being retried 60 seconds later (assuming default qualify settings). And, we don’t see any reachable / unreachable being logged. So the logging is suspect.

Please try setting Outbound Proxy to
sip:voip1-ext.kpn.net\;lr\;hide
and retest.

If it doesn’t help, leave that setting in place and paste a new log from /var/log/asterisk/full (not the console). Confirm that in Settings → Asterisk Logfile Settings → Log Files, full, you have Debug, Error, Notice, Verbose and Warning all set On.

If you have any custom config files for pjsip, please post them. Also, post a screenshot of the Advanced tab of your trunk settings.

1 Like

We have already tried the ;hide option, this has no effect.
I’ll redo the logs as recommended and will repost/update the pastebin wehn done and report when completed.
Oh and no custom configs are used.
I’ll see if we can do this tonight after dinner.

I understand that it doesn’t make it work, but it may make a difference in the logs, helping to find the next problem, so please leave it in place.

was already planning to, thanks for the clarification though :wink:

@Steward1 please see the new log with startup of Asterisk/FreePBX as well as connection with both Cisco handsets (ext 10 and 20) and the entire log of the trunk setup and failing.
It indeed seems to get no response on the option outbound packet and concludes then that the ims.imscore.net route is unreachable (that hostname btw does not resolve via DNS, not necessary as it goes via the KPN proxy server, see screenshot).
KPN failure log with \:hide - FreePBX Pastebin
HOpe you can find the missing and/or misconfigured option to get this working again.

and here is the second screenshot (only allowed to do one at a time).

Note that the places where it says +31 will list the entire phone number which is part of the subscription.

I’m puzzled. We’re now seeing OPTIONS properly retried with no response. Possibly, the server doesn’t respond to OPTIONS at all, or it doesn’t like some other field.

Please try setting Qualify Frequency to 0. See whether registration is now stable, and report what happens on incoming and outgoing call attempts.

Our mistake, we removed a little too many of the double lines in the first pastebin, they are their with the same result and effect. My apologies.

Will do indeed.

The other two lines that caught my eye in this are these:
Service-Route: sip:145.7.97.53:5060;lr;bidx=0
Service-Route: <sip:[email protected]:5090;reg-
Specifically the second line and the port number referenced there :5090.
Another thing that’s different is the expiry timetou, 3600 in FreePBX 1620 on the KPN reply (although obviously if fails locally well before that now, but could be an issue later).

It now is working as it should, let\s see if this stays that way in the coming days.
I will report on any further progress.

Seems to have remained stable today.
I was even able to test a call-confirm macro copied over to the extensions overwrite config to play around with the call confirm setup (different thread) without issues.
Except for some warnings in extensions_additional :wink:

That did the trick, seems they did change this in December as before it worked with the qualify left at 60 seconds (unless something in FreePBX/Asterisk changed at that time as well).

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.