News:

On Tuesday September 6th the forum will be down for maintenance from 9:30 PM to 11:59 PM PDT

Main Menu

Automatic switch between trunks when one becomes unavailable

Started by NewY, February 01, 2013, 12:26:59 AM

Previous topic - Next topic

NewY

hi, I use one Obi110 and one Linksys PAP2. My provider is callwithus. My obi110 SP1 is google and SP2 is callwithus. I use google to make domestic calls and use callwithus to make international calls. However, Callwithus' registration is not stable on Obi110 but is very stable on Linksys PAP2. So I hook PAP2's phone line to Obi110's line port as a backup. 

My questions is how to set up on Obi110 so that when i make international call with SP2 and SP2 fails to register with Callwithus, it automatically switches to PSTN port (here it is PAP2)?

My thinking is to set up outbound call route configuration. But each rule seems independent. Or I need to work on TrunkGroup?

Please help. Thanks.


xibai

I understand somebody posted similar questions here athttp://www.obitalk.com/forum/index.php?topic=2390.msg15480#msg15480.

However, my need is not to switch all calls to the primary line, but only international calls.

Thanks.

xibai

To make it clearer: I want to keep sp1 as my primary line, while have the ability to automatically switch between sp2 and PSTN. How to set up? Thanks.

ianobi

NewY,

I'm starting with some assumptions: I'm guessing that sp1 (GV) is your PrimaryLine and you dial **2 to get to Callwithus on OBi sp2 and **8 to get Callwithus via the OBi Line Port and the PAP2. What you would like to do is dial **2 and if Callwithus is failed on sp2, have the call automatically forward to the OBi Line Port.

Trunk Groups are the only way to create a "step-over failed/busy route" facility in an OBi. Please be aware that the OBi sometimes takes a few minutes to realise that it has lost registration with a Service Provider.

Something like this may work for you:

Physical Interfaces -> PHONE Port -> PrimaryLine: SP1 Service
Voice Service -> Auto Attendant -> PrimaryLine: SP1 Service

Physical Interfaces > Phone Port > DigitMap:
([1-9]x?*(Mpli)|[1-9]S9|[1-9][0-9]S9|911|**0|***|#|**1(Msp1)|**2(Mtg1)|**8(Mli)|**9(Mpp)|(Mpli))

Physical Interfaces > Phone Port > OutboundCallRoute
{([1-9]x?*(Mpli)):pp},{(<#:>|911):li},{**0:aa},{***:aa2},{(<**1:>(Msp1)):sp1},{(<**2:>(Mtg1)):tg1},{(<**8:>(Mli)):li},{(<**9:>(Mpp)):pp},{(Mpli):pli}

Voice Services > Gateways and Trunk Groups > Trunk Group1
TrunkList > sp2,li
DigitMap > ((Msp2)|(Mli))

There are other ways of arranging the trunk group, say by using **6 to access the trunk group, which would leave you free to choose sp2 via **2 when you wanted to. Any of my assumptions at the start of this post might be wrong, so let me know if you want to modify my suggestion.

Always with Trunk Groups, be very careful where 911 is being routed.


Ostracus

Quote from: ianobi on February 01, 2013, 06:28:07 AM
Trunk Groups are the only way to create a "step-over failed/busy route" facility in an OBi. Please be aware that the OBi sometimes takes a few minutes to realise that it has lost registration with a Service Provider.

Doesn't apply to the Obi100/110, but does X_NoRegNoCall shorten that process?

ianobi

xibai,

I think my reply to NewY does what you want: Keep sp1 as PrimaryLine, use sp2 for calls starting with **2, when sp2 fails or is busy divert those calls to PSTN.

Let me know if that's not ok for you.

ianobi

Ostracus,

The truth is I don't know! The only Obihai info seems to be:

QuoteAdded SP parameter X_NoRegNoCall, if enabled, do not allow incoming or outgoing calls on that SP service.

Seems more like a user enable/disable setting rather than an automatic test for registration. I don't have an OBi202 to test that function.

xibai

hi, ianobi,

No wonder you are marked as "hero member." Your help is greatly appreciated! I mixed my two accounts. NewY and Xibai are one person. So double thanks to you.

Your approach does make sense. However, I got a message "the number you dialed is rejected" when I intentionally make sp2 "register failed" to test the switch. Apparently, it did not automatically switch to LINE, which is I tested good.

Following is my configuration. Please have a look if you have time:

I call china (86) frequently so

General -> DigitMap>ITSP A
(<**2>[86]x.|*xx|1xxxxxxxxxx|<1607>[2-9]xxxxxx|<1>[2-9]xxxxxxxxx|011xx.|xx.|(Mipd)|[^*]@@.)

PhonePort: DigitMap
([1-9]x?*(Mpli)|[1-9]S9|[1-9][0-9]S9|911|**0|***|#|**1(Msp1)|**2(Mtg2)|**8(Mli)|**9(Mpp)|(Mpli))

PhonePort:OutboundCallRoute
{([1-9]x?*(Mpli)):pp},{(<#:>|911):li},{**0:aa},{***:aa2},{(<**1:>(Msp1)):sp1},{(<**2:>(Mtg2)):tg2},{(<**8:>(Mli)):li},{(<**9:>(Mpp)):pp},{(Mpli):pli}

GateWays & TrunkGrps
TrunkGroup2
TrunkList: sp2,li,sp1
DigitMap: ((Msp2)|(Mli)|(Msp1))

I setup a trunkgroup 2, which includes three channels. My intention is that since both sp2 and Line actually use same callwithus. If callwithus's service down, it will switch to google to make international calls, even though google is a bit expensive.

Let me know where I did wrong. Again, thanks.


ianobi

QuoteHowever, I got a message "the number you dialed is rejected" when I intentionally make sp2 "register failed" to test the switch.

This seems to indicate that something went out to a service provider. Please look in Status > Call History on your OBi web page to see what you dialled and where the number routed to. I'm assuming that normally you can dial Callwith us via **2 or **8 when all is working normally.

This rule <**2>[86]x. should be written as <**2>86x. Using [86] means 8 or 6. The rule probably worked ok as the numbers started with an 8 anyhow.


QuoteTrunkGroup2
TrunkList: sp2,li,sp1
DigitMap: ((Msp2)|(Mli)|(Msp1))
There is a problem here. The first part should work ok. If sp2 is failed then calls should go to line. However, if Callwithus service is down, that will not make the OBi Line Port fail. So long as the OBi110 sees the voltage around 50v from the PAP2's Phone Port, it will assume all is ok.


xibai

ianobi,

Thanks for your prompt response.

1. here is what I got from Call Status when the call was rejected:

Call 1                    Terminal 1                    Terminal 2
Terminal ID             PHONE 1                      Announcement 1
State                    Connected                    Connected
Peer Number           **21(plus my home number)
Direction                Outbound                      Inbound

2. thanks for correcting the digitmap.

3. I will delete sp1 in trunk group 2. You are right. Thanks.

so what could be wrong with the automatic switch?

ianobi

We really need to see Status > Call History after a call has failed. This can only be seen in your OBi web page. Dial ***1 to get the ip address, put that in your browser. To log in the User Name and password will be "admin".

Call History cannot be seen in the OBi Expert Configuration pages.

hwittenb

xibai,

Although it looks to me like the Trunk approach should work, CallWithUs does not require registration to make an outgoing call.  You can have the SP2 setup to not register and still make calls with CallWithUs over SP2.  The OBi will show an SP2 status of Registration Not Required.  If you do not have incoming calls from a DID with CallWithUs I would try that setting (X_RegisterEnable unchecked). 

Maybe the problem has only to do with the Registration sip sequence failing.  It doesn't make sense that you could make calls with a PAP2 and not the OBi when both are behind the same router unless it has something to do with the sip Registration itself.

ianobi

hwittenb,

Thanks for the useful info. I agree the best approach is to fix the problem with callwithus in the OBi.

Looks like it is going to be difficult to make sp2 "fail" in these circumstances.

xibai

thanks you guys,

Here is what I got from the web:

Terminal ID        Phone1                                         SP2
Peer Number      **21(plus ten digits local number)     the ten digits local number
Direction            Outbound                                     Outbound
                                                                          End call (407 proxy authentication required)

to hwittenb, the reason I can not make call through sp2 is because I Intentionally make the registration by putting a wrong password so that I can test the autonomic switch from sp2 to LINE. But hwittenb helps me since I can disable the registration so that incoming calls only routes to PAP2 then to Obi11o LINE to avoid conflict.

By the way, <**2>86x. is better put under the SP1 or phone port? Putting into phone port may be more logoic?

ianobi

As you can see your call went to callwithus on sp2 and then failed due to wrong password. I cannot see a way to make the OBi110 see this route as failed, maybe hwittenb can suggest a way forward.

<**2>86x. is in the correct place. By putting it in your PrimaryLine DigitMap you achieve automatic routing of calls to sp2.

xibai

Thanks,ianobi.

I misunderstood hwittenb's last post. It happened quite frequently that callwithus fails with Obi110 while stable with PAP2. it is weird. Also I have incoming call from other callwithus internal numbers.

So anyway to make obi110 knows when sp2 fails and then automatically switch to LINe?

ianobi

I cannot see a way to make the OBi110 see this route as failed, as registration of the OBi110 is not required, it does not know if anything has failed.

Try to compare settings with the PAP2 and OBi110 to see why OBi110 is less reliable.

If you want to give up on the callwithus via OBi sp2, you could change <**2>86x. to <**8>86x. so making all calls starting with 86 go to the OBi110 Line Port and PAP2 callwithus. This would free up sp2 for another service provider if needed.

xibai

Thanks, ianobi. You help a lot.

Now I just wonder what is the purpose of trunkgroup if it did not serve automatic switch.

QBZappy

Owner of the 1st OBi110/100 units in service in Canada & South America. 1st OBi202 on my street. 1st OBi1032 in Montreal.

ianobi

xiabi,

I agree, you really do not need a trunk group in this situation. Your original setup is ok for what you need. Use <**2>86x. or <**8>86x. depending on where you want to send "86" calls.


QBZappy,

The problem here is the OBi simply will never know that sp2 has failed, so it cannot "failover" to another trunk.