Timezone is off by a couple of hours

There seems to be something not right about the time shown in different locations in ERPNext. In my installation, they are off (ahead) by 2 hours.

For a quick fix, I just used a later timezone - 2 hours later than where we actually are. I noticed that this has been fixed before. But after I updated, it seems to be back.

Happens the same to me, but with an offset of 11 hours.

Already checked the server timezone and ERPNext site timezone and they are OK, but when ever you create a transaction, it shows it was created 11 hours ago.

This happens because of the timezone settings of your system and MySQL. MySQL can either take the timezone of the system in which it is installed, or it can have its onw timezone. Dependingon your setting, the time value will differ.

In my case, I run a VM in Ubuntu. Even though the host Ubuntu systemwas set to correct timezone, the VM was in GMT timezone and that caused issue in timestamps. (TheMysql is set to use System timezone in my case)

Hope it helps.

Thanks @kirthi. But isn’t this supposed to be taken care of the Frappe/ERPNext system already?

No, the system configuration is controlled by us, individually. We all live in different timezones, and we have to set the machines to correct timezone.

What setup is yours? Ate you running VM?

Yes, the system config is ours to set. But there are ways of getting the system config values, like the timezone, and then comparing that to the setting that we applied in ERPNext, and then from that, the ERPNext can display the correct local time.