If set to normal, it creates a root@localhost account that authenticates with the mysql_native_password authentication plugin and that has no initial password set, which can be insecure. If set to socket, it creates a root@localhost account that authenticates with the unix_socket authentication plugin. Set to socket by default from MariaDB 10.4 (see Authentication from MariaDB 10.4), or normal by default in earlier versions. Available since MariaDB 10.1.
Syntax:-
mysql_install_db --auth-root-authentication-method={normal | socket}
Used with --auth-root-authentication-method=socket. It specifies the name of the second account to create with SUPER privileges in addition to root, as well as of the system account allowed to access it. Defaults to the value of --user.
Syntax:-
mysql_install_db --auth-root-socket-user=USER
The path to the MariaDB installation directory.
mysql_install_db --basedir=path
If using --srcdir with out-of-directory builds, you will need to set this to the location of the build directory where built files reside.
mysql_install_db --builddir=path
For internal use. Used when building the MariaDB system tables on a different host than the target.
Syntax:-
mysql_install_db --cross-bootstrap
The path to the MariaDB data directory.
Syntax:-
mysql_install_db --datadir=path , mysql_install_db --ldata=path
Read this file after the global files are read. Must be given as the first option.
syntax:-
mysql_install_db --defaults-extra-file=name
Only read default options from the given file name Must be given as the first option.
Syntax:-
mysql_install_db --defaults-file=name
In addition to the given groups, read also groups with this suffix. From MariaDB 10.1.31, MariaDB 10.2.13 and MariaDB 10.3.5.
Syntax:-
mysql_install_db --defaults-group-suffix=name
Causes mysql_install_db to run even if DNS does not work. In that case, grant table entries that normally use host names will use IP addresses.
Syntax:-
mysql_install_db --force
Don't read default options from any option file. Must be given as the first option.
Syntax:-
mysql_install_db --no-defaults
Print the program argument list and exit. Must be given as the first option.
Syntax:-
mysql_install_db --print-defaults
For internal use. This option is used by RPM files during the MariaDB installation process.
Syntax:-
mysql_install_db --rpm
Do not create the anonymous user.
Syntax:-
mysql_install_db --skip-auth-anonymous-user
Uses IP addresses rather than host names when creating grant table entries. This option can be useful if your DNS does not work.
Syntax:-
mysql_install_db --skip-name-resolve
Don't install the test database.
Syntax:-
mysql_install_db --skip-test-db
For internal use. The path to the MariaDB source directory. This option uses the compiled binaries and support files within the source tree, useful for if you don't want to install MariaDB yet and just want to create the system tables. The directory under which mysql_install_db looks for support files such as the error message file and the file for populating the help tables.
Syntax:-
mysql_install_db --srcdir=path