[asterisk-users] ODBC connection failure - can it be fatal?
Antony.Stone at asterisk.open.source.it
Tue Jun 23 08:19:04 CDT 2020
I have an Asterisk 13.14.1 setup which uses ODBC to write CEL and CDR records.
The connection to my database server depends on a VPN tunnel being up, and if
Asterisk starts before that tunnel is functional, I get messages such as the
following in the Asterisk log file:
[2020-06-23 10:40:22.384335] delta WARNING: res_odbc.c:958 in
odbc_obj_connect: res_odbc: Error SQLConnect=-1 errno=1045 [unixODBC]
[ma-3.0.6]Access denied for user 'Trimble'@'delta.example.net' (using
The problem is that this is not a fatal error as far as Asterisk is concerned,
so it continues to start up to the point where I get:
[2020-06-23 10:40:26.076377] delta VERBOSE: asterisk.c:4791 in
asterisk_daemon: Asterisk Ready.
and the system then processes calls without creating any CEL or CDR entries.
Is there any way I can tell Asterisk that an ODBC connection problem is a
fatal error, so please shut down and don't process any calls (I have an HA
setup so another machine will handle any calls which needs processing; I just
don't want to process calls without generating CDRs)?
"Can you keep a secret?"
"Well, I shouldn't really tell you this, but... no."
Please reply to the list;
please *don't* CC me.
More information about the asterisk-users