1MYSQL_TZINFO_TO_S(1) MariaDB Database System MYSQL_TZINFO_TO_S(1)
2
3
4
6 mysql_tzinfo_to_sql - load the time zone tables
7
9 mysql_tzinfo_to_sql arguments
10
12 The mysql_tzinfo_to_sql program loads the time zone tables in the mysql
13 database. It is used on systems that have a zoneinfo database (the set
14 of files describing time zones). Examples of such systems are Linux,
15 FreeBSD, Solaris, and Mac OS X. One likely location for these files is
16 the /usr/share/zoneinfo directory (/usr/share/lib/zoneinfo on Solaris).
17
18 mysql_tzinfo_to_sql can be invoked several ways:
19
20 shell> mysql_tzinfo_to_sql tz_dir
21 shell> mysql_tzinfo_to_sql tz_file tz_name
22 shell> mysql_tzinfo_to_sql --leap tz_file
23
24 For the first invocation syntax, pass the zoneinfo directory path name
25 to mysql_tzinfo_to_sql and send the output into the mysql program. For
26 example:
27
28 shell> mysql_tzinfo_to_sql /usr/share/zoneinfo | mysql -u root mysql
29
30 mysql_tzinfo_to_sql reads your system´s time zone files and generates
31 SQL statements from them. mysql processes those statements to load the
32 time zone tables.
33
34 The second syntax causes mysql_tzinfo_to_sql to load a single time zone
35 file tz_file that corresponds to a time zone name tz_name:
36
37 shell> mysql_tzinfo_to_sql tz_file tz_name | mysql -u root mysql
38
39 If your time zone needs to account for leap seconds, invoke
40 mysql_tzinfo_to_sql using the third syntax, which initializes the leap
41 second information. tz_file is the name of your time zone file:
42
43 shell> mysql_tzinfo_to_sql --leap tz_file | mysql -u root mysql
44
45 After running mysql_tzinfo_to_sql, it is best to restart the server so
46 that it does not continue to use any previously cached time zone data.
47
49 Copyright 2007-2008 MySQL AB, 2008-2010 Sun Microsystems, Inc.,
50 2010-2019 MariaDB Foundation
51
52 This documentation is free software; you can redistribute it and/or
53 modify it only under the terms of the GNU General Public License as
54 published by the Free Software Foundation; version 2 of the License.
55
56 This documentation is distributed in the hope that it will be useful,
57 but WITHOUT ANY WARRANTY; without even the implied warranty of
58 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
59 General Public License for more details.
60
61 You should have received a copy of the GNU General Public License along
62 with the program; if not, write to the Free Software Foundation, Inc.,
63 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335 USA or see
64 http://www.gnu.org/licenses/.
65
66
68 For more information, please refer to the MariaDB Knowledge Base,
69 available online at https://mariadb.com/kb/
70
72 MariaDB Foundation (http://www.mariadb.org/).
73
74
75
76MariaDB 10.5 27 June 2019 MYSQL_TZINFO_TO_S(1)