CDR refuses to populate


(Les) #1

I’ve recently loaded a docker image of freepbx 15 asterisk 16, configured trunks, extensions, etc. everything works except CDR. So from my previous freepbx 15 installation (virtual machine) I backed up the CDRs only and restored on the docker container. The old entries are visible but no new entries are made.

Looking through the log I saw the following errors:

[2020-09-15 19:46:48] NOTICE[328] cdr.c: CDR simple logging enabled.
2297[2020-09-15 19:46:48] WARNING[328] cdr_manager.c: Failed to load configuration file. Module not activated.
2298[2020-09-15 19:46:48] WARNING[328] cdr_sqlite3_custom.c: Failed to load configuration file. Module not activated.
2299[2020-09-15 19:46:48] ERROR[328] loader.c: Error loading module ‘cdr_adaptive_odbc.so’: libodbc.so.2: cannot open shared object file: No such file or directory
2300[2020-09-15 19:46:48] ERROR[328] loader.c: Error loading module ‘cdr_odbc.so’: libodbc.so.2: cannot open shared object file: No such file or directory
2301[2020-09-15 19:46:48] ERROR[328] loader.c: cdr_manager declined to load.
2302[2020-09-15 19:46:48] ERROR[328] loader.c: cdr_csv declined to load.
2303[2020-09-15 19:46:48] ERROR[328] loader.c: cdr_sqlite3_custom declined to load.

I do see cdr_adaptive_odbc.so cdr_csv.so cdr_custom.so cdr_manager.so cdr_sqlite3_custom.so in
/usr/lib/asterisk/module.

Any ideas what could be causing this?


#2

My guess is that you have incompletely set up your odbc modules.

(Docker is a very imperfect device to run all of FreePBX/Asterisk/Mysql/Apache/ on, it’s just not designed to be used that way)


(Les) #3

ok, thanks for the feedback. I’ll try a different image.


#4

Before you hurt yourself unnecessarily


(Les) #5

you were correct. the image was missing libodbc, I’ll post the command in case anyone else has similar issues.

apt update
apt install libodbc1 odbcinst odbcinst1debian2