mysqld - 官方详细文档(MySQL社区版Ver 8.0.20 for Win64)_1

mysqld.exe  Ver 8.0.20 for Win64 on x86_64 (MySQL Community Server - GPL)
Copyright (c) 2000, 2020, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Starts the MySQL database server.

Usage: mysqld.exe [OPTIONS]
NT and Win32 specific options:
  --install                     Install the default service (NT).
  --install-manual              Install the default service started manually (NT).
  --install service_name        Install an optional service (NT).
  --install-manual service_name Install an optional service started manually (NT).
  --remove                      Remove the default service from the service list (NT).
  --remove service_name         Remove the service_name from the service list (NT).
  --enable-named-pipe           Only to be used for the default server (NT).
  --standalone                  Dummy option to start as a standalone server (NT).


Default options are read from the following files in the given order:
C:\WINDOWS\my.ini C:\WINDOWS\my.cnf C:\my.ini C:\my.cnf C:\Program Files\MySQL-8.0.20\my.ini C:\Program Files\MySQL-8.0.20\my.cnf
The following groups are read: mysqld server mysqld-8.0
The following options may be given as the first argument:
--print-defaults        Print the program argument list and exit.
--no-defaults           Don't read default options from any option file,
                        except for login file.
--defaults-file=#       Only read default options from the given file #.
--defaults-extra-file=# Read this file after the global files are read.
--defaults-group-suffix=#
                        Also read groups with concat(group, suffix)
--login-path=#          Read this path from the login file.

  --abort-slave-event-count=#
                      Option used by mysql-test for debugging and testing of
                      replication.
  --activate-all-roles-on-login
                      Automatically set all granted roles as active after the
                      user has authenticated successfully.
  --admin-address=name
                      IP address to bind to for service connection. Address can
                      be an IPv4 address, IPv6 address, or host name. Wildcard
                      values *, ::, 0.0.0.0 are not allowed. Address value can
                      have following optional network namespace separated by
                      the delimiter / from the address value. E.g., the
                      following value 192.168.1.1/red specifies IP addresses to
                      listen for incoming TCP connections that have to be
                      placed into the namespace 'red'. Using of network
                      namespace requires its support from underlying Operating
                      System. Attempt to specify a network namespace for a
                      platform that doesn't support it results in error during
                      socket creation.
  --admin-port=#      Port number to use for service connection, built-in
                      default (33062)
  --allow-suspicious-udfs
                      Allows use of UDFs consisting of only one symbol xxx()
                      without corresponding xxx_init() or xxx_deinit(). That
                      also means that one can load any function from any
                      library, for example exit() from libc.so
  -a, --ansi          Use ANSI SQL syntax instead of MySQL syntax. This mode
                      will also set transaction isolation level 'serializable'.
  --archive[=name]    Enable or disable ARCHIVE plugin. Possible values are ON,
                      OFF, FORCE (don't start if the plugin fails to load).
  --auto-generate-certs
                      Auto generate SSL certificates at server startup if --ssl
                      is set to ON and none of the other SSL system variables
                      are specified and certificate/key files are not present
                      in data directory.
                      (Defaults to on; use --skip-auto-generate-certs to disable.)
  --auto-increment-increment[=#]
                      Auto-increment columns are incremented by this
  --auto-increment-offset[=#]
                      Offset added to Auto-increment columns. Used when
                      auto-increment-increment != 1
  --autocommit        Set default value for autocommit (0 or 1)
                      (Defaults to on; use --skip-autocommit to disable.)
  --automatic-sp-privileges
                      Creating and dropping stored procedures alters ACLs
                      (Defaults to on; use --skip-automatic-sp-privileges to disable.)
  --avoid-temporal-upgrade
                      When this option is enabled, the pre-5.6.4 temporal types
                      are not upgraded to the new format for ALTER TABLE
                      requests ADD/CHANGE/MODIFY COLUMN, ADD INDEX or FORCE
                      operation. This variable is deprecated and will be
                      removed in a future release.
  --back-log=#        The number of outstanding connection requests MySQL can
                      have. This comes into play when the main MySQL thread
                      gets very many connection requests in a very short time
  -b, --basedir=name  Path to installation directory. All paths are usually
                      resolved relative to this
  --big-tables        Allow big result sets by saving all temporary sets on
                      file (Solves most 'table full' errors)
  --bind-address=name IP address(es) to bind to. Syntax: address[,address]...,
                      where address can be an IPv4 address, IPv6 address, host
                      name or one of the wildcard values *, ::, 0.0.0.0. In
                      case more than one address is specified in a
                      comma-separated list, wildcard values are not allowed.
                      Every address can have optional network namespace
                      separated by the delimiter / from the address value.
                      E.g., the following value
                      192.168.1.1/red,172.16.1.1/green,193.168.1.1 specifies
                      three IP addresses to listen for incoming TCP connections
                      two of that have to be placed in corresponding
                      namespaces: the address 192.168.1.1 must be placed into
                      the namespace red and the address 172.16.1.1 must be
                      placed into the namespace green. Using of network
                      namespace requires its support from underlying Operating
                      System. Attempt to specify a network namespace for a
                      platform that doesn't support it results in error during
                      socket creation.
  --binlog-cache-size=#
                      The size of the transactional cache for updates to
                      transactional engines for the binary log. If you often
                      use transactions containing many statements, you can
                      increase this to get more performance
  --binlog-checksum=name
                      Type of BINLOG_CHECKSUM_ALG. Include checksum for log
                      events in the binary log. Possible values are NONE and
                      CRC32; default is CRC32.
  --binlog-direct-non-transactional-updates
                      Causes updates to non-transactional engines using
                      statement format to be written directly to binary log.
                      Before using this option make sure that there are no
                      dependencies between transactional and non-transactional
                      tables such as in the statement INSERT INTO t_myisam
                      SELECT * FROM t_innodb; otherwise, slaves may diverge
                      from the master.
  --binlog-do-db=name Tells the master it should log updates for the specified
                      database, and exclude all others not explicitly
                      mentioned.
  --binlog-encryption Enable/disable binary and relay logs encryption.
  --binlog-error-action=name
                      When statements cannot be written to the binary log due
                      to a fatal error, the server can either ignore the error
                      and let the master continue, or abort.
  --binlog-expire-logs-seconds=#
                      If non-zero, binary logs will be purged after
                      binlog_expire_logs_seconds seconds; If both this option
                      and expire_logs_days are set to non-zero  values, this
                      option takes priority. Purges happen at startup and at
                      binary log rotation.
  --binlog-format=name
                      What form of binary logging the master will use: either
                      ROW for row-based binary logging, STATEMENT for
                      statement-based binary logging, or MIXED. MIXED is
                      statement-based binary logging except for those
                      statements where only row-based is correct: those which
                      involve user-defined functions (i.e. UDFs) or the UUID()
                      function; for those, row-based binary logging is
                      automatically used. If NDBCLUSTER is enabled and
                      binlog-format is MIXED, the format switches to row-based
                      and back implicitly per each query accessing an
                      NDBCLUSTER table
  --binlog-group-commit-sync-delay=#
                      The number of microseconds the server waits for the
                      binary log group commit sync queue to fill before
                      continuing. Default: 0. Min: 0. Max: 1000000.
  --binlog-group-commit-sync-no-delay-count=#
                      If there are this many transactions in the commit sync
                      queue and the server is waiting for more transactions to
                      be enqueued (as set using
                      --binlog-group-commit-sync-delay), the commit procedure
                      resumes.
  --binlog-gtid-simple-recovery
                      If this option is enabled, the server does not open more
                      than two binary logs when initializing GTID_PURGED and
                      GTID_EXECUTED, either during server restart or when
                      binary logs are being purged. Enabling this option is
                      useful when the server has already generated many binary
                      logs without GTID events (e.g., having GTID_MODE = OFF).
                      Note: If this option is enabled, GLOBAL.GTID_EXECUTED and
                      GLOBAL.GTID_PURGED may be initialized wrongly in two
                      cases: (1) All binary logs were generated by MySQL 5.7.5
                      or older, and GTID_MODE was ON for some binary logs but
                      OFF for the newest binary log. (2) The oldest existing
                      binary log was generated by MySQL 5.7.5 or older, and SET
                      GTID_PURGED was issued after the oldest binary log was
                      generated. If a wrong set is computed in one of case (1)
                      or case (2), it will remain wrong even if the server is
                      later restarted with this option disabled.
                      (Defaults to on; use --skip-binlog-gtid-simple-recovery to disable.)
  --binlog-ignore-db=name
                      Tells the master that updates to the given database
                      should not be logged to the binary log.
  --binlog-max-flush-queue-time=#
                      The maximum time that the binary log group commit will
                      keep reading transactions before it flush the
                      transactions to the binary log (and optionally sync,
                      depending on the value of sync_binlog).
  --binlog-order-commits
                      Issue internal commit calls in the same order as
                      transactions are written to the binary log. Default is to
                      order commits.
                      (Defaults to on; use --skip-binlog-order-commits to disable.)
  --binlog-rotate-encryption-master-key-at-startup
                      Force binlog encryption master key rotation at startup
  --binlog-row-event-max-size=#
                      The maximum size of a row-based binary log event in
                      bytes. Rows will be grouped into events smaller than this
                      size if possible. The value has to be a multiple of 256.
  --binlog-row-image=name
                      Controls whether rows should be logged in 'FULL',
                      'NOBLOB' or 'MINIMAL' formats. 'FULL', means that all
                      columns in the before and after image are logged.
                      'NOBLOB', means that mysqld avoids logging blob columns
                      whenever possible (e.g. blob column was not changed or is
                      not part of primary key). 'MINIMAL', means that a PK
                      equivalent (PK columns or full row if there is no PK in
                      the table) is logged in the before image, and only
                      changed columns are logged in the after image. (Default:
                      FULL).
  --binlog-row-metadata=name
                      Controls whether metadata is logged using FULL or MINIMAL
                      format. FULL causes all metadata to be logged; MINIMAL
                      means that only metadata actually required by slave is
                      logged. Default: MINIMAL.
  --binlog-row-value-options=name
                      When set to PARTIAL_JSON, this option enables a
                      space-efficient row-based binary log format for UPDATE
                      statements that modify a JSON value using only the
                      functions JSON_SET, JSON_REPLACE, and JSON_REMOVE. For
                      such updates, only the modified parts of the JSON
                      document are included in the binary log, so small changes
                      of big documents may need significantly less space.
  --binlog-rows-query-log-events
                      Allow writing of Rows_query_log events into binary log.
  --binlog-stmt-cache-size=#
                      The size of the statement cache for updates to
                      non-transactional engines for the binary log. If you
                      often use statements updating a great number of rows, you
                      can increase this to get more performance
  --binlog-transaction-compression
                      Whether to compress transactions or not. Transactions are
                      compressed using the ZSTD compression algorythm.
  --binlog-transaction-compression-level-zstd=#
                      Specifies the transaction compression level for ZSTD
                      transaction compression in the binary log.
  --binlog-transaction-dependency-history-size=#
                      Maximum number of rows to keep in the writeset history.
  --binlog-transaction-dependency-tracking=name
                      Selects the source of dependency information from which
                      to assess which transactions can be executed in parallel
                      by the slave's multi-threaded applier. Possible values
                      are COMMIT_ORDER, WRITESET and WRITESET_SESSION.
  --blackhole[=name]  Enable or disable BLACKHOLE plugin. Possible values are
                      ON, OFF, FORCE (don't start if the plugin fails to load).
  --block-encryption-mode=name
                      mode for AES_ENCRYPT/AES_DECRYPT
  --bulk-insert-buffer-size=#
                      Size of tree cache used in bulk insert optimisation. Note
                      that this is a limit per thread!
  --caching-sha2-password-auto-generate-rsa-keys
                      Auto generate RSA keys at server startup if corresponding
                      system variables are not specified and key files are not
                      present at the default location.
                      (Defaults to on; use --skip-caching-sha2-password-auto-generate-rsa-keys to disable.)
  --caching-sha2-password-private-key-path=name
                      A fully qualified path to the private RSA key used for
                      authentication.
  --caching-sha2-password-public-key-path=name
                      A fully qualified path to the public RSA key used for
                      authentication.
  --character-set-client-handshake
                      Don't ignore client side character set value sent during
                      handshake.
                      (Defaults to on; use --skip-character-set-client-handshake to disable.)
  --character-set-filesystem=name
                      Set the filesystem character set.
  -C, --character-set-server=name
                      Set the default character set.
  --character-sets-dir=name
                      Directory where character sets are
  --check-proxy-users If set to FALSE (the default), then proxy user identity
                      will not be mapped for authentication plugins which
                      support mapping from grant tables.  When set to TRUE,
                      users associated with authentication plugins which signal
                      proxy user mapping should be done according to GRANT
                      PROXY privilege definition.
  -r, --chroot=name   Chroot mysqld daemon during startup.
  --collation-server=name
                      Set the default collation.
  --completion-type=name
                      The transaction completion type, one of NO_CHAIN, CHAIN,
                      RELEASE
  --concurrent-insert[=name]
                      Use concurrent insert with MyISAM. Possible values are
                      NEVER, AUTO, ALWAYS
  --connect-timeout=# The number of seconds the mysqld server is waiting for a
                      connect packet before responding with 'Bad handshake'
  --console           Write error output on screen; don't remove the console
                      window on windows.
  --core-file         Write core on errors.
  --create-admin-listener-thread
                      Use a dedicated thread for listening incoming connections
                      on admin interface
  --cte-max-recursion-depth=#
                      Abort a recursive common table expression if it does more
                      than this number of iterations.
  -h, --datadir=name  Path to the database root directory
  --default-authentication-plugin=name
                      The default authentication plugin used by the server to
                      hash the password.
  --default-password-lifetime=#
                      The number of days after which the password will expire.
  --default-storage-engine=name
                      The default storage engine for new tables
  --default-table-encryption
                      Database and tablespace are created with this default
                      encryption property unless the user specifies an explicit
                      encryption property.
  --default-time-zone=name
                      Set the default time zone.
  --default-tmp-storage-engine=name
                      The default storage engine for new explicit temporary
                      tables
  --default-week-format=#
                      The default week format used by WEEK() functions
  --delay-key-write[=name]
                      Type of DELAY_KEY_WRITE
  --delayed-insert-limit=#
                      After inserting delayed_insert_limit rows, the INSERT
                      DELAYED handler will check if there are any SELECT
                      statements pending. If so, it allows these to execute
                      before continuing. This variable is deprecated along with
                      INSERT DELAYED.
  --delayed-insert-timeout=#
                      How long a INSERT DELAYED thread should wait for INSERT
                      statements before terminating. This variable is
                      deprecated along with INSERT DELAYED.
  --delayed-queue-size=#
                      What size queue (in rows) should be allocated for
                      handling INSERT DELAYED. If the queue becomes full, any
                      client that does INSERT DELAYED will wait until there is
                      room in the queue again. This variable is deprecated
                      along with INSERT DELAYED.
  --disabled-storage-engines=name
                      Limit CREATE TABLE for the storage engines listed
  --disconnect-on-expired-password
                      Give clients that don't signal password expiration
                      support execution time error(s) instead of connection
                      error
                      (Defaults to on; use --skip-disconnect-on-expired-password to disable.)
  --disconnect-slave-event-count=#
                      Option used by mysql-test for debugging and testing of
                      replication.
  --div-precision-increment=#
                      Precision of the result of '/' operator will be increased
                      on that value
  --early-plugin-load=name
                      Optional semicolon-separated list of plugins to load
                      before storage engine initialization, where each plugin
                      is identified as name=library, where name is the plugin
                      name and library is the plugin library in plugin_dir.
  --end-markers-in-json
                      In JSON output ("EXPLAIN FORMAT=JSON" and optimizer
                      trace), if variable is set to 1, repeats the structure's
                      key (if it has one) near the closing bracket
  --enforce-gtid-consistency[=name]
                      Prevents execution of statements that would be impossible
                      to log in a transactionally safe manner. Currently, the
                      disallowed statements include CREATE TEMPORARY TABLE
                      inside transactions, all updates to non-transactional
                      tables, and CREATE TABLE ... SELECT.
  --eq-range-index-dive-limit=#
                      The optimizer will use existing index statistics instead
                      of doing index dives for equality ranges if the number of
                      equality ranges for the index is larger than or equal to
                      this number. If set to 0, index dives are always used.
  --event-scheduler[=name]
                      Enable the event scheduler. Possible values are ON, OFF,
                      and DISABLED (keep the event scheduler completely
                      deactivated, it cannot be activated run-time)
  -T, --exit-info[=#] Used for debugging. Use at your own risk.
  --expire-logs-days=#
                      If non-zero, binary logs will be purged after
                      expire_logs_days days; If this option alone is set on the
                      command line or in a configuration file, it overrides the
                      default value for binlog-expire-logs-seconds. If both
                      options are set to nonzero values,
                      binlog-expire-logs-seconds takes priority. Possible
                      purges happen at startup and at binary log rotation.
  --explicit-defaults-for-timestamp
                      This option causes CREATE TABLE to create all TIMESTAMP
                      columns as NULL with DEFAULT NULL attribute, Without this
                      option, TIMESTAMP columns are NOT NULL and have implicit
                      DEFAULT clauses. The old behavior is deprecated. The
                      variable can only be set by users having the SUPER
                      privilege.
                      (Defaults to on; use --skip-explicit-defaults-for-timestamp to disable.)
  --external-locking  Use system (external) locking (disabled by default).
                      With this option enabled you can run myisamchk to test
                      (not repair) tables while the MySQL server is running.
                      Disable with --skip-external-locking.
  --federated[=name]  Enable or disable FEDERATED plugin. Possible values are
                      ON, OFF, FORCE (don't start if the plugin fails to load).
  --flush             Flush MyISAM tables to disk between SQL commands
  --flush-time=#      A dedicated thread is created to flush all tables at the
                      given interval
  --ft-boolean-syntax=name
                      List of operators for MATCH ... AGAINST ( ... IN BOOLEAN
                      MODE)
  --ft-max-word-len=# The maximum length of the word to be included in a
                      FULLTEXT index. Note: FULLTEXT indexes must be rebuilt
                      after changing this variable
  --ft-min-word-len=# The minimum length of the word to be included in a
                      FULLTEXT index. Note: FULLTEXT indexes must be rebuilt
                      after changing this variable
  --ft-query-expansion-limit=#
                      Number of best matches to use for query expansion
  --ft-stopword-file=name
                      Use stopwords from this file instead of built-in list
  --gdb               Set up signals usable for debugging.
  --general-log       Log connections and queries to a table or log file.
                      Defaults to logging to a file hostname.log, or if
                      --log-output=TABLE is used, to a table mysql.general_log.
  --general-log-file=name
                      Log connections and queries to given file
  --generated-random-password-length=#
                      Determines the length randomly generated passwords in
                      CREATE USER-,SET PASSWORD- or ALTER USER statements
  --group-concat-max-len=#
                      The maximum length of the result of function
                      GROUP_CONCAT()
  --group-replication-consistency[=name]
                      Transaction consistency guarantee, possible values:
                      EVENTUAL, BEFORE_ON_PRIMARY_FAILOVER, BEFORE, AFTER,
                      BEFORE_AND_AFTER
  --gtid-executed-compression-period[=#]
                      When binlog is disabled, a background thread wakes up to
                      compress the gtid_executed table every
                      gtid_executed_compression_period transactions, as a
                      special case, if variable is 0, the thread never wakes up
                      to compress the gtid_executed table.
  --gtid-mode=name    Controls whether Global Transaction Identifiers (GTIDs)
                      are enabled. Can be OFF, OFF_PERMISSIVE, ON_PERMISSIVE,
                      or ON. OFF means that no transaction has a GTID.
                      OFF_PERMISSIVE means that new transactions (committed in
                      a client session using GTID_NEXT='AUTOMATIC') are not
                      assigned any GTID, and replicated transactions are
                      allowed to have or not have a GTID. ON_PERMISSIVE means
                      that new transactions are assigned a GTID, and replicated
                      transactions are allowed to have or not have a GTID. ON
                      means that all transactions have a GTID. ON is required
                      on a master before any slave can use
                      MASTER_AUTO_POSITION=1. To safely switch from OFF to ON,
                      first set all servers to OFF_PERMISSIVE, then set all
                      servers to ON_PERMISSIVE, then wait for all transactions
                      without a GTID to be replicated and executed on all
                      servers, and finally set all servers to GTID_MODE = ON.
  -?, --help          Display this help and exit.
  --histogram-generation-max-mem-size=#
                      Maximum amount of memory available for generating
                      histograms
  --host-cache-size=# How many host names should be cached to avoid resolving.
  --information-schema-stats-expiry=#
                      The number of seconds after which mysqld server will
                      fetch data from storage engine and replace the data in
                      cache.
  --init-connect=name Command(s) that are executed for each new connection
  --init-file=name    Read SQL commands from this file at startup
  --init-slave=name   Command(s) that are executed by a slave server each time
                      the SQL thread starts
  -I, --initialize    Create the default database and exit. Create a super user
                      with a random expired password and store it into the log.
  --initialize-insecure
                      Create the default database and exit. Create a super user
                      with empty password.
  --innodb            Deprecated option. Provided for backward compatibility
                      only. The option has no effect on the server behaviour.
                      InnoDB is always enabled. The option will be removed in a
                      future release.
  --innodb-adaptive-flushing
                      Attempt flushing dirty pages to avoid IO bursts at
                      checkpoints.
                      (Defaults to on; use --skip-innodb-adaptive-flushing to disable.)
  --innodb-adaptive-flushing-lwm=#
                      Percentage of log capacity below which no adaptive
                      flushing happens.
  --innodb-adaptive-hash-index
                      Enable InnoDB adaptive hash index (enabled by default).
                      Disable with --skip-innodb-adaptive-hash-index.
                      (Defaults to on; use --skip-innodb-adaptive-hash-index to disable.)
  --innodb-adaptive-hash-index-parts[=#]
                      Number of InnoDB Adapative Hash Index Partitions.
                      (default = 8).
  --innodb-adaptive-max-sleep-delay=#
                      The upper limit of the sleep delay in usec. Value of 0
                      disables it.
  --innodb-api-bk-commit-interval[=#]
                      Background commit interval in seconds
  --innodb-api-disable-rowlock
                      Disable row lock when direct access InnoDB through InnoDB
                      APIs
  --innodb-api-enable-binlog
                      Enable binlog for applications direct access InnoDB
                      through InnoDB APIs

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值