CDR Reports Time Wrong

My timezone is set correctly in FreePBX (EST)… My time shows correctly in Asterisk Log Files but the times are incorrect in CDR reports… Off my 3 hours… In Settings>Advanced Settings PHP Timezone is also set correctly. In SysAdmin>Timezone also set correctly to America>New York.

What controls CDR reports and Call Event Logging times?? How do I get it to show the correct time for proper diagnosing of calls?

[root@freepbx ~]# date
Thu May 2 09:22:21 EDT 2024
[root@freepbx ~]# grep date.timezone /etc/php.ini
; PHP: Runtime Configuration - Manual
date.timezone = “America/New_York” ;;;; Automatically updated by Sysadmin
[root@freepbx ~]#

make sure you don’t have

usegmtime=yes

in your cdr conf file, (but that would be 4 not 3 from NY in the summer)

So I just went back and looked at CDR reports again and it is 4 hours different. Says 4:47AM where that calls was actually made at 8:47am per Asterisk Log Files…

Where do I go to make the change you suggest of usegmtime=yes ??

The suggestion was to set it to “no”!

However, I would advise against doing that, at least in any time zone that implement daylight saving time, as you will get strange results when the clocks go back. (Forward as well, but you can post-process those out.)

Ok, so then whats the change I need to make to get CDR reports to show accurate times then?

I can only answer for Asterisk. I don’t know the details of FreePBX’s built in reporting, and whether, or not, it is broken around daylight saving time changes.

@lgaetz any help on this one?

It’s in /etc/asterisk/cdr.conf, but I don’t know if you are allowed to edit that in FreePBX, and, as I said, best practice is to log in UTC and convert to local time in the reporting process: