<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body dir="auto"><div>The command he gave you was in Asterisk. Why do you not want to call it to try it?</div><div><br></div><div>Then you can fail over to the other trunk if the IAX link is down. <br><br><span style="font-family: UICTFontTextStyleBody; -webkit-text-size-adjust: auto;">Kind regards,</span><div><span style="font-family: UICTFontTextStyleBody; -webkit-text-size-adjust: auto;"><br></span></div><div><span style="font-family: UICTFontTextStyleBody; -webkit-text-size-adjust: auto;">Matt</span></div></div><div><br>On May 30, 2015, at 2:03 AM, Ashwin Surendran <<a href="mailto:Ashwin.Surendran@now-health.com">Ashwin.Surendran@now-health.com</a>> wrote:<br><br></div><blockquote type="cite"><div><span>Many Thanks Carlos, I was hoping to check whether the remote server is</span><br><span>available before I issue the dial in my dial plan.</span><br><span></span><br><span>Is there a better way to do it in asterisk without using unix commands?</span><br><span></span><br><span></span><br><span>Many Thanks,</span><br><span>Ashwin</span><br><span></span><br><span>On 5/30/15, 2:06 AM, "Carlos Chavez" <<a href="mailto:cursor@telecomabmex.com">cursor@telecomabmex.com</a>> wrote:</span><br><span></span><br><blockquote type="cite"><span>On 5/29/15 1:16 PM, Ashwin Surendran wrote:</span><br></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span>Hi,</span><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span>I have multiple Asterisk servers in various parts of the world all</span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span>connected using dedicated VPN¹s.</span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span>Each of these servers have iax and dahdi TRUNK configured on them.</span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span>Occasionally the VPN¹s fail.</span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span>What I want to be able to do is on my dial plan, use IAX if the asterisk</span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span>server can reach the remote server using the internet OR, use TRUNK only</span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span>if it can¹t use IAX.</span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span>Any ideas on how this can be implemented on the dial plan?</span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote><blockquote type="cite"><span>    Check the DIALSTATUS variable to see if the IAX trunk failed and</span><br></blockquote><blockquote type="cite"><span>then dial via DAHDI.</span><br></blockquote><blockquote type="cite"><span></span><br></blockquote><blockquote type="cite"><span><a href="https://wiki.asterisk.org/wiki/display/AST/Dial+Channel+Variables">https://wiki.asterisk.org/wiki/display/AST/Dial+Channel+Variables</a></span><br></blockquote><blockquote type="cite"><span></span><br></blockquote><blockquote type="cite"><span>--</span><br></blockquote><blockquote type="cite"><span>Telecomunicaciones Abiertas de México S.A. de C.V.</span><br></blockquote><blockquote type="cite"><span>Carlos Chávez</span><br></blockquote><blockquote type="cite"><span>+52 (55)9116-91161</span><br></blockquote><blockquote type="cite"><span></span><br></blockquote><blockquote type="cite"><span></span><br></blockquote><blockquote type="cite"><span>--</span><br></blockquote><blockquote type="cite"><span>_____________________________________________________________________</span><br></blockquote><blockquote type="cite"><span>-- Bandwidth and Colocation Provided by <a href="http://www.api-digital.com">http://www.api-digital.com</a> --</span><br></blockquote><blockquote type="cite"><span>New to Asterisk? Join us for a live introductory webinar every Thurs:</span><br></blockquote><blockquote type="cite"><span>              <a href="http://www.asterisk.org/hello">http://www.asterisk.org/hello</a></span><br></blockquote><blockquote type="cite"><span></span><br></blockquote><blockquote type="cite"><span>asterisk-users mailing list</span><br></blockquote><blockquote type="cite"><span>To UNSUBSCRIBE or update options visit:</span><br></blockquote><blockquote type="cite"><span>  <a href="http://lists.digium.com/mailman/listinfo/asterisk-users">http://lists.digium.com/mailman/listinfo/asterisk-users</a></span><br></blockquote><span></span><br><span>This email (and any attachments or hyperlinks within it) may contain information that is confidential, legally privileged or otherwise protected from disclosure. If you are not the intended recipient of this email, you are not entitled to use, disclose, distribute, copy, print, disseminate or rely on this email in any way. If you have received this email in error, please notify the sender immediately by telephone or email and destroy it, and all copies of it. Thank you for your cooperation.</span><br><span>-- </span><br><span>_____________________________________________________________________</span><br><span>-- Bandwidth and Colocation Provided by <a href="http://www.api-digital.com">http://www.api-digital.com</a> --</span><br><span>New to Asterisk? Join us for a live introductory webinar every Thurs:</span><br><span>               <a href="http://www.asterisk.org/hello">http://www.asterisk.org/hello</a></span><br><span></span><br><span>asterisk-users mailing list</span><br><span>To UNSUBSCRIBE or update options visit:</span><br><span>   <a href="http://lists.digium.com/mailman/listinfo/asterisk-users">http://lists.digium.com/mailman/listinfo/asterisk-users</a></span></div></blockquote></body></html>