Server Command Options
When you start the mysqld server, you can specify program options using any of the methods described in , "Specifying Program Options". The most common methods are to provide options in an option file or on the command line. However, in most cases it is desirable to make sure that the server uses the same options each time it runs. The best way to ensure this is to list them in an option file. See , "Using Option Files".
mysqld reads options from the [mysqld] and [server] groups. mysqld_safe reads options from the [mysqld], [server], [mysqld_safe], and [safe_mysqld] groups. mysql.server reads options from the [mysqld] and [mysql.server] groups.
An embedded MariaDB server usually reads options from the [server], [embedded], and [ groups, where xxxxx_SERVER]xxxxx is the name of the application into which the server is embedded.
mysqld accepts many command options. For a brief summary, execute mysqld --help. To see the full list, use mysqld --verbose --help.
The following list shows some of the most common server options. Additional options are described in other sections:
- Options that affect security: See , "Security-Related mysqld Options".
- SSL-related options: See , "SSL Command Options".
- Binary log control options: See , "The Binary Log".
- Replication-related options: See , "Replication and Binary Logging Options and Variables".
- Options for loading plugins such as pluggable storage engines: See , "Installing and Uninstalling Plugins".
- Options specific to particular storage engines: See , "
MyISAMStartup Options", and , "InnoDBStartup Options and System Variables".
You can also set the values of server system variables by using variable names as options, as described at the end of this section.
Some options control the size of buffers or caches. For a given buffer, the server might need to allocate internal data structures. These structures typically are allocated from the total memory allocated to the buffer, and the amount of space required might be platform dependent. This means that when you assign a value to an option that controls a buffer size, the amount of space actually available might differ from the value assigned. In some cases, the amount might be less than the value assigned. It is also possible that the server will adjust a value upward. For example, if you assign a value of 0 to an option for which the minimal value is 1024, the server will set the value to 1024.
Values for buffer sizes, lengths, and stack sizes are given in bytes unless otherwise specified.
Some options take file name values. Unless otherwise specified, the default file location is the data directory if the value is a relative path name. To specify the location explicitly, use an absolute path name. Suppose that the data directory is /var/mysql/data. If a file-valued option is given as a relative path name, it will be located under /var/mysql/data. If the value is an absolute path name, its location is as given by the path name.
--help,-?Command-Line Format -?--helpOption-File Format helpDisplay a short help message and exit. Use both the
--verboseand--helpoptions to see the full message.--allow-suspicious-udfsCommand-Line Format --allow-suspicious-udfsOption-File Format allow-suspicious-udfsPermitted Values Type booleanDefault FALSEThis option controls whether user-defined functions that have only an
xxxsymbol for the main function can be loaded. By default, the option is off and only UDFs that have at least one auxiliary symbol can be loaded; this prevents attempts at loading functions from shared object files other than those containing legitimate UDFs. See , "User-Defined Function Security Precautions".--ansiCommand-Line Format --ansi-aOption-File Format ansiUse standard (ANSI) SQL syntax instead of MariaDB syntax. For more precise control over the server SQL mode, use the
--sql-modeoption instead. See , "Running MariaDB in ANSI Mode", and , "Server SQL Modes".--basedir=,path-bpathCommand-Line Format --basedir=path-bOption-File Format basedirOption Sets Variable Yes, basedirVariable Name basedirVariable Scope Global Dynamic Variable No Permitted Values Type file nameThe path to the MariaDB installation directory. All paths are usually resolved relative to this directory.
--big-tablesVersion Removed 5.6.1 Command-Line Format --big-tablesOption-File Format big-tablesOption Sets Variable Yes, big_tablesVariable Name big-tablesVariable Scope Global, Session Dynamic Variable Yes Permitted Values Type booleanEnable large result sets by saving all temporary sets in files. This option prevents most "table full" errors, but also slows down queries for which in-memory tables would suffice. Since MariaDB 3.23.2, the server is able to handle large result sets automatically by using memory for small temporary tables and switching to disk tables where necessary.
--bind-address=IPCommand-Line Format --bind-address=nameOption-File Format bind-address=nameVariable Name bind-addressVariable Scope Global Dynamic Variable No Permitted Values Type stringDefault 0.0.0.0Range 255.255.255.255The IP address to bind to. Only one address can be selected. If this option is specified multiple times, the last address given is used.
If no address or
0.0.0.0is specified, the server listens on all interfaces.--binlog-format={ROW|STATEMENT|MIXED}Command-Line Format --binlog-format=formatOption-File Format binlog-format=formatOption Sets Variable Yes, binlog_formatVariable Name binlog_formatVariable Scope Global, Session Dynamic Variable Yes Permitted Values Type enumerationDefault STATEMENTValid Values ROWSTATEMENTMIXEDSpecify whether to use row-based, statement-based, or mixed replication. Statement-based is the default in MariaDB 5.6. See , "Replication Formats".
In MariaDB 5.6, setting the binary logging format without enabling binary logging sets the
binlog_formatglobal system variable and logs a warning.--bootstrapCommand-Line Format --bootstrapOption-File Format bootstrapThis option is used by the mysql_install_db script to create the MariaDB privilege tables without having to start a full MariaDB server.
This option is unavailable if MariaDB was configured with the
DISABLE-GRANT-OPTIONScompiler flag. See , "MySQL Source-Configuration Options".--character-sets-dir=pathCommand-Line Format --character-sets-dir=pathOption-File Format character-sets-dir=pathOption Sets Variable Yes, character_sets_dirVariable Name character-sets-dirVariable Scope Global Dynamic Variable No Permitted Values Type directory nameThe directory where character sets are installed. See , "Character Set Configuration".
--character-set-client-handshakeCommand-Line Format --character-set-client-handshakeOption-File Format character-set-client-handshakePermitted Values Type booleanDefault TRUEDo not ignore character set information sent by the client. To ignore client information and use the default server character set, use
--skip-character-set-client-handshake; this makes MariaDB behave like MariaDB 4.0.--character-set-filesystem=charset_nameCommand-Line Format --character-set-filesystem=nameOption-File Format character-set-filesystemOption Sets Variable Yes, character_set_filesystemVariable Name character_set_filesystemVariable Scope Global, Session Dynamic Variable Yes Permitted Values Type stringThe file system character set. This option sets the
character_set_filesystemsystem variable.--character-set-server=,charset_name-Ccharset_nameCommand-Line Format --character-set-serverOption-File Format character-set-serverOption Sets Variable Yes, character_set_serverVariable Name character_set_serverVariable Scope Global, Session Dynamic Variable Yes Permitted Values Type stringUse
charset_nameas the default server character set. See , "Character Set Configuration". If you use this option to specify a nondefault character set, you should also use--collation-serverto specify the collation.--chroot=,path-rpathCommand-Line Format --chroot=name-r nameOption-File Format chrootPermitted Values Type file namePut the mysqld server in a closed environment during startup by using the
chroot()system call. This is a recommended security measure. Note that use of this option somewhat limitsLOAD DATA INFILEandSELECT ... INTO OUTFILE.--collation-server=collation_nameCommand-Line Format --collation-serverOption-File Format collation-serverOption Sets Variable Yes, collation_serverVariable Name collation_serverVariable Scope Global, Session Dynamic Variable Yes Permitted Values Type stringUse
collation_nameas the default server collation. See , "Character Set Configuration".--consoleCommand-Line Format --consoleOption-File Format consolePlatform Specific windows (Windows only.) Write error log messages to
stderrandstdouteven if--log-erroris specified. mysqld does not close the console window if this option is used.--core-fileCommand-Line Format --core-fileOption-File Format core-filePermitted Values Type booleanDefault FALSEWrite a core file if mysqld dies. The name and location of the core file is system dependent. On Linux, a core file named
core.is written to the current working directory of the process, which for mysqld is the data directory.pidpidrepresents the process ID of the server process. On Mac OS X, a core file namedcore.is written to thepid/coresdirectory. On Solaris, use the coreadm command to specify where to write the core file and how to name it.For some systems, to get a core file you must also specify the
--core-file-sizeoption to mysqld_safe. See , "mysqld_safe - MariaDB Server Startup Script". On some systems, such as Solaris, you do not get a core file if you are also using the--useroption. There might be additional restrictions or limitations. For example, it might be necessary to execute ulimit -c unlimited before starting the server. Consult your system documentation.--datadir=,path-hpathCommand-Line Format --datadir=path-hOption-File Format datadirOption Sets Variable Yes, datadirVariable Name datadirVariable Scope Global Dynamic Variable No Permitted Values Type file nameThe path to the data directory.
--debug[=,debug_options]-# [debug_options]Command-Line Format --debug[=debug_options]Option-File Format debugVariable Name debugVariable Scope Global, Session Dynamic Variable Yes Permitted Values Type stringDefault 'd:t:o,/tmp/mysqld.trace'If MariaDB is configured with
-DWITH-DEBUG=1, you can use this option to get a trace file of what mysqld is doing. A typicaldebug_optionsstring is'd:t:o,. The default isfile_name''d:t:i:o,mysqld.trace'. See MySQL Internals: Porting.Using
-DWITH-DEBUG=1to configure MariaDB with debugging support enables you to use the--debug='d,parser_debug'option when you start the server. This causes the Bison parser that is used to process SQL statements to dump a parser trace to the server's standard error output. Typically, this output is written to the error log.This option may be given multiple times. Values that begin with
+or-are added to or subtracted from the previous value. For example,--debug=T--debug=+Psets the value toP:T.--debug-sync-timeout[=N]Command-Line Format --debug-sync-timeout[=#]Option-File Format debug-sync-timeoutPermitted Values Type numericControls whether the Debug Sync facility for testing and debugging is enabled. Use of Debug Sync requires that MariaDB be configured with the
-DENABLE_DEBUG_SYNC=1option (see , "MySQL Source-Configuration Options"). If Debug Sync is not compiled in, this option is not available. The option value is a timeout in seconds. The default value is 0, which disables Debug Sync. To enable it, specify a value greater than 0; this value also becomes the default timeout for individual synchronization points. If the option is given without a value, the timeout is set to 300 seconds.For a description of the Debug Sync facility and how to use synchronization points, see MySQL Internals: Test Synchronization.
--default-storage-engine=typeCommand-Line Format --default-storage-engine=nameOption-File Format default-storage-engineOption Sets Variable Yes, default_storage_engineVariable Name default_storage_engineVariable Scope Global, Session Dynamic Variable Yes Permitted Values Type enumerationDefault InnoDBSet the default storage engine for tables. See , Storage Engines. As of MariaDB 5.6.3, this option sets the storage engine for permanent tables only. To set the storage engine for
TEMPORARYtables, set thedefault_tmp_storage_enginesystem variable.If you disable the default storage engine at server startup, you must set the default engine for both permanent and
TEMPORARYtables to a different engine or the server will not start.--default-time-zone=timezoneCommand-Line Format --default-time-zone=nameOption-File Format default-time-zonePermitted Values Type stringSet the default server time zone. This option sets the global
time_zonesystem variable. If this option is not given, the default time zone is the same as the system time zone (given by the value of thesystem_time_zonesystem variable.--delay-key-write[={OFF|ON|ALL}]Command-Line Format --delay-key-write[=name]Option-File Format delay-key-writeOption Sets Variable Yes, delay_key_writeVariable Name delay-key-writeVariable Scope Global Dynamic Variable Yes Permitted Values Type enumerationDefault ONValid Values ONOFFALLSpecify how to use delayed key writes. Delayed key writing causes key buffers not to be flushed between writes for
MyISAMtables.OFFdisables delayed key writes.ONenables delayed key writes for those tables that were created with theDELAY_KEY_WRITEoption.ALLdelays key writes for allMyISAMtables. See , "Tuning Server Parameters", and , "MyISAMStartup Options".NoteIf you set this variable to
ALL, you should not useMyISAMtables from within another program (such as another MariaDB server or myisamchk) when the tables are in use. Doing so leads to index corruption.--des-key-file=file_nameCommand-Line Format --des-key-file=file_nameOption-File Format des-key-file=file_nameRead the default DES keys from this file. These keys are used by the
DES-ENCRYPT()andDES_DECRYPT()functions.--enable-named-pipeCommand-Line Format --enable-named-pipeOption-File Format enable-named-pipeOption Sets Variable Yes, named_pipePlatform Specific windows Enable support for named pipes. This option applies only on Windows.
--engine-condition-pushdown={ON|OFF}Version Removed 5.6.1 Command-Line Format --engine-condition-pushdownOption-File Format engine-condition-pushdownOption Sets Variable Yes, engine_condition_pushdownVariable Name engine_condition_pushdownVariable Scope Global, Session Dynamic Variable Yes Deprecated 5.5.3, by optimizer_switchPermitted Values Type booleanDefault ONSets the
engine-condition-pushdownsystem variable. For more information, see , "Engine Condition Pushdown Optimization".--event-scheduler[=value]Command-Line Format --event-scheduler[=value]Option-File Format event-schedulerOption Sets Variable Yes, event_schedulerVariable Name event_schedulerVariable Scope Global Dynamic Variable Yes Permitted Values Type enumerationDefault OFFValid Values ONOFFDISABLEDEnable or disable, and start or stop, the event scheduler.
For detailed information, see The
--event-schedulerOption.--exit-info[=,flags]-T [flags]Command-Line Format --exit-info[=flags]-T [flags]Option-File Format exit-infoPermitted Values Type numericThis is a bit mask of different flags that you can use for debugging the mysqld server. Do not use this option unless you know exactly what it does!
--external-lockingCommand-Line Format --external-lockingOption-File Format external-lockingOption Sets Variable Yes, skip_external_lockingDisabled by skip-external-lockingPermitted Values Type booleanDefault FALSEEnable external locking (system locking), which is disabled by default as of MariaDB 4.0. Note that if you use this option on a system on which
lockddoes not fully work (such as Linux), it is easy for mysqld to deadlock.External locking affects only
MyISAMtable access. For more information, including conditions under which it can and cannot be used, see , "External Locking".--flushCommand-Line Format --flushOption-File Format flushVariable Name flushVariable Scope Global Dynamic Variable Yes Permitted Values Type booleanDefault OFFFlush (synchronize) all changes to disk after each SQL statement. Normally, MariaDB does a write of all changes to disk only after each SQL statement and lets the operating system handle the synchronizing to disk. See "What to Do If MariaDB Keeps Crashing".
--gdbCommand-Line Format --gdbOption-File Format gdbPermitted Values Type booleanDefault FALSEInstall an interrupt handler for
SIGINT(needed to stop mysqld with^Cto set breakpoints) and disable stack tracing and core file handling. See MySQL Internals: Porting.--general-log[={0|1}]Command-Line Format --general-logOption-File Format general-logOption Sets Variable Yes, general_logVariable Name general_logVariable Scope Global Dynamic Variable Yes Permitted Values Type booleanDefault OFFSpecify the initial general query log state. With no argument or an argument of 1, the
--general-logoption enables the log. If omitted or given with an argument of 0, the option disables the log.--ignore-db-dir=dir_nameVersion Introduced 5.6.3 Command-Line Format --ignore-db-dirOption-File Format ignore-db-dirOption Sets Variable Yes, ignore_db_dirsPermitted Values Type directory nameThis option tells the server to ignore the given directory name for purposes of the
SHOW DATABASESstatement orINFORMATION_SCHEMAtables. For example, if a MariaDB configuration locates the data directory at the root of a file system on Unix, the system might create alost+founddirectory there that the server should ignore. Starting the server with--ignore-db-dir=lost+foundcauses that name not to be listed as a database.To specify more than one name, use this option multiple times, once for each name. Specifying the option with an empty value (that is, as
--ignore-db-dir=) resets the directory list to the empty list.Instances of this option given at server startup are used to set the
ignore_db_dirssystem variable.This option was added in MariaDB 5.6.3.
--init-file=file_nameCommand-Line Format --init-file=file_nameOption-File Format init-file=file_nameOption Sets Variable Yes, init_fileVariable Name init_fileVariable Scope Global Dynamic Variable No Permitted Values Type file nameRead SQL statements from this file at startup. Each statement must be on a single line and should not include comments.
This option is unavailable if MariaDB was configured with the
DISABLE-GRANT-OPTIONScompiler flag. See , "MySQL Source-Configuration Options".--innodb-xxxThe
InnoDBoptions are listed in , "InnoDBStartup Options and System Variables".--install [service_name]Command-Line Format --install [service_name](Windows only) Install the server as a Windows service that starts automatically during Windows startup. The default service name is
MariaDBif noservice_namevalue is given. For more information, see , "Starting MariaDB as a Windows Service".--install-manual [service_name]Command-Line Format --install-manual [service_name](Windows only) Install the server as a Windows service that must be started manually. It does not start automatically during Windows startup. The default service name is
MariaDBif noservice_namevalue is given. For more information, see , "Starting MariaDB as a Windows Service".--language=lang_name, -Llang_nameVersion Deprecated 5.6.1 Command-Line Format --language=name-LOption-File Format languageOption Sets Variable Yes, languageVariable Name languageVariable Scope Global Dynamic Variable No Deprecated 5.6.1 Permitted Values Type directory nameDefault /usr/local/mysql/share/mysql/english/The language to use for error messages.
lang_namecan be given as the language name or as the full path name to the directory where the language files are installed. See , "Setting the Error Message Language".In MariaDB 5.6,
--lc-messages-dirand--lc-messagesshould be used rather than--language, which is deprecated as of MariaDB 5.6.1 and handled as an alias for--lc-messages-dir. The--languageoption will be removed in a future MariaDB release.--large-pagesCommand-Line Format --large-pagesOption-File Format large-pagesOption Sets Variable Yes, large_pagesVariable Name large_pagesVariable Scope Global Dynamic Variable No Platform Specific linux Permitted Values Type (linux) booleanDefault FALSESome hardware/operating system architectures support memory pages greater than the default (usually 4KB). The actual implementation of this support depends on the underlying hardware and operating system. Applications that perform a lot of memory accesses may obtain performance improvements by using large pages due to reduced Translation Lookaside Buffer (TLB) misses.
MySQL 5.6 supports the Linux implementation of large page support (which is called HugeTLB in Linux). See , "Enabling Large Page Support". For Solaris support of large pages, see the description of the
--super-large-pagesoption.--large-pagesis disabled by default.--lc-messages=locale_nameCommand-Line Format --lc-messages=nameOption-File Format lc-messagesOption Sets Variable Yes, lc_messagesVariable Name lc-messagesVariable Scope Global, Session Dynamic Variable Yes Permitted Values Type stringThe locale to use for error messages. The server converts the argument to a language name and combines it with the value of the
--lc-messages-dirto produce the location for the error message file. See , "Setting the Error Message Language".--lc-messages-dir=pathCommand-Line Format --lc-messages-dir=pathOption-File Format lc-messages-dirOption Sets Variable Yes, lc_messages_dirVariable Name lc-messages-dirVariable Scope Global Dynamic Variable No Permitted Values Type directory nameThe directory where error messages are located. The value is used together with the value of
--lc-messagesto produce the location for the error message file. See , "Setting the Error Message Language".--log[=,file_name]-l [file_name]Version Removed 5.6.1 Command-Line Format --log[=name]-lOption-File Format logOption Sets Variable Yes, logVariable Name logVariable Scope Global Dynamic Variable Yes Deprecated 5.1.29, by general-logPermitted Values Type stringDefault OFFThe
--logoption was removed in MariaDB 5.6.1 (along with thelogsystem variable). Instead, use the--general-logoption to enable the general query log and the--general_log_file=option to set the general query log file name.file_name--log-error[=file_name]Command-Line Format --log-error[=name]Option-File Format log-errorOption Sets Variable Yes, log_errorVariable Name log_errorVariable Scope Global Dynamic Variable No Permitted Values Type file nameLog errors and startup messages to this file. See , "The Error Log". If you omit the file name, MariaDB uses
. If the file name has no extension, the server adds an extension ofhost_name.err.err.--log-isam[=file_name]Command-Line Format --log-isam[=name]Option-File Format log-isamPermitted Values Type file nameLog all
MyISAMchanges to this file (used only when debuggingMyISAM).--log-output[=value,...]Command-Line Format --log-output[=name]Option-File Format log-outputOption Sets Variable Yes, log_outputVariable Name log_outputVariable Scope Global Dynamic Variable Yes Permitted Values Type setDefault FILEValid Values TABLEFILENONEThis option determines the destination for general query log and slow query log output. The option value can be given as one or more of the words
TABLE,FILE, orNONE. If the option is given without a value, the default isFILE.TABLEselect logging to thegeneral_logandslow_logtables in theMariaDBdatabase as a destination.FILEselects logging to log files as a destination.NONEdisables logging. IfNONEis present in the option value, it takes precedence over any other words that are present.TABLEandFILEcan both be given to select to both log output destinations.This option selects log output destinations, but does not enable log output. To do that, use the
--general_logand--slow_query_logoptions. ForFILElogging, the--general_log_fileand-slow_query_log_fileoptions determine the log file location. For more information, see , "Selecting General Query and Slow Query Log Output Destinations".--log-queries-not-using-indexesCommand-Line Format --log-queries-not-using-indexesOption-File Format log-queries-not-using-indexesOption Sets Variable Yes, log_queries_not_using_indexesVariable Name log_queries_not_using_indexesVariable Scope Global Dynamic Variable Yes Permitted Values Type booleanDefault OFFIf you are using this option with the slow query log enabled, queries that are expected to retrieve all rows are logged. See , "The Slow Query Log". This option does not necessarily mean that no index is used. For example, a query that uses a full index scan uses an index but would be logged because the index would not limit the number of rows.
--log-rawVersion Introduced 5.6.3 Command-Line Format --log-raw[=value]Option-File Format log-raw[=value]Permitted Values Type booleanDefault OFFAs of MariaDB 5.6.3, passwords in statements written to the general query log, slow query log, and binary log are rewritten by the server not to occur literally in plain text. Password rewriting can be suppressed for the general query log by starting the server with the
--log-rawoption. This option may be useful for diagnostic purposes, to see the exact text of statements as received by the server, but for security reasons is not recommended for production use.Before MariaDB 5.6.3, passwords in statements are not rewritten and the general query log should be protected. See , "Administrator Guidelines for Password Security".
This option was added in MariaDB 5.6.3.
--log-short-formatCommand-Line Format --log-short-formatOption-File Format log-short-formatPermitted Values Type booleanDefault FALSELog less information to the binary log and slow query log, if they have been activated.
--log-slow-admin-statementsCommand-Line Format --log-slow-admin-statementsOption-File Format log-slow-admin-statementsPermitted Values Type booleanDefault FALSELog slow administrative statements such as
OPTIMIZE TABLE,ANALYZE TABLE, andALTER TABLEto the slow query log.--log-slow-queries[=file_name]Version Removed 5.6.1 Command-Line Format --log-slow-queries[=name]Option-File Format log-slow-queriesOption Sets Variable Yes, log_slow_queriesVariable Name log_slow_queriesVariable Scope Global Dynamic Variable Yes Deprecated 5.1.29, by slow-query-logPermitted Values Type booleanThe
--log-slow-queriesoption was removed in MariaDB 5.6.1 (along with thelog_slow_queriessystem variable). Instead, use the--slow_query_logoption to enable the slow query log and the--slow_query_log_file=option to set the slow query log file name.file_name--log-tc=file_nameCommand-Line Format --log-tc=nameOption-File Format log-tcPermitted Values Type file nameDefault tc.logThe name of the memory-mapped transaction coordinator log file (for XA transactions that affect multiple storage engines when the binary log is disabled). The default name is
tc.log. The file is created under the data directory if not given as a full path name. Currently, this option is unused.--log-tc-size=sizeCommand-Line Format --log-tc-size=#Option-File Format log-tc-sizePermitted Values Platform Bit Size 32Type numericDefault 24576Max Value 4294967295Permitted Values Platform Bit Size 64Type numericDefault 24576Max Value 18446744073709547520The size in bytes of the memory-mapped transaction coordinator log. The default size is 24KB.
--log-warnings[=,level]-W [level]Command-Line Format --log-warnings[=#]-W [#]Option-File Format log-warningsOption Sets Variable Yes, log_warningsVariable Name log_warningsVariable Scope Global Dynamic Variable Yes Disabled by skip-log-warningsPermitted Values Platform Bit Size 64Type numericDefault 1Range 0 .. 18446744073709547520Print out warnings such as
Aborted connection...to the error log. Enabling this option is recommended, for example, if you use replication (you get more information about what is happening, such as messages about network failures and reconnections). This option is enabled (1) by default, and the defaultlevelvalue if omitted is 1. To disable this option, use--log-warnings=0. If the value is greater than 1, aborted connections are written to the error log, and access-denied errors for new connection attempts are written. See "Communication Errors and Aborted Connections".If a slave server was started with
--log-warningsenabled, the slave prints messages to the error log to provide information about its status, such as the binary log and relay log coordinates where it starts its job, when it is switching to another relay log, when it reconnects after a disconnect, and so forth. The server logs messages about statements that are unsafe for statement-based logging only if--log-warningsis enabled.--low-priority-updatesCommand-Line Format --low-priority-updatesOption-File Format low-priority-updatesOption Sets Variable Yes, low_priority_updatesVariable Name low_priority_updatesVariable Scope Global, Session Dynamic Variable Yes Permitted Values Type booleanDefault FALSEGive table-modifying operations (
INSERT,REPLACE,DELETE,UPDATE) lower priority than selects. This can also be done using{INSERT | REPLACE | DELETE | UPDATE} LOW_PRIORITY ...to lower the priority of only one query, or bySET LOW_PRIORITY_UPDATES=1to change the priority in one thread. This affects only storage engines that use only table-level locking (MyISAM,MEMORY,MERGE). See , "Table Locking Issues".--min-examined-row-limit=numberCommand-Line Format --min-examined-row-limit=#Option-File Format min-examined-row-limitVariable Name min_examined_row_limitVariable Scope Global, Session Dynamic Variable Yes Permitted Values Platform Bit Size 32Type numericDefault 0Range 0 .. 4294967295Permitted Values Platform Bit Size 64Type numericDefault 0Range 0 .. 18446744073709547520When this option is set, queries which examine fewer than
numberrows are not written to the slow query log. The default is 0.--memlockCommand-Line Format --memlockOption-File Format memlockVariable Name locked_in_memoryVariable Scope Global Dynamic Variable No Permitted Values Type booleanDefault FALSELock the mysqld process in memory. This option might help if you have a problem where the operating system is causing mysqld to swap to disk.
--memlockworks on systems that support themlockall()system call; this includes Solaris, most Linux distributions that use a 2.4 or newer kernel, and perhaps other Unix systems. On Linux systems, you can tell whether or notmlockall()(and thus this option) is supported by checking to see whether or not it is defined in the systemmman.hfile, like this:shell>
grep mlockall /usr/include/sys/mman.hIf
mlockall()is supported, you should see in the output of the previous command something like the following:extern int mlockall (int __flags) __THROW;
ImportantUse of this option may require you to run the server as
root, which, for reasons of security, is normally not a good idea. See , "How to Run MariaDB as a Normal User".On Linux and perhaps other systems, you can avoid the need to run the server as
rootby changing thelimits.conffile. See the notes regarding the memlock limit in , "Enabling Large Page Support".You must not try to use this option on a system that does not support the
mlockall()system call; if you do so, mysqld will very likely crash as soon as you try to start it.--myisam-block-size=NCommand-Line Format --myisam-block-size=#Option-File Format myisam-block-sizePermitted Values Type numericDefault 1024Range 16384The block size to be used for
MyISAMindex pages.--myisam-recover-options[=option[,option]...]]Command-Line Format --myisam-recover-options[=name]Option-File Format myisam-recover-optionsOption Sets Variable Yes, myisam_recover_optionsPermitted Values Type enumerationDefault OFFValid Values OFFDEFAULTBACKUPFORCEQUICKSet the
MyISAMstorage engine recovery mode. The option value is any combination of the values ofDEFAULT,OFF,BACKUP,FORCE, orQUICK. If you specify multiple values, separate them by commas. Specifying the option with no argument is the same as specifyingDEFAULT, and specifying with an explicit value of''disables recovery (same as not giving the option). If recovery is enabled, each time mysqld opens aMyISAMtable, it checks whether the table is marked as crashed or was not closed properly. (The last option works only if you are running with external locking disabled.) If this is the case, mysqld runs a check on the table. If the table was corrupted, mysqld attempts to repair it.The following options affect how the repair works.
Option Description DEFAULTRecovery without backup, forcing, or quick checking. OFFRecovery without backup, forcing, or quick checking. BACKUPIf the data file was changed during recovery, save a backup of the file astbl_name.MYD.tbl_name-datetime.BAKFORCERun recovery even if we would lose more than one row from the .MYDfile.QUICKDo not check the rows in the table if there are not any delete blocks. Before the server automatically repairs a table, it writes a note about the repair to the error log. If you want to be able to recover from most problems without user intervention, you should use the options
BACKUP,FORCE. This forces a repair of a table even if some rows would be deleted, but it keeps the old data file as a backup so that you can later examine what happened.--old-alter-tableCommand-Line Format --old-alter-tableOption-File Format old-alter-tableOption Sets Variable Yes, old_alter_tableVariable Name old_alter_tableVariable Scope Global, Session Dynamic Variable Yes Permitted Values Type booleanDefault OFFWhen this option is given, the server does not use the optimized method of processing an
ALTER TABLEoperation. It reverts to using a temporary table, copying over the data, and then renaming the temporary table to the original, as used by MariaDB 5.0 and earlier. For more information on the operation ofALTER TABLE, see , "ALTER TABLESyntax".--old-passwordsCommand-Line Format --old_passwordsOption-File Format old-passwordsOption Sets Variable Yes, old_passwordsVariable Name old_passwordsVariable Scope Global, Session Dynamic Variable Yes Permitted Values Type booleanDefault FALSEForce the server to generate short (pre-4.1) password hashes for new passwords. This is useful for compatibility when the server must support older client programs. See , "Password Hashing in MySQL".
--old-style-user-limitsCommand-Line Format --old-style-user-limitsOption-File Format old-style-user-limitsPermitted Values Type booleanDefault FALSEEnable old-style user limits. (Before MariaDB 5.0.3, account resource limits were counted separately for each host from which a user connected rather than per account row in the
usertable.) See , "Setting Account Resource Limits".--one-threadVersion Removed 5.6.1 Command-Line Format --one-threadOption-File Format one-threadThis option was removed in MariaDB 5.6.1. Use
--thread_handling=no-threadsinstead.--open-files-limit=countCommand-Line Format --open-files-limit=#Option-File Format open-files-limitOption Sets Variable Yes, open_files_limitVariable Name open_files_limitVariable Scope Global Dynamic Variable No Permitted Values Type numericDefault 0Range 0 .. 65535Changes the number of file descriptors available to mysqld. You should try increasing the value of this option if mysqld gives you the error
Too many open files. mysqld uses the option value to reserve descriptors withsetrlimit(). If the requested number of file descriptors cannot be allocated, mysqld writes a warning to the error log.mysqld may attempt to allocate more than the requested number of descriptors (if they are available), using the values of
max-connectionsandtable_open_cacheto estimate whether more descriptors will be needed.--partition[=value]Command-Line Format --partitionOption-File Format partitionOption Sets Variable Yes, have_partitioningVariable Name partitionVariable Scope Global Dynamic Variable No Disabled by skip-partitionPermitted Values Type booleanDefault ONEnables or disables user-defined partitioning support in the MariaDB Server.
--performance_schema_consumer_consumer_name=valueConfigure a Performance Schema consumer. For details, see , "Performance Schema Startup Configuration".
--performance_schema_instrument=instrument_name=valueConfigure a Performance Schema instrument. For details, see , "Performance Schema Startup Configuration".
--pid-file=pathCommand-Line Format --pid-file=file_nameOption-File Format pid-file=file_nameOption Sets Variable Yes, pid_fileVariable Name pid_fileVariable Scope Global Dynamic Variable No Permitted Values Type file nameThe path name of the process ID file. The server creates the file in the data directory unless an absolute path name is given to specify a different directory. This file is used by other programs such as mysqld_safe to determine the server's process ID.
--plugin-xxxSpecifies an option that pertains to a server plugin. For example, many storage engines can be built as plugins, and for such engines, options for them can be specified with a
--pluginprefix. Thus, the--innodb_file_per_tableoption forInnoDBcan be specified as--plugin-innodb_file_per_table.For boolean options that can be enabled or disabled, the
--skipprefix and other alternative formats are supported as well (see , "Program Option Modifiers"). For example,--skip-plugin-innodb_file_per_tabledisablesinnodb_file_per_table.The rationale for the
--pluginprefix is that it enables plugin options to be specified unambiguously if there is a name conflict with a built-in server option. For example, were a plugin writer to name a plugin "sql" and implement a "mode" option, the option name might be--sql-mode, which would conflict with the built-in option of the same name. In such cases, references to the conflicting name are resolved in favor of the built-in option. To avoid the ambiguity, users can specify the plugin option as--plugin-sql-mode. Use of the--pluginprefix for plugin options is recommended to avoid any question of ambiguity.--plugin-load=plugin_listCommand-Line Format --plugin-load=plugin_listOption-File Format plugin-load=plugin_listPermitted Values Type stringThis option tells the server to load the named plugins at startup. The option value is a semicolon-separated list of
pairs. Eachname=plugin_librarynameis the name of the plugin, andplugin_libraryis the name of the shared library that contains the plugin code. Each library file must be located in the directory named by theplugin_dirsystem variable. For example, if plugins namedmyplug1andmyplug2have library filesmyplug1.soandmyplug2.so, use this option to load them at startup:shell>
mysqld --plugin-load=myplug1=myplug1.so;myplug2=myplug2.soIf multiple
--plugin-loadoptions are given, only the last one is used. Additional plugins to load may be specified using--plugin-load-addoptions.If a plugin library is named without any preceding plugin name, the server loads all plugins in the library.
Each plugin is loaded for a single invocation of mysqld only. After a restart, the plugin is not loaded unless
--plugin-loadis used again. This is in contrast toINSTALL PLUGIN, which adds an entry to themysql.pluginstable to cause the plugin to be loaded for every normal server startup.Under normal startup, the server determines which plugins to load by reading the
mysql.pluginssystem table. If the server is started with the--skip-grant-tablesoption, it does not consult themysql.pluginstable and does not load plugins listed there.--plugin-loadenables plugins to be loaded even when--skip-grant-tablesis given.--plugin-loadalso enables plugins to be loaded at startup under configurations when plugins cannot be loaded at runtime.For additional information about plugin loading, see , "Installing and Uninstalling Plugins".
--plugin-load-add=plugin_listVersion Introduced 5.6.3 Command-Line Format --plugin-load-add=plugin_listOption-File Format plugin-load-add=plugin_listPermitted Values Type stringThis option complements the
--plugin-loadoption.--plugin-load-addadds a plugin or plugins to the set of plugins to be loaded at startup. The argument format is the same as for--plugin-load.--plugin-load-addcan be used to avoid specifying a large set of plugins as a single long unwieldy--plugin-loadargument. This option was added in MariaDB 5.6.3.--plugin-load-addcan be given in the absence of--plugin-load, but any instance of--plugin-load-addthat appears before--plugin-load. has no effect because--plugin-loadresets the set of plugins to load. In other words, these options:--plugin-load=x --plugin-load-add=y
are equivalent to this option:
--plugin-load=x;y
But these options:
--plugin-load-add=y --plugin-load=x
are equivalent to this option:
--plugin-load=x
For additional information about plugin loading, see , "Installing and Uninstalling Plugins".
--port=,port_num-Pport_numCommand-Line Format --port=#-POption-File Format portOption Sets Variable Yes, portVariable Name portVariable Scope Global Dynamic Variable No Permitted Values Type numericDefault 3306The port number to use when listening for TCP/IP connections. The port number must be 1024 or higher unless the server is started by the
rootsystem user.--port-open-timeout=numCommand-Line Format --port-open-timeout=#Option-File Format port-open-timeoutPermitted Values Type numericDefault 0On some systems, when the server is stopped, the TCP/IP port might not become available immediately. If the server is restarted quickly afterward, its attempt to reopen the port can fail. This option indicates how many seconds the server should wait for the TCP/IP port to become free if it cannot be opened. The default is not to wait.
--remove [service_name]Command-Line Format --remove [service_name](Windows only) Remove a MariaDB Windows service. The default service name is
MariaDBif noservice_namevalue is given. For more information, see , "Starting MariaDB as a Windows Service".--safe-modeCommand-Line Format --safe-modeOption-File Format safe-modeDeprecated 5.0 Skip some optimization stages.
--safe-user-createCommand-Line Format --safe-user-createOption-File Format safe-user-createPermitted Values Type booleanDefault FALSEIf this option is enabled, a user cannot create new MariaDB users by using the
GRANTstatement unless the user has theINSERTprivilege for themysql.usertable or any column in the table. If you want a user to have the ability to create new users that have those privileges that the user has the right to grant, you should grant the user the following privilege:GRANT INSERT(user) ON mysql.user TO '
user_name'@'host_name';This ensures that the user cannot change any privilege columns directly, but has to use the
GRANTstatement to give privileges to other users.--secure-authCommand-Line Format --secure-authOption-File Format secure-authOption Sets Variable Yes, secure_authVariable Name secure_authVariable Scope Global Dynamic Variable Yes Permitted Values (<= 5.6.4) Type booleanDefault OFFPermitted Values (>= 5.6.5) Type booleanDefault ONThis option causes the server to block connections by clients that attempt to use accounts that have passwords stored in the old (pre-4.1) format. Use it to prevent all use of passwords employing the old format (and hence insecure communication over the network). Before MariaDB 5.6.5, this option is disabled by default. As of MariaDB 5.6.5, it is enabled by default; to disable it, use
--skip-secure-auth.Server startup fails with an error if this option is enabled and the privilege tables are in pre-4.1 format. See "
Client does not support authentication protocol".--secure-file-priv=pathCommand-Line Format --secure-file-priv=pathOption-File Format secure-file-priv=pathOption Sets Variable Yes, secure_file_privVariable Name secure-file-privVariable Scope Global Dynamic Variable No Permitted Values Type stringThis option limits the effect of the
LOAD-FILE()function and theLOAD DATAandSELECT ... INTO OUTFILEstatements to work only with files in the specified directory.--shared-memoryEnable shared-memory connections by local clients. This option is available only on Windows.
--shared-memory-base-name=nameThe name of shared memory to use for shared-memory connections. This option is available only on Windows. The default name is
MariaDB. The name is case sensitive.--skip-concurrent-insertTurn off the ability to select and insert at the same time on
MyISAMtables. (This is to be used only if you think you have found a bug in this feature.) See , "Concurrent Inserts".--skip-external-lockingDo not use external locking (system locking). This affects only
MyISAMtable access. For more information, including conditions under which it can and cannot be used, see , "External Locking".External locking has been disabled by default since MariaDB 4.0.
--skip-event-schedulerCommand-Line Format --skip-event-scheduler--disable-event-schedulerOption-File Format skip-event-schedulerTurns the Event Scheduler
OFF. This is not the same as disabling the Event Scheduler, which requires setting--event-scheduler=DISABLED; see The--event-schedulerOption, for more information.--skip-grant-tablesThis option causes the server to start without using the privilege system at all, which gives anyone with access to the server unrestricted access to all databases. You can cause a running server to start using the grant tables again by executing mysqladmin flush-privileges or mysqladmin reload command from a system shell, or by issuing a MariaDB
FLUSH PRIVILEGESstatement after connecting to the server. This option also suppresses loading of plugins that were installed with theINSTALL PLUGINstatement, user-defined functions (UDFs), and scheduled events. To cause plugins to be loaded anyway, use the--plugin-loadoption.--skip-grant-tablesis unavailable if MariaDB was configured with theDISABLE_GRANT_OPTIONScompiler flag. See , "MySQL Source-Configuration Options".--skip-host-cacheDisable use of the internal host cache for faster name-to-IP resolution. In this case, the server performs a DNS lookup every time a client connects. See , "DNS Lookup Optimization and the Host Cache".
Use of
--skip-host-cacheis similar to setting thehost_cache_sizesystem variable to 0, buthost_cache_sizeis more flexible because it can also be used to resize, enable, or disable the host cache at runtime, not just at server startup. If you start the server with--skip-host-cache, the host cache cannot be re-enabled at runtime.--skip-innodbDisable the
InnoDBstorage engine. In this case, because the default storage engine isInnoDB, the server will not start unless you also use--default-storage-engineand--default-tmp-storage-engineto set the default to some other engine for both permanent andTEMPORARYtables.--skip-name-resolveDo not resolve host names when checking client connections. Use only IP addresses. If you use this option, all
Hostcolumn values in the grant tables must be IP addresses orlocalhost. See , "DNS Lookup Optimization and the Host Cache".--skip-networkingDo not listen for TCP/IP connections at all. All interaction with mysqld must be made using named pipes or shared memory (on Windows) or Unix socket files (on Unix). This option is highly recommended for systems where only local clients are permitted. See , "DNS Lookup Optimization and the Host Cache".
--skip-partitionCommand-Line Format --skip-partition--disable-partitionOption-File Format skip-partitionDisables user-defined partitioning. Existing partitioned tables cannot be accessed when the server has been started with this option.
--ssl*Options that begin with
--sslspecify whether to permit clients to connect using SSL and indicate where to find SSL keys and certificates. See , "SSL Command Options".--standaloneCommand-Line Format --standaloneOption-File Format standalonePlatform Specific windows Available on Windows only; instructs the MariaDB server not to run as a service.
--super-large-pagesStandard use of large pages in MariaDB attempts to use the largest size supported, up to 4MB. Under Solaris, a "super large pages" feature enables uses of pages up to 256MB. This feature is available for recent SPARC platforms. It can be enabled or disabled by using the
--super-large-pagesor--skip-super-large-pagesoption.--symbolic-links,--skip-symbolic-linksCommand-Line Format --symbolic-linksOption-File Format symbolic-linksEnable or disable symbolic link support. This option has different effects on Windows and Unix:
- On Windows, enabling symbolic links enables you to establish a symbolic link to a database directory by creating a
file that contains the path to the real directory. See , "Using Symbolic Links for Databases on Windows".db_name.sym - On Unix, enabling symbolic links means that you can link a
MyISAMindex file or data file to another directory with theINDEX DIRECTORYorDATA DIRECTORYoptions of theCREATE TABLEstatement. If you delete or rename the table, the files that its symbolic links point to also are deleted or renamed. See , "Using Symbolic Links for Tables on Unix".
- On Windows, enabling symbolic links enables you to establish a symbolic link to a database directory by creating a
--skip-show-databaseCommand-Line Format --skip-show-databaseOption-File Format skip-show-databaseOption Sets Variable Yes, skip_show_databaseVariable Name skip_show_databaseVariable Scope Global Dynamic Variable No With this option, the
SHOW DATABASESstatement is permitted only to users who have theSHOW DATABASESprivilege, and the statement displays all database names. Without this option,SHOW DATABASESis permitted to all users, but displays each database name only if the user has theSHOW DATABASESprivilege or some privilege for the database. Note that any global privilege is considered a privilege for the database.--skip-stack-traceCommand-Line Format --skip-stack-traceOption-File Format skip-stack-traceDo not write stack traces. This option is useful when you are running mysqld under a debugger. On some systems, you also must use this option to get a core file. See MySQL Internals: Porting.
--skip-thread-priorityVersion Removed 5.6.1 Command-Line Format --skip-thread-priorityOption-File Format skip-thread-priorityDeprecated 5.1.29 Disable using thread priorities for faster response time. This option was unused and was removed in MariaDB 5.6.1.
--slow-query-log[={0|1}]Command-Line Format --slow-query-logOption-File Format slow-query-logOption Sets Variable Yes, slow_query_logVariable Name slow_query_logVariable Scope Global Dynamic Variable Yes Permitted Values Type booleanDefault OFFSpecify the initial slow query log state. With no argument or an argument of 1, the
--slow-query-logoption enables the log. If omitted or given with an argument of 0, the option disables the log.--slow-start-timeout=timeoutVersion Introduced 5.6.5 Command-Line Format --slow-start-timeout=#Option-File Format slow-start-timeout=#Permitted Values Type (windows) numericDefault 15000This option controls the Windows service control manager's service start timeout. The value is the maximum number of milliseconds that the service control manager waits before trying to kill the windows service during startup. The default value is 15000 (15 seconds). If the MariaDB service takes too long to start, you may need to increase this value. A value of 0 means there is no timeout.
--socket=pathCommand-Line Format --socket=nameOption-File Format socketOption Sets Variable Yes, socketVariable Name socketVariable Scope Global Dynamic Variable No Permitted Values Type file nameDefault /tmp/mysql.sockOn Unix, this option specifies the Unix socket file to use when listening for local connections. The default value is
/tmp/mysql.sock. If this option is given, the server creates the file in the data directory unless an absolute path name is given to specify a different directory. On Windows, the option specifies the pipe name to use when listening for local connections that use a named pipe. The default value isMariaDB(not case sensitive).--sql-mode=value[,value[,value...]]Command-Line Format --sql-mode=nameOption-File Format sql-modeOption Sets Variable Yes, sql_modeVariable Name sql_modeVariable Scope Global, Session Dynamic Variable Yes Permitted Values Type setDefault ''Valid Values ALLOW_INVALID_DATESANSI_QUOTESERROR_FOR_DIVISION_BY_ZEROHIGH_NOT_PRECEDENCEIGNORE_SPACENO_AUTO_CREATE_USERNO_AUTO_VALUE_ON_ZERONO_BACKSLASH_ESCAPESNO_DIR_IN_CREATENO_ENGINE_SUBSTITUTIONNO_FIELD_OPTIONSNO_KEY_OPTIONSNO_TABLE_OPTIONSNO_UNSIGNED_SUBTRACTIONNO_ZERO_DATENO_ZERO_IN_DATEONLY_FULL_GROUP_BYPAD_CHAR_TO_FULL_LENGTHPIPES_AS_CONCATREAL_AS_FLOATSTRICT_ALL_TABLESSTRICT_TRANS_TABLESSet the SQL mode. See , "Server SQL Modes".
--sysdate-is-nowCommand-Line Format --sysdate-is-nowOption-File Format sysdate-is-nowPermitted Values Type booleanDefault FALSESYSDATE()by default returns the time at which it executes, not the time at which the statement in which it occurs begins executing. This differs from the behavior ofNOW(). This option causesSYSDATE()to be an alias forNOW(). For information about the implications for binary logging and replication, see the description forSYSDATE()in , "Date and Time Functions" and forSET TIMESTAMPin , "Server System Variables".--tc-heuristic-recover={COMMIT|ROLLBACK}Command-Line Format --tc-heuristic-recover=nameOption-File Format tc-heuristic-recoverPermitted Values Type enumerationValid Values COMMITRECOVERThe type of decision to use in the heuristic recovery process. Currently, this option is unused.
--temp-poolCommand-Line Format --temp-poolOption-File Format temp-poolPermitted Values Type booleanDefault TRUEThis option causes most temporary files created by the server to use a small set of names, rather than a unique name for each new file. This works around a problem in the Linux kernel dealing with creating many new files with different names. With the old behavior, Linux seems to "leak" memory, because it is being allocated to the directory entry cache rather than to the disk cache. This option is ignored except on Linux.
--transaction-isolation=levelCommand-Line Format --transaction-isolation=nameOption-File Format transaction-isolationOption Sets Variable Yes, tx_isolationPermitted Values Type enumerationValid Values READ-UNCOMMITTEDREAD-COMMITTEDREPEATABLE-READSERIALIZABLESets the default transaction isolation level. The
levelvalue can beREAD-UNCOMMITTED,READ-COMMITTED,REPEATABLE-READ, orSERIALIZABLE. See , "SET TRANSACTIONSyntax".The default transaction isolation level can also be set at runtime using the
SET TRANSACTIONstatement or by setting thetx_isolationsystem variable.--transaction-read-only=modeVersion Introduced 5.6.5 Command-Line Format --transaction-read-only[=value]Option-File Format transaction-read-only[=value]Option Sets Variable Yes, tx_read_onlyPermitted Values Type booleanSets the default transaction access mode. The value can be
OFF(read/write, the default) orON(read only).To set the default transaction access mode at runtime, use the
SET TRANSACTIONstatement or set thetx_read_onlysystem variable. See , "SET TRANSACTIONSyntax".This option was added in MariaDB 5.6.5.
--tmpdir=,path-tpathCommand-Line Format --tmpdir=path-tOption-File Format tmpdirOption Sets Variable Yes, tmpdirVariable Name tmpdirVariable Scope Global Dynamic Variable No Permitted Values Type file nameThe path of the directory to use for creating temporary files. It might be useful if your default
/tmpdirectory resides on a partition that is too small to hold temporary tables. This option accepts several paths that are used in round-robin fashion. Paths should be separated by colon characters (":") on Unix and semicolon characters (";") on Windows. If the MariaDB server is acting as a replication slave, you should not set--tmpdirto point to a directory on a memory-based file system or to a directory that is cleared when the server host restarts. For more information about the storage location of temporary files, see "Where MariaDB Stores Temporary Files". A replication slave needs some of its temporary files to survive a machine restart so that it can replicate temporary tables orLOAD DATA INFILEoperations. If files in the temporary file directory are lost when the server restarts, replication fails.--user={,user_name|user_id}-u {user_name|user_id}Command-Line Format --user=name-u nameOption-File Format userPermitted Values Type stringRun the mysqld server as the user having the name
user_nameor the numeric user IDuser_id. ("User" in this context refers to a system login account, not a MariaDB user listed in the grant tables.)This option is mandatory when starting mysqld as
root. The server changes its user ID during its startup sequence, causing it to run as that particular user rather than asroot. See , "General Security Guidelines".To avoid a possible security hole where a user adds a
--user=rootoption to amy.cnffile (thus causing the server to run asroot), mysqld uses only the first--useroption specified and produces a warning if there are multiple--useroptions. Options in/etc/my.cnfand$MYSQL_HOME/my.cnfare processed before command-line options, so it is recommended that you put a--useroption in/etc/my.cnfand specify a value other thanroot. The option in/etc/my.cnfis found before any other--useroptions, which ensures that the server runs as a user other thanroot, and that a warning results if any other--useroption is found.--verbose,-vUse this option with the
--helpoption for detailed help.--version,-VDisplay version information and exit.
You can assign a value to a server system variable by using an option of the form --. For example, var_name=value--key_buffer_size=32M sets the key_buffer_size variable to a value of 32MB.
Note that when you assign a value to a variable, MariaDB might automatically correct the value to stay within a given range, or adjust the value to the closest permissible value if only certain values are permitted.
If you want to restrict the maximum value to which a variable can be set at runtime with SET, you can define this by using the --maximum- command-line option.
var_name=value
You can change the values of most system variables for a running server with the SET statement. See , "SET Syntax".
, "Server System Variables", provides a full description for all variables, and additional information for setting them at server startup and runtime. , "Tuning Server Parameters", includes information on optimizing the server by tuning system variables.