OBiTALK Community

General Support => Installation and Set-Up (Devices) => Topic started by: jadog on December 08, 2018, 09:39:52 AM

Title: Outbound call routing doesn't appear to be working properly
Post by: jadog on December 08, 2018, 09:39:52 AM
I continue to struggle with getting my calls to route to the correct SP. I have reset my Obi multiple times and started fresh, and configured SP1 as my primary, SP2 as international calls only to numbers that begin with 0113620, 0113630, or 0113670. I have configured SP3 and SP4 as two different Google Voice numbers.

My primary SP appears to be configured properly as I can use that for usual calling. However it's when I want the calls to route out on a different SP that I run into trouble.

1. Dialing international numbers all go to SP1, regardless of what the number begins with. I'm guessing this is because I have 011xx.S3 as part of the digit map. I just don't know how to make it choose SP2 instead.
2. I have my outbound route configured to use SP4 when pressing <9> first. But that instead routes to SP1 and the call fails. Pressing **4 and then the number routes the call to SP4.

Here is my configuration:

Phone 1 and Phone2 OutboundCallRoute:
{([19]900xxxxxxx):},{(<9:1>xxxxxxxxxx|<9:1260>xxxxxxx):sp4},{911:sp1},{933:sp1},{([1-9]x?*(Mpli)):pp},{(<##:>):li},{(<#:>):ph2},{(<**70:>(Mli)):li},{(<**82:>(Mbt2)):bt2},{(<**81:>(Mbt)):bt},{(<**8:>(Mbt)):bt},{**0:aa},{***:aa2},{(<**1:>(Msp1)):sp1},{(<**2:>(Msp2)):sp2},{(<**3:>(Msp3)):sp3},{(<**4:>(Msp4)):sp4},{(<**9:>(Mpp)):pp},{(Mpli):pli}

DigitMap for ITSP Profile A
(911|933|1xxxxxxxxxx|<1260>[2-9]xxxxxx|<1>[2-9]xxxxxxxxx|011xx.S3|*21|*50xxxx|*51xxxx|*52xxxx|*53xxxx|*54|*6[013569]|*6[27]xx.|*77|*[789]2xx.|*73|*74[0-1][0-9]*xxxxxxxxxx|*75[0-1][0-9]|*8[137]|90xxxx|*93|*96)

DigitMap for ITSP Profile B
(01136[237]0xx.S3)

DigitMap for ITSP Profile D
(<9:>xxxxxxxxxx|1xxxxxxxxxx)

Gateway and Trunks are configured to ObiTalk defaults.

I would love to have someone help me figure out what I'm doing wrong. It's driving me crazy!
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: drgeoff on December 08, 2018, 09:51:37 AM
Unlike the Digit Maps the OutboundCallRoute is sensitive to the order of its rules.  It will send the call to the SP in the first rule that gives a match.  So make sure that more specific rules precede more general ones.

Try moving the SP2 stuff to come before SP1. ie

{([19]900xxxxxxx):},{(<9:1>xxxxxxxxxx|<9:1260>xxxxxxx):sp4},{911:sp1},{933:sp1},{([1-9]x?*(Mpli)):pp},{(<##:>):li},{(<#:>):ph2},{(<**70:>(Mli)):li},{(<**82:>(Mbt2)):bt2},{(<**81:>(Mbt)):bt},{(<**8:>(Mbt)):bt},{**0:aa},{***:aa2},{(<**2:>(Msp2)):sp2},{(<**1:>(Msp1)):sp1},{(<**3:>(Msp3)):sp3},{(<**4:>(Msp4)):sp4},{(<**9:>(Mpp)):pp},{(Mpli):pli}

We also need to see your Phone Port Digit Maps.
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: jadog on December 08, 2018, 11:05:08 AM
I'm not sure I completely follow what you are telling me. I only have one rule in the OutboundCallRoute that I added (bolded below). The rest is the default. But I did as you mentioned and changed it to:

{911:sp1},{933:sp1},{([19]900xxxxxxx):},{(<9:1>xxxxxxxxxx|<9:1260>xxxxxxx):sp4},{([1-9]x?*(Mpli)):pp},{(<##:>):li},{(<#:>):ph2},{(<**70:>(Mli)):li},{(<**82:>(Mbt2)):bt2},{(<**81:>(Mbt)):bt},{(<**8:>(Mbt)):bt},{**0:aa},{***:aa2},{(<**1:>(Msp1)):sp1},{(<**2:>(Msp2)):sp2},{(<**3:>(Msp3)):sp3},{(<**4:>(Msp4)):sp4},{(<**9:>(Mpp)):pp},{(Mpli):pli}

After making this change, I tried again and the results were the same. International numbers that begin with 0113620, 0113630, or 0113670 still go to SP1 instead of SP2. Adding a <9> to the beginning of a call also still fails. The call history shows - To SP1(19336333010). It's trying to dial the 9 instead of using it as a command to use SP4.

The Phone Port Digit Map is set to the Obitalk settings default. I've copied it below:

([1-9]x?*(Mpli)|[1-9]S9|[1-9][0-9]S9|911|**0|***|#|##|**70(Mli)|**8(Mbt)|**81(Mbt)|**82(Mbt2)|**1(Msp1)|**2(Msp2)|**3(Msp3)|**4(Msp4)|**9(Mpp)|(Mpli))
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: azrobert on December 08, 2018, 11:52:37 AM
Replace:
{(<9:1>xxxxxxxxxx|<9:1260>xxxxxxx):sp4}

With:
{(<9:1>xxxxxxxxxx|01136[237]0x.):sp4}

Do not dial 9 prefix for international calls.

What is 1260 area code?

QuoteThe call history shows - To SP1(19336333010). It's trying to dial the 9 instead of using it as a command to use SP4.

It looks like you're dialing 9336332010

I thought you will dial:
011336332010
or
9011336332010
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: jadog on December 08, 2018, 12:02:34 PM
Thanks Robert. Am I misunderstanding what you are telling me to do? I do NOT want international calls to go to SP4. There are two different SP's that have seperate issues with outbound calls. All International calls to numbers that begin with 0113620, 0113630, or 0113670 are supposed to route to SP2. All other international calls should use the primary SP1. Numbers with a <9> in front are supposed to route to SP4 (one of my Google Voice numbers). The 260 area code is my local area code. I was testing a dial to a random number that began with 336 and preceeded with a '9' as I was expecting for it to route to SP4. Sorry, I didn't mean to make it confusing.

So maybe this is what you are wanting me to put in the OutboundCallRoute?

{911:sp1},{933:sp1},{01136[237]0x.:sp2},{([19]900xxxxxxx):},{(<9:1>xxxxxxxxxx|<9:1260>xxxxxxx):sp4},{([1-9]x?*(Mpli)):pp},{(<##:>):li},{(<#:>):ph2},{(<**70:>(Mli)):li},{(<**82:>(Mbt2)):bt2},{(<**81:>(Mbt)):bt},{(<**8:>(Mbt)):bt},{**0:aa},{***:aa2},{(<**1:>(Msp1)):sp1},{(<**2:>(Msp2)):sp2},{(<**3:>(Msp3)):sp3},{(<**4:>(Msp4)):sp4},{(<**9:>(Mpp)):pp},{(Mpli):pli}

To restate what I need:

SP1: Primary line for most calls including international numbers that do NOT begin with 0113620, 0113630, or 0113670
SP2: International calls for numbers that ONLY begin with 0113620, 0113630, or 0113670
SP4: Google Voice number that I can dial <9> to use this for my outbound call. No international calling.
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: drgeoff on December 08, 2018, 12:47:48 PM
Quote from: jadog on December 08, 2018, 11:05:08 AM
I'm not sure I completely follow what you are telling me.
The OBi works through the OutboundCallRoute from left to right.  As soon as it reaches a match it stops and the call is attempted on that SP.

So, if you have a rule for all international destinations before a rule for some international destinations, the OBi will always act on the former and not even look at the latter.  That is why I moved the {(<**2:>(Msp2)):sp2} which has  references the (01136[237]0xx.S3) to before {(<**1:>(Msp1)):sp1} which references 011xx.S3.
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: azrobert on December 08, 2018, 01:58:10 PM
Sorry for my post. I tend to skim and not read.

QuoteThe call history shows - To SP1(19336333010). It's trying to dial the 9 instead of using it as a command to use SP4.

The phone DigitMap is ignoring the 11th dialed digit because you don't have a rule for 11 digits beginning with "9". It's matching the 10 digit rule and adding a "1" prefix. Add rules "9xxxxxxxxxx|9xxxxxxx|" to the Phone DigitMap.

Edit:

Add "{(Msp2):sp2}," to the beginning of the Phone OutboundCallRoute.
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: jadog on December 08, 2018, 06:18:32 PM
We're making progress! I'm now able to dial <9> in front of a number to get to my google voice SP4. So thanks for that guys! International calls are not working though. As soon as I dial "011", I get an immediate fast busy signal.

This is with {(<**2:>(Msp2)):sp2} or even just {(Msp2)):sp2} at the front of the OutboundCallRoute. Must be missing something...
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: azrobert on December 08, 2018, 08:05:17 PM
Put "{(<**2:>(Msp2)):sp2}" back at its default location.

You shouldn't get the fast busy when SP1 is your Primary Line because of rule "011xx.S3" in the ITSP A DigitMap. You get the fast busy when the dialed number doesn't match the Phone and Primary Line DigitMaps.

Try putting "011xx.S3|" somewhere in the Phone Port DigitMap.
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: jadog on December 09, 2018, 11:34:13 AM
Well at least I'm learning more about how this all works. I put the Msp2 string back in it's original location like you suggested and added the "011xx.S3" in the Phone Port Digit map. When I placed an international call, I heard the announcement: "There is no call route available to complete your call". I tried two different numbers - one that would match the SP1 route and the other to match the SP2 route. Both gave the same message. Here are my current maps.

PHONE2 DigitMap
(9xxxxxxxxxx|9xxxxxxx|011xx.S3|[1-9]x?*(Mpli)|[1-9]S9|[1-9][0-9]S9|911|**0|***|#|##|**70(Mli)|**8(Mbt)|**81(Mbt)|**82(Mbt2)|**1(Msp1)|**2(Msp2)|**3(Msp3)|**4(Msp4)|**9(Mpp)|(Mpli))

OutboundCallRoute
{911:sp1},{933:sp1},{([19]900xxxxxxx):},{(<9:1>xxxxxxxxxx|<9:1260>xxxxxxx):sp4},{([1-9]x?*(Mpli)):pp},{(<##:>):li},{(<#:>):ph2},{(<**70:>(Mli)):li},{(<**82:>(Mbt2)):bt2},{(<**81:>(Mbt)):bt},{(<**8:>(Mbt)):bt},{**0:aa},{***:aa2},{(<**1:>(Msp1)):sp1},{(<**2:>(Msp2)):sp2},{(<**3:>(Msp3)):sp3},{(<**4:>(Msp4)):sp4},{(<**9:>(Mpp)):pp},{(Mpli):pli}
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: azrobert on December 09, 2018, 03:32:52 PM
Quote from: jadog on December 09, 2018, 11:34:13 AM
Well at least I'm learning more about how this all works.

Routing an outbound call is a 2 step process.
Step 1 the Phone Port DigitMap validates the dialed number.
The last rule (Mpli) will include the rules in primary line's DigitMap.
If the dialed number doesn't match a rule, you will receive a fast busy.

2nd step the phone port OutboundCallRoute will route the call to the primary line using rule {(Mpli):pli}
If you don't get a match you will get message "No routes available"
If you want to route a call to another provider without the "**n" prefix, you need to add rules before the last rule.

The Primary Line is defined here:
Physical Interfaces -> Phone1/2 Port -> PrimaryLine

Phone1 and Phone2 can have different Primary lines, so you might need different rules.
Remember {(Mpli):pli} will handle routing to the Primary Line.
So add {(Msp1):sp1} and/or {(Msp2):sp2} depending on what the PrimaryLine is for that Phone Port.

[1-9]x?*(Mpli) in the DigitMap and {([1-9]x?*(Mpli)):pp} in the OutboundRoute are used to route calls over the OBiTalk Network. You can delete these if not used.

Title: Re: Outbound call routing doesn't appear to be working properly
Post by: jadog on December 10, 2018, 07:06:05 PM
You mentioned that Phone1 and Phone2 can have different primary lines and that I should add {(Msp1):sp1} and/or {(Msp2):sp2} depending on what the PrimaryLine is for that Phone Port.

I have Phone 1 and Phone 2 both checked as "Primary Line for Outgoing Calls" for only SP1. My phone system is only connected to Phone 1 and I don't actually use Phone 2. However, I thought I would make both identical in the event that I ever move the Obi device then it won't matter which phone port I connect back to. Are you saying I should just choose one?
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: drgeoff on December 11, 2018, 03:05:06 AM
Quote from: jadog on December 10, 2018, 07:06:05 PM
You mentioned that Phone1 and Phone2 can have different primary lines and that I should add {(Msp1):sp1} and/or {(Msp2):sp2} depending on what the PrimaryLine is for that Phone Port.

I have Phone 1 and Phone 2 both checked as "Primary Line for Outgoing Calls" for only SP1. My phone system is only connected to Phone 1 and I don't actually use Phone 2. However, I thought I would make both identical in the event that I ever move the Obi device then it won't matter which phone port I connect back to. Are you saying I should just choose one?
There is no problem having SP1 (or any other SP) as the Primary Line for both PHONE1 and PHONE2.  All the settings for PHONE1 and PHONE2 are independent with no interaction between the two sets.
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: jadog on December 11, 2018, 04:54:49 PM
Ok, I've made some progress! After resetting my Obi200 (again), I left all the settings as default and made only the following changes:

Set the ITSP Profile B DigitMap to only the following:
(01136[237]0xx.S3)

OutboundCallRoute
{911:sp1},{933:sp1},{(<##:>):li},{(<#:>):ph1},{(<**70:>(Mli)):li},{(<**82:>(Mbt2)):bt2},{(<**81:>(Mbt)):bt},{(<**8:>(Mbt)):bt},{**0:aa},{***:aa2},{(<**2:>(Msp2)):sp2},{(<**1:>(Msp1)):sp1},{(<**3:>(Msp3)):sp3},{(<**4:>(Msp4)):sp4},{(<**9:>(Mpp)):pp},{(Mpli):pli}

I removed the {([1-9]x?*(Mpli)):pp}, since I don't use the OBiTalk network. I also moved Msp2 before Msp1.

I made no changes to the Phone Port DigitMap and left it at the default. When I dial the following number, it goes to SP2 as expected!

01136-309-845-276

Note that numbers that begin with 0113620, 0113630, or 0113670 should go to SP2 and all other international calls should go to SP1. So the above number is routed correctly. Next I try a number that should go to SP1:

01136-126-12389

However, I get the fast busy with this number. ITSP Profile A has the 011xx. assigned by default, so I'm not sure why the call is not going to SP1.

*** Edit *** 
Apparently moving Msp2 before Msp1 causes ALL other outbound calls (other than the 0113630..) to fail as ALL calls now seem to be trying to go to SP2. I had to change it back. But I believe this may be key to resolving this issue.
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: azrobert on December 11, 2018, 07:30:21 PM
The rule you moved is used when you dial **2 followed by a number to force routing to SP2.
The rule used without a prefix is: {(Mpli):pli}
I think the only way you routed the call to SP2 is your PrimaryLine is set to SP2 Service.
Make the following changes:

Physical Interfaces -> Phone1-2 Port -> PrimaryLine: SP1 service

Outbound Route:
{(Msp2):sp2},{911|933:sp1},{(<##:>):li},{(<#:>):ph1},{(<**70:>(Mli)):li},{(<**82:>(Mbt2)):bt2},{(<**81:>(Mbt)):bt},{(<**8:>(Mbt)):bt},{**0:aa},{***:aa2},{(<**1:>(Msp1)):sp1},{(<**2:>(Msp2)):sp2},{(<**3:>(Msp3)):sp3},{(<**4:>(Msp4)):sp4},{(<**9:>(Mpp)):pp},{(Mpli):pli}
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: jadog on December 12, 2018, 10:16:30 AM
You were absolutely correct. I accidentally set SP2 as the PrimaryLine. I corrected and I was able to call out as usual. By setting the Outbound Route as you instructed with {(Msp2):sp2} at the front, everything works correctly! International calls that begin with the correct prefix are routed to SP2. I also checked other international calls without the specified prefix and those now go to SP1 as desired. I was nearly ready to give up. Thanks for sticking with me guys!

Ok, so I am 95% done. My last desire is to configure the failover with the trunks. I'm scared to touch it now that it is working though. Here's what I would like:

SP1 - Failover to SP3, then SP4 (do not failover to SP2)
SP2 - Never failover

Also, is it possible to set a lower delay for the time it takes to connect when dialing a 7-digit number? It takes at least 3 seconds and this seems like a long time when waiting for it to connect.
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: azrobert on December 12, 2018, 08:22:40 PM
Are you still using a "9" prefix to route calls to SP4?

Anyway, please post the following:

ITSP A, C and D DigitMaps

Phone Port DigitMap and OutboundCallRoute
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: jadog on December 14, 2018, 05:00:57 PM
Yes, I am still using a "9" prefix to route calls to SP4. And it's actually working. However, I tested using **4 and that doesn't work since I added the routing to use "9". Here are the requested digitmaps:

ITSP A: (*xx|1xxxxxxxxxx|911|933|<1260>[2-9]xxxxxx|<1>[2-9]xxxxxxxxx|011xx.S3|*21|*50xxxx|*51xxxx|*52xxxx|*53xxxx|*54|*6[013569]|*6[27]xx.|*77|*[789]2xx.|*73|*74[0-1][0-9]*xxxxxxxxxx|*75[0-1][0-9]|*8[137]|90xxxx|*93|*96|xx.|(Mipd)|[^*]@@.)

ITSP B: (01136[237]0xx.S3)

ITSP D: (<9:>xxxxxxxxxx|1xxxxxxxxxx)

Phone Port DigitMap (default): ([1-9]x?*(Mpli)|[1-9]S9|[1-9][0-9]S9|911|**0|***|#|##|**70(Mli)|**8(Mbt)|**81(Mbt)|**82(Mbt2)|**1(Msp1)|**2(Msp2)|**3(Msp3)|**4(Msp4)|**9(Mpp)|(Mpli))

OutboundCallRoute: {(Msp2):sp2},{911:sp1},{933:sp1},{([19]900xxxxxxx):},{(<9:1>xxxxxxxxxx|<9:1260>xxxxxxx):sp4},{(<9:1>xxxxxxxxxx|<9:1260>xxxxxxx):sp3},{([1-9]x?*(Mpli)):pp},{(<##:>):li},{(<#:>):ph2},{(<**70:>(Mli)):li},{(<**82:>(Mbt2)):bt2},{(<**81:>(Mbt)):bt},{(<**8:>(Mbt)):bt},{**0:aa},{***:aa2},{(<**1:>(Msp1)):sp1},{(<**2:>(Msp2)):sp2},{(<**3:>(Msp3)):sp3},{(<**4:>(Msp4)):sp4},{(<**9:>(Mpp)):pp},{(Mpli):pli}
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: azrobert on December 15, 2018, 06:48:34 AM
Quote from: jadog on December 12, 2018, 10:16:30 AM
SP1 - Failover to SP3, then SP4 (do not failover to SP2)

You didn't post ITSP C DigitMap, so I don't know what to route to SP3.

The following will only failover 11, 10, 7 and international numbers. If you want more, you need to add those rules to ITSP C and D DigitMaps.

I removed what I think are unnecessary rules.

**4 should now work.

You had "9" prefix rules routing to SP3, but these would never execute because they were to the right of SP4 rules. I removed them.

ITSP A: (*xx|1xxxxxxxxxx|911|933|<1260>[2-9]xxxxxx|<1>[2-9]xxxxxxxxx|011xx.S3|*21|*50xxxx|*51xxxx|*52xxxx|*53xxxx|*54|*6[013569]|*6[27]xx.|*77|*[789]2xx.|*73|*74[0-1][0-9]*xxxxxxxxxx|*75[0-1][0-9]|*8[137]|90xxxx|*93|*96)

ITSP B: (01136[237]0xx.)

ITSP C: (1xxxxxxxxxx|<1>[2-9]xxxxxxxxx|<1260>[2-9]xxxxxx|011xx.)

ITSP D: (<9:1>xxxxxxxxxx|<9:1260>xxxxxxx|1xxxxxxxxxx|<1>[2-9]xxxxxxxxx|<1260>[2-9]xxxxxx|011xx.)

Phone Port DigitMap: ([1-9]S9|[1-9][0-9]S9|911|9xxxxxxxxxx|9xxxxxxx|**0|***|#|##|**70(Mli)|**8(Mbt)|**81(Mbt)|**82(Mbt2)|**1(Msp1)|**2(Msp2)|**3(Msp3)|**4(Msp4)|**9(Mpp)|(Mpli))

OutboundCallRoute: {(Msp2):sp2},{([19]900xxxxxxx):},{(<##:>):li},{(<#:>):ph2},{(<**70:>(Mli)):li},{(<**82:>(Mbt2)):bt2},{(<**81:>(Mbt)):bt},{(<**8:>(Mbt)):bt},{**0:aa},{***:aa2},{(<**1:>(Msp1)):sp1},{(<**2:>(Msp2)):sp2},{(<**3:>(Msp3)):sp3},{(<**4:>(Msp4)):sp4},{(<**9:>(Mpp)):pp},{(Mpli):pli}

Voice Services -> SP1 Service -> X_NoRegNoCall: Checked

Voice Services -> SP3 Service -> X_NoRegNoCall: Checked

Physical Interfaces -> Phone1 Port -> PrimaryLine: Trunk Group 1

Voice Service -> Gateways and Trunk Groups -> Trunk Group 1
TrunkList: sp1,sp3,sp4
DigitMap: ((Msp1)|9xxxxxxxxxx|9xxxxxxx)
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: jadog on December 15, 2018, 04:43:04 PM
Thank you. My apologies for not posting the ITSP C DigitMap. SP3 is a Google number that I just added. I wanted it to be setup similar to SP4 except that I would dial "8" to get to SP3. More on that in a moment.

I tried your recommended configuration without the Trunk configuration as I wanted to see if it would work without that additional variable. Here is what I found.

With ITSP A-D and the Phone Port DigitMap and OutboundCallRoute configured per your guide, I got a message that there was no route available when trying the "9" prefix. So then I put everything back and just started with just one step at a time. With the ITSP A, I see that you removed the (Mipd)|[^*#]@@. from the map. It seems this must be important as the "9" doesn't appear to work without it for some reason.

Also, your modified outbound call route seemed to deliver the same message, so I set my previous back in place with a slight tweak to accomodate what I had meant to add in initially which you spotted as a duplicate for SP4 (bolded below).

So when I added that back to ITSP A, with your Phone Port DigitMap, all seems to be working when dialing "9" or **4. I then proceeded with the Trunk setup for failover.

When I set as "Physical Interfaces -> Phone1 Port -> PrimaryLine: Trunk Group 1", there is no dial tone. Just silence. I set back to "SP1 Service" again.

So here is my updated configuration - I bolded what I added on top of your recommendation:

ITSP A: (*xx|1xxxxxxxxxx|911|933|<1260>[2-9]xxxxxx|<1>[2-9]xxxxxxxxx|011xx.S3|*21|*50xxxx|*51xxxx|*52xxxx|*53xxxx|*54|*6[013569]|*6[27]xx.|*77|*[789]2xx.|*73|*74[0-1][0-9]*xxxxxxxxxx|*75[0-1][0-9]|*8[137]|90xxxx|*93|*96|xx.|(Mipd)|[^*]@@.)

ITSP B: (01136[237]0xx.)

ITSP C: (<8:1>xxxxxxxxxx|<8:1260>xxxxxxx|1xxxxxxxxxx|<1>[2-9]xxxxxxxxx|<1260>[2-9]xxxxxx|011xx.)

ITSP D: (<9:1>xxxxxxxxxx|<9:1260>xxxxxxx|1xxxxxxxxxx|<1>[2-9]xxxxxxxxx|<1260>[2-9]xxxxxx|011xx.)

Phone Port DigitMap: ([1-9]S9|[1-9][0-9]S9|911|9xxxxxxxxxx|9xxxxxxx|8xxxxxxxxxx|8xxxxxxx|**0|***|#|##|**70(Mli)|**8(Mbt)|**81(Mbt)|**82(Mbt2)|**1(Msp1)|**2(Msp2)|**3(Msp3)|**4(Msp4)|**9(Mpp)|(Mpli))

OutboundCallRoute: {(Msp2):sp2},{911:sp1},{933:sp1},{([19]900xxxxxxx):},{(<9:1>xxxxxxxxxx|<9:1260>xxxxxxx):sp4},{(<8:1>xxxxxxxxxx|<8:1260>xxxxxxx):sp3},{([1-9]x?*(Mpli)):pp},{(<##:>):li},{(<#:>):ph2},{(<**70:>(Mli)):li},{(<**82:>(Mbt2)):bt2},{(<**81:>(Mbt)):bt},{(<**8:>(Mbt)):bt},{**0:aa},{***:aa2},{(<**1:>(Msp1)):sp1},{(<**2:>(Msp2)):sp2},{(<**3:>(Msp3)):sp3},{(<**4:>(Msp4)):sp4},{(<**9:>(Mpp)):pp},{(Mpli):pli}

**************************

Not sure why it doesn't seem to be working like you expected. However, I've tested the "8" and "9" as well as **3 and **4 and these now seem to be working. Interestingly, whether or not I use the above Phone Port DigitMap or leave the ObiTalk Default checked, it makes no difference.  Lastly, the delay for 7 and 10 digit calls are still taking 5 seconds before connecting (ringing). The delay when using "8" or "9" as a prefix before a number causes a 7 second delay. Is there a way to shorten this? All in all, this is getting exciting!
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: azrobert on December 15, 2018, 09:07:16 PM
Quote from: jadog on December 15, 2018, 04:43:04 PM
I tried your recommended configuration without the Trunk configuration as I wanted to see if it would work without that additional variable.

Trunk groups use a different method for routing calls, so you can't test my suggested configuration without the Trunk Group definition. Try again with the TG1 definition.

The following config should reduce the delay by 2 seconds.

You can test the failover by changing the SP1 password, so it won't register. Now place a call. It should get routed to SP3.

ITSP A: (*xx|1xxxxxxxxxx|911|933|<1260>[2-9]xxxxxx|<1>[2-9]xxxxxxxxx|011xx.S3|*21|*50xxxx|*51xxxx|*52xxxx|*53xxxx|*54|*6[013569]|*6[27]xx.|*77|*[789]2xx.|*73|*74[0-1][0-9]*xxxxxxxxxx|*75[0-1][0-9]|*8[137]|90xxxx|*93|*96)

ITSP B: (01136[237]0xx.)

ITSP C: (<8:1>xxxxxxxxxx|<8:1260>xxxxxxx|1xxxxxxxxxx|<1>[2-9]xxxxxxxxx|<1260>[2-9]xxxxxx|011xx.)

ITSP D: (<9:1>xxxxxxxxxx|<9:1260>xxxxxxx|1xxxxxxxxxx|<1>[2-9]xxxxxxxxx|<1260>[2-9]xxxxxx|011xx.)

Phone Port DigitMap: ([1-9]S9|[1-9][0-9]S9|911|**0|***|#|##|**70(Mli)|**8(Mbt)|**81(Mbt)|**82(Mbt2)|**1(Msp1)|**2(Msp2)|**3(Msp3)|**4(Msp4)|**9(Mpp)|(Mpli))

OutboundCallRoute: {(Msp2):sp2},{([19]900xxxxxxx):},{(<##:>):li},{(<#:>):ph2},{(<**70:>(Mli)):li},{(<**82:>(Mbt2)):bt2},{(<**81:>(Mbt)):bt},{(<**8:>(Mbt)):bt},{**0:aa},{***:aa2},{(<**1:>(Msp1)):sp1},{(<**2:>(Msp2)):sp2},{(<**3:>(Msp3)):sp3},{(<**4:>(Msp4)):sp4},{(<**9:>(Mpp)):pp},{(Mpli):pli}

Voice Services -> SP1 Service -> X_NoRegNoCall: Checked

Voice Services -> SP3 Service -> X_NoRegNoCall: Checked

Physical Interfaces -> Phone1 Port -> PrimaryLine: Trunk Group 1

Voice Service -> Gateways and Trunk Groups -> Trunk Group 1
TrunkList: sp1,sp3,sp4
DigitMap: ((Msp1)|8xxxxxxxxxx|8xxxxxxx|9xxxxxxxxxx|9xxxxxxx)
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: jadog on December 18, 2018, 04:31:37 PM
Ok, so I took your advice and I configured everything exactly as you listed. With the Trunk Group 1 enabled for the Primary Line, I get no dial tone. I push the talk button on my handset and I only hear a faint click on the line. I even tried rebooting the OBi a few times but still nothing. As soon as I change the Primary Line setting back to "SP1 Service", I get a dial tone. Maybe I don't understand completely how the Trunk Group works, but I thought that as long as SP1 is the first value in the TrunkList, it should look there first. Maybe we can start fresh with smaller steps and then add as we go?

Having the phone setup to use Trunks for a failover is certainly not a requirement. It would be cool, but I don't have to have it. You have already helped me so much and I have everything that I originally requested.
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: azrobert on December 18, 2018, 06:32:35 PM
I never heard of a problem like this. You should get dial tone even if there are errors in the config. Maybe this is a firmware bug.

Try changing the Trunk Group 1 DigitMap to the following just to see if you get dial tone:
(1xxxxxxxxxx)
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: jadog on December 24, 2018, 05:33:24 AM
I changed the DigitMap to your recommendation and there was still no dial tone. I think you are likely correct and that it is related to the firmware. Of note, I am currently using firmware version 3.2.2 (Build: 5921EX). I know there is a later version (I believe 5998), but because I use PhonePower as my primary SP, I have decided not to update. I've read others having issues with the later version and having to roll back.

Unless you know of another way, I think I will just sit tight for now and wait for a future firmware that plays nice with PhonePwer before I try again. By the way, if I create a backup of all my settings, then update the firmware, when I restore will it restore the previous firmware? I would assume not.
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: drgeoff on December 24, 2018, 09:40:55 AM
Quote from: jadog on December 24, 2018, 05:33:24 AM
I changed the DigitMap to your recommendation and there was still no dial tone. I think you are likely correct and that it is related to the firmware. Of note, I am currently using firmware version 3.2.2 (Build: 5921EX). I know there is a later version (I believe 5998), but because I use PhonePower as my primary SP, I have decided not to update. I've read others having issues with the later version and having to roll back.

Unless you know of another way, I think I will just sit tight for now and wait for a future firmware that plays nice with PhonePwer before I try again. By the way, if I create a backup of all my settings, then update the firmware, when I restore will it restore the previous firmware? I would assume not.
1. I think you are confused between 5898 and 5998.

2. Restoring settings from a backup file does not change the firmware.
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: jadog on December 24, 2018, 09:56:34 AM
Ah. You're right. So I am on the latest firmware version then. So apparently there is a bug with the trunks. I guess I'll just have to wait for a future release before trying again.
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: azrobert on December 24, 2018, 12:42:48 PM
I'm guessing it doesn't like the Primary Line set to TG1.
Using my last posted config change following:

Physical Interfaces -> Phone1 Port -> PrimaryLine: SP1 Service

The last rule in the OutboundCallRoute change it from: {(Mpli):pli} To: {(Mpli):tg1}

If this fixes the dial tone then everything should work except 8 and 9 prefix numbers.

To fix 8 and 9 do this:

Change the last rule in the Phone DigitMap to: (Mtg1)
Change the last rule in the OutboundCallRoute to: {(Mtg1):tg1}
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: jadog on January 03, 2019, 01:56:45 PM
Sorry for the delay, the holidays were crazy  :o. Changing the OutboundCallRoute from: {(Mpli):pli} To: {(Mpli):tg1} gave me dialtone! And I was able to successfully place a call. What a rock star!

I'm unclear on the additional instructions though for the 8 and 9 prefix numbers.

QuoteTo fix 8 and 9 do this:

Change the last rule in the Phone DigitMap to: (Mtg1)
Change the last rule in the OutboundCallRoute to: {(Mtg1):tg1}

Can you confirm I need to make this change under the Phone 1 interface? I already changed the last rule in the OutboundCallRoute to {(Mpli):tg1}. Are you saying I should change it again to {(Mtg1):tg1}?
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: azrobert on January 03, 2019, 08:13:38 PM
Your problem is probably caused by corrupted memory in the OBi202. I had you make a minimal change to see if my theory was correct. You now need to make a couple more changes to fix the 8 and 9 prefixes.

Phone1 Port DigitMap: ([1-9]S9|[1-9][0-9]S9|911|**0|***|#|##|**70(Mli)|**8(Mbt)|**81(Mbt)|**82(Mbt2)|**1(Msp1)|**2(Msp2)|**3(Msp3)|**4(Msp4)|**9(Mpp)|(Mtg1))

Phone1 Port OutboundCallRoute: {(Msp2):sp2},{([19]900xxxxxxx):},{(<##:>):li},{(<#:>):ph2},{(<**70:>(Mli)):li},{(<**82:>(Mbt2)):bt2},{(<**81:>(Mbt)):bt},{(<**8:>(Mbt)):bt},{**0:aa},{***:aa2},{(<**1:>(Msp1)):sp1},{(<**2:>(Msp2)):sp2},{(<**3:>(Msp3)):sp3},{(<**4:>(Msp4)):sp4},{(<**9:>(Mpp)):pp},{(Mtg1):tg1}

If everything seems to be working, you can test failover by disabling SP1 or change the password so registration fails. Now make a call and it should failover to SP3.

Voice Services -> SP1 Service -> Enable: unchecked
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: jadog on January 17, 2019, 02:59:15 PM
Bingo! I am very stoked! This is working just as you said after I made the recommended changes. With SP1 disabled, it rolls to SP3. Note, I updated the OutboundCallRoute to the below, otherwise I was unable to complete a call when I dialed the 8 or 9 prefix to get out to SP3 and SP4 respectively. I also updated to force 800 toll free calls to go to SP4.

{(Msp2):sp2},{911:sp1},{933:sp1},{([19]900xxxxxxx):},{(<9:1>xxxxxxxxxx|<9:1260>xxxxxxx|18(00|88|77|66|55|44)xxxxxxx|<1>8(00|88|77|66|55|44)xxxxxxx):sp4},{(<8:1>xxxxxxxxxx|<8:1260>xxxxxxx):sp3},{([1-9]x?*(Mpli)):pp},{(<##:>):li},{(<#:>):ph2},{(<**70:>(Mli)):li},{(<**82:>(Mbt2)):bt2},{(<**81:>(Mbt)):bt},{(<**8:>(Mbt)):bt},{**0:aa},{***:aa2},{(<**1:>(Msp1)):sp1},{(<**2:>(Msp2)):sp2},{(<**3:>(Msp3)):sp3},{(<**4:>(Msp4)):sp4},{(<**9:>(Mpp)):pp},{(Mpli):tg1}

Let me know if I should make any tweaks to the changes I made. It takes several seconds to connect to SP4, but I can live with that.
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: azrobert on January 19, 2019, 11:20:03 AM
Try:

{(Msp2):sp2},{911:sp1},{933:sp1},{([19]900xxxxxxx):},{(18(00|88|77|66|55|44)xxxxxxx):sp4},{([1-9]x?*(Mpli)):pp},{(<##:>):li},{(<#:>):ph2},{(<**70:>(Mli)):li},{(<**82:>(Mbt2)):bt2},{(<**81:>(Mbt)):bt},{(<**8:>(Mbt)):bt},{**0:aa},{***:aa2},{(<**1:>(Msp1)):sp1},{(<**2:>(Msp2)):sp2},{(<**3:>(Msp3)):sp3},{(<**4:>(Msp4)):sp4},{(<**9:>(Mpp)):pp},{(Mtg1):tg1}

You missed changing Mpli to Mtg1. This caused 8 & 9 prefixes to fail.

This is how a Trunk Group works:

(Mtg1):tg1 will route any number matching the TG1 digit map to TG1
When the Trunk Group gets control it processes the Trunk List left to right trying to route the call.
If the call fails OR the number doesn't match the trunk digit map the trunk is bypassed and processing skips to the next trunk in the list.

If you dial an 8 prefix number, it doesn't match the SP1 digit map and processing skips to SP3.
The number matches the SP3 digit map and is then routed to SP3.

You had (Mpli):tg1
(Mpli) doesn't contain a rule for 8 or 9 prefixes, so the call wasn't routed to TG1.
________________

The Phone digit map validates the dialed number.
The TG1 and SP1 digit maps are included by (Mtg1) and (Msp1)
When you dial a 10 digit number, rule <1>[2-9]xxxxxxxxx in (Msp1) validates it and adds a "1" prefix.
The outbound call route will see an 11 digit number.
The 10 digit 800 rule was redundant and removed.
_________________

I don't see anything that will cause a delay on SP4. I'm guessing it's the GV account.
________________

You can define a free tollfree provider as a Voice Gateway for 800 numbers.
VGs share an SP trunk with another provider.
You must use a non-GV SP for the VG.

Voice Service -> Gateways and Trunk Groups -> Voice Gateway1
Name: Tollfree
AccessNumber: sp1(tollfree.alcazarnetworks.com)
DigitMap: (18(00|88|77|66|55|44)xxxxxxx)
AuthUserID: 8005551212

AuthUserID Will be used for the outbound CallerID
You are sharing SP1 with Phonepower.
This might eliminate the delay for tollfree numbers.

{(Msp2):sp2},{911:sp1},{933:sp1},{([19]900xxxxxxx):},{(Mvg1):vg1},{([1-9]x?*(Mpli)):pp},{(<##:>):li},{(<#:>):ph2},{(<**70:>(Mli)):li},{(<**82:>(Mbt2)):bt2},{(<**81:>(Mbt)):bt},{(<**8:>(Mbt)):bt},{**0:aa},{***:aa2},{(<**1:>(Msp1)):sp1},{(<**2:>(Msp2)):sp2},{(<**3:>(Msp3)):sp3},{(<**4:>(Msp4)):sp4},{(<**9:>(Mpp)):pp},{(Mtg1):tg1}
________________

You can take this one step further and setup a Trunk Group for tollfree numbers.

Service Providers -> ITSP Profile A SIP -> TimerB: 8000

Voice Service -> Gateways and Trunk Groups -> Trunk Group 2
TrunkList: vg1,sp4
DigitMap: (18(00|88|77|66|55|44)xxxxxxx)

{(Msp2):sp2},{911:sp1},{933:sp1},{([19]900xxxxxxx):},{(Mtg2):tg2},{([1-9]x?*(Mpli)):pp},{(<##:>):li},{(<#:>):ph2},{(<**70:>(Mli)):li},{(<**82:>(Mbt2)):bt2},{(<**81:>(Mbt)):bt},{(<**8:>(Mbt)):bt},{**0:aa},{***:aa2},{(<**1:>(Msp1)):sp1},{(<**2:>(Msp2)):sp2},{(<**3:>(Msp3)):sp3},{(<**4:>(Msp4)):sp4},{(<**9:>(Mpp)):pp},{(Mtg1):tg1}

If a tollfree call fails on VG1, it will failover to SP4.

If a call isn't completed within the value of TimerB it will failover.
The default is 32 seconds.
I changed it to 8 seconds.
You don't want to make this value too small, you might get false failovers.

After you get this working, you can test failover by making this change:
Voice Service -> Gateways and Trunk Groups -> Voice Gateway1
Name: Tollfree
AccessNumber: sp1(192.168.1.199)

Dial a tollfree number and it will failover to SP4 after 8 seconds.
Title: Re: Outbound call routing doesn't appear to be working properly
Post by: jadog on January 19, 2019, 12:57:41 PM
Thanks for the incredibly detailed explanation! I replaced the Mpli with Mtg1 as you suggested. However, removing the line you stated as redundant prevented me from making 800 calls without the 1. So I added back again.

<1>8(00|88|77|66|55|44)xxxxxxx

Let me know if I misunderstood anything. Otherwise, I think I'm going to let perfect alone!  ;D

Thanks so much for all your help and time. You are a true asset to this forum!