Documentation Home
MySQL Enterprise Backup 8.0 User's Guide
Related Documentation Download this Manual
PDF (US Ltr) - 1.4Mb
PDF (A4) - 1.4Mb


Chapter 20 mysqlbackup Command-Line Options

The following sections describe the command-line options for the different modes of operation ofmysqlbackup.

The table below list all the command options formysqlbackup. Use the hyperlinks at the option names to jump to the detailed descriptions for the options.

Note

The command options can also be specified in configuration files; see explanations inChapter 21,Configuration Files and Parameters.mysqlbackup follows the MySQL standard practice for handling duplicate options, whether specified in a configuration file, on the command line, or both. Options are processed first from configuration files, then from the command line. If an option is specified more than once, the last instance takes precedence.

Table 20.1 List of All Options

Option NameDescriptionIntroducedDeprecatedRemoved
--backup-dirThe directory to store the backup data.
--backup-imageSpecifies the path name of the backup image.
--backup_innodb_data_file_pathSpecifies Innodb system tablespace files' path and size in backup.
--backup_innodb_data_home_dirBackup base directory for all InnoDB data files in the system tablespace.
--backup_innodb_log_group_home_dirBackup directory for InnoDB log files.
--backup_innodb_undo_directoryThe relative or absolute directory path where InnoDB creates separate tablespaces for the undo logs.
--character-sets-dirDirectory for character set files.
--cloud-access-keyAccess key for the cloud account.8.0.23
--cloud-access-key-idAWS access key ID for logging onto Amazon S3.
--cloud-aws-regionRegion for Amazon Web Services that mysqlbackup access for S3.
--cloud-basicauth-urlThe URL for HTTP Basic Authentication for accessing Swift.
--cloud-bucketThe storage bucket for the backup image.
--cloud-buffer-sizeSize of buffer for cloud operations.
--cloud-ca-infoAbsolute path to the CA bundle file for host authentication for SSL connections.
--cloud-ca-pathCA certificate directory, in addition to the system's default folder.
--cloud-chunk-sizeThe size of a chunk in megabytes if chunked transfer is enabled.8.0.23
--cloud-chunked-transferUse chunked transfer with cloud storage service.
--cloud-containerThe Swift container for the backup image.
--cloud-hostThe hostname for a storage service.8.0.22
--cloud-identity-urlThe URL of the Keystone identity service.
--cloud-objectThe storage object for the backup image.
--cloud-object-keyThe Amazon S3 object key for the backup image.
--cloud-par-urlPre-Authenticated Request URL for OCI Object Storage8.0.22
--cloud-passwordPassword for user specified by --cloud-user-id.
--cloud-proxyProxy address and port number for overriding the environment's default proxy settings for accessing cloud service.
--cloud-regionThe Keystone region for the user specified by --cloud-user-id.
--cloud-secret-access-keyAWS secret access key.
--cloud-secret-keySecret key for the cloud account.8.0.23
--cloud-serviceCloud service for data backup or restoration.
--cloud-tempauth-urlThe URL of the identity service for authenticating user credentials with Swift's TempAuth authentication system.
--cloud-tenantThe Keystone tenant for the user specified by --cloud-user-id.
--cloud-tracePrint trace information for cloud operations.
--cloud-user-idUser ID for accessing Swift.
--commentsSpecifies comments string.
--comments-fileSpecifies path to comments file.
--compressCreate backup in compressed format.
--compress-levelSpecifies the level of compression.
--compress-methodSpecifies the compression algorithm.
--compression-algorithmsPermitted compression algorithms for connections to server8.0.18
--connect_timeoutConnection timeout in seconds.
--datadirPath to mysql server data directory.
--debugPrint debug information.
--decryptDecrypt backup image written in an MEB Secure File.
--default-character-setSet the default character set.
--defaults-extra-fileRead this file after the global files are read.
--defaults-fileOnly read default options from the given file.
--defaults-group-suffixAlso read option groups with the usual names and a suffix of str.
--disable-manifestDisable generation of manifest files for a backup operation.
--dst-entryUsed with single-file backups to extract a single file or directory to a user-specified path.
--enable-cleartext-pluginEnables the cleartext authentication plugin.8.0.22
--encryptEncrypt backup image and write it in an MEB Secure File.
--encrypt-passwordThe user-supplied password by which mysqlbackup encrypts the encryption keys for encrypted InnoDB tablespaces.
--error-codeThe exit code for which the print-message command prints the corresponding exit message.
--exclude-tablesExclude in a backup or restore tables whose names match the regular expression REGEXP.
--exec-when-lockedExecute the specified utility in the lock phase near the end of the backup operation.
--forceForce overwriting of data, log, or image files, depending on the operation.8.0.28
--free-os-buffersFree filesystem cache by syncing the buffers
--helpDisplay help.
--hostHost name to connect.
--include[Legacy] Backup only those per-table innodb data files which match the regular expression REGEXP.8.0.20
--include-tablesInclude in a backup or a restore tables whose names match the regular expression REGEXP.
--incrementalSpecifies that the associated backup or backup-to-image operation is incremental.
--incremental-backup-dirSpecifies the location for an incremental directory backup.
--incremental-baseThe specification of base backup for --incremental option.
--incremental-with-redo-log-onlySpecifies the incremental backup of InnoDB tables to be based on copying redo log to the backup, without including any InnoDB data files in the backup.
--innodb_data_home_dirSpecifies base directory for all InnoDB data files in the shared system tablespace.
--innodb_log_group_home_dirThe directory path to InnoDB log files.
--innodb_undo_directoryThe directory path to InnoDB undo tablespaces.
--keyThe symmetric key used for encryption and decryption.
--key-fileThe pathname of a file that contains the symmetric key used for encryption and decryption.
--limit-memoryThe memory in MB available for the MEB operation.
--lock-wait-timeoutSpecify the timeout in seconds for the FLUSH TABLES WITH READ LOCK statement that mysqlbackup issues during the final stage of a backup.8.0.16
--log-binSpecify the location for the binary log to be restored.
--log-bin-indexSpecifies the absolute path of the index file that lists all the binary log files.
--login-pathRead options from the named login path in the .mylogin.cnf login file.
--messages-logdirSpecifies the path name of an existing directory for storing the message log.
--no-defaultsDo not read default options from any given file.
--no-history-loggingDisable history logging even if connection is available.
--no-lockingDisable all locking of tables during backups.
--no-redo-log-archiveSkip using redo log archiving during backups.8.0.17
--number-of-buffersSpecifies the exact number of memory buffers to be used for the backup operation.
--on-disk-fullSpecifies the behavior when a backup process encounters a disk-full condition.
--only-innodbBack up only InnoDB data and log files.
--only-known-file-typesIncludes only files of a list of known types in the backup.
--optimistic-busy-tablesPerform an optimistic backup, using the regular expression specified with the option to select tables that will be skipped in the first phase of an optimistic backup.
--optimistic-timePerform an optimistic backup with the value specified with the option as the optimistic time—a time after which tables that have not been modified are believed to be inactive tables.
--page-reread-countMaximum number of page re-reads.
--page-reread-timeWait time before a page re-read.
--passwordConnection password.
--pipealias for –protocol=pipe.
--plugin-dirSpecifies the directory for client-side plugins.8.0.22
--portTCP portnumber to connect to.
--print-defaultsPrint a list of option values supplied by defaults files and exit.
--process-threadsSpecifies the number of process-threads for the backup operation.
--progress-intervalInterval between progress reports in seconds.
--protocolConnection protocol.
--read-threadsSpecifies the number of read-threads for the backup operation.
--relay-logSpecify the location for the relay log to be restored on a replica server.
--relay-log-indexSpecifies the absolute path of the index file that lists all the relay log files.
--renameRename a single table when it is selected by the --include-tables option to be restored
--replica-infoCapture information needed to set up an identical replica server.8.0.32
--safe-replica-backup-timeoutWhen backing up a replica server, the timeout value for waiting for the replication SQL thread to drop its temporary tables.8.0.32
--safe-slave-backup-timeoutWhen backing up a replica server, the timeout value for waiting for the replication SQL thread to drop its temporary tables.8.0.32
--sbt-database-nameUsed as a hint to the Media Management Software (MMS) for the selection of media and policies for tape backup.
--sbt-environmentComma separated list of environment variable assignments to be given to the SBT library.
--sbt-lib-pathPath name of the SBT library used by software that manages tape backups.
--shared-memory-base-nameIt designates the shared-memory name used by a Windows server to permit clients to connect using shared memory (Windows only).
--show-progressInstructs mysqlbackup to periodically output short progress reports known as progress indicators on its operation.
--skip-binlogDo not include binary log files during backup, or do not restore binary log files during restore.
--skip-final-rescanSkip the final rescan for InnoDB tables that are modified by DDL operations.
--skip-messages-logdirDisable logging to teelog file.
--skip-relaylogDo not include relay log files during backup, or do not restore relay log files during a restore.
--skip-unused-pagesSkip unused pages in tablespaces when backing up InnoDB tables.
--slave-infoCapture information needed to set up an identical replica server.8.0.32
--sleepTime to sleep in milliseconds after copying each 1MB of data.
--socketSocket file to use to connect.
--src-entryIdentifies a file or directory to extract from a single-file backup.
--ssl-caCA file in PEM format (implies –ssl).
--ssl-capathCA directory (check OpenSSL docs,implies --ssl).
--ssl-certX509 cert in PEM format (implies --ssl).
--ssl-cipherSSL cipher to use (implies --ssl).
--ssl-fips-modeControls whether MEB operates in FIPS mode.8.0.14
--ssl-keyX509 key in PEM format (implies --ssl).
--ssl-modeSecurity state of connection to server.
--start-lsnSpecifies the highest LSN value included in a previous backup.
--suspend-at-endPauses the mysqlbackup command when the backup procedure is close to ending.
--traceTrace level of messages by mysqlbackup.
--uncompressUncompress a backup during an operation.
--use-ttsEnable selective backup of InnoDB tables using transportable tablespaces (TTS).
--userDatabase server user name to connect.
--verbosePrint more verbose information.
--versionDisplay version information.
--with-timestampCreate a subdirectory underneath the backup directory with a name formed from the timestamp of the backup operation.
--write-threadsSpecifies the number of write-threads for the backup operation.
--zstd-compression-levelCompression level for connections to server that use ZSTD compression8.0.18