

If you are starting the server with mysqld_safe, then you can set the system time zone with the -timezone option either on the command-line or in the option group in an option file.You can change the system time zone in several different ways, such as: The system time zone is usually read from the operating system's environment. The system time zone is determined when the server starts, and it sets the value of the system_time_zone system variable. For example: SHOW SESSION VARIABLES LIKE 'time_zone' + -+-+ | Variable_name | Value | + -+-+ | time_zone | SYSTEM | + -+-+ System Time Zone The current session time zone can be viewed by looking at the session value of the time_zone system variable. For example: SET time_zone = 'America/New_York' This time zone is initially inherited from the global value of the time_zone system variable, which sets the session value of the same variable.Ī session's time zone can be changed dynamically by setting the time_zone system variable. For example: SHOW GLOBAL VARIABLES LIKE 'time_zone' + -+-+ | Variable_name | Value | + -+-+ | time_zone | SYSTEM | + -+-+ Session Time ZoneĮach session that connects to the server will also have its own time zone. The current global server time zone can be viewed by looking at the global value of the time_zone system variable. For example: SET GLOBAL time_zone = 'America/New_York' The global server time zone can also be changed dynamically by setting the time_zone system variable as a user account that has the SUPER privilege. The global server time zone can be changed at server startup by setting the -default-time-zone option either on the command-line or in a server option group in an option file. There is also a third time zone setting which may be relevant-the system time zone. There are two time zone settings that can be set within MariaDB-the global server time zone, and the time zone for your current session. See mysql Time Zone Tables below for more information. If the time zone tables in the mysql database were loaded, then a named time zone, such as America/New_York, Africa/Johannesburg, or Europe/Helsinki, is also permissible.


