To control activation of X Plugin, use this option:
-
Command-Line Format --mysqlx[=value]Introduced 5.7.12 Type Enumeration Default Value ONValid Values ONOFFFORCEFORCE_PLUS_PERMANENTThis option controls how the server loads X Plugin at startup. It is available only if the plugin has been previously registered with
INSTALL PLUGINor is loaded with--plugin-loador--plugin-load-add.The option value should be one of those available for plugin-loading options, as described in Section 5.5.1, “Installing and Uninstalling Plugins”. For example,
--mysqlx=FORCE_PLUS_PERMANENTtells the server to load the plugin and prevent it from being removed while the server is running.
If X Plugin is enabled, it exposes several system variables that permit control over its operation:
-
Command-Line Format --mysqlx-bind-address=addrIntroduced 5.7.17 System Variable mysqlx_bind_addressScope Global Dynamic No Type String Default Value *The network address on which X Plugin listens for TCP/IP connections. This variable is not dynamic and can be configured only at startup. This is the X Plugin equivalent of the
bind_addresssystem variable; see that variable description for more information.mysqlx_bind_addressaccepts a single address value, which may specify a single non-wildcard IP address or host name, or one of the wildcard address formats that permit listening on multiple network interfaces (*,0.0.0.0, or::).An IP address can be specified as an IPv4 or IPv6 address. If the value is a host name, X Plugin resolves the name to an IP address and binds to that address. If a host name resolves to multiple IP addresses, X Plugin uses the first IPv4 address if there are any, or the first IPv6 address otherwise.
X Plugin treats different types of addresses as follows:
If the address is
*, X Plugin accepts TCP/IP connections on all server host IPv4 interfaces, and, if the server host supports IPv6, on all IPv6 interfaces. Use this address to permit both IPv4 and IPv6 connections for X Plugin. This value is the default.If the address is
0.0.0.0, X Plugin accepts TCP/IP connections on all server host IPv4 interfaces.If the address is
::, X Plugin accepts TCP/IP connections on all server host IPv4 and IPv6 interfaces.If the address is an IPv4-mapped address, X Plugin accepts TCP/IP connections for that address, in either IPv4 or IPv6 format. For example, if X Plugin is bound to
::ffff:127.0.0.1, a client such as MySQL Shell can connect using--host=127.0.0.1or--host=::ffff:127.0.0.1.If the address is a “regular” IPv4 or IPv6 address (such as
127.0.0.1or::1), X Plugin accepts TCP/IP connections only for that IPv4 or IPv6 address.
If binding to the address fails, X Plugin produces an error and the server does not load it.
-
Command-Line Format --mysqlx-connect-timeout=#Introduced 5.7.12 System Variable mysqlx_connect_timeoutScope Global Dynamic Yes Type Integer Default Value 30Minimum Value 1Maximum Value 1000000000Unit seconds The number of seconds X Plugin waits for the first packet to be received from newly connected clients. This is the X Plugin equivalent of
connect_timeout; see that variable description for more information. mysqlx_idle_worker_thread_timeoutCommand-Line Format --mysqlx-idle-worker-thread-timeout=#Introduced 5.7.12 System Variable mysqlx_idle_worker_thread_timeoutScope Global Dynamic Yes Type Integer Default Value 60Minimum Value 0Maximum Value 3600Unit seconds The number of seconds after which idle worker threads are terminated.
-
Command-Line Format --mysqlx-max-allowed-packet=#Introduced 5.7.12 System Variable mysqlx_max_allowed_packetScope Global Dynamic Yes Type Integer Default Value 67108864Minimum Value 512Maximum Value 1073741824Unit bytes The maximum size of network packets that can be received by X Plugin. This is the X Plugin equivalent of
max_allowed_packet; see that variable description for more information. -
Command-Line Format --mysqlx-max-connections=#Introduced 5.7.12 System Variable mysqlx_max_connectionsScope Global Dynamic Yes Type Integer Default Value 100Minimum Value 1Maximum Value 65535The maximum number of concurrent client connections X Plugin can accept. This is the X Plugin equivalent of
max_connections; see that variable description for more information.For modifications to this variable, if the new value is smaller than the current number of connections, the new limit is taken into account only for new connections.
-
Command-Line Format --mysqlx-min-worker-threads=#Introduced 5.7.12 System Variable mysqlx_min_worker_threadsScope Global Dynamic Yes Type Integer Default Value 2Minimum Value 1Maximum Value 100The minimum number of worker threads used by X Plugin for handling client requests.
-
Command-Line Format --mysqlx-port=port_numIntroduced 5.7.12 System Variable mysqlx_portScope Global Dynamic No Type Integer Default Value 33060Minimum Value 1Maximum Value 65535The network port on which X Plugin listens for TCP/IP connections. This is the X Plugin equivalent of
port; see that variable description for more information. -
Command-Line Format --mysqlx-port-open-timeout=#Introduced 5.7.17 System Variable mysqlx_port_open_timeoutScope Global Dynamic No Type Integer Default Value 0Minimum Value 0Maximum Value 120Unit seconds The number of seconds X Plugin waits for a TCP/IP port to become free.
-
Command-Line Format --mysqlx-socket=file_nameIntroduced 5.7.15 System Variable mysqlx_socketScope Global Dynamic No Type String Default Value /tmp/mysqlx.sockThe path to a Unix socket file which X Plugin uses for connections. This setting is only used by MySQL Server when running on Unix operating systems. Clients can use this socket to connect to MySQL Server using X Plugin.
The default
mysqlx_socketpath and file name is based on the default path and file name for the main socket file for MySQL Server, with the addition of anxappended to the file name. The default path and file name for the main socket file is/tmp/mysql.sock, therefore the default path and file name for the X Plugin socket file is/tmp/mysqlx.sock.If you specify an alternative path and file name for the main socket file at server startup using the
socketsystem variable, this does not affect the default for the X Plugin socket file. In this situation, if you want to store both sockets at a single path, you must set themysqlx_socketsystem variable as well. For example in a configuration file:socket=/home/sockets/mysqld/mysql.sock mysqlx_socket=/home/sockets/xplugin/xplugin.sockIf you change the default path and file name for the main socket file at compile time using the
MYSQL_UNIX_ADDRcompile option, this does affect the default for the X Plugin socket file, which is formed by appending anxto theMYSQL_UNIX_ADDRfile name. If you want to set a different default for the X Plugin socket file at compile time, use theMYSQLX_UNIX_ADDRcompile option.The
MYSQLX_UNIX_PORTenvironment variable can also be used to set a default for the X Plugin socket file at server startup (see Section 4.9, “Environment Variables”). If you set this environment variable, it overrides the compiledMYSQLX_UNIX_ADDRvalue, but is overridden by themysqlx_socketvalue. -
Command-Line Format --mysqlx-ssl-ca=file_nameIntroduced 5.7.12 System Variable mysqlx_ssl_caScope Global Dynamic No Type File name Default Value NULLThe
mysqlx_ssl_casystem variable is likessl_ca, except that it applies to X Plugin rather than the MySQL Server main connection interface. For information about configuring encryption support for X Plugin, see Section 19.4.1, “Using Encrypted Connections with X Plugin”. -
Command-Line Format --mysqlx-ssl-capath=dir_nameIntroduced 5.7.12 System Variable mysqlx_ssl_capathScope Global Dynamic No Type Directory name Default Value NULLThe
mysqlx_ssl_capathsystem variable is likessl_capath, except that it applies to X Plugin rather than the MySQL Server main connection interface. For information about configuring encryption support for X Plugin, see Section 19.4.1, “Using Encrypted Connections with X Plugin”. -
Command-Line Format --mysqlx-ssl-cert=file_nameIntroduced 5.7.12 System Variable mysqlx_ssl_certScope Global Dynamic No Type File name Default Value NULLThe
mysqlx_ssl_certsystem variable is likessl_cert, except that it applies to X Plugin rather than the MySQL Server main connection interface. For information about configuring encryption support for X Plugin, see Section 19.4.1, “Using Encrypted Connections with X Plugin”. -
Command-Line Format --mysqlx-ssl-cipher=nameIntroduced 5.7.12 System Variable mysqlx_ssl_cipherScope Global Dynamic No Type String Default Value NULLThe
mysqlx_ssl_ciphersystem variable is likessl_cipher, except that it applies to X Plugin rather than the MySQL Server main connection interface. For information about configuring encryption support for X Plugin, see Section 19.4.1, “Using Encrypted Connections with X Plugin”. -
Command-Line Format --mysqlx-ssl-crl=file_nameIntroduced 5.7.12 System Variable mysqlx_ssl_crlScope Global Dynamic No Type File name Default Value NULLThe
mysqlx_ssl_crlsystem variable is likessl_crl, except that it applies to X Plugin rather than the MySQL Server main connection interface. For information about configuring encryption support for X Plugin, see Section 19.4.1, “Using Encrypted Connections with X Plugin”. -
Command-Line Format --mysqlx-ssl-crlpath=dir_nameIntroduced 5.7.12 System Variable mysqlx_ssl_crlpathScope Global Dynamic No Type Directory name Default Value NULLThe
mysqlx_ssl_crlpathsystem variable is likessl_crlpath, except that it applies to X Plugin rather than the MySQL Server main connection interface. For information about configuring encryption support for X Plugin, see Section 19.4.1, “Using Encrypted Connections with X Plugin”. -
Command-Line Format --mysqlx-ssl-key=file_nameIntroduced 5.7.12 System Variable mysqlx_ssl_keyScope Global Dynamic No Type File name Default Value NULLThe
mysqlx_ssl_keysystem variable is likessl_key, except that it applies to X Plugin rather than the MySQL Server main connection interface. For information about configuring encryption support for X Plugin, see Section 19.4.1, “Using Encrypted Connections with X Plugin”.