CDR not working after FreePBX 13 to 14 upgrade

Upgrade went fine, system is operational. However CDR data is no longer being updated, data is present from before the upgrade. Not sure where to begin troubleshooting. I can restore the VM to FreePBX 13 but I wanted to figure out why this might have failed and see if I can just stay with 14 since otherwise the upgrade went okay.

cdr show status from the CLI gives this:

Call Detail Record (CDR) settings
----------------------------------
  Logging:                    Enabled
  Mode:                       Simple
  Log unanswered calls:       No
  Log congestion:             No

* Registered Backends
  -------------------
(none)

Hi Mike!

This is one of the problems I had with my upgrade (which I did at the same time as you initially did), see

and the ticket it refers to…

I could see the old data but nothing new was getting added to it…

Good luck and have a nice day!

Nick

Thanks for the reply… I have an odbc.ini so I don’t think your post applies to my situation. I compared my odbc.ini and odbc.ini.rpmsave and they are identical.

No problem, I wish it was that simple…

Similar problem, different cause…

Do you have anything interesting in your logs like what I had in mine?

ie

2017-08-07 20:47:09] WARNING[11637] res_odbc.c: res_odbc: Error SQLConnect=-1 errno=0 [unixODBC][Driver Manager]Data source name not found, and no default driver specified
[2017-08-07 20:47:09] WARNING[11637] cel_odbc.c: No such connection ‘asteriskcdrdb’ in the ‘cel’ section of cel_odbc.conf. Check res_odbc.conf.

There’s probably a clue in there as to what is wrong…

You might also want to check if there there are any other interesting rpmsave files… (I have a few on my working system but nothing concerning but it might not be the case for you…

(If you use locate don’t forget to run /etc/cron.daily/mlocate the first time to reindex everything…)

Good luck and have a nice day!

Nick

I’ll add that I can’t even do an odbc show in the CLI. Not sure what happened with the upgrade.

freepbx*CLI> odbc show
No such command 'odbc show' (type 'core show help odbc show' for other possible commands)

Also looks like there is no odbc module in FreePBX.

freepbx*CLI> module reload res_odbc.so
No such module 'res_odbc.so'

Hi!

Hi!

Assuming you have Asterisk 13 it should be in /usr/lib64/asterisk/modules/res_odbc.so and it is provided by the asterisk13-odbc-13.17.0-3.sng7.x86_64 package.

Is the file present and is that package (or the one appropriate for your Asterisk version) installed?

Good luck and have a nice day!

Nick

Hi!

Have you tried yum update?

There were new packages published recently…

Do make sure you have the odbc one in the bunch…

Good luck and have a nice day!

Nick

I have exactly this same problem. Same results from cdr show status and from odbc show.

Other than call reporting, everything seems to be working fine.

And according to yum everything is updated.

Bonjour!/Hi!

Is the file /usr/lib64/asterisk/modules/res_odbc.so present on your disk and is the appropriate package installed?

What is the output of rpm -q -a | grep odbc ?

Good luck and have a nice day!

Nick

Have had same issue for a while, have tried reverting back to FreePBX 13 no change and then back again to 14. Yum update done, system works Ok in all other respects just no CDR records visible in reports since full upgrade on 10th August. Query output for this system is:

rpm -q -a | grep odbc
asterisk14-odbc-14.6.1-2.sng7.x86_64
mysql-connector-odbc-5.2.5-6.el7.x86_64
php56w-odbc-5.6.31-2.sng7.x86_64

Hi!

Have you checked for/tried this:

UCP data stopped after upgrade to FreepBX 14 - #3 by Marbled ?

Good luck and have a nice day!

Nick

You are running Asterisk 14, who else in this thread is?

Good luck and have a nice day!

Nick

No Nick, I hadn’t tried the fix suggested, erring on the cautious side to see if others found a non invasive therapy . This morning however, boldly stepping out, I found etc/odbc.ini.rpmsave and renamed it as odbc.ini, ‘presto’ CDR records are being accumulated once again. There remains the record gap between snag and solution, c’est la vie!

Hi!

FYI, If the file was no longer present it is a non invasive therapy…

In essence, part of the configuration needed to access the database was no longer present on your system…

For some of us the file we had was moved out of the way (into the .rpmsave) and not replaced by a new one…

If I am not mistake a .rpmsave is made if the file we had is not the original one published with the RPM, in my case I believe I had to add the character set (charset) which was not initially present in the file…

You essentially had one of the problems I documented in my ticket about a month ago. Somehow, in some situations, this problem happens again after many releases of the upgrade “script”…

Yep, that’s life… :wink:

(French is actually my mother tongue so saying it in French in a sentence which is mostly in English would not sound as nice as an English speaking person using a French expression…)

Have a nice day!

Nicolas

et à toi aussi une belle journée

Richard

Interesting. My odbc.ini looked the same as odbc.ini.rpmsave. I have since reverted my VM back to FreePBX 13.

If you figure out a fix, please share!

LOL, merci!

Nicolas

Hi!

I believe it is two different problems… The end result appears to be the same but the cause apparently different…

Hopefully we can figure out what is missing.

Was the file /usr/lib64/asterisk/modules/res_odbc.so actually present on your disk?

Mike, when you retry this and especially if it is on the system that has a Sangoma A200, please let me know.

Once booted my system works but I am experiencing very slow boot and it seems to be directly related to my DAHDI hardware… I am wondering if you have the same problem as well…

As for your system I am sure that if we compare a system where CDR works to your non-working one I am sure we can figure out what is missing.

The first thing I would check if if the file is there, it looks like it is not… That would suggest the asterisk*-odbc package didn’t get installed somehow…

Good luck and have a nice day!

Nick

In my case /usr/lib64/asterisk/modules/res_odbc.so is not present.
odbc.ini matches odbci.ini.rpmsave

But the output from the rpm query gives:

rpm -q -a | grep odbc
php56w-odbc-5.6.31-2.sng7.x86_64
mysql-connector-odbc-5.2.5-6.el7.x86_64

So it looks like I have no odbc…