Man page - thin_migrate(8)
Packages contains this manual
- thin_repair(8)
- cache_restore(8)
- cache_repair(8)
- thin_metadata_pack(8)
- thin_restore(8)
- era_check(8)
- thin_check(8)
- thin_metadata_unpack(8)
- thin_metadata_size(8)
- era_restore(8)
- thin_rmap(8)
- thin_ls(8)
- era_invalidate(8)
- thin_migrate(8)
- thin_dump(8)
- cache_metadata_size(8)
- cache_check(8)
- cache_dump(8)
- era_dump(8)
- thin_trim(8)
- thin_delta(8)
- cache_writeback(8)
apt-get install thin-provisioning-tools
Manual
thin_migrate
NAMESYNOPSIS
DESCRIPTION
OPTIONS
EXAMPLE
DIAGNOSTICS
AUTHOR
NAME
thin_migrate
SYNOPSIS
thin_migrate
[
options
]
--source-dev
{device}
--dest-dev
{device}
thin_migrate
[
options
]
--source-dev
{device}
--dest-file
{file}
DESCRIPTION
thin_migrate copies provisioned data blocks from a thin device to another device or file. It is designed for cloning a read-only snapshot or thin volume within a live thin-pool. A metadata snapshot is required to read the data mappings.
OPTIONS
-h, --help
Print help and exit.
-V, --version
Print version information and exit.
--source-dev {device}
The input read-only thin device to copy.
--dest-dev {device}
The output device as the copy destination.
--dest-file {file}
The output file as the copy destination.
-q, --quit
Suppress output messages, return only exit code.
--buffer-size-meg {size}
Specify the size of the data buffers, in megabytes.
EXAMPLE
Assuming that thereโs a thin snapshot โvg/snapโ to copy, we must first set the snapshot to read-only:
$ lvchange vg/snap --permission r
Next, create a metadata snapshot for running thin_migrate :
$ dmsetup message vg-mythinpool-tpool 0 reserve_metadata_snap
Once the metadata snapshot is created, copy the snapshot into another linear or thin volume. The destination volume must have the same size as the source device.
$ thin_migrate --src-device /dev/vg/snap --dest-device /dev/vg2/dest
Alternatively, copy the snapshot into a file. thin_migrate can optionally create the destination file if it is not present, or the size of the file will be truncated to match that of the source device.
$ thin_migrate --src-device /dev/vg/snap --dest-file dest.bin
Finally, release the metadata snapshot after thin_migrate finishes its job:
$ dmsetup message vg-mythinpool-tpool 0 release_metadata_snap
DIAGNOSTICS
thin_migrate returns an exit code of 0 for success or 1 for error.
AUTHOR
Joe Thornber <ejt@redhat.com>