Multiple GV outgoing on Obi thru FreePBX/Asterisk
azrobert:
I used a different approach. What you did works fine, so I'm not suggesting you change anything. I'm just showing you a different method.
I'm assuming you have sp2 and sp4 registered to Raspbx as different extensions. You route 10 digit numbers to sp2 and **4 prefixed numbers to sp4. Is this correct?
1st, to route the **4 prefix to Raspbx make the following change in your OBi:
{(**4(Msp4)):sp4}
Now the **4 prefix will not be removed, so you don't have to add a 2nd prefix.
I routed calls in Raspbx by extension number, not by prefix.
I removed the **4 prefix before sending the call to Raspbx and just put the extension number into the callerid parm of the raspbx outbound route.
Edit:
You don't need to use a SPx trunk to point to a Raspbx extension. You can use a Voice Gateway.
hapollo:
Quote from: azrobert on July 24, 2016, 12:19:35 pm
I used a different approach. What you did works fine, so I'm not suggesting you change anything. I'm just showing you a different method.
I'm assuming you have sp2 and sp4 registered to Raspbx as different extensions. You route 10 digit numbers to sp2 and **4 prefixed numbers to sp4. Is this correct?
Actually 10 digits are routed to an offsite OBi110 which I didn't want older family members to have to remember **2 codes and such. The Sp2 and Sp4 are on a local Obi200 which forward to 2 cell phones, respectively.
Quote from: azrobert on July 24, 2016, 12:19:35 pm
1st, to route the **4 prefix to Raspbx make the following change in your OBi:
{(**4(Msp4)):sp4}
Now the **4 prefix will not be removed, so you don't have to add a 2nd prefix.
I actually did a **2 /**4 Prefix in RasPBX as noted in my very first post above, mentioned it was being stripped. Now I realize it was the simple colon removal that made the difference!!
Quote from: azrobert on July 24, 2016, 12:19:35 pm
I routed calls in Raspbx by extension number, not by prefix.
I removed the **4 prefix before sending the call to Raspbx and just put the extension number into the callerid parm of the raspbx outbound route.
I also tried that in my experimentation using the extension number in the caller ID parm of the RasPBX outbound route and also the the actual 9 digit callerID number. Can you clarify if it makes any difference to use an extension or the actual CallerID number in that field? Wasn't quite sure what it was looking to match when it's placed in that Outbound Routes CallerID field when a prefix will already match.
Quote from: azrobert on July 24, 2016, 12:19:35 pm
Edit:
You don't need to use a SPx trunk to point to a Raspbx extension. You can use a Voice Gateway.
I actually tried that as well when experimenting but got the 403 error because I put the IP address of the RasPBX after sp2 in the accessnumber field of the Obi Gateway sp2(192.168.XX.XX). I just removed it and now the gateway works without any authentication info. Why does this not need anything besides a proper DigitMap? While it seems this will allow multiple outgoing calls. Only incoming calls registered to a proper spX will ring, right?
Thanks for this, azrobert. It helped clarify alot of things and made me understand where some of my previous experimentation went wrong.
azrobert:
Quote
Now I realize it was the simple colon removal that made the difference!!
You also have to remove the "<>"
_______________________________
I'm totally confused on how you're routing calls to Raspbx, so I'll just explain my setup.
I have an OBi200 with SP3 registered to Raspbx as extension 1000
I have an OBi110 without an open SP trunk, so I have a VG pointing to Raspbx as extension 2000.
I changed the port number in Raspbx, so the VG definition looks like this:
AccessNumber: sp2(xx.xx.xx.xx:pppp)
AuthUserID: 2000
AuthPassword: password
I use a zero prefix to route calls to Raspbx in both devices.
I strip off the zero before routing the call.
Raspbx outbound routes looks like this:
Trunk1
Pattern: NXXNXXXXXX
CallerID: 1000
Trunk2
Pattern: NXXNXXXXXX
CallerID: 2000
You can use a prefix OR extension number to route calls.
It's redundant to use both.
______________________________
The 403 error means Forbidden.
My Raspbx doesn't require my extension to be registered.
Maybe your version does.
My OBi110 isn't registered to Raspbx.
I do have a trunk defined on Raspbx pointing to the OBi110.
I need this trunk, so Raspbx knows the IP address of the OBi110.
If I route inbound OBi110 calls to Raspbx without this trunk defined, the call will be treated as anonymous and be rejected with I think a 403 error.
You are supplying credentials, so it shouldn't be considered anonymous, but maybe it will.
You can try defining a trunk pointing to your OBi on Raspbx and see if it clears the 403 error.
Define it like this:
Trunk Name: OBixxx
Outbound CallerID: any number
Peer details:
type=peer
username=anything
host=xx.xx.xx.xx (OBi IP address)
port=5061
canreinvite=no
insecure=invite,port
qualify=yes
No Register String
__________________________
It's a mystery to me why removing the VG access number works.
___________________________
Quote
While it seems this will allow multiple outgoing calls. Only incoming calls registered to a proper spX will ring, right?
You can change the extension definition to route inbound calls to the IP address of the OBi.
The default Dial command looks like: SIP/2000
Change it to: SIP/0@xx.xx.xx.xx:5061
That's the IP address and port of SP2 on the OBi.
The OBi SP2 inbound call route must be able to accept this call.
Edit:
If you use a prefix to route outbound calls, you only need to define 1 extension.
Route all prefixes to the same extension then have 2 outbound routes.
I don't know if you need to route inbound calls to different destinations.
hapollo:
Thanks azrobert, I'm with you for the most part as well but in reading these post, I realized I needed to step back and not take these examples literally but to use as a guideline depending on how my Obis have been set up.
With that I am wondering:
Quote from: azrobert on July 24, 2016, 08:44:22 pm
I changed the port number in Raspbx, so the VG definition looks like this:
AccessNumber: sp2(xx.xx.xx.xx:pppp)
Did you change the port number to accommodate the VG or to avoid SIP scanners? I get confused as to when ports need to be changed for reasons other than SIP scanners as I notice SP1,2,3,4 on Obi200 use 5060,61,62,63 on xUserAgentPort but most places I've read say multiple SIPs can all use 5060 at the same time.
Quote from: azrobert on July 24, 2016, 08:44:22 pm
You can try defining a trunk pointing to your OBi on Raspbx and see if it clears the 403 error.
Define it like this:
Trunk Name: OBixxx
Outbound CallerID: any number
Peer details:
type=peer
username=anything
host=xx.xx.xx.xx (OBi IP address)
port=5061
canreinvite=no
insecure=invite,port
qualify=yes
No Register String
__________________________
Quote
While it seems this will allow multiple outgoing calls. Only incoming calls registered to a proper spX will ring, right?
You can change the extension definition to route inbound calls to the IP address of the OBi.
The default Dial command looks like: SIP/2000
Change it to: SIP/0@xx.xx.xx.xx:5061
That's the IP address and port of SP2 on the OBi.
The OBi SP2 inbound call route must be able to accept this call.
Thanks, after following this as a template and not literally using port 5061 since my SP4 allows incoming calls but not SP2, I changed the above to port 5063 for SP4 and can register multiple GVs # to allow incoming calls to Obi.
Quote from: azrobert on July 24, 2016, 08:44:22 pm
Edit:
If you use a prefix to route outbound calls, you only need to define 1 extension.
Route all prefixes to the same extension then have 2 outbound routes.
I don't know if you need to route inbound calls to different destinations.
Not quite sure I follow this, although when I did register my vg2 as suggested:
I changed the port number in Raspbx, so the VG definition looks like this:
AccessNumber: sp2(xx.xx.xx.xx:pppp)
AuthUserID: 2000
AuthPassword: password
Now I get a busy signal when I dial out vg2 while Asterisk CDR show it going out with the correct prefix and Busy while Obi200 Call history shows
SP4("NumberIcalled"@192.168.XX.XX:5060) Call Ended (486 Busy Here)
Is that why you changed the port number above or something else causing this Busy error?
After I get Outbound Calling over VG working properly, I think I'll have the proper framework for future expansion and flexibility using Asterisk/FreePBX and various Obi configs.
Thanks in advance azrobert!
NoelB:
Quote from: hapollo on July 25, 2016, 03:48:48 pm
Did you change the port number to accommodate the VG or to avoid SIP scanners? I get confused as to when ports need to be changed for reasons other than SIP scanners as I notice SP1,2,3,4 on Obi200 use 5060,61,62,63 on xUserAgentPort but most places I've read say multiple SIPs can all use 5060 at the same time.
Just chiming in briefly. I have a very similar setup to azrobert with VG on an obi110 setup to point to my asterisk. I started off ignoring ports with the intention of changing them for better security later but just havent got around to it. So my VG access number is just sp2(192.168.1.34) with AuthUserID as obi110.
In asterisk I use type=friend for extensions with host=dynamic and defaultuser=obi110.
When an Invite comes from VG it comes to asterisk 5060 by default and asterisk knows from the received pkt it comes from obi110 at 192.168.1.103:5061 ( my obi addr) so now it knows everything it needs to match on obi110 and setup the call correctly.
I am not suggesting that my asterisk settings are better just that asterisk can be setup in many different ways and still work correctly. I have a no frills version so have to enter all settings via CLI.
Navigation
[0] Message Index
[#] Next page
[*] Previous page