How do I keep the trunk alive

Get help with installing and running AsteriskNOW.

Moderators: Moderator, Support

How do I keep the trunk alive

Postby mike_b » Thu May 14, 2015 7:31 am

Is there any way to have Asterisk check that the trunk is alive and either reconnect or at least send a message?
My problem is that I have my PC and network on UPS power backups, so everything runs fine through a brownout or a short power loss. But every time that happens, it seems that I lose connection to the ISP. It is typically not a big deal, as everything just reconnects automatically after the connection is back, except the trunk connection. If I notice the outage, I usually simply reboot my asterisk box and the trunk is back on (is there a better way to re-establish the trunk)? But sometimes, for example if the power outage happens at night, I don't know, and I find out when I try to make a call. Or when people call me on my cellphone and ask why my number has been disconnected ...
So, Is there a way for Asterisk to monitor the trunk status and initiate a re-connect if it is lost or a reboot? Or at a minimum send me a message that something is wrong?
mike_b
Newsterisk
 
Posts: 17
Joined: Fri Jul 29, 2011 8:28 pm

Re: How do I keep the trunk alive

Postby navaismo » Thu May 14, 2015 9:07 am

You can qualify your trunk, then create a script to check the status of the qualify IF UNREACHABLE or UNKNOW then you just send the command
Code: Select all
asterisk -rx 'sip reload'
You dont need to reboot the server.
navaismo
Salt of the Asterisk
 
Posts: 1610
Joined: Mon Dec 07, 2009 1:30 pm
Location: Mexico City, Mexico

Re: How do I keep the trunk alive

Postby mike_b » Thu May 14, 2015 11:46 am

Thank you , navaismo, that sound like it is exactly what I need.

How do I "qualify" the trunk, and where can I find how to write that script?
mike_b
Newsterisk
 
Posts: 17
Joined: Fri Jul 29, 2011 8:28 pm


Return to AsteriskNOW Support

Who is online

Users browsing this forum: No registered users and 1 guest