1MARIADB-INSTALL-DB(1)       MariaDB Database System      MARIADB-INSTALL-DB(1)
2
3
4

NAME

6       mariadb-install-db - initialize MariaDB data directory
7       (mysql_install_db is now a symlink to mariadb-install-db)
8

SYNOPSIS

10       mysql_install_db [options]
11

DESCRIPTION

13       mysql_install_db initializes the MariaDB data directory and creates the
14       system tables that it contains, if they do not exist.
15
16       To invoke mysql_install_db, use the following syntax:
17
18           shell> mysql_install_db [options]
19
20       Because the MariaDB server, mysqld, needs to access the data directory
21       when it runs later, you should either run mysql_install_db from the
22       same account that will be used for running mysqld or run it as root and
23       use the --user option to indicate the user name that mysqld will run
24       as. It might be necessary to specify other options such as --basedir or
25       --datadir if mysql_install_db does not use the correct locations for
26       the installation directory or data directory. For example:
27
28           shell> bin/mysql_install_db --user=mysql \
29                    --basedir=/opt/mysql/mysql \
30                    --datadir=/opt/mysql/mysql/data
31
32       mysql_install_db needs to invoke mysqld with the --bootstrap and
33       --skip-grant-tables options (see Section 2.3.2, “Typical configure
34       Options”). If MariaDB was configured with the --disable-grant-options
35       option, --bootstrap and --skip-grant-tables will be disabled. To handle
36       this, set the MYSQLD_BOOTSTRAP environment variable to the full path
37       name of a server that has all options enabled.  mysql_install_db will
38       use that server.
39
40       mysql_install_db supports the following options, which can be specified
41       on the command line or in the [mysql_install_db] and (if they are
42       common to mysqld) [mysqld] option file groups.
43
44--basedir=path
45
46           The path to the MariaDB installation directory.
47
48--builddir=path
49
50           If using --srcdir with out-of-directory builds, you will need to
51           set this to the location of the build directory where built files
52           reside..
53
54--cross-bootstrap
55
56           For internal use. Used when building the MariaDB system tables on a
57           different host than the target..
58
59--datadir=path, --ldata=path
60
61           The path to the MariaDB data directory.
62
63--defaults-extra-file=filename
64
65           Set filename as the file to read default options from after the
66           global defaults files has been read.  Must be given as first
67           option.
68
69--defaults-file=filename
70
71           Set filename as the file to read default options from, override
72           global defaults files.  Must be given as first option.
73
74--defaults-group-suffix=name
75
76           In addition to the given groups, also read groups with this suffix.
77
78--force
79
80           Cause mysql_install_db to run even if DNS does not work. In that
81           case, grant table entries that normally use host names will use IP
82           addresses.
83
84--help
85
86           Display a help message and exit.
87
88--no-defaults
89
90           Do not read default options from any option file. This must be
91           given as the first argument.
92
93--print-defaults
94
95           Print the program argument list and exit.  This must be given as
96           the first argument.
97
98--rpm
99
100           For internal use. This option is used by RPM files during the
101           MariaDB installation process.
102
103--skip-name-resolve
104
105           Use IP addresses rather than host names when creating grant table
106           entries. This option can be useful if your DNS does not work.
107
108--srcdir=path
109
110           For internal use. The directory under which mysql_install_db looks
111           for support files such as the error message file and the file for
112           populating the help tables.4.
113
114--user=user_name
115
116           The login user name to use for running mysqld. Files and
117           directories created by mysqld will be owned by this user. You must
118           be root to use this option. By default, mysqld runs using your
119           current login name and files and directories that it creates will
120           be owned by you.
121
122--verbose
123
124           Verbose mode. Print more information about what the program does.
125
126--windows
127
128           For internal use. This option is used for creating Windows
129           distributions.
130
132       Copyright 2007-2008 MySQL AB, 2008-2010 Sun Microsystems, Inc.,
133       2010-2019 MariaDB Foundation
134
135       This documentation is free software; you can redistribute it and/or
136       modify it only under the terms of the GNU General Public License as
137       published by the Free Software Foundation; version 2 of the License.
138
139       This documentation is distributed in the hope that it will be useful,
140       but WITHOUT ANY WARRANTY; without even the implied warranty of
141       MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
142       General Public License for more details.
143
144       You should have received a copy of the GNU General Public License along
145       with the program; if not, write to the Free Software Foundation, Inc.,
146       51 Franklin Street, Fifth Floor, Boston, MA 02110-1335 USA or see
147       http://www.gnu.org/licenses/.
148
149

SEE ALSO

151       For more information, please refer to the MariaDB Knowledge Base,
152       available online at https://mariadb.com/kb/
153

AUTHOR

155       MariaDB Foundation (http://www.mariadb.org/).
156
157
158
159MariaDB 10.5                     27 June 2019            MARIADB-INSTALL-DB(1)
Impressum