These repository options specify various parameters related to the database server, from which the data is backed up or to which a backup is restored.
These options are used only with the following operations:
Backup creation operations:
backup,backup-and-apply-log,backup-to-image.Restore operations:
copy-back,copy-back-and-apply-log.
When a database connection is available during a backup, the parameters describing the source repository are ignored, overridden by the corresponding values retrieved from the database connection.
For information about how these options are specified for the MySQL server, click the option names to see the descriptions in the MySQL Reference Manual.
datadir=PATHThis is the
datadirvalue used by the MySQL instance. The.frmfiles reside here inside subdirectories named after the databases inside the instance.When a database connection exists, the value is retrieved automatically and overrides any value you specify. This is a crucial parameter for both the MySQL server and MySQL Enterprise Backup.
log-bin[=basename]For MySQL Enterprise Backup 4.1.2 and later: Specify the location for the binary log to be restored. By default, during a restore, the binary log is restored to the same location it was found on the backed-up server. Use this option to specify a different target location for the binary log. The option works similarly as the
--log-binoption of the MySQL server in determining the location and the name of the binary log files—see description of the server --log-bin option for details. As a summary:Using this option without supplying a
puts the binary log in the target server's data directory with the default basenamebasename.host_name-binUsing this option while supplying a
puts the binary log in the target server's data directory with the specified basename.basenameUsing this option while supplying a
containing a full file path (for example,basename/home/admin/db/binlogdir/binlog) puts the binary log on the target server in the specified folder (/home/admin/db/binlogdir/) using the supplied basename (binlog).
The option is only for the
copy-back-and-apply-logandcopy-backoperations. Using it with any other operations makes the command fail.relay-log[=basename]For MySQL Enterprise Backup 4.1.2 and later: Specify the location for the relay log to be restored on a replica server. By default, during a restore for a replica server, the relay log is restored to the same location it was found on the backed-up replica server. Use this option to specify a different target location for the relay log. The option works similarly as the
--log-binoption for mysqlbackup in determining the location and the name of the relay log—see description of the--log-binoption for details.The option is only for the
copy-back-and-apply-logandcopy-backoperations. Using it with any other operations makes the command fail.innodb_data_home_dir=PATHSpecifies the directory where InnoDB data files reside. Usually the same as
datadir, but can be different.This parameter, together with
innodb_data_file_path=SIZE, determines where the InnoDB data files such asibdata1,ibdata2, and so on, are situated within the MySQL server.For backups: Typically, you do not need to specify this option, because its value is retrieved automatically using the database connection. Specifies the option for an offline backup if the InnoDB data files do not reside under the server's data directory.
For restores: The directory where InnoDB data files are to be restored. Specify the option only if the InnoDB data files are to be restored outside of the server's data directory. For release 4.1.3 and later: the specified directory must be non-existent or empty, or the restore operation will fail, even if the
--forceoption is used.Its value is derived as follows:
If
innodb_data_home_diris not specified, it inherits the value ofdatadir.If
innodb_data_home_diris a relative path, the path is located relative to (that is, underneath) thedatadirvalue.An
innodb_data_home_dirof""refers to the/root directory.If
innodb_data_home_diris an absolute path, its value is used as-is.
innodb_data_file_path=VALUESpecifies InnoDB data file names and sizes. Examples:
ibdata1:32M;ibdata2:32M:autoextend /abs/path/ibdata1:32M:autoextend innodb-dir/ibdata1:32M:autoextendWhen a database connection exists, the value is retrieved automatically and overrides any value you specify.
This parameter together with innodb_data_home_dir determines where the InnoDB data files (such as
ibdata1,ibdata2, and so on) reside in server repository.Typically, you do not need to specify this option, because its value is retrieved automatically using the database connection. If no database connection is available, you must specify it.
Whether the initial file name begins with a
/character or not, the files are located relative to theinnodb_data_home_dirvalue.innodb_log_group_home_dir=PATHSpecifies where the InnoDB redo log reside within the server repository. Usually the same as
datadir, but can be different.For backups: Typically, you do not need to specify this option, because its value is retrieved automatically using the database connection. Specifies the option for an offline backup if the InnoDB redo log files do not reside under the server's data directory.
For restores: The directory where InnoDB redo log files are to be restored. Specify the option only if the InnoDB redo log files are to be restored outside of the server's data directory. For release 4.1.3 and later: the specified directory must be non-existent or empty, or the restore operation will fail, even if the
--forceoption is used.Its value is derived as follows:
If
innodb_log_group_home_diris not specified, it inherits the value ofdatadir.If
innodb_log_group_home_diris a relative path, the path is taken to be relative to (that is, underneath) thedatadirvalue.If
innodb_log_group_home_diris an absolute path, its value is used as-is.
Specifies the number of InnoDB log files before being rotated.
Typically, you do not need to specify this option, because its value is retrieved automatically using the database connection. If no database connection is available, you must specify it.
When a database connection exists, the value is retrieved automatically and overrides any value you specify.
innodb_log_file_size=SIZESpecifies maximum single InnoDB log file size before switching to next log file. Example: 20M.
Typically, you do not need to specify this option, because its value is retrieved automatically using the database connection. If no database connection is available, you must specify it.
When a database connection exists, the value is retrieved automatically and overrides any value you specify.
innodb_page_size=SIZESpecifies the page size for all InnoDB tablespaces.
Typically, you do not need to specify this option, because its value is retrieved automatically using the database connection. If no database connection is available, you must specify it.
When a database connection exists, the value is retrieved automatically and overrides any value you specify.
Specifies where the InnoDB undo log reside within the server repository. Usually the same as
datadir, but can be different.For backups: Typically, you do not need to specify this option, because its value is retrieved automatically using the database connection. Specifies the option for an offline backup if the InnoDB undo log files do not reside under the server's data directory.
For restores: The directory where InnoDB undo log files are to be restored. Specify the option only if the undo log files are to be restored outside of the server's data directory. For release 4.1.3 and later: the specified directory must be non-existent or empty, or the restore operation will fail, even if the
--forceoption is used.Its value is derived as follows:
If
innodb_undo_directoryis not specified, it inherits the value ofdatadir.If
innodb_undo_directoryis a relative path, the path is taken to be relative to (that is, underneath) thedatadirvalue.If
innodb_undo_directoryis an absolute path, its value is used as-is.
WarningWhen using this option, make sure the undo log location does not change between successive restores of a full and an incremental backups, or of two incremental backups. Otherwise, the restore is going to fail.
innodb_checksum_algorithm=NAMESpecifies the name of the checksum algorithm used for validating InnoDB tablespaces. Default is
innodb.Typically, you do not need to specify this option, because its value is retrieved automatically using the database connection. If no database connection is available, you must specify it.
When a database connection exists, the value is retrieved automatically and overrides any value you specify.
innodb_buffer_pool_filename=FILENAMEThe file produced on the server when
innodb_buffer_pool_dump_at_shutdown(enabled by default on MySQL 5.7.7 and after) orinnodb_buffer_pool_dump_nowis enabled. It holds the list of tablespace IDs and page IDs of the server's buffer pool.Typically, you do not need to specify this option, because its value is retrieved automatically using the database connection. If no database connection is available during backup, you must specify it.
When a database connection exists, the value is retrieved automatically and overrides any value you specify.