How can I fix incorrect date and times displayed in the extension?

Server Time

Our extensions require that the date, time, and timezone be set correctly on the server. You can check if the timezone is set correctly using the command below. It should be symlinked properly to the correct timezone as that is what the extension uses to determine the timezone:

# ls -l /etc/localtime
lrwxrwxrwx. 1 root root 36 Oct 30  2020 /etc/localtime -> /usr/share/zoneinfo/America/Edmonton

How to set the timezone in Linux

https://linuxize.com/post/how-to-set-or-change-timezone-in-linux/

How to change the Time Zone by Creating a Symlink

https://linuxize.com/post/how-to-set-or-change-timezone-in-linux/#changing-the-time-zone-by-creating-a-symlink

MySQL Timezone

Some time columns uses the MySQL NOW() function for generating time information. You can check to see that the timezone is set correctly for the database using the commands below. It should match the time from the date command :

# mysql -u admin -p`cat /etc/psa/.psa.shadow` -s -N -e "SELECT NOW();"
2024-10-15 10:27:06

# date
Tue Oct 15 10:27:10 MDT 2024

How to set the timezone in MySQL

https://phoenixnap.com/kb/change-mysql-time-zone

Checking if the time is stored correctly in the Warden database

You can query the msgs log table from the command line to check if the last records have the correct time:

mysql -u admin -p`cat /etc/psa/.psa.shadow` -s -N -e "use danami_warden; select time_iso, subject, from_addr from msgs order by time_iso DESC limit 5;" 
  • timezone, time
  • 0 Users Found This Useful
この回答はお役に立ちましたか?

Related Articles

How can I fix any statistics generation problems?

Missing the Warden Crontab Entry There is a crontab entry that will update Warden statistics...

How can I fix the error: "milter-reject: END-OF-MESSAGE from..." in the log and found the AV in error (cannot read /etc/clam.d/scan.conf).

Cloudlinux / Imunify360 added their own version of ClamAV to their repo which accidentally...

How can I fix the error: Can't connect to TCP port 10024 on 127.0.0.0 [Address already in use] when trying to start Amavis?

When trying to start Amavis you see this in the mail log: Oct 02 03:20:15 condor3648 systemd[1]:...

How can I fix the error: Can't connect to TCP port 10024 on ::1 [Cannot assign requested address] when trying to start Amavis?

When trying to start Amavis you see this in the mail log: Oct 02 03:20:15 condor3648 systemd[1]:...

How can I fix the error: Error [Contentfilter_Settings_Contentfilter]. Message [[QUARANTINEDIR] must be a valid directory?

This error means that Amavis was not installed correctly. Try running the Warden from the command...