Our local clocks just went forward for daylight saving’s time, and as usual our database server is an hour off again. Is it possible to configure my.cnf
to simply inherit the timezone offset from Cent OS or are we destined to have to change it manually every six months?
2
Answers
The answer seems to be to add a hash before
default-time-zone
from/etc/my.cnf
to disable it, then restart MySQL.As the manual describes, MySQL will default to system_time_zone if the default is not explicitly set.
My answer got converted to comment for some reason because it was short.
Your database is most likely set to the same timezone as the server. The issue is the following:
For a detailed answer take a look here: https://stackoverflow.com/a/1650910/11291413