Cdr_adaptive_odbc - Unable to query database columns

Running Asterisk 16.5 (built from gerrit clone).

Problem relates to CDR and Adaptive ODBC module. It occurs when issuing a “core reload” in the CLI:

[2019-09-05 13:46:17] ERROR[8854]: cdr_adaptive_odbc.c:172 load_config: Unable to query database columns on connection ‘asterisk-db’. Skipping.

I’m recording CDR to MySQL via ODBC. On Asterisk load everything works fine but if I execute a “core reload” on the CLI, I am getting the error above. The effect is that CDR records stop being written. As a work around, I can execute “module reload” and CDRs are once again written.

Can anyone shed light on the possible cause of this error and what I can do to fix it.

Thanks, A

It might be that module load order is causing problems on reload. Can you try adding this near the top of /etc/asterisk/modules.conf ?

1 Like

great idea… I’ve updated my modules.conf and will monitor the restarts for 24 hours.

Thanks :slight_smile:

Glad that helped!

Related, there is a NOTE: in latest Asterisk 16 configs/samples/modules.conf about not using preload, so that is something to consider changing, until underlying auto-reload issues are addressed. Maybe adding a HOWEVER: ... would do it.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.