NAME
SYNOPSIS
DESCRIPTION
EXAMPLES
SEE ALSO
pmempool-transform – Modify internal structure of a poolset.
pmempool transform [options] <poolset_file_src> <poolset_file_dst>
The pmempool transform command modifies internal structure of a poolset
defined by the poolset_file_src
file, according to a structure described in
the poolset_file_dst
file.
The following operations are supported:
adding replicas - a new replica can be added and synchronized with other replicas in the poolset,
removing replicas - replicas can be removed from the poolset.
Currently these operations are allowed only for pmemobj pools (see libpmemobj(3)).
The poolset_file_src argument provides the source poolset to be changed.
The poolset_file_dst argument points to the target poolset.
When adding or deleting replica, the two poolset files can differ only in the definitions of replicas which are to be added or deleted. Also, to add a replica it is necessary for its size to match or exceed the poolset size. Otherwise the whole operation fails and no changes are applied.
-d, --dry-run
Enable dry run mode. In this mode no changes are applied, only check for viability of the operation is performed.
-v, --verbose
Increase verbosity level.
-h, --help
Display help message and exit.
Let files /path/poolset_file_src
and /path/poolset_file_dst
have the
following contents:
PMEMPOOLSET
20M /0/partfile1
20M /0/partfile2
25M /0/partfile3
REPLICA
40M /1/partfile1
20M /1/partfile2
PMEMPOOLSET
20M /0/partfile1
20M /0/partfile2
25M /0/partfile3
REPLICA
40M /1/partfile1
20M /1/partfile2
REPLICA
50M /2/partfile1
20M /2/partfile2
Then, the command
pmempool transform /path/poolset_file_src /path/poolset_file_dst
adds a replica to the poolset. All other replicas remain unchanged and the size of the pool remains 60M.
Let files /path/poolset_file_src
and /path/poolset_file_dst
have the
following contents:
PMEMPOOLSET
20M /0/partfile1
20M /0/partfile2
25M /0/partfile3
REPLICA
40M /1/partfile1
20M /1/partfile2
PMEMPOOLSET
20M /0/partfile1
20M /0/partfile2
25M /0/partfile3
Then
pmempool_transform /path/poolset_file_src /path/poolset_file_dst
deletes the second replica from the poolset. The first replica remains unchanged and the size of the pool is still 60M.
libpmemblk(3), libpmemlog(3), pmempool(1)