Timezones

In order to get timezones working on a MariaDB/MySQL instance, you will have to initialize Timezones data and grant GLPI database user read ACL on their table.

Warnung

Enabling timezone support on your MySQL instance may affect other database in the same instance; be carefull!

Warnung

Currently, MySQL and MariaDB have a maximum date limited to 2038-01-19 on fields relying on timestamp type!

Non windows users

On most systems, you’ll have to initialize timezones data from your system’s timezones:

mysql_tzinfo_to_sql /usr/share/zoneinfo | mysql -p -u root mysql

You may want to check MariaDB documentation about mysql_tzinfo_to_sql and your system documentation to know where data are stored (if not in /usr/share/zoneinfo).

Do not forget to restart the database server once command is successfull.

Windows users

Windows does not provide timezones informations, you’ll have to download and intialize data yourself.

See MariaDB documentation about timezones.

Grant access

Warnung

Be carefull not to give your GLPI database user too large access. System tables should never grant access to app users.

In order to list possible timezones, your GLPI database user must have read access on mysql.time_zone_name table. Assuming your user is glpi@localhost, you should run something like:

GRANT SELECT ON `mysql`.`time_zone_name` TO 'glpi'@'localhost';
FLUSH PRIVILEGES;

Creative Commons License