Routing outbound calls from box B through Box A using SIP trunks


(Joseph Helou) #1

Hello community,
I have a scenario in which i use FreePBX box A as a gateway for all calls from and into our network. All other FreePBX boxes communicate internally between each other and use box A to go outside our network. All works well using IAX trunks. The problem that we are having is with routing outbound FAX calls. IAX does not support T.38 and so we need to route calls using SIP trunks. I have tried many different configurations but cannot seem to be able to allow an extension on box B to send a FAX through box A while maintaining the CID of the extension on box B.
Anyone has any recommendations on how to setup the SIP trunking between the boxes to allow box B to send external calls using trunks on box A and while maintaining the call parameters of the calling extension on box B?


#2

In the general case, this is a difficult problem, because only one caller ID is sent with a normal SIP call.

However, if your box A is essentially an SBC (handling only external calls), then I would think that by defining the Outbound Route on box B as not an Intracompany route, the Outbound CID for the extension should be passed on the trunk. At the box A end, the trunk context is from-internal, so the call has access to to all Outbound Routes.


#3

Have you considered using a SIP proxy instead of a B2BUA? It might well fit your use case better.


(Joseph Helou) #4

i tried this approach already, changing the context to from-internal results in chan-unavailable. i guess since the from-internal tries to match the cid to an existing user.


(Joseph Helou) #5

hi Dicko, i think this approach will work, i need to read up a bit on how to get it set up. Thanks for the tip


#6

Kamailio is a very able open source SIP router, it is a little ‘geeky’ to configure, but DSipRouter is a nice gooey front end to it that ‘knows about’ FreePBX/Asterisk (and others) . Likely it will work for you as a point of ingress/egress thus effective as an ‘exchange’ between DIDs to designated PBI, PBX to PBX trunking. and PBX to PSTN routing.

Also it is relatively easily ‘clusterable’ using DNS SRV’s and BGP if appropriate. T38 is not a concern as the routing will ultimately be one to one.


(Tom Ray) #7

Once again, FreePBX being used the wrong way.


#8

It doesn’t. Possibly, the call is being blocked by Extension Routes, Class of Service, or Outbound Routes

Or, the caller ID format differs from what the carrier wants. A SIP trace should show what is happening.


(Joseph Helou) #9

Hi @Stewart1, i have no idea what was the bug during my initial testing, but i confirm that setting the context to from-internal worked! thank you again for your input.