I have upgraded PBX to Asterisk 1.6.2.7
and now CDR files are not created. It looks that such logging is disabled:
Connected to Asterisk 1.6.2.7 currently running on pbx2 (pid = 5824)
Verbosity is at least 3
pbx2*CLI> cdr show status
pbx2*CLI>
Call Detail Record (CDR) settings
----------------------------------
Logging: Disabled
Mode: Simple
Asterisk shows that CDR modules are loaded:
pbx2*CLI> module show like cd
Module Description Use Count
cdr_manager.so Asterisk Manager Interface CDR Backend 0
cdr_csv.so Comma Separated Values CDR Backend 0
app_cdr.so Tell Asterisk to not maintain a CDR for 0
app_forkcdr.so Fork The CDR into 2 separate entities 0
func_cdr.so Call Detail Record (CDR) dialplan functi 0
cdr_custom.so Customizable Comma Separated Values CDR 0
6 modules loaded
How to enable creating CDR csv files?
We had to follow some more steps.
We needed some CDR logging ASAP and our AsteriskNOW server did not have modules for MySQL CDR logging. We would not install new packages in a running, highly requested production server, so we relied on CSV logging.
To enable it is easy. First, we edit
/etc/asterisk/cdr.conf
(if it does not exist, we create it) adding a[csv]
section. We added some more configuration on it as below, but apparently the important thing is to create the section.Then, we edited
/etc/asterisk/modules.conf
for loading thecdr_csv.so
module:For enabling the logging immediately without restarting Asterisk, we called
asterisk -vvvr
and loaded the module:Now every call is logged in
/var/log/asterisk/cdr-csv/Master.csv
.It took us some time to get it working. This page proved itself as a useful reference.
It seems there was bug in
Asterisk Now
. It needed/etc/asterisk/cdr.conf
which was absent.