Outbound Failover from SIP to PSTN

Discussion in 'General' started by jnickel, Nov 21, 2008.

  1. jnickel

    Joined:
    Dec 7, 2007
    Messages:
    15
    Likes Received:
    0
    Hi everyone,

    I have Gafachi as my primary method of making long distance calls.

    I also have a partial T1 connected via a Sangoma card.

    Everything works fine...but the other day, I lost internet and no one could make long distance calls.

    Is there some way to make it such that if the internet is down, the system will fail back/over to the PSTN/T1 lines?

    I did add both the Gafachi trunk and the Zap (the T1) to the outgoing route for long distance, but I get the impression that it will only use the second entry once all channels have been used on the primary one.

    Jim
     
  2. Chilling_Silence

    Joined:
    Sep 23, 2008
    Messages:
    488
    Likes Received:
    0
    Yes, thats correct, or unless calls cannot be made out the first. IF calls cannot be made out any of the trunks you will get "All circuits are busy now, please try your call again later".
    Provided you've specified the T1 in the outbound route underneath the Gafachi trunk, then you should be fine.
    Have you tested dialing directly out the T1? Perhaps with an outbound route which only captures your Cellphone number? (Be sure to move it to the top of the list or it'll be captured by your other rules first).
    What if at one point you deliberately cut the internet to do a test, late one night perhaps? What happens?
     
  3. jnickel

    Joined:
    Dec 7, 2007
    Messages:
    15
    Likes Received:
    0
    When I cut the internet connection, I can make local calls (so the T1 is working as I have a outbound route for local calls after the long distance one and only the T1 is listed), however, I cannot make any long distance calls.

    So....I think what is happening is that it doesn't recognize that the the Gafachi trunk is down and continues to try that.

    Going back to the T1 doesn't seem to work. Is there something else I need to do?

    I only have 2 outbound routes. The first lists SIP/Gafachi as the 0 and the Zap/g0 as 1 and it has a dial pattern of 9|1.

    Then the second outbound route only has the Zap/g0 as 0 and has a dial pattern of 9|.


    Jim
     
  4. jnickel

    Joined:
    Dec 7, 2007
    Messages:
    15
    Likes Received:
    0
    If I simply disable the Gafachi trunk, then it uses the Zap trunk as I would expect.

    Are you sure that it is supposed to fall back to the Zap trunk if the internet connection is dead?

    Maybe it only falls back if the channels are full - which isn't really the case.

    Could I maybe use the "Monitor Trunk Failues" option with a AGI script to disable the Gafachi trunk if it is dead?

    If so...what would that script look like?

    Jim
     
  5. jgutierrez

    Joined:
    Feb 28, 2008
    Messages:
    5,737
    Likes Received:
    0
    It seems to me that on your sip truk configuration you have specied your sip register proxy using a hostname, something like host=sip.myprovider.com, I'll recommend you to use the ip instead of the hostname, as well at /etc/hosts wite down something like:
    200.59.84.26 sip.myprovider.com

    Try that, restart network services, and unplug your internet connection cable to see if the problem persists.
     

Share This Page