I have FreePBX 13.0.191.11 with Asterisk 13.12.1.
I can’t enable queue_log to write to database (mysql), i want to log queues to files and database. Log to files works ok. I try out many queue_log table structures and options to make it works but with no success.
Current configuration:
File /etc/asterisk/logger_general_custom.conf
queue_adaptive_realtime = yes
queue_log_to_file = yes
queue_log => odbc,asteriskcdrdb,queue_log
File res_odbc.conf
#include res_odbc_custom.conf
#include res_odbc_additional.conf
File res_odbc_additional.conf
[asteriskcdrdb]
enabled=>yes
dsn=>MySQL-asteriskcdrdb
pooling=>no
limit=>1
pre-connect=>yes
username=>freepbxuser
password=>password123
database=>asteriskcdrdb
mysql table:
CREATE TABLE queue_log
(
id
bigint(255) unsigned NOT NULL AUTO_INCREMENT,
time
varchar(26) NOT NULL DEFAULT ‘’,
callid
varchar(40) NOT NULL DEFAULT ‘’,
queuename
varchar(20) NOT NULL DEFAULT ‘’,
agent
varchar(20) NOT NULL DEFAULT ‘’,
event
varchar(20) NOT NULL DEFAULT ‘’,
data
varchar(100) NOT NULL DEFAULT ‘’,
data1
varchar(40) NOT NULL DEFAULT ‘’,
data2
varchar(40) NOT NULL DEFAULT ‘’,
data3
varchar(40) NOT NULL DEFAULT ‘’,
data4
varchar(40) NOT NULL DEFAULT ‘’,
data5
varchar(40) NOT NULL DEFAULT ‘’,
created
timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
PRIMARY KEY (id
),
KEY queue
(queuename
),
KEY event
(event
)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
localhost*CLI> module show like mysql
Module Description Use Count Status Support Level
app_mysql.so Simple Mysql Interface 0 Running deprecated
res_config_mysql.so MySQL RealTime Configuration Driver 0 Running extended
2 modules loaded
localhost*CLI> module show like odbc
Module Description Use Count Status Support Level
cdr_adaptive_odbc.so Adaptive ODBC CDR backend 0 Running core
cdr_odbc.so ODBC CDR Backend 0 Not Running extended
cel_odbc.so ODBC CEL backend 0 Running core
func_odbc.so ODBC lookups 0 Not Running core
res_config_odbc.so Realtime ODBC configuration 0 Running core
res_odbc.so ODBC resource 0 Running core
res_odbc_transaction.so ODBC transaction resource 0 Running core
7 modules loaded
localhost*CLI> module show like queue
Module Description Use Count Status Support Level
app_queue.so True Call Queueing 3 Running core
1 modules loaded
In console and log i had no errors or warnings linked with queue_log or mysql.
Database connection is ok. Anyone has working configuration with queue_log in database?
I was using it at older version freepbx at it was working fine.