HOLLAND(1)
π NAME π
holland β Holland Documentation, bestie. Thatβs the whole manual vibe, and weβre diving in π
πΈ TABLE OF CONTENTS πΈ
okay so the whole map is below, bestie β same sections, same order, no cap.
π Introduction to Holland π
Holland is an Open Source backup framework originally developed by Rackspace and written in Python. Its goal is to help facilitate backing up databases with greater configurability, consistency, and ease. Holland currently focuses on MySQL, however future development will include other database platforms and even non-database related applications. Because of its plugin structure, Holland can be used to backup anything you want by whatever means you want.
π¨ Important vibe check: Python2 support has been removed as of holland 1.2.0.
π¦ Dependencies π¦
The core Holland framework has the following dependencies (available on any remotely modern Linux distribution):
Python >= 3.6pkg_resourcespython-setuptoolsConfigParser
MySQL based plugins additionally require the MySQLdb python connector:
pyMySQL
Note that other plugins may have additional dependency requirements.
π Holland Command-Line Reference π
Here are the commands available from the 'holland' command-line tool:
β¨ help (h) β¨
Usage:
holland <command> --help(-h)
Provides basic information about the provided command. If no command is provided, it displays global help instead.
β¨ backup (bk) β¨
Usage:
holland backup [backup-set1, backup-set2, ..., backup-setN]
Runs the backup operation. If no backup-sets are specified, all active backup-sets (those defined in the 'backupsets' variable in holland.conf) are backed up.
One or more backup-sets can be specified directly, in which case only those backup-sets are backed up.
Additional Command Line Arguments:
--dry-run (-n)β Can be used here to simulate, but not actually run, a backup. This should be used when troubleshooting a particular error before trying to run a real backup.--no-lock (-f)β Normally, only one instance of Holland can run at any given time using lock-files. Using this flag causes the lock-files to be ignored. This has some very clear use-cases but otherwise be mindful of using this setting as it can cause backups to fail in some cases.--abort-immediatelyβ abort on the first backup-set that fails (assuming multiple backupsets were specified)
Examples:
# holland bk --dry-run weekly: Attempts a dry-run of the weekly backup-set.
# holland bk --no-lock --abort-immediately: Attempts a backup of all the
default backup-sets ignoring locks and aborting immediately if one of the
backup-sets fails.
β¨ list-backups (lb) β¨
Usage:
holland list-backups
Provides extended information about available backups.
β¨ list-plugins (lp) β¨
Usage:
holland list-plugins
Lists all the available (installed) plugins available to Holland.
β¨ mk-config (mc) β¨
Usage:
holland mk-config <provider>
Generates a template backup-set for a particular provider (such as mysqldump). By default, the output is sent to standard out but can be copied to a file, either by using the --file, --edit, or -name options (see below).
Additional Command Line Arguments:
--editβ Load the file into the system text-editor for further modifications.--file=FILE (-f)β Write the output directly to provided file.--name=NAMEβ Creates a backup-set usable in Holland, which basically means that a file is created of the provided name under the backup-set directory.--providerβ Indicates that the default provider configuration should be outputted instead. This is really only used when creating a provider config specifically - it should not be used for backup-sets.
Examples:
# holland mk-config mysql-lvm > mysql-lvm.conf: Output the default
configuration for MySQL-LVM backups and write the contents out to
mysql-lvm.conf in the current working directory.
# holland mc mysqldump --name=Bob --edit: Create a backup-set using the
mysqldump provider named Bob and allow interactive editing of the
backup-set before saving the file.
β¨ purge (pg) β¨
Usage:
holland purge <backup-set>/<backup-id>
Purges old backups by specifying the backup-set name and set-id.
For example:
# holland purge mybackups/20090502_155438: Purge one of the backups taken on May 2nd, 2009 from the mybackups backup-set.
π Usage and Implementation Overview π
Because Holland is very pluggable, it may first seem a bit confusing when it comes to configuring Holland to do something useful. Out of the box, Holland is designed to backup MySQL databases using the mysqldump provider. This is the simplest setup, and may be sufficient for most people. However, others may wish to have more fine-grained control over their backups and/or use another method other than mysqldump.
For instance, one can configure a backup set to backup certain databases using mysqldump, others using the mysql-lvm plugins etc. All this is done by a mix of providers and backup-sets.
π Backup-Sets π
Each backup-set implements exactly one provider and will inherit the default values of that provider. These values can be overridden to adjust the behavior of the backup set. This includes defining what databases or tables to include (or exclude) in the backup, the type of compression used (if any), what locking method to use, among other things.
π Providers π
Providers essentially provide a backup service for use in a backup set.
mysqldumpβ Uses themysqldumputility to backup databases.- MySQL + LVM β Backup MySQL databases using LVM snapshots which allows for near lockless or fully lockless (when transactional engines are used) backups.
mysqldump + LVMβ This plugin creates an LVM snapshot, starts a mysql instance using the snapshot as its datadir, and then use themysqldumputility to backup the databases.- XtraBackup β New in version
1.0.8. Backup MySQL databases using Percona's XtraBackup tool. This provides a near lockless backup when using the InnoDB storage engine. pgdumpβ Backup PostgreSQL databases using thepgdumputility.pg_basebackupβ New in version1.2.8. Backup PostgreSQL databases using thepg_basebackuputility.mariabackupβ New in version1.1.0. Backup MySQL databases using MariaDB'smariabackuptool.mongodumpβ New in version1.1.0. This plugin performs logical backups of a MongoDB by using themongodumputility.- Example β This is used solely as a template for designing providers. It otherwise does nothing.
As Holland is a framework, it can actually backup most anything as long as there is a provider for it. This includes things that have nothing to do with databases. The idea is to present an easy to use and clear method of backing up and restoring backups no matter the source.
π§ Holland Config Files π§
By default, Holland's configuration files reside in /etc/holland. The main configuration file is holland.conf, however there are a number of other configuration files for configuring default settings for providers and for configuring backup sets.
Each configuration file has one or more sections, defined by square brackets. Underneath each section, one or more configuration option can be specified. These options are in a standard "option = value" format. Comments are prefixed by the # sign.
Note that many settings have default values and, as a result, can either be commented out or omitted entirely.
π holland.conf - main config π
The main configuration file (usually /etc/holland/holland.conf) defines both global settings as well as the active backup sets. It is divided into two sections [holland] and [logging].
π [holland] π
plugin-dirsβ Defines where the plugins can be found. This can be a comma-separated list but usually does not need to be modified.backup_directoryβ Top-level directory where backups are held.backupsetsβ A comma-separated list of all the backup sets Holland should backup. Each backup set is defined in/etc/holland/backupsets/<name>.confby default.umaskβ Sets the umask of the resulting backup files.pathβ Defines a path for holland and its spawned processes
πΈ [logging] πΈ
filenameβ The log file itself.levelβ Sets the verbosity of Holland's logging process. Available options aredebug,info,warning,error, andcriticalformatβ Define the format of the log message. This option should be in the format defined by the'logging'python library. New in version1.1.0.
π Provider Configs π
These files control the global settings / defaults for the providers used by the backup-sets. Many of these global settings can be overridden if defined in a backup-set. Note that each provider's configuration file should begin with [provider-name].
π mysqldump Provider Configuration [mysqldump] π
Backs up a MySQL database using the mysqldump tool.
π¦ [mysqldump] π¦
mysql-binpath = /path/to/mysql/binβ Defines the location of the MySQL binary utilities. If not provided, Holland will use whatever is in the path.lock-method = flush-lock | lock-tables | single-transaction | auto-detect | noneβ Defines which lock method to use. By default,auto-detectwill be used.flush-lockβflush-lockwill place a global lock on all tables involved in the backup regardless of whether or not they are in the backup-set. Iffile-per-databaseis enabled, thenflush-lockwill lock all tables for every database being backed up. In other words, this option may not make much sense when usingfile-per-database.lock-tablesβlock-tableswill lock all tables involved in the backup. Iffile-per-databaseis enabled, thenlock-tableswill only lock all the tables associated with that database.single-transactionβ Forces the use of--single-transactionwhich enables semi-transparent backups of transactional tables. Forcing this can cause inconsistencies with non-transactional tables, however. While non-transactional tables will still lock, they will only lock when they are actually being backed up. Use this setting with extreme caution when backing non-transactional tables.auto-detectβ Let Holland decide which option to use by checking to see if a database or backup-set only contains transactional tables. If so,--single-transactionwill be used. Otherwise,--lock-tableswill be used.
noneβ literally does absolutely no explicit locking when backing up the databases or backup-set. This should only be used when backing up a slave, and only after the slave has been turned off (ie, this can be used with thestop-slaveoption). πexclude-invalid-views = yes | no (default: no)β whether to automate exclusion of invalid views that would otherwise causemysqldumpto fail. Heads up: this adds additional overhead, so this option is not enabled by default. β¨ When enabled, this option will scan theINFORMATION_SCHEMA.VIEWStable and executeSHOW FIELDSagainst each view. If a view is detected as invalid, anignore-tableoption will be added to exclude the table. Additionally, the plugin will attempt to save the view definition toinvalid_views.sqlin the backupset's backup directory. New in version 1.0.8.dump-routines = yes | no (default: yes)β whether or not to backup routines in the backup set directly. Routines are stored in themysqldatabase, but it can sometimes be convenient to include them in a backup-set directly. Changed in version 1.0.8: this option now enabled by default. π«Άdump-events = yes | noβ whether or not to dump events explicitly. Like routines, events are stored in themysqldatabase. Nonetheless, it can sometimes be convenient to include them in the backup-set directly. Note: this feature requires MySQL 5.1 or later. Themysqldumpplugin will automatically disable events if the version ofmysqldumpis too old. Changed in version 1.0.8: this option is now enabled by default. πΈstop-slave = yes | noβ stops theSQL_THREADduring the backup. This means that writes from the master will continue to spool but will not be replayed. This helps avoid lock wait timeouts among things while still allowing data to be spooled from the master. Note that previous versions of Holland prior to 1.0.6 simply ran aSTOP SLAVEinstead, which suspends both replication threads. πbin-log-position = yes | noβ record the binary log name and position at the time of the backup. The information provided by this option is collected just before locking the database. Note that if bothstop-slaveandbin-log-positionare enabled, Holland will grab the master binary log name and position at the time of the backup which can be useful in using the backup to create slaves or for point in time recovery using the master's binary log. This information is found within thebackup.conffile located in the backup-set destination directory (/var/spool/holland/<backup-set>/<backup>by default). For example:
[mysql:replication]
slave_master_log_pos = 4512
slave_master_log_file = 260792-mmm-agent1-bin-log.000001
flush-logs = yes | noβ whether or not to runFLUSH LOGSin MySQL with the backup. WhenFLUSH LOGSis actually executed depends on whether database filtering is being used and whetherfile-per-databaseis enabled. Generally speaking, it does not make sense to useflush-logswithfile-per-databasesince the binary logs will not be consistent with the backup. π₯file-per-database = yes | noβ whether or not to split up each database into its own file. Note that it can be more consistent and efficient to backup all databases into one file, however this means that restoring a single database can be difficult if multiple databases are defined in the backup set. πΎarg-per-database = JSON objectβ iffile-per-databaseis enabled, this argument is used to specifymysqldumparguments per database. It takes a JSON object with the database names as keys. Example:{"employee1": "--no-data"}adds the'--no-data'argument to themysqldumpcommand when backing up the'employee1'database. New in version 1.0.9. πadditional-options = <mysqldump argument>[, <mysqldump argument>]β can optionally specify additional options directly tomysqldumpif there is no native Holland option available. This option accepts a comma delimited list of arguments to pass on the commandline. π§extra-defaults = yes | no (default: no)β this option controls whethermysqldumpwill only read options as set by holland or if additional options from global config files are read. By default, the plugin only uses options as set in the backupset config and includes authentication credentials only from the[client]section in~/.my.cnf. πestimate-method = plugin | const:<size> (default: plugin)β this option will skip some of the heavyweight queries necessary to calculate the size of tables to be backed up. If a constant size is specified, then only table names are evaluated and only if table filtering is being used. Valid units for size are: K, M, G, T, P, E (case-insensitive). Additionally, engines will be looked up viaSHOW CREATE TABLEiflock-method = auto-detect, in order for the plugin to determine if tables are using a transactional storage engine. Withplugin, the default behavior of reading both size information and table names from the information schema is used, which may be slow particularly for a large number of tables. β
ποΈ Database and Table filtering
databases = <glob>exclude-databases = <glob>tables = <glob>exclude-tables = <glob>
The above options accept GLOBs in comma-separated lists. Multiple filtering options can be specified. When filtering on tables, be sure to include both the database and table name. π¦
Be careful with quotes. Normally these are not needed, but when quotes are necessary, be sure to only quote each filtering statement, as opposed to putting quotes around all statements. iykyk π
Below are a few examples of how these can be applied:
Default (backup everything):
databases = *
tables = *
Using database inclusion and exclusions:
databases = drupal*, smf_forum,
exclude-databases = drupal5
Including Tables:
tables = phpBB.sucks, drupal6.node*, smf_forum.*
Excluding Tables:
exclude-tables = mydb.uselesstable1, x_cart.*, *.sessions
ποΈ [compression]
Specify various compression settings, such as compression utility, compression level, etc. π
method = gzip| gzip-rsyncable | pigz | bzip2 | pbzip2 | lzop | lzma | gpg | zstdβ define which compression method to use. Note that some methods may not be available by default on every system and may need to be compiled or installed. Forgpgcompression, a key should already exist (gpg --gen-key) anddefault-recipientmust be configured in~/.gnupg/gpg.conf. πinline = yes | noβ whether or not to pipe the output of the backup command into the compression utility. Enabling this is recommended since it usually only marginally impacts performance, particularly when using a lower compression level. πlevel = 0-9β specify the compression ratio. The lower the number, the lower the compression ratio, but the faster the backup will take. Generally, setting the level to 1 or 2 results in favorable compression of textual data and is noticeably faster than the higher levels. Setting the level to 0 effectively disables compression. β‘bin-path = <full path to utility>β this only needs to be defined if the compression utility is not in the usual places or not in the system path. πoptions = <string>β add commandline options to the configuration compression command. Example:options = "-Q4"π―split = yes | noβ defaults to no. If set, the backup will be piped through thesplitcommand. This may be useful for users with large databases, as some backup systems perform better with many smaller files instead of 1 large one. This defaults to 1GB file size, so this option isn't helpful if your dumps are smaller than that. For python2.6, this option will be disabled if thesubprocess32module isn't available. New in version 1.1.13. π
π MySQL connection info [mysql:client]
These are optional and, if left undefined, Holland will try to login using the standard .my.cnf conventions. π«Ά
user = <user>β the user to connect to MySQL as.password = <password>β the password for the MySQL user.socket = <socket>β the socket file to connect to MySQL with.host = <host>β this would be used for connecting to MySQL remotely.port = <port>β used if MySQL is running on a port other than 3306. π
π§ MySQL LVM Provider Configuration [mysql-lvm]
Creates an LVM snapshot of a running MySQL instance and performs a binary-based backup with minimal locking. MySQL must be running on an LVM volume with reserved space for snapshots. It is highly recommended that this volume be separate from the one storing the resulting backups. π
πΎ [mysql-lvm]
snapshot-size = <size-in-MB>β the size of the snapshot itself. By default it is 20% of the size of the MySQL LVM mount or the remaining free-space in the Volume Group (if there is less than 20% available) up to 15GB. Ifsnapshot-sizeis defined, the number represents the size of the snapshot in megabytes. πsnapshot-name = <name>β the name of the snapshot, the default being the name of the MySQL LVM volume +_snapshot(ieStorage-MySQL_snapshot). π·οΈsnapshot-mountpoint = <path>β where to mount the snapshot. By default a randomly generated directory under/tmpis used. πinnodb-recovery = yes | no (default: no)β whether or not to run an InnoDB recovery operation. This avoids needing to do so during a restore, though will make the backup process itself take longer. π’force-innodb-backup = yes | no (default: no)β whether to attempt a backup even if themysql-lvmplugin thinks it cannot obtain a good backup. This can occur when innodb data files are outside of the mysql datadir or exist on entirely separate logical volumes. πͺlock-tables = yes | no (default: yes)β whether or not to run aFLUSH TABLES WITH READ LOCKto grab various bits of information (such as the binary log name and position). Disabling this requires that binary logging is disabled and InnoDB is being used exclusively. Otherwise, it is possible that the backup could contain crashed tables. πextra-flush-tables = yes | no (default: yes)β whether or not to run aFLUSH TABLESbefore running the fullFLUSH TABLES WITH READ LOCK. Should make theFLUSH TABLES WITH READ LOCKoperation a bit faster. π§Όarchive-method = tar | dir (default: tar)β create a tar file of the datadir, or just copy it. π¦
π¦ [tar]
exclude = pattern[, pattern...]
so, patterns to exclude from the archive π« these should be relative paths, and they're almost always relative to the mysql data directory. like, if you wanna keep the binary logs in the data directory out of your backup, you'd write something like:
exclude = ./bin-log.*, mysql.sock
pre-args=<string>β extra arguments to append to thetarcommandline before the backup path is specified. this should be the full string exactly as you might specify on the commandline. shell globbing is not supported π for instance you might add the/etc/my.cnfto the tar archive via:
pre-args = -C /etc ./my.cnf
post-args=<string>β extra arguments to append to thetarcommandline after the backup path is specified. this should be a string exactly as you might specify on the commandline. shell globbing is not evaluated. periodt π
β¨ [compression]
specify various compression settings, such as compression utility, compression level, etc. the whole vibe π
method=gzip| gzip-rsyncable | pigz | bzip2 | pbzip2 | lzop | lzma | gpg | zstdβ define which compression method to use. note that some methods may not be available by default on every system and may need to be compiled or installed π forgpgcompression, a key should already exist (gpg --gen-key) anddefault-recipientmust be configured in~/.gnupg/gpg.conf.inline=yes | noβ whether or not to pipe the output of the backup command into the compression utility. enabling this is recommended since it usually only marginally impacts performance, particularly when using a lower compression level. it's giving free efficiency π«Άlevel=0-9β specify the compression ratio. the lower the number, the lower the compression ratio, but the faster the backup will take. generally, setting the level to1or2results in favorable compression of textual data and is noticeably faster than the higher levels. setting the level to0effectively disables compression. no cap.bin-path=<full path to utility>β this only needs to be defined if the compression utility is not in the usual places or not in the system path.options=<string>β add commandline options to the configuration compression command.
options = "-Q4"
split=yes | noβ defaults tono. if set the backup will be piped through thesplitcommand. this may be useful for user's with large databases, as some backup systems perform better with many smaller files instead of 1 large one. this defaults to 1GB file size, so this option isn't helpful if your dumps are smaller than that. forpython2.6, this option will be disabled if thesubprocess32module isn't available. New in version 1.1.13.
π¬ MySQL connection info [mysql:client]
these are optional and, if left undefined, Holland will try to login using the standard .my.cnf conventions. lowkey convenient π
user=<user>the user to connect to MySQL as.password=<password>the password for the MySQL user.socket=<socket>the socket file to connect to MySQL with.host=<host>this would be used for connecting to MySQL remotely.port=<port>used if MySQL is running on a port other than3306.
π mysqldump LVM Provider Configuration [mysqldump-lvm]
backs up one or more MySQL databases by creating an LVM snapshot and then starting a instance of MySQL on top of it to then perform a mysqldump. this effectively produces a non-blocking logical backup. iconic behaviour, honestly π
π¦ [mysql-lvm]
snapshot-size=<size-in-MB>β the size of the snapshot itself. by default it is 20% of the size of the MySQL LVM mount or the remaining free-space in the Volume Group (if there is less than 20% available) up to 15GB. ifsnapshot-sizeis defined, the number represents the size of the snapshot in megabytes.snapshot-name=<name>β the name of the snapshot, the default being the name of the MySQL LVM volume +"_snapshot"(ieStorage-MySQL_snapshot).snapshot-mountpoint=<path>β where to mount the snapshot. by default a randomly generated directory under/tmpis used πinnodb-recovery=yes | no(default:no) β whether or not to run an InnoDB recovery operation. this avoids needing to do so during a restore, though will make the backup process itself take longer. trade-offs, bestie πlock-tables=yes | no(default:yes) β whether or not to run aFLUSH TABLES WITH READ LOCKto grab various bits of information (such as the binary log name and position). disabling this requires that binary logging is disabled and InnoDB is being used exclusively. otherwise, it is possible that the backup could contain crashed tables π not the vibe.extra-flush-tables=yes | no(default:yes) β whether or not to run aFLUSH TABLESbefore running the fullFLUSH TABLES WITH READ LOCK. should make theFLUSH TABLES WITH READ LOCKoperation a bit faster. little speed boost, we love to see it β¨
πΈ [mysqld]
mysqld-exe=<path>[, <path>...](default:mysqldin PATH,/usr/libexec/mysqld) β this provides a list of locations where themysqldprocess to use might be found. this is searched in order of entries in this list.user=<name>β the--userparameter to use withmysqld.innodb-buffer-pool-size=<size>(default:128M) β how large to size theinnodb-buffer-pool-size.tmpdir=<path>(default: system tempdir) β path to the--tmpdirthatmysqldshould use.log-error=<path>(default:tempdir/holland_lvm.log) β define path formysqld's error log. the default location get cleaned up by Holland after the backup is complete. this settings allows the user to define the log file in another location and can be useful for debugging issue with the MySQL instance running on the snapshot. honestly a lifesaver for debugging π§ New in version 1.0.9.
π [mysqldump]
mysqldump-lvm supports almost all of the options from the mysqldump plugin. --master-data is not supported, as the mysqld process will not read binary logs, so this plugin will automatically disable bin-log-position, if set.
binary log information from SHOW MASTER STATUS and SHOW SLAVE STATUS is recorded in the ${backup_directory}/backup.conf file under the [mysql:replication] section π
π [compression]
specify various compression settings, such as compression utility, compression level, etc. (yep β the page really does print this block twice, so here it is again, no skipping π )
method=gzip| gzip-rsyncable | pigz | bzip2 | pbzip2 | lzop | lzma | gpg | zstdβ define which compression method to use. note that some methods may not be available by default on every system and may need to be compiled or installed. forgpgcompression, a key should already exist (gpg --gen-key) anddefault-recipientmust be configured in~/.gnupg/gpg.conf.inline=yes | noβ whether or not to pipe the output of the backup command into the compression utility. enabling this is recommended since it usually only marginally impacts performance, particularly when using a lower compression level.level=0-9β specify the compression ratio. the lower the number, the lower the compression ratio, but the faster the backup will take. generally, setting the level to1or2results in favorable compression of textual data and is noticeably faster than the higher levels. setting the level to0effectively disables compression.bin-path=<full path to utility>β this only needs to be defined if the compression utility is not in the usual places or not in the system path.options=<string>β add commandline options to the configuration compression command.
options = "-Q4"
split=yes | noβ defaults tono. if set the backup will be piped through thesplitcommand. this may be useful for user's with large databases, as some backup systems perform better with many smaller files instead of 1 large one. this defaults to 1GB file size, so this option isn't helpful if your dumps are smaller than that. forpython2.6, this option will be disabled if thesubprocess32module isn't available. New in version 1.1.13.
π«Ά [mysql:client]
these are optional and, if left undefined, Holland will try to login using the standard .my.cnf conventions.
user=<user>the user to connect to MySQL as.password=<password>the password for the MySQL user.socket=<socket>the socket file to connect to MySQL with.host=<host>this would be used for connecting to MySQL remotely.port=<port>used if MySQL is running on a port other than3306.
π₯ Xtrabackup Provider Configuration [xtrabackup]
backs up a MySQL instance using Percona's Xtrabackup tool. main character energy fr π₯
π [xtrabackup]
global-defaults=<path>(default:/etc/my.cnf) β the MySQL configuration file forxtrabackupto parse. this is!include'd into themy.cnfthextrabackupplugin generates.innobackupex=<name>(default:innobackupex-1.5.1) β the path to theinnobackupexscript to run. if this is a relative path this will be found in holland's environmentPATHas configured in/etc/holland/holland.conf. Changed in version 1.1.12: forxtrabackupversion 8.0 or greater, this option is ignored.ibbackup=<name>β the path to theibbackupcommand to use. by default, no--ibbackupoption is passed to theinnobackupexscript. usuallyinnobackupexwill detect this by itself and this should not need to be set.stream=tar|xbstream|yes|no(default:xbstream) β whether to generate a streaming backup. Changed in version 1.0.8:'tar'and'xbstream'are now valid options. the oldstream = yesis now equivalent tostream = tarandstream = nodisables streaming entirely and will result in a normal directory copy withxtrabackup. Changed in version 1.1.12: forxtrabackupversion 8.0 or greater,'xbstream'will be used unless this value is set to'no'. Changed in version 1.3.0: the default stream method has switched fromtartoxbstream.apply-logs=yes | no(default:yes) β whether to runinnobackupex --apply-logsat the end of the backup. this is only supported when performing a non-streaming, non-compressed backup. in this case, even ifapply-logs = yes(the default), the prepare stage will be skipped. even with an uncompressed, non-streaming backup you may want to disableapply-logsif you wish to use incremental backups. read that twice bestie, it's a whole tangle π New in version 1.0.8.slave-info=yes | no(default:yes) β whether to enable the--slave-infoinnobackupexoption.safe-slave-backup=yes | no(default:yes) β whether to enable the--safe-slave-backupinnobackupexoption.no-lock=yes | no(default:no) β whether to enable the--no-lockinnobackupexoption.tmpdir=<path>(default:${backup_directory}) β the path for theinnobackupex --tmpdiroption. by default this will use the current holland backup directory to workaround the following bug:https://bugs.launchpad.net/percona-xtrabackup/+bug/1007446π
π New in version 1.0.8.
additional-options = <option>[, <option>...]β a whole list of extra flags you wanna hand off toinnobackupex, fr fr. It's a comma separated list, so just line 'em up with commas between and you're golden πpre-command = <command-string>β a command that runs before this xtrabackup run kicks off. Like, say you wanna generate amysqldumpschema dump first and then let xtrabackup do its thing β this is your moment β¨. Anyinstancesof${backup_directory}and${backupdir}inside it get swapped out for the current holland backup directory, aka the place where the xtrabackup data is gonna live.strict = yes | no(default:yes) β if you set strict tono, it adds the--strict=OFFoption onto the xtrabackup command. The strict option in xtrabackup is the thing that blocks errors and warnings over invalid command line options, so yeah β turning it off is a choice, bestie π
π New in version 1.2.10.
[compression] π
All your squish settings live here β which compression utility, what compression level, the whole vibe check.
method = gzip| gzip-rsyncable | pigz | bzip2 | pbzip2 | lzop | lzma | gpg | zstdβ picks which compression method we're using. Heads up tho: some of these methods might not be available by default on every system, and might need to be compiled or installed first. Not all of them are just sitting there, yk?
For gpg compression, a key should already exist (via gpg --gen-key) and default-recipient must be configured in ~/.gnupg/gpg.conf. That's a you-problem, prep it ahead of time π
inline = yes | noβ whether or not to pipe the output of the backup command straight into the compression utility. Enabling this is recommended β it usually only marginally impacts performance, especially when you're running a lower compression level. Highkey free real estate πlevel = 0-9β sets the compression ratio. Lower number = lower compression ratio = faster backup. Generally1or2gives you favorable compression of textual data and is noticeably faster than the higher levels. And0effectively disables compression entirely, so like... nothing. Zero squish π«bin-path = <full path to utility>β only define this if your compression utility isn't in the usual places or not in the system path. Otherwise ignore it, she's fine πΈoptions = <string>β toss commandline options onto the compression command from your config.
options = "-Q4"
split = yes | noβ defaults tono. If you set it, the backup gets piped through thesplitcommand. This can be useful for people with large databases, since some backup systems perform better with many smaller files instead of 1 large one. It defaults to a1GBfile size, so this option isn't helpful if your dumps are smaller than that. Sorry to the small-dump girlies π
For python2.6, this option will be disabled if the subprocess32 module isn't available.
π New in version 1.1.13.
MySQL connection info [mysql:client] π¦
These are all optional, and if you leave them undefined, Holland will try to login using the standard .my.cnf conventions. So like, she'll figure it out π
user = <user>
The user to connect to MySQL as.
password = <password>
The password for the MySQL user.
socket = <socket>
The socket file to connect to MySQL with.
host = <host>
This would be used for connecting to MySQL remotely.
port = <port>
Used if MySQL is running on a port other than 3306.
pgdump Provider Configuration [pgdump] π
Backs up a PostgreSQL instance using the pgdump utility. Slay.
[pgdump]
format = custom | tar | plain(default:custom) β defines the--formatoption forpg_dump. This defaults to--format=custom. Thecustomformat is required forpg_restoreto do partial restore as well as enabling parallel restores. If set tocustom, the--compressoption will be passed topgdump. Custom really is the main character here πadditional-options = <command-string>β pass additional options to thepg_dumpcommand.
β οΈ Only the 'level' option will be used if 'format=custom'.
[compression] π
Specify various compression settings, such as compression utility, compression level, etc. (yes, again β every provider gets its own lil compression corner π )
method = gzip| gzip-rsyncable | pigz | bzip2 | pbzip2 | lzop | lzma | gpg | zstdβ define which compression method to use. Note that some methods may not be available by default on every system and may need to be compiled or installed.
For gpg compression, a key should already exist (gpg --gen-key) and default-recipient must be configured in ~/.gnupg/gpg.conf.
inline = yes | noβ whether or not to pipe the output of the backup command into the compression utility. Enabling this is recommended since it usually only marginally impacts performance, particularly when using a lower compression level.level = 0-9β specify the compression ratio. The lower the number, the lower the compression ratio, but the faster the backup will take. Generally, setting the level to1or2results in favorable compression of textual data and is noticeably faster than the higher levels. Setting the level to0effectively disables compression.bin-path = <full path to utility>β this only needs to be defined if the compression utility is not in the usual places or not in the system path.options = <string>β add commandline options to the configuration compression command.
options = "-Q4"
split = yes | noβ defaults tono. If set, the backup will be piped through thesplitcommand. This may be useful for user's with large databases, as some backup systems perform better with many smaller files instead of 1 large one. This defaults to1GBfile size, so this option isn't helpful if your dumps are smaller than that.
For python2.6, this option will be disabled if the subprocess32 module isn't available.
π New in version 1.1.13.
[pgauth] π
username = <name>β username forpg_dumpto authenticate with.password = <string>β password forpg_dumpto authenticate with.hostname = <string>β hostname forpg_dumpto connect with.port = <integer>β TCP port forpg_dumpto connect on.
pg_basebackup Provider Configuration [pg_basebackup] πβ¨
Backs up a PostgreSQL instance using the pg_basebackup utility.
[pg_basebackup]
format = tar | plain(default:tar) β defines the--formatoption forpg_basebackup.wal-method = none | fetch | plain(default:fetch) β defines the--wal-methodused forpg_basebackup.checkpoint = none | fast | spread(default:fast) β defines the--checkpointused forpg_basebackup.additional-options = <command-string>(default:none) β pass additional options to thepg_basebackupcommand. This will expandbackup_directory/backupdirvariables. π«Ά
[compression] π
Specify various compression settings, such as compression utility, compression level, etc.
method = gzip| gzip-rsyncable | pigz | bzip2 | pbzip2 | lzop | lzma | gpg | zstdβ define which compression method to use. Note that some methods may not be available by default on every system and may need to be compiled or installed.
For gpg compression, a key should already exist (gpg --gen-key) and default-recipient must be configured in ~/.gnupg/gpg.conf.
inline = yes | noβ whether or not to pipe the output of the backup command into the compression utility. Enabling this is recommended since it usually only marginally impacts performance, particularly when using a lower compression level.level = 0-9β specify the compression ratio. The lower the number, the lower the compression ratio, but the faster the backup will take. Generally, setting the level to1or2results in favorable compression of textual data and is noticeably faster than the higher levels. Setting the level to0effectively disables compression.bin-path = <full path to utility>β this only needs to be defined if the compression utility is not in the usual places or not in the system path.options = <string>β add commandline options to the configuration compression command.
options = "-Q4"
split = yes | noβ defaults tono. If set, the backup will be piped through thesplitcommand. This may be useful for user's with large databases, as some backup systems perform better with many smaller files instead of 1 large one. This defaults to1GBfile size, so this option isn't helpful if your dumps are smaller than that.
For python2.6, this option will be disabled if the subprocess32 module isn't available.
π New in version 1.1.13.
[pgauth] π
username = <name>β username forpg_basebackupto authenticate with.password = <string>β password forpg_basebackupto authenticate with.hostname = <string>β hostname forpg_basebackupto connect with.port = <integer>β TCP port forpg_basebackupto connect on.
mongodump Provider Configuration [mongodump] π
This plugin performs logical backups of a MongoDB by using the mongodump utility. Cute, efficient, iconic.
[mongodump]
host = <string>β hostname formongodumpto connect with.username = <name>β username formongodumpto authenticate with.password = <string>β password formongodumpto authenticate with.port = <integer>β TCP port formongodumpto connect on.uri = <string>β use a connection string instead of ahost,username, andpassword. One string to rule them all π₯
π New in version 1.1.14.
[compression] π
Specify various compression settings, such as compression utility, compression level, etc.
method = gzip| gzip-rsyncable | pigz | bzip2 | pbzip2 | lzop | lzma | gpg | zstdβ define which compression method to use. Note that some methods may not be available by default on every system and may need to be compiled or installed.
For gpg compression, a key should already exist (gpg --gen-key) and default-recipient must be configured in ~/.gnupg/gpg.conf.
inline = yes | noβ whether or not to pipe the output of the backup command into the compression utility. Enabling this is recommended since it usually only marginally impacts performance, particularly when using a lower compression level.level = 0-9β specify the compression ratio. The lower the number, the lower the compression ratio, but the faster the backup will take. Generally, setting the level to1or2results in favorable compression of textual data and is noticeably faster than the higher levels. Setting the level to0effectively disables compression.bin-path = <full path to utility>β this only needs to be defined if the compression utility is not in the usual places or not in the system path.options = <string>β add commandline options to the configuration compression command.
options = "-Q4"
split = yes | noβ The default isno. If you set it, the backup gets piped through thesplitcommand. This can be a whole vibe for users with large databases, because some backup systems perform better with many smaller files instead of 1 large one. It defaults to a 1GB file size, so this option isnβt helpful if your dumps are smaller than that.
For python2.6, this option will be disabled if the subprocess32 module isnβt available.
New in version 1.1.13.
π¦ Mariabackup Provider Configuration [mariabackup] π¦
Backs up a MySQL instance using mariabackup tool.
π [mariabackup] π
global-defaults = <path> (default: /etc/my.cnf)β The MySQL configuration file for mariabackup to parse. This is!include'dinto themy.cnfthe mariabackup plugin generates.innobackupex = <name> (default: innobackupex-1.5.1)β The path to theinnobackupexscript to run. If this is a relative path, this will be found in hollandβs environmentPATHas configured in/etc/holland/holland.conf.ibbackup = <name>β The path to theibbackupcommand to use. By default, no--ibbackupoption is passed to theinnobackupexscript. Usuallyinnobackupexwill detect this by itself and this should not need to be set.stream = mbstream (default: mbstream)β Placeholder.apply-logs = yes | no (default: yes)β Whether to runinnobackupex --apply-logsat the end of the backup. This is only supported when performing a non-streaming, non-compressed backup. In this case, even ifapply-logs = yes(the default), the prepare stage will be skipped. Even with an uncompressed, non-streaming backup you may want to disableapply-logsif you wish to use incremental backups.slave-info = yes | no (default: yes)β Whether to enable the--slave-infoinnobackupex option.safe-slave-backup = yes | no (default: yes)β Whether to enable the--safe-slave-backupinnobackupex option.no-lock = yes | no (default: no)β Whether to enable the--no-lockinnobackupex option.tmpdir = <path> (default: ${backup_directory})β The path for theinnobackupex --tmpdiroption.additional-options = <option>[, <option>...]β A list of additional options to pass toinnobackupex. This is a comma separated list of options.pre-command = <command-string>β A command to run prior to running this mariabackup run. This can be used, for instance, to generate amysqldumpschema dump prior to running mariabackup. Instances of${backup_directory}and${backupdir}will be replaced with the current holland backup directory where the mariabackup data will be stored.
π [compression] π
Specify various compression settings, such as compression utility, compression level, etc.
method = gzip| gzip-rsyncable | pigz | bzip2 | pbzip2 | lzop | lzma | gpg | zstdβ Define which compression method to use. Note that some methods may not be available by default on every system and may need to be compiled or installed.
For gpg compression, a key should already exist(gpg --gen-key) and default-recipient must be configured in ~/.gnupg/gpg.conf.
inline = yes | noβ Whether or not to pipe the output of the backup command into the compression utility. Enabling this is recommended since it usually only marginally impacts performance, particularly when using a lower compression level.level = 0-9β Specify the compression ratio. The lower the number, the lower the compression ratio, but the faster the backup will take. Generally, setting the level to 1 or 2 results in favorable compression of textual data and is noticeably faster than the higher levels. Setting the level to 0 effectively disables compression.bin-path = <full path to utility>β This only needs to be defined if the compression utility is not in the usual places or not in the system path.options = <string>β Add commandline options to the configuration compression command.
options = "-Q4"
split = yes | noβ The default isno. If set, the backup will be piped through thesplitcommand. This may be useful for users with large databases, as some backup systems perform better with many smaller files instead of 1 large one. This defaults to 1GB file size, so this option isnβt helpful if your dumps are smaller than that.
For python2.6, this option will be disabled if the subprocess32 module isnβt available.
New in version 1.1.13.
π MySQL connection info [mysql:client] π
These are optional and, if left undefined, Holland will try to login using the standard .my.cnf conventions.
user = <user>β The user to connect to MySQL as.password = <password>β The password for the MySQL user.socket = <socket>β The socket file to connect to MySQL with.host = <host>β This would be used for connecting to MySQL remotely.port = <port>β Used if MySQL is running on a port other than3306.
πΈ mariadb-dump Provider Configuration [mariadb-dump] πΈ
Backs up a MariaDB database using the mariadb-dump tool.
π«Ά [mariadb-dump] π«Ά
extra-defaults = yes | no (default: no)β This option controls whethermariadb-dumpwill only read options as set by holland or if additional options from global config files are read. By default, the plugin only uses options as set in the backupset config and includes authentication credentials only from the[client]section in~/.my.cnf.executable = "mariadb-dump"β Override the path where we can find mariadb command line utilities.lock-method = flush-lock | lock-tables | single-transaction | auto-detect | none (default: auto-detect)β One of:flush-lock,lock-tables,single-transaction,auto-detect,none.flush-lockβflush-lockwill place a global lock on all tables involved in the backup regardless of whether or not they are in the backup-set. Iffile-per-databaseis enabled, thenflush-lockwill lock all tables for every database being backed up. In other words, this option may not make much sense when usingfile-per-database.lock-tablesβlock-tableswill lock all tables involved in the backup. Iffile-per-databaseis enabled, thenlock-tableswill only lock all the tables associated with that database.single-transactionβsingle-transactionwill force running a backup within a transaction. This allows backing up of transactional tables without imposing a lock however will NOT properly backup non-transactional tables.auto-detectβ Auto-detect will choosesingle-transactionunless Holland finds non-transactional tables in the backup-set.noneβ None will completely disable locking. This is generally only viable on a MariaDB slave and only after traffic has been diverted, or slave services suspended.
databases = "*"β List of comma-delimited glob patterns for matching databases. Only databases matching these patterns will be backed up. default: include everything.exclude-databases =β List of comma-delimited glob patterns to exclude particular databases.tables = "*"β List of comma-delimited tables to include.exclude-tables = ""β List of comma-delimited tables to exclude.engines = "*"β List of comma-delimited glob patterns for matching table engines. Only tables matching these patterns will be backed up. default: include everything.exclude-engines =β List of comma-delimited glob patterns to exclude particular table engines.exclude-invalid-views = yes | no (default: no)β Whether to automate exclusion of invalid views that would otherwise causemariadb-dumpto fail. This adds additional overhead so this option is not enabled by default.flush-logs = yes | no (default: no)β Whether to runFLUSH LOGSin MariaDB with the backup. WhenFLUSH LOGSis actually executed depends on which if database filtering is being used and whether or notfile-per-databaseis enabled. Generally speaking, it does not make sense to useflush-logswithfile-per-databasesince the binary logs will not be consistent with the backup.flush-privileges = yes | no (default: yes)β Whether to emit aFLUSH PRIVILEGESstatement after dumping themysqldatabase. This ensures a proper restore when a dump contains themysqldatabase.dump-routines = yes | no (default: yes)β Whether to dump routines explicitly. (routines are implicitly included in the mariadb database)dump-events = yes | no (default: no)β Whether to dump events explicitly.dump-history = yes | no (default: no)β Whether to dump history explicitly. Requires MariaDB 10.11.0 or later.order-by-size = yes | no (default: no)β Whether to dump tables in the order of their size, smaller first. Requires MariaDB 10.9.1 or later.stop-slave = yes | no (default: no)β Whether to stop the slave before commencing with the backup.bin-log-position = yes | no (default: no)β Whether to record the binary log name and position at the time of the backup.max-allowed-packet = 128Mβ Maximum packet length to send/receive from the server.file-per-database = yes | no (default: yes)β Whether to run a separatemariadb-dumpfor each database. Note that while this may initially sound like a good idea, it is far simpler to backup all databases in one file, although that makes the restore process more difficult when only certain data needs to be restored.arg-per-database = {}β Theargs-per-databaseoption is only used iffile-per-databaseis enabled. It takes a JSON string in the format{"table1": "--arg", "table2": "--arg"}.additional-options = ""β Any additional options to pass to themariadb-dumpcommand-line utility. These should show up exactly as they are on the command line. e.g.:--flush-privileges --reset-master.
π¦ Database and Table filtering π¦
π
[compression] π
Specify various compression settings, such as compression utility, compression level, etc.
method = gzip| gzip-rsyncable | pigz | bzip2 | pbzip2 | lzop | lzma | gpg | zstdβ Define which compression method to use. Note that some methods may not be available by default on every system and may need to be compiled or installed.
For gpg compression, a key should already exist(gpg --gen-key) and default-recipient must be configured in ~/.gnupg/gpg.conf.
inline = yes | noβ the "should we pipe the output of the backup command straight into the compression utility" switch. Turning this on is highly recommended since it usually only marginally impacts performance, particularly when you're running a lower compression level. Free wins only πlevel = 0-9β the compression ratio dial. Lower number = lower compression ratio, but the backup will be faster. Generally, setting the level to1or2results in favorable compression of textual data and is noticeably faster than the higher levels. And setting the level to0? Effectively disables compression. periodt. π«Άbin-path = <full path to utility>β you only need to define this if the compression utility isn't in the usual places or isn't in the system path.options = <string>β adds commandline options to the configuration compression command, bestie. Like this:
options = "-Q4"
split = yes | noβ defaults tono. If you set it, the backup gets piped through thesplitcommand. This may be useful for users with large databases, since some backup systems perform better with many smaller files instead of 1 large one. It defaults to1GBfile size, so this option isn't helpful if your dumps are smaller than that. Forpython2.6, this option will be disabled if thesubprocess32module isn't available. New in version 1.1.13. β¨
π MySQL connection info [mysql:client]
These are optional and, if left undefined, Holland will try to login using the standard .my.cnf conventions. iykyk π
user = <user>β the user to connect to MySQL as.password = <password>β the password for the MySQL user.socket = <socket>β the socket file to connect to MySQL with.host = <host>β this would be used for connecting to MySQL remotely.port = <port>β used if MySQL is running on a port other than3306.
π¦ mysqlsh-dump-instance Provider Configuration [mysqlsh-dump-instance]
Backs up a MySQL instance using the mysqlsh dump-instance utility. main character provider energy π
[mysqlsh-dump-instance]
executable = mysqlshβ override the path where we can find themysqlshbinary.bin-log-position = yes | no (default: no)β whether to record the binary log name and position at the time of the backup.estimate-method = pluginβ the method to use to estimate the size of the backup.extra-defaults = yes | no (default: no)β this option controls whethermysqlshwill only read options as set by holland or if additional options from global config files are read. By default, the plugin only uses options as set in the backupset config and includes authentication credentials only from the[client]section in~/.my.cnf.log-level = 5β the log level used for the mysqlsh application log (mysqlsh.log).1=none,2=internal,3=error,4=warning,5=info,6=debug,7=debug2, or8=debug3.stop-slave = yes | no (default: no)β whether to stop the slave before commencing with the backup.additional-options = ,β additional options to pass to themysqlshcommand. When specifying an additional named argument that takes a list of values, you'll want to define the key repeatedly for each item in the list. e.g.--compatibility=strip_definers,--compatibility=strip_restricted_grantsthreads = 4β the number of parallel threads to use to dump chunks of data from the MySQL instance.max-rate = 0β the maximum number of bytes per second per thread for data read throughput during the dump. The unit suffixeskfor kilobytes,Mfor megabytes, andGfor gigabytes can be used. Setting this to0will disable rate limiting. ποΈconsistent = yes | no (default: yes)β whether to enable consistent data dumps by locking the instance for backup during the dump.skip-consistency-checks = yes | no (default: no)β whether to skip consistency checks.tz-utc = yes | no (default: yes)β whether to include a statement at the start of the dump to set the time zone to UTC.compression = zstdβ the compression type to use when writing data files for the dump.chunking = yes | no (default: yes)β whether to enable chunking of table data.bytes-per-chunk = 64Mβ the approximate size of each chunk when chunking is enabled. Requires chunking to be enabled in the backupset config. This option is always specified when holland executesmysqlshand chunking is enabled.ddl-only = yes | no (default: no)β whether to only dump the DDL files and exclude the data.data-only = yes | no (default: no)β whether to only dump the data and exclude the DDL files.exclude-tables = ,β a list of tables to exclude from the dump. Table names must be qualified with a valid schema name and quoted with backticks if needed.include-tables = ,β a list of tables to include in the dump. Table names must be qualified with a valid schema name and quoted with backticks if needed.events = yes | no (default: yes)β whether to dump events.exclude-events = ,β a list of events to exclude from the dump. Events must be qualified with a valid schema name and quoted with backticks if needed.include-events = ,β a list of events to include in the dump. Events must be qualified with a valid schema name and quoted with backticks if needed.routines = yes | no (default: yes)β whether to dump routines.exclude-routines = ,β a list of routines to exclude from the dump. Routines must be qualified with a valid schema name and quoted with backticks if needed.include-routines = ,β a list of routines to include in the dump. Routines must be qualified with a valid schema name and quoted with backticks if needed.triggers = yes | no (default: yes)β whether to dump triggers.exclude-triggers = ,β a list of triggers to exclude from the dump. Triggers must be qualified with a valid schema name and quoted with backticks if needed.include-triggers = ,β a list of triggers to include in the dump. Triggers must be qualified with a valid schema name and quoted with backticks if needed.users = yes | no (default: yes)β whether to include users and their roles and grants in the dump.exclude-users = ,β a list of users to exclude from the dump.include-users = ,β a list of users to include in the dump.exclude-schemas = ,β a list of schemas to exclude from the dump.include-schemas = ,β a specific list of schemas to include in the dump. You cannot include theinformation_schema,mysql,ndbinfo,performance_schema, orsysschemas by naming them here. Use thedump-schemasplugin instead. πstrip-definers = yes | no (default: no)β whether to enable thestrip_definersHeatWave compatibility requirement.create-invisible-pks = yes | no (default: no)β whether to enable thecreate_invisible_pksHeatWave compatibility requirement.
π MySQL connection info [mysql:client]
These are optional and, if left undefined, Holland will try to login using the standard .my.cnf conventions. (yes, same deal as before, she's consistent π
)
user = <user>β the user to connect to MySQL as.password = <password>β the password for the MySQL user.socket = <socket>β the socket file to connect to MySQL with.host = <host>β this would be used for connecting to MySQL remotely.port = <port>β used if MySQL is running on a port other than3306.
πΈ mysqlsh-dump-schemas Provider Configuration [mysqlsh-dump-schemas]
Backs up MySQL schemas using the mysqlsh dump-schemas utility. π
[mysqlsh-dump-schemas]
Same energy, different provider β but bestie, still every single option:
executable = mysqlshβ override the path where we can find themysqlshbinary.bin-log-position = yes | no (default: no)β whether to record the binary log name and position at the time of the backup.estimate-method = pluginβ the method to use to estimate the size of the backup.extra-defaults = yes | no (default: no)β this option controls whethermysqlshwill only read options as set by holland or if additional options from global config files are read. By default, the plugin only uses options as set in the backupset config and includes authentication credentials only from the[client]section in~/.my.cnf.log-level = 5β the log level used for the mysqlsh application log (mysqlsh.log).1=none,2=internal,3=error,4=warning,5=info,6=debug,7=debug2, or8=debug3.stop-slave = yes | no (default: no)β whether to stop the slave before commencing with the backup.additional-options = ,β additional options to pass to themysqlshcommand. When specifying an additional named argument that takes a list of values, you'll want to define the key repeatedly for each item in the list. e.g.--compatibility=strip_definers,--compatibility=strip_restricted_grantsthreads = 4β the number of parallel threads to use to dump chunks of data from the MySQL instance.max-rate = 0β the maximum number of bytes per second per thread for data read throughput during the dump. The unit suffixeskfor kilobytes,Mfor megabytes, andGfor gigabytes can be used. Setting this to0will disable rate limiting.consistent = yes | no (default: yes)β whether to enable consistent data dumps by locking the instance for backup during the dump.skip-consistency-checks = yes | no (default: no)β whether to skip consistency checks.tz-utc = yes | no (default: yes)β whether to include a statement at the start of the dump to set the time zone to UTC.compression = zstdβ the compression type to use when writing data files for the dump.chunking = yes | no (default: yes)β whether to enable chunking of table data.bytes-per-chunk = 64Mβ the approximate size of each chunk when chunking is enabled. Requires chunking to be enabled in the backupset config. This option is always specified when holland executesmysqlshand chunking is enabled.ddl-only = yes | no (default: no)β whether to only dump the DDL files and exclude the data.data-only = yes | no (default: no)β whether to only dump the data and exclude the DDL files.exclude-tables = ,β a list of tables to exclude from the dump. Table names must be qualified with a valid schema name and quoted with backticks if needed.include-tables = ,β a list of tables to include in the dump. Table names must be qualified with a valid schema name and quoted with backticks if needed.events = yes | no (default: yes)β whether to dump events.exclude-events = ,β a list of events to exclude from the dump. Events must be qualified with a valid schema name and quoted with backticks if needed.include-eventsβ a list of events you wanna include in the dump β¨. Every event has to be qualified with a legit schema name, and quoted with backticks if it needs it. no cap.routines=yes|no(default:yes) β whether to dump routines. that's it, that's the option πexclude-routinesβ a list of routines to leave out of the dump. Routines must be qualified with a valid schema name and quoted with backticks if needed. bye bestie πinclude-routinesβ a list of routines to pull into the dump. Same deal: qualified with a valid schema name, quoted with backticks when needed. πtriggers=yes|no(default:yes) β whether to dump triggers. lowkey important, don't skip it π₯exclude-triggersβ a list of triggers to exclude from the dump. Qualified with a valid schema name, backticks if needed. π¦include-triggersβ a list of triggers to include in the dump. Qualified with a valid schema name, backticks if needed. π«Άschemasβ a list of schemas to include in the dump. heads up: this one is required for thedump-schemasprovider. like, mandatory mandatory π
πΈ MySQL connection info [mysql:client] πΈ
These are optional, and if you leave them undefined, Holland will just try to log in using the standard .my.cnf conventions. comfy defaults, we love to see it π
user=<user>β the user to connect to MySQL as.password=<password>β the password for the MySQL user. yes it's literally called that. keep it secret, keep it safe πsocket=<socket>β the socket file to connect to MySQL with.host=<host>β this one's for connecting to MySQL remotely. long distance relationship core πport=<port>β used if MySQL is running on a port other than3306.
β‘ command Provider Configuration [command] β‘
Executes custom backup commands. you're the main character here, you write the command π
[command]
command=""(no default) β the command to execute for backing up data. You can inject the Holland backup data directory path by using the{backup_data_dir}placeholder inside the command. That placeholder gets replaced with the actual backup directory path at runtime. Using the placeholder is not required, tho. The backup will fail if the command exits with a non-zero status. Also!! if you're using thebefore-backup-command,after-backup-command, orfailed-backup-commandoptions in yourholland:backupsection, the backup will also fail if those commands exit with a non-zero status. so many ways to fail, stay vigilant π
Examples:
command = "rsync -av /var/lib/mysql/ {backup_data_dir}/"
command = "tar -czf {backup_data_dir}/backup.tar.gz /var/lib/mysql"
command = "cp -r /var/lib/mysql {backup_data_dir}/"
create-backup-data-dir=yes|no(default:no) β whether to create the"backup_data"subdirectory inside the backup directory. If you're using the{backup_data_dir}placeholder in your command, some commands may or may not automatically create this directory (rude, honestly). This option is here as a convenience so the directory definitely exists before the command runs. girl scout promise π
π Backup-Set Configs π
Backup-Set config files largely inherit the config options of whatever provider you specified. To define a provider for the backup set, you gotta put this at the top of the backup set config file:
[holland:backup]
plugin = <plugin>
backups-to-keep = #
estimated-size-factor = #
historic-size = <yes|no>
historic-size-factor = #
historic-estimated-size-factor = #
π Configuration Options π
plugin=<plugin>β the name of the provider used for the backup-set. This is required for the backup-set to function at all. no plugin, no vibes β¨backups-to-keep=#β how many backups to keep for a backup-set. Defaults to retaining1backup.estimated-size-factor=#β the scale factor Holland uses when deciding if there's enough free space to perform a backup. Default is1.0, and this number gets multiplied against whatever each individual plugin reports as its estimated backup size when Holland is verifying there's enough free space for the backupset.
As of Holland 1.1.1, the 'historic' backup size will be used instead. If Holland can't determine that size, it defaults back to this. plan B slay π
auto-purge-failures=yes|noβ whether to keep a failed backup or automatically remove the backup directory. By default this is on, with the intention that whatever process is calling holland will retry when a backup fails. You can disable this behavior by settingauto-purge-failures = nowhen partial backups might be useful or when you're troubleshooting a backup failure. πpurge-policy=manual|before-backup|after-backupβ when to run the purge routine on a backupset. By default it runs after a new successful backup completes. Up tobackups-to-keepbackups will be retained, including the most recent.
purge-policy = before-backup runs the purge routine just before a new backup starts. This retains up to backups-to-keep backups before the new backup is even started, letting it purge all previous backups if backups-to-keep is set to 0. Useful when some other process is retaining backups off-server and disk space is at a premium. πΈ
purge-policy = manual never runs the purge routine automatically. Either holland purge has to be run externally, or you explicitly remove the desired backup directories at some later time. you're on your own bestie π«‘
before-backup-command=stringβ run a shell command before a backup starts. This lets a command do something before the backup kicks off, like setting up aniptablesrule (taking a mysql slave out of a load balancer) or aborting the backup based on some external condition.
The backup will fail if this command exits with a non-zero status. β οΈ
New in version 1.0.7.
after-backup-command=stringβ run a shell command after a backup completes. This lets a command do something when a backup completes successfully, like sending out a success notification. π
The backup will fail if this command exits with a non-zero status. β οΈ
New in version 1.0.7.
failed-backup-command=stringβ run a shell command if a backup fails. This lets some command do something when a backup fails, like sending out a failure notification. π
The backup will fail if this command exits with a non-zero status. β οΈ
New in version 1.0.7.
historic-size=yes|noβ defaults toyes. Checks for the'backup.conf'file in the'newest'spooled folder for the running "backupset". If the config file exists and contains'estimated-size'and'on-disk-size', those values get used to decide if holland has enough free space for a backupset. Basically Holland uses the previous backup's values to estimate the next backup's size. time travel but make it storage π¦
New in version 1.1.1.
historic-size-factor=#β defaults to'1.5'. If the estimated size of the database has changed by more than this multiple, the'estimated-size-factor'value gets used to determine if there's sufficient free space for the backupset.
New in version 1.1.1.
historic-estimated-size-factor=#β defaults to'1.1'. Specifies the scale factor when Holland decides if there's enough free space to perform a backup. Holland will throw an error if the system has less free space than the last backup size multiplied by this value. math girlies rise π€
New in version 1.1.1.
create-symlinks=yes|noβ defaults toyes. Enables creation of the"newest"and"oldest"symlinks in the backupset directory. Disabling the symlink creation process can be helpful on filesystems that don't support symlinks. π¦
New in version 1.2.7.
$ ls -l /var/spool/holland/default/
total 0
drwxrwx---. 3 root root 58 Aug 18 16:18 20210818_161856
lrwxrwxrwx. 1 root root 42 Aug 18 16:18 newest -> /var/spool/holland/default/20210818_161856
lrwxrwxrwx. 1 root root 42 Aug 18 16:18 oldest -> /var/spool/holland/default/20210818_161856
For all hook commands, Holland performs simple text substitution on these three parameters:
hookβ name of the hook being called (one of:before-backup-command,after-backup-command,failed-backup-command)backupdirβ path to the current backup directory (e.g./var/spool/holland/mysqldump/YYYYmmdd_HHMMSS)backupsetβ name of the backupset being run (e.g.'mysql-lvm')
For example:
[holland:backup]
plugin = mysqldump
before-backup-command = /usr/local/bin/my-custom-script --hook ${hook} --backupset ${backupset} --backupdir ${backupdir}
after-backup-command = echo ${backupset} completed successfully. Files are in ${backupdir}
[mysqldump]
...
Backup-Set files live in the "backupsets" directory, which by default is /etc/holland/backupsets. The name of the backup-set is defined by its configuration filename and can really be almost anything β which means backup-sets can be organized in any arbitrary way you want, as long as the files end in .conf. The file extension is not part of the backup-set's name. π
As noted above, for a backup-set to actually be active, it has to be listed in the backupsets variable. no listing, no backup, periodt π
Backups get placed under the directory defined in the backup_directory section of the main configuration file. Each backup lives under a directory corresponding to the backup-set name, followed by a date-encoded directory. πβ¨
π AUTHOR π
Holland Core Team. icons only π
π COPYRIGHT π
2025
and that's a wrap bestie!! you just read the whole thing, i'm so proud of you π₯Ή this was Holland 1.3.1, dated Sep 08, 2025, and it's HOLLAND(1). go forth and back up your databases, mwah πβ¨
π¦ where this page comes from
- epel 9: holland 1.3.1-2.el9 Β· BSD
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms