CDR not working on freepbx + centos 7 install

Just installed freepbx + centos 7 install as per:
http://wiki.freepbx.org/display/FOP/Installing+FreePBX+13+on+CentOS+7

Two problems so far. Unable to support commercial modules, I know the issues and am not too concerned about it.

But the second problem is I cant access cdr reports. In Asterisk Logs it reports the following:

[2016-01-04 10:29:40] VERBOSE[4702] loader.c: Reloading module ‘res_odbc.so’ (ODBC resource)
[2016-01-04 10:29:40] VERBOSE[4702] config.c: Parsing ‘/etc/asterisk/res_odbc.conf’: Found
[2016-01-04 10:29:40] VERBOSE[4702] config.c: Parsing ‘/etc/asterisk/res_odbc_custom.conf’: Found
[2016-01-04 10:29:40] VERBOSE[4702] config.c: Parsing ‘/etc/asterisk/res_odbc_additional.conf’: Found
[2016-01-04 10:29:40] NOTICE[4702] res_odbc.c: Connecting asteriskcdrdb
[2016-01-04 10:29:40] WARNING[4702] res_odbc.c: res_odbc: Error SQLConnect=-1 errno=0 [unixODBC][Driver Manager]Can’t open lib ‘/usr/lib64/libmyodbc5.so’ : file not found
[2016-01-04 10:29:40] WARNING[4702] res_odbc.c: Failed to connect to asteriskcdrdb
[2016-01-04 10:29:40] NOTICE[4702] res_odbc.c: Registered ODBC class ‘asteriskcdrdb’ dsn->[MySQL-asteriskcdrdb]

Any help would be most welcome.

edit: Done a little digging and in odbcinst.ini there is reference to libmyodbc5.so in the line Driver64 = /usr/lib64/libmyodbc5.so. And on 32 bit system, not the one with the problem, libmyodcb5.so exists but its in /usr/lib.

So is reference to this file incorrect or is the file missing, and how could I put this right??

The error you are having is with unixODBC. There is no driver for MYSQL. You’ll have to lookup how to fix that as it’s outside the scope of Asterisk and FreePBX.

Hi tm1000,

Also can connect to the database:

MariaDB [asterisk]> \s

mysql Ver 15.1 Distrib 5.5.44-MariaDB, for Linux (x86_64) using readline 5.1

Connection id: 45
Current database: asterisk
Current user: root@localhost
SSL: Not in use
Current pager: stdout
Using outfile: ‘’
Using delimiter: ;
Server: MariaDB
Server version: 5.5.44-MariaDB MariaDB Server
Protocol version: 10
Connection: Localhost via UNIX socket
Server characterset: latin1
Db characterset: utf8
Client characterset: utf8
Conn. characterset: utf8
UNIX socket: /var/lib/mysql/mysql.sock
Uptime: 27 min 2 sec

Threads: 1 Questions: 767 Slow queries: 0 Opens: 63 Flush tables: 2 Open tables: 89 Queries per second avg: 0.472

From Freepbx logs I get: WARNING[3540] func_cdr.c: CDR requires a value (CDR(variable)=value)

Also see several lines as follows:

[2016-01-05 18:14:14] VERBOSE[3527] asterisk.c: Remote UNIX connection
[2016-01-05 18:14:14] VERBOSE[3743] asterisk.c: Remote UNIX connection disconnected

That doesn’t mean anything. You need to figure out why ODBC is missing the driver.

That being the missing libmyODBC5.so.

Right, I run a yum update last night and on checking the folder /usr/lib64 the libmyodbc5.so file is there, well sort of. This is whats there:

lrwxrwxrwx 1 root root 14 Jan 5 18:22 libmyodbc5.so -> libmyodbc5w.so

is this implying that libmyodbc5.so is pointing to libmyodbc5w.so

Update - cdr is now up and running. Thanks tm1000 for your help, you put me back on track.