此内容没有您所选择的语言版本。
2.2. Backup drivers
This section describes how to configure the
cinder-backup
service and its drivers.
To set a backup driver, use the
backup_driver
flag. By default there is no backup driver enabled.
2.2.1. Ceph backup driver
The Ceph backup driver backs up volumes of any type to a Ceph back-end store. The driver can also detect whether the volume to be backed up is a Ceph RBD volume, and if so, it tries to perform incremental and differential backups.
For source Ceph RBD volumes, you can perform backups within the same Ceph pool (not recommended). You can also perform backups between different Ceph pools and between different Ceph clusters.
At the time of writing, differential backup support in Ceph/librbd was quite new. This driver attempts a differential backup in the first instance. If the differential backup fails, the driver falls back to full backup/copy.
If incremental backups are used, multiple backups of the same volume are stored as snapshots so that minimal space is consumed in the backup store. It takes far less time to restore a volume than to take a full copy.
Note
Block Storage enables you to:
- Restore to a new volume, which is the default and recommended action.
- Restore to the original volume from which the backup was taken. The restore action takes a full copy because this is the safest action.
To enable the Ceph backup driver, include the following option in the
cinder.conf
file:
backup_driver = cinder.backup.drivers.ceph
The following configuration options are available for the Ceph backup driver.
Configuration option = Default value | Description |
---|---|
[DEFAULT] | |
backup_ceph_chunk_size = 134217728
|
(IntOpt) The chunk size, in bytes, that a backup is broken into before transfer to the Ceph object store. |
backup_ceph_conf = /etc/ceph/ceph.conf
|
(StrOpt) Ceph configuration file to use. |
backup_ceph_pool = backups
|
(StrOpt) The Ceph pool where volume backups are stored. |
backup_ceph_stripe_count = 0
|
(IntOpt) RBD stripe count to use when creating a backup image. |
backup_ceph_stripe_unit = 0
|
(IntOpt) RBD stripe unit to use when creating a backup image. |
backup_ceph_user = cinder
|
(StrOpt) The Ceph user to connect with. Default here is to use the same user as for Cinder volumes. If not using cephx this should be set to None. |
restore_discard_excess_bytes = True
|
(BoolOpt) If True, always discard excess bytes when restoring volumes i.e. pad with zeroes. |
This example shows the default options for the Ceph backup driver.
backup_ceph_conf=/etc/ceph/ceph.conf backup_ceph_user = cinder backup_ceph_chunk_size = 134217728 backup_ceph_pool = backups backup_ceph_stripe_unit = 0 backup_ceph_stripe_count = 0
2.2.2. IBM Tivoli Storage Manager backup driver
The IBM Tivoli Storage Manager (TSM) backup driver enables performing volume backups to a TSM server.
The TSM client should be installed and configured on the machine running the
cinder-backup
service. See the IBM Tivoli Storage Manager Backup-Archive Client Installation and User's Guide for details on installing the TSM client.
To enable the IBM TSM backup driver, include the following option in
cinder.conf
:
backup_driver = cinder.backup.drivers.tsm
The following configuration options are available for the TSM backup driver.
Configuration option = Default value | Description |
---|---|
[DEFAULT] | |
backup_tsm_compression = True
|
(BoolOpt) Enable or Disable compression for backups |
backup_tsm_password = password
|
(StrOpt) TSM password for the running username |
backup_tsm_volume_prefix = backup
|
(StrOpt) Volume prefix for the backup id when backing up to TSM |
This example shows the default options for the TSM backup driver.
backup_tsm_volume_prefix = backup backup_tsm_password = password backup_tsm_compression = True
2.2.3. Swift backup driver
The backup driver for the swift back end performs a volume backup to an object storage system.
To enable the swift backup driver, include the following option in the
cinder.conf
file:
backup_driver = cinder.backup.drivers.swift
The following configuration options are available for the Swift back-end backup driver.
Configuration option = Default value | Description |
---|---|
[DEFAULT] | |
backup_swift_auth = per_user
|
(StrOpt) Swift authentication mechanism |
backup_swift_auth_version = 1
|
(StrOpt) Swift authentication version. Specify "1" for auth 1.0, or "2" for auth 2.0 |
backup_swift_block_size = 32768
|
(IntOpt) The size in bytes that changes are tracked for incremental backups. backup_swift_object_size has to be multiple of backup_swift_block_size. |
backup_swift_ca_cert_file = None
|
(StrOpt) Location of the CA certificate file to use for swift client requests. |
backup_swift_container = volumebackups
|
(StrOpt) The default Swift container to use |
backup_swift_enable_progress_timer = True
|
(BoolOpt) Enable or Disable the timer to send the periodic progress notifications to Ceilometer when backing up the volume to the Swift backend storage. The default value is True to enable the timer. |
backup_swift_key = None
|
(StrOpt) Swift key for authentication |
backup_swift_object_size = 52428800
|
(IntOpt) The size in bytes of Swift backup objects |
backup_swift_retry_attempts = 3
|
(IntOpt) The number of retries to make for Swift operations |
backup_swift_retry_backoff = 2
|
(IntOpt) The backoff time in seconds between Swift retries |
backup_swift_tenant = None
|
(StrOpt) Swift tenant/account name. Required when connecting to an auth 2.0 system |
backup_swift_url = None
|
(StrOpt) The URL of the Swift endpoint |
backup_swift_user = None
|
(StrOpt) Swift user name |
swift_catalog_info = object-store:swift:publicURL
|
(StrOpt) Info to match when looking for swift in the service catalog. Format is: separated values of the form: <service_type>:<service_name>:<endpoint_type> - Only used if backup_swift_url is unset |
To enable the swift backup driver for 1.0 or 2.0 authentication version, specify
1
or 2
correspondingly. For example:
backup_swift_auth_version = 2
In addition, the 2.0 authentication system requires
backup_swift_tenant
setting:
backup_swift_tenant = <None>
This example shows the default options for the Swift back-end backup driver.
backup_swift_url = http://localhost:8080/v1/AUTH_ backup_swift_auth = per_user backup_swift_auth_version = 1 backup_swift_user = <None> backup_swift_key = <None> backup_swift_container = volumebackups backup_swift_object_size = 52428800 backup_swift_retry_attempts = 3 backup_swift_retry_backoff = 2 backup_compression_algorithm = zlib
2.2.4. NFS backup driver
The backup driver for the NFS back end backs up volumes of any type to an NFS exported backup repository.
To enable the NFS backup driver, include the following option in the
[DEFAULT]
section of the cinder.conf
file:
backup_driver = cinder.backup.drivers.nfs
The following configuration options are available for the NFS back-end backup driver.
Configuration option = Default value | Description |
---|---|
[DEFAULT] | |
backup_container = None
|
(StrOpt) Custom directory to use for backups. |
backup_enable_progress_timer = True
|
(BoolOpt) Enable or Disable the timer to send the periodic progress notifications to Ceilometer when backing up the volume to the backend storage. The default value is True to enable the timer. |
backup_file_size = 1999994880
|
(IntOpt) The maximum size in bytes of the files used to hold backups. If the volume being backed up exceeds this size, then it will be backed up into multiple files.backup_file_size must be a multiple of backup_sha_block_size_bytes. |
backup_mount_options = None
|
(StrOpt) Mount options passed to the NFS client. See NFS man page for details. |
backup_mount_point_base = $state_path/backup_mount
|
(StrOpt) Base dir containing mount point for NFS share. |
backup_sha_block_size_bytes = 32768
|
(IntOpt) The size in bytes that changes are tracked for incremental backups. backup_file_size has to be multiple of backup_sha_block_size_bytes. |
backup_share = None
|
(StrOpt) NFS share in hostname:path, ipv4addr:path, or "[ipv6addr]:path" format. |