## MySQL LVM Backup Example Backup-Set
##
## This implements a standard MySQL + LVM Backup. For the most part, 
## the snapshot options need no modification. Changing the recovery
## and locking options may be occasionally useful. The plugin is designed
## to fit the majority of configurations without needing to make any 
## modifications, however.

## Global Holland Settings
[holland:backup]
plugin = mysqldump-lvm
backups-to-keep = 1
auto-purge-failures = yes
purge-policy = after-backup
estimated-size-factor = 1.0

## LVM Backup Specific Settings
[mysql-lvm]
## 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.
##
## If snapshot-size is defined, the number represents the size of the 
## snapshot in megabytes.
#snapshot-size = ""

## The name of the snapshot, the default being the name of the MySQL LVM
## volume + "_snapshot" (ie Storage-MySQL_snapshot)
#snapshot-name = "" # no default

## Where to mount the snapshot. By default a randomly generated directory
## under /tmp is used.
#snapshot-mountpoint = "" # no default

## Whether or not to run a FLUSH TABLES WITH READ LOCK to 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.
lock-tables = True

## Whether or not to run a FLUSH TABLES before running the full 
## FLUSH TABLES WITH READ LOCK. Should make the FLUSH TABLES WITH READ LOCK
## operation a bit faster.
extra-flush-tables = True

## MySQL Instance Settings
##
## These control the behavior of the MySQL instance which runs on the LVM
## snapshot that mysqldump runs against. Note that only a sub-set of
## MySQL parameters are supported.
[mysqld]
## User to run the MySQL instance as. 
user = mysql

## The size of the InnoDB buffer pool. Larger values can equate to faster
## backups, though be careful as setting this too large could overcommit
## the memory available on the server and could cause swapping.
innodb-buffer-pool-size = 128M

## The size of the key buffer. This will likely only affect backup-times
## when using the --where option for mysqldump. Otherwise, it is unlikely
## to affect backup-times. Be careful as setting this too large could 
##overcommit the memory available on the server and could cause swapping.
key-buffer-size = 128M

## Useful when mysqld is in a non-standard place and not in the PATH.
#mysqld-exe = /usr/libexec/mysqld

## mysqldump Settings
##
## These are identical to the settings provided by the mysqldump
## provider. See the mysqldump.conf example configuration file or consult
## the documentation for a full description of options.
[mysqldump]
file-per-database = yes
## Probably not all that useful in this specific case since the backup
## is of the MySQL instance running on the LVM snapshot and, thus, locking
## may not matter much.
lock-method = lock-tables
#databases = "*"
#tables = "*"
#stop-slave = no
#bin-log-position = no

## Compression Settings
##
## Identical in behavior to the compression options provided by most of
## the backup plugins. Consult the mysqldump.conf example configuration 
## file, or the documentation for a full explanation.
[compression]
method = gzip
inline = True
level = 1

## MySQL Connection Settings
##
## mysqldump-lvm backups are a special case because Holland has to connect
## to the MySQL instance running on the LVM snapshot using an @localhost
## account. As a result, the only useful options here might be to set
## the password, user, or defaults-file
[mysql:client]
#defaults-file = /root/.my.cnf
#user = "" # no default
#password = "" # no default
