PBX to PBX Inbound Routes

Hello,

I have 2 FreePBX servers, we’ll say Server A and Server B. I have a PJSIP trunk going between the two and can call between the 2 just fine (contexts on both sides of the trunk is set to FROM-INTERNAL). The trouble that I am having is that the SIP Trunk provider comes in on Server A (and needs to stay this way) and needs to pass the call to Server B. Server B has just 1 single DID (XXXXXX5997).

I have the inbound route destination for the above DID on Server A set to “Trunk - Home”. On Server B I have the inbound route destination for the above DID set to “Extension - 5000”.

When I call XXXXXX5997 from an external phone I get a congestion message coming from Server B and I’m not sure why. Would anyone be able to take a look at this Pastebin and see if you can decipher what might be causing the call to not go through? I can see that it is hitting Server B, I just don’t know why it won’t route to ext 5000.

https://pastebin.freepbx.org/view/286b6646

Thanks,
Daniel

I believe that the from-internal context does not evaluate Inbound Routes.

Assuming that dialing 5000 from a phone on server A will ring to ext. 5000 on server B, try setting up a Misc Destination of 5000 on server A and setting the Inbound Route for XXXXXX5997 to that Misc Destination.

BTW, please ensure that logs you paste are set to never expire, so future readers of the thread can follow along.

Confirming what @Stewart1 said. The two main Asterisk contexts used in FreePBX are from-internal and from-trunk. If you want a call to be processed with inbound routes, it must go to context from-trunk or a workaround such as suggested above.

2 Likes

Yes indeed Lorne.
For everything about internal, then let’s use from-internal.
That was an old setup using SIP or IAX2 trunk between two or more FreePBX systems.
Need to do like this yes.

The black point was using the MWI or BLF everywhere. I member there was a script in php to sync the data if I recall correctly.