Odbc Connection Timeout Varable

Home » Asterisk Users » Odbc Connection Timeout Varable
Asterisk Users 12 Comments

Hi all Does anyone know of a variable that i could check to see if the reason func odbc didnt return results was because of a timeout error so i could play a audio file about that


12 thoughts on - Odbc Connection Timeout Varable

  • I would like to tell callers the system is down as apposed to saying no info in system when the system is up or saying the info in the system

  • Unless of course the database server is not running at all for some reason. Regards;

    —–Original Message—

  • right but that is the problem and i was wondering if there is way for asterisk to set a variable when that happens just like curl

  • It should not happen. I have a couple of Asterisk servers using the ODBC connection. I never ever had any problem with ODBC or the database. What database are you using?


  • well it should but this morning my database hosted at a remote location was down due to conditions at the remote site

    the question isnt if it should happen or not

    the questions is there a way for me to know that the odbc query retruned empty because of a connection timeout?

    in curl i could get that info is there a way also for odbc?

  • To just answer your question:

    No, there is no channel variable for this, nor anything in Asterisk that does this automatically.

    You would need to have something else monitoring your databases, and use it to inform Asterisk of the failure.