-.TH LFS-MIGRATE 1 2021-11-08 "Lustre" "Lustre Utilities"
+.TH LFS-MIGRATE 1 2024-08-20 Lustre "Lustre User Utilities"
.SH NAME
lfs-migrate \- migrate files or directories between MDTs or OSTs.
.SH SYNOPSIS
-.B lfs migrate
-.RB [ -h "] [" -v ]
+.SY "lfs migrate"
+.RB [ -h ]
+.RB [ -v ]
.RI [ SETSTRIPE_OPTIONS " ... ]"
.IR FILE " ..."
-.br
-.B lfs migrate -m \fISTART_MDT_INDEX
+.SY "lfs migrate"
+.B -m
+.I START_MDT_INDEX
.RB [ -cdHv ]
.I DIRECTORY
-.br
+.YS
.SH DESCRIPTION
Migrate OST objects between OSTs for the specified
.IR FILE ,
or recursively migrate
.I DIRECTORY
and all inodes/directories therein between MDTs.
-.SH OST MIGRATE OPTIONS
+.SH OPTIONS
+.SS OST MIGRATE OPTIONS
.P
The
.B lfs migrate
.I SETSTRIPE_OPTIONS
listed in
.BR lfs-setstripe (1)
-to specify the layout of the target file. The migrate command differs from
+to specify the layout of the target file. The migrate command differs from
.B lfs setstripe
in that
.B lfs migrate
.BR lfs-setstripe (1)
for details.
.TP
-.BR -b , --block
+.BR -b ", " --block
Block access to the file by other applications during data migration
-(default). This prevents other processes from accessing the file during
+(default). This prevents other processes from accessing the file during
migration, which prevents data data writes to the old file objects from
-being lost. This should be used if an OST needs to be completely emptied
+being lost. This should be used if an OST needs to be completely emptied
prior to its removal, to ensure all requested files are migrated off the
OST.
.TP
-.BR -h , --help
+.BR -h ", " --help
Print usage message.
.TP
-.BR -n , --non-block
-Abort migration if concurrent file access is detected. This can be
+.BR -n ", " --non-block
+Abort migration if concurrent file access is detected. This can be
used with OST space balancing migration to avoid interfering with file
access by applications if there is not a requirement to migrate any
particular file to the new layout.
.TP
-.BR -D , --non-direct
+.BR -D ", " --non-direct
Do
.B not
use
.B O_DIRECT
-read and write operations when migrating a file. The
+read and write operations when migrating a file. The
.B O_DIRECT
option avoids data copy from kernel buffers into userspace, which can
impose CPU and memory overhead on the copy operation, but makes read and
-write operations synchronous. Using the
+write operations synchronous. Using the
.B --non-direct
option uses buffered read/write operations, which may improve migration
speed at the cost of more CPU and memory overhead.
-.br
+.IP
This option cannot be used on encrypted files when the encryption key is not
available. It will result in
-.B
--ENOKEY.
+.BR -ENOKEY .
.TP
-.BR -W , --bandwidth
+.BR -W ", " --bandwidth
Limit how much file system bandwidth a migrate job can consume.
.TP
.BR --stats
.BR --stats-interval
Controls how often the stats are output; this defaults to 5 seconds.
.TP
-.BR -v , --verbose
+.BR -v ", " --verbose
Print each filename as it is migrated.
-.P
-NOTE:
+.SS NOTES
.B lfs migrate
has a complementary
.B lfs_migrate
script which is used to provide extra functionality when migrating file
-data between OSTs and has a separate man page. See
+data between OSTs and has a separate man page. See
.BR lfs_migrate (1)
for details.
-.SH MDT MIGRATE OPTIONS
+.SS MDT MIGRATE OPTIONS
.TP
-.BR -m , --mdt-index=\fIMDT_INDEX [, \fIMDT_INDEX ,...]
+.BR -m ", " --mdt-index=\fIMDT_INDEX [, \fIMDT_INDEX ,...]
The specified
.I DIRECTORY
.B and all subdirectories and inodes
and future metadata workload. If
.I MDT_INDEX
is -1, the MDT index will be balanced by free space and inodes among
-available MDTs. If multiple
+available MDTs. If multiple
.I MDT_INDEX
values are specified in a comma-separated list, then all
subdirectories will be
.BI -c N
option were given.
.TP
-.BR -c , --mdt-count=\fICOUNT\fR
+.BR -c ", " --mdt-count=\fICOUNT\fR
All directories and subdirectories in the tree will be striped across
.I COUNT
MDTs, always using
.I MDT_INDEX
-as the primary MDT for the directory. If
+as the primary MDT for the directory. If
.I MDT_INDEX is
.B -1
then
.I COUNT
directory stripes will be chosen from MDTs proportional to the amount
-of free inodes and space on each MDT. If multiple
+of free inodes and space on each MDT. If multiple
.I MDT_INDEX
values are specified in a comma-separated list, then the number of specified
.I MDT_INDEX
values must match
.IR COUNT .
.TP
-.BR -d , --directory
-Only migrate the specified \fIDIRECTORY\fR and the non-directory inodes that are
-directly located within it.
-Similar to '\fBls -d\fR' and '\fBlfs getstripe -d\fR'.
+.BR -d ", " --directory
+Only migrate the specified
+.I DIRECTORY
+and the non-directory inodes that are directly located within it.
+Similar to
+.RB ' "ls -d" '
+and
+.RB ' "lfs getstripe -d" '.
.TP
.BR --clear-fixed
Do not set LMV_HASH_FIXED_FLAG upon migrating the directory. It allows a striped dir
with only one stripe to be converted to a plain directory.
.TP
-.BR -H , --mdt-hash=\fIHASH_TYPE\fR
+.BR -H ", " --mdt-hash=\fIHASH_TYPE\fR
Use
.I HASH_TYPE
for the new directory layout.
perfectly uniform distribution (e.g. sequential numbers).
.TP
.B fnv_1a_64 (type 2)
-Fowler-Noll-Vo (FNV-1a) hash algorithm. This provides
+Fowler-Noll-Vo (FNV-1a) hash algorithm. This provides
reasonably uniform, but not cryptographically strong,
hashing of the filename. (default)
.TP
.B crush (type 3)
-CRUSH hash algorithm. This is a consistent hash
+CRUSH hash algorithm. This is a consistent hash
algorithm, so minimum sub files need to relocate
during directory restripe.
.RE
-.P
-.TP
-.B NOTE
-Only the root user can migrate directories. Files that have been archived by
+.SS NOTES
+Only the root user can migrate directories. Files that have been archived by
HSM or are currently opened will fail to migrate, user can run the same migrate
-command again to finish migration when files are ready. Both inode and
-directory entry will be migrated. During migration directory and sub files can
+command again to finish migration when files are ready. Both inode and
+directory entry will be migrated. During migration directory and sub files can
be accessed like normal ones, but the migration itself cannot be interrupted.
-.TP
-.B NOTE
+.PP
It is not currently possible to migrate files with an
.B mdt
-component (Data-on-MDT, DoM). If it is necessary to migrate such files off
+component (Data-on-MDT, DoM). If it is necessary to migrate such files off
a particular MDT, they must first be migrated to have a non-DoM file layout
-and then the inodes migrated separately. See
+and then the inodes migrated separately. See
.B EXAMPLES
for details on how to migrate DoM files between MDTs.
-.TP
-.B WARNING
+.SS WARNING
Each migrated file or directory will have a new FID, and hence a new inode
-number. As a consequence, files archived by Lustre HSM that depend on
+number. As a consequence, files archived by Lustre HSM that depend on
the FID as the identifier in the HSM archive cannot currently be migrated.
Having a new inode number may also cause backup tools to consider the
migrated file(s) to be a new, and cause them to be backed up again.
-.P
.SH EXAMPLES
-.TP
-.B $ lfs migrate -c 2 /mnt/lustre/file1
This migrates the data in
.B file1
-into a new layout with 2 stripes.
-.TP
-.B $ lfs migrate -E 256M -c 1 -E 16G -c 4 -E eof -c 40 /mnt/lustre/file2
-.br
+into a new layout with 2 stripes:
+.RS
+.EX
+.B # lfs migrate -c 2 /mnt/lustre/file1
+.EE
+.RE
+.PP
This migrates the data in
.B file2
into a three component composite layout (number of stripes depends on
-file size).
-.TP
-.B # lfs migrate -m 0,2 testremote
-.br
+file size):
+.RS
+.EX
+.B # lfs migrate -E 256M -c 1 -E 16G -c 4 -E eof -c 40 /mnt/lustre/file2
+.EE
+.RE
+.PP
Recursively move the subdirectories and inodes contained in directory
.B remotedir
-from its current MDT to MDT0000 and MDT0002. The
+from its current MDT to MDT0000 and MDT0002. The
.B testremote
-directory and all of its subdirectories will be striped across both MDTs.
-.TP
-.B $ lfs migrate -m 0,2 -d ./testremote
+directory and all of its subdirectories will be striped across both MDTs:
+.RS
+.EX
+.B # lfs migrate -m 0,2 testremote
+.EE
+.RE
+.PP
Move ./testremote and the first level of sub files from their current MDT
to the MDT with index 0 and 2. Different from above case, the layout of
-subdirectories under ./testremote won't be changed.
-.TP
-.B # lfs setstripe -E 256M -c 1 -E 16G -c 4 -E eof -c 40 topdir
+subdirectories under ./testremote won't be changed:
+.RS
+.EX
+.B # lfs migrate -m 0,2 -d ./testremote
+.EE
+.RE
+.PP
Set a default PFL layout (without any DoM component) on the directory
-.BR topdir ,
-.TP
-.B # lfs find dir -type f -L mdt -0 | xargs -0 lfs migrate --copy topdir
+.BR topdir :
+.RS
+.EX
+.B # lfs setstripe -E 256M -c 1 -E 16G -c 4 -E eof -c 40 topdir
+.EE
+.RE
then find and migrate all regular files that have an
.B mdt
component to copy the default layout from the specified
-.BR topdir ,
-.TP
-.B # lfs migrate -m 2 topdir
-.br
+.BR topdir :
+.RS
+.EX
+.B # lfs find dir -type f -L mdt -0 | xargs -0 lfs migrate --copy topdir
+.EE
+.RE
and finally migrate the directory
.B topdir
-and all files and subdirectories in that tree to MDT0002. This allows
-migrating files with DoM components off an MDT.
-.SH AUTHOR
-The lfs command is part of the Lustre filesystem.
+and all files and subdirectories in that tree to MDT0002. This allows
+migrating files with DoM components off an MDT:
+.RS
+.EX
+.B # lfs migrate -m 2 topdir
+.EE
+.RE
+.SH AVAILABILITY
+The
+.B lfs migrate
+command is part of the
+.BR lustre (7)
+filesystem package since release 2.4.0
+.\" lfs_setstripe_migrate added in commit v2_3_63_0-6-gead6f5b2b5)
.SH SEE ALSO
.BR lfs (1),
-.BR lfs-setstripe (1),
-.BR lfs-setdirstripe (1),
.BR lfs-getdirstripe (1),
-.BR lfs-mkdir (1),
.BR lfs_migrate (1),
-.BR lctl (8),
+.BR lfs-mkdir (1),
+.BR lfs-setdirstripe (1),
+.BR lfs-setstripe (1),
+.BR lctl (8)
-.TH LFS-MIRROR-COPY 1 2018-09-23 "Lustre" "Lustre Utilities"
+.TH LFS-MIRROR-COPY 1 2024-08-19 Lustre "Lustre User Utilities"
.SH NAME
lfs-mirror-copy \- copy a mirror's content to other mirror(s) of a mirrored file
.SH SYNOPSIS
-.B lfs mirror copy
-{\fB\-\-read-mirror|\-i\fR <\fIid0\fR>}
-{\fB\-\-write-mirror|\-o\fR <\fIid1>[,<id2>,...]\fR}
-<\fImirrored_file\fR>
+.SY "lfs mirror copy"
+.BR --read-mirror | -i
+.I SRC_ID0
+.BR --write-mirror | -o
+.IR TGT_ID1 [, TGT_ID2 ,...]
+.I MIRRORED_FILE
+.YS
.SH DESCRIPTION
This command copies a mirror's content to other mirror(s) of a mirrored file,
-the file is specified by the path name \fImirrored_file\fR, the mirrors are
-specified by their mirror ID.
-.SH NOTE
-Beware that the written mirror(s) will be marked as non-stale mirror(s),
-be careful that after using this command, you could get a file with non-stale
-mirrors while containing different contents.
-.br
+the file is specified by the path name
+.IR MIRRORED_FILE ,
+the mirrors are specified by their mirror ID.
.SH OPTIONS
.TP
-.BR \-\-read-mirror|\-i\fR\ <\fIid0\fR>
-This option indicates the content of which mirror specified by \fIid0\fR
-needs to be read. The \fIid0\fR is the numerical unique identifier for
-a mirror.
+.BR -i ", " --read-mirror \fISRC_ID0
+This option indicates the content of which mirror specified by
+.I SRC_ID0
+needs to be read. The
+.I SRC_ID0
+is the numerical unique identifier for a mirror.
.TP
-.BR \-\-write-mirror|\-o\fR\ <\fIid1\fR>[,<\fIid2\fR>,...]
+.BR -o ", " --write-mirror \fITGT_ID1\fR[,\fITGT_ID2\fR,...]
This option indicates the content of which mirror(s) specified by mirror IDs
needs to be written. The mirror IDs are separated with comma.
-If the mirror id \fB-1\fR is used here, it means that all mirrors other than
+If the mirror id
+.B -1
+is used here, it means that all mirrors other than
the read mirror are to be written.
+.SH NOTES
+Be ware that the written mirror(s) will be marked as non-stale mirror(s),
+be careful that after using this command, you could get a file with non-stale
+mirrors while containing different contents.
.SH EXAMPLES
-.TP
-.B lfs mirror copy -i1 -o2,3 /mnt/lustre/file1
Copy the content of mirror with mirror ID 1 to the mirrors with mirror ID 2 and
-mirror ID 3 in /mnt/lustre/file1.
-.TP
-.B lfs mirror copy -i1 -o-1 /mnt/lustre/file1
-Copy the content of mirror with mirror ID 1 to all other mirrors in /mnt/lustre/file1.
-.TP
-.SH AUTHOR
-The \fBlfs mirror copy\fR command is part of the Lustre filesystem.
+mirror ID 3 in /mnt/lustre/file1:
+.RS
+.EX
+.B # lfs mirror copy -i1 -o2,3 /mnt/lustre/file1
+.EE
+.RE
+.PP
+Copy the content of mirror with mirror ID 1 to all other mirrors in \
+/mnt/lustre/file1:
+.RS
+.EX
+.B # lfs mirror copy -i1 -o-1 /mnt/lustre/file1
+.EE
+.RE
+.SH AVAILABILITY
+The
+.B lfs mirror copy
+command is part of the
+.BR lustre (7)
+filesystem package since release 2.13.0
+.\" Added in commit v2_12_52-20-gc6e7c0788d
.SH SEE ALSO
.BR lfs (1),
-.BR lfs-setstripe (1),
.BR lfs-getstripe (1),
.BR lfs-mirror-create (1),
.BR lfs-mirror-extend (1),
+.BR lfs-mirror-read (1),
.BR lfs-mirror-split (1),
.BR lfs-mirror-verify (1),
-.BR lfs-mirror-read (1)
-.BR lfs-mirror-write (1)
+.BR lfs-mirror-write (1),
+.BR lfs-setstripe (1)
-.TH LFS-MIRROR-CREATE 1 2017-07-25 "Lustre" "Lustre Utilities"
+.TH LFS-MIRROR-CREATE 1 2024-08-20 Lustre "Lustre User Utilities"
.SH NAME
lfs-mirror-create \- create a mirrored file or directory
.SH SYNOPSIS
-.B lfs mirror create
-<\fB\-\-mirror\-count\fR|\fB\-N\fR[\fImirror_count\fR]>
-[\fIsetstripe_options\fR|[\fB--flags\fR<=\fIflags\fR>]] ...
-.RI < filename | directory >
+.SY "lfs mirror create"
+.BR --mirror-count | -N\c
+.RI [ MIRROR_COUNT ]
+.RI [ SETSTRIPE_OPTIONS |\c
+.RB [ --flags\c
+.RI = FLAGS "]] ..."
+.IR FILENAME | DIRECTORY
+.YS
.SH DESCRIPTION
This command creates a mirrored file or directory specified by the path name
-\fIfilename\fR or \fIdirectory\fR.
-.br
-The \fB\-\-mirror\-count\fR|\fB\-N\fR option is required and indicates how many
+.I FILENAME
+or
+.IR DIRECTORY .
+.P
+The
+.BR --mirror-count | -N
+parameter is required and indicates how many
mirrors that have the same layout will be created. It can be repeated multiple
-times to separate mirrors that have different layouts. The \fImirror_count\fR
+times to separate mirrors that have different layouts. The
+.I MIRROR_COUNT
argument is optional and defaults to 1 if it's not specified; if specified, it
must follow the option without a space.
-.br
-The \fIsetstripe_options\fR specify the specific layout for the mirror. It can
-be a plain layout with specific striping pattern or a composite layout like
-Progressive File Layout (PFL) (see \fBlfs-setstripe\fR(1)).
-If \fIsetstripe_options\fR are not specified,
+.P
+The
+.I SETSTRIPE_OPTIONS
+specify the specific layout for the mirror.
+It can be a plain layout with specific striping pattern or a composite layout
+like Progressive File Layout (PFL) (see
+.BR lfs-setstripe (1)).
+If
+.I SETSTRIPE_OPTIONS
+are not specified,
then the stripe options inherited from the previous component will be used. If
-there is no previous component, then the \fIstripe_count\fR and
-\fIstripe_size\fR options inherited from filesystem-wide default values will be
-used, and OST \fIpool_name\fR inherited from parent directory will be used.
-.br
+there is no previous component, then the
+.I STRIPE_COUNT
+and
+.I STRIPE_SIZE
+options inherited from filesystem-wide default values will be used, and OST
+.I POOL_NAME
+inherited from parent directory will be used.
+.P
If no option is specified, then the command will return an error.
.SH OPTIONS
.TP
-.BR \-\-mirror\-count\fR|\fB\-N\fR[\fImirror_count\fR]
+.BR -N ", " --mirror-count [\fIMIRROR_COUNT ]
The number of mirrors that have the same layout to be created. The option can be
repeated multiple times to separate mirrors that have different layouts. The
-\fImirror_count\fR argument is optional and defaults to 1 if it's not specified;
+.I MIRROR_COUNT
+argument is optional and defaults to 1 if it's not specified;
if specified, it must follow the option without a space.
.TP
-.I setstripe_options
+.I SETSTRIPE_OPTIONS
The layout of one mirror. The options are the same as those for
-\fBlfs-setstripe\fR(1) command.
-If \fIsetstripe_options\fR are not specified, then
-the stripe options inherited from the previous component will be used.
+.BR lfs-setstripe (1)
+command.
+If
+.I SETSTRIPE_OPTIONS
+are not specified,
+then the stripe options inherited from the previous component will be used.
.TP
-.B --flags<=\fIflags\fR>
-Where available \fIflags\fR are as follows:
+.BR --flags =\fIFLAGS
+Where available
+.I FLAGS
+are as follows:
.RS
.TP
-.BI prefer
+.B prefer
is supported in mirror creation. This flag will be set to all components that
-belong to the corresponding mirror. The \fBprefer\fR flag gives hint to Lustre
-for which mirrors should be used to serve I/O. When a mirrored file is being
-read, the component(s) with \fBprefer\fR are likely to be picked to serve the
-read; and when a mirrored file is prepared to be written, the MDT will
-tend to choose the component with \fBprefer\fR flag set and stale the other
-components with overlapping extents. This flag just provides a hint to Lustre,
+belong to ths corresponding mirror. The
+.B prefer
+flag gives hint to Lustre for which mirrors should be used to serve I/O.
+When a mirrored file is being read, the component(s) with
+.B prefer
+are likely to be picked to serve the read;
+and when a mirrored file is prepared to be written,
+the MDT will tend to choose the component with
+.B prefer
+flag set and stale the other components with overlapping extents.
+This flag just provides a hint to Lustre,
which means Lustre may still choose mirrors without this flag set, for instance,
-if all preferred mirrors are unavailable when the I/O occurs. This flag could be
-set on multiple components.
+if all preferred mirrors are unavailable when the I/O occurs.
+This flag could be set on multiple components.
.LP
Please note that this flag will be set to all components that belong to the
-corresponding mirror. There also exists option \fB--comp-flags\fR that can be
-set to individual components at mirror creation time.
+corresponding mirror. There also exists option
+.B --comp-flags
+that can be set to individual components at mirror creation time.
.RE
.SH EXAMPLES
-.TP
-.B lfs mirror create -N2 /mnt/lustre/file1
Create a mirrored file with 2 mirrors. Each mirror has the same default striping
-pattern with \fIstripe_count\fR and \fIstripe_size\fR inherited from
-filesystem-wide default values, and OST \fIpool_name\fR inherited from
-parent directory.
-.TP
-.B lfs mirror create -N2 -E 1M -E eof -c -1 /mnt/lustre/dir1
-Create a mirrored directory with 2 PFL mirrors. Each mirror has the same
-specified PFL layout.
-.LP
-.B lfs mirror create -N3 -E 1M -c 1 -E 32M -c 4 -S 16M -E eof -c -1
-.B /mnt/lustre/file1
-.in
-Create a mirrored file with 3 PFL mirrors. Each mirror has the same specified
-PFL layout.
-.LP
-.B lfs mirror create -N -c 1 -S 4M -N -c 2 -o 2,3 -p flash
-.B -N -p none /mnt/lustre/file1
-.in
+pattern with
+.I STRIPE_COUNT
+and
+.I STRIPE_SIZE
+inherited from filesystem-wide default values, and OST
+.I POOL_NAME
+inherited from parent directory:
+.RS
+.EX
+.B # lfs mirror create -N2 /mnt/lustre/file1
+.EE
+.RE
+.PP
+Create a mirrored directory with 2 PFL mirrors.
+Each mirror has the same specified PFL layout:
+.RS
+.EX
+.B # lfs mirror create -N2 -E 1M -E eof -c -1 /mnt/lustre/dir1
+.EE
+.RE
+.PP
+Create a mirrored file with 3 PFL mirrors.
+Each mirror has the same specified PFL layout:
+.RS
+.EX
+.B # lfs mirror create -N3 -E 1M -c 1 -E 32M -c 4 -S 16M -E eof -c -1 \
+/mnt/lustre/file1
+.EE
+.RE
+.PP
Create a mirrored file with 3 plain layout mirrors. The first mirror has a
single stripe and 4MB stripe size. The second mirror has two stripes and locates
-on OSTs with indices 2 and 3 allocated from the \fBflash\fR OST pool.
-It also has 4MB stripe size inherited from the first mirror.
+on OSTs with indices 2 and 3 allocated from the
+.B flash
+OST pool. It also has 4MB stripe size inherited from the first mirror.
The third mirror has two stripes and 4MB stripe size inherited from the previous
-mirror, and also has inherited OST \fIpool_name\fR from parent directory.
-.LP
-.B lfs mirror create -N2 -E 4M -c 2 --pool flash --flags prefer -E eof -c 4
-.B -N3 -E 16M -c 4 -S 16M --pool archive --comp-flags=prefer -E eof -c -1
-.B /mnt/lustre/file1
-.in
+mirror, and also has inherited OST
+.I POOL_NAME
+from parent directory:
+.RS
+.EX
+.B # lfs mirror create -N -c 1 -S 4M -N -c 2 -o 2,3 -p flash \
+-N -p none /mnt/lustre/file1
+.EE
+.RE
+.PP
Create a mirrored file with 5 PFL mirrors. The first and second mirrors have the
-same PFL layout, and both of the components are allocated from the \fBflash\fR
-OST pool. Also, flag \fBprefer\fR is applied to all the components of the first
+same PFL layout, and both of the components are allocated from the
+.B flash
+OST pool. Also, flag
+.B prefer
+is applied to all the components of the first
two mirrors, which tells the client to read data from those components whenever
they are available.
-.br
+.P
The last three mirrors have the same PFL layout, and each of these
-components have a stripe size of 16MB and use OSTs in the \fBarchive\fR pool.
-However, the flag \fBprefer\fR is only applied to the first component of each
-mirror.
-.SH AUTHOR
-The \fBlfs mirror create\fR command is part of the Lustre filesystem.
+components have a stripe size of 16MB and use OSTs in the
+.B archive
+pool. However, the flag
+.B prefer
+is only applied to the first component of each mirror:
+.RS
+.EX
+.B # lfs mirror create -N2 -E 4M -c 2 --pool flash --flags prefer -E eof -c 4 \
+-N3 -E 16M -c 4 -S 16M --pool archive --comp-flags=prefer -E eof -c -1 \
+/mnt/lustre/file1
+.EE
+.RE
+.SH AVAILABILITY
+The
+.B lfs mirror create
+command is part of the
+.BR lustre (7)
+filesystem package since release 2.11.0
+.\" Added in commit v2_10_55_0-55-g125f98fb5c
.SH SEE ALSO
.BR lfs (1),
-.BR lfs-setstripe (1),
.BR lfs-mirror-delete (1),
.BR lfs-mirror-extend (1),
-.BR lfs-mirror-split (1),
.BR lfs-mirror-resync (1),
-.BR lfs-mirror-verify (1)
+.BR lfs-mirror-split (1),
+.BR lfs-mirror-verify (1),
+.BR lfs-setstripe (1)
-.TH LFS-MIRROR-DELETE 1 2019-09-15 "Lustre" "Lustre Utilities"
+.TH LFS-MIRROR-DELETE 1 2024-08-20 Lustre "Lustre User Utilities"
.SH NAME
lfs-mirror-delete \- delete a specified mirror from an existing mirrored file
.SH SYNOPSIS
-.B lfs mirror delete
-{\fB\-\-mirror\-id\fR <\fImirror_id\fR> | \fB\-\-component\-id\fR|\
-\fB\-\-comp\-id\fR|\fB\-I\fR <\fIcomp_id\fR> |
-\fB\-\-pool\fR <\fIpool\fR>} <\fImirrored_file\fR>
+.SY "lfs mirror delete"
+.RB { --mirror-id
+.I MIRROR_ID
+|
+.BR --component-id | --comp-id | -I
+.I COMP_ID
+|
+.B --pool
+.IR POOL }
+.I MIRRORED_FILE
+.YS
.SH DESCRIPTION
-This command deletes a mirror with mirror ID <\fImirror_id\fR> or containing
-a component with <\fIcomp_id\fR> or containing a component on <\fIpool\fR>
-out of a mirrored file specified by the path name \fImirrored_file\fR.
-.br
-If \fImirrored_file\fR has only one mirror existing after split, it will be
-converted to a regular non-mirrored file.
-.br
-If the original \fImirrored_file\fR is not a mirrored file, then the command
-will return an error.
+This command deletes a mirror with mirror ID
+.I MIRROR_ID
+or containing a component with
+.I COMP_ID
+or containing a component on
+.I POOL
+out of a mirrored file specified by the path name
+.IR MIRRORED_FILE .
+.P
+If
+.I MIRRORED_FILE
+has only one mirror existing after split,
+it will be converted to a regular non-mirrored file.
+.P
+If the original
+.I MIRRORED_FILE
+is not a mirrored file, then the command will return an error.
.SH OPTIONS
.TP
-.BR \-\-mirror\-id\fR\ <\fImirror_id\fR>
+.BI --mirror-id " MIRROR_ID"
The numerical unique identifier for a mirror. The mirror ID is unique within a
mirrored file and is automatically assigned at file creation or extension time.
-It can be fetched by \fBlfs getstripe\fR command (see \fBlfs(1)\fR).
+It can be fetched by
+.B lfs getstripe
+command (see
+.BR lfs (1)).
.TP
-.BR \-\-comp\-id\fR\ <\fIcomp_id\fR>
+.BR -I ", " --comp-id " \fICOMP_ID"
The numerical unique identifier for a component contained within a mirror.
.TP
-.BR \-\-pool\fR\ <\fIpool\fR>
+.BI --pool " POOL"
The pool storing a component contained within a mirror.
.SH EXAMPLES
-.TP
-.B lfs mirror delete --mirror-id 2 /mnt/lustre/file1
-Delete the mirror with ID 2 of /mnt/lustre/file1.
-.TP
-.B lfs mirror delete --comp-id 65537 /mnt/lustre/file1
-Delete the mirror containing the component with ID 65537 of /mnt/lustre/file1.
-.TP
-.B lfs mirror delete --pool ssd /mnt/lustre/file1
-Split a mirror on pool ssd out of /mnt/lustre/file1 and destroy it.
-.SH AUTHOR
-The \fBlfs mirror split\fR command is part of the Lustre filesystem.
+Delete the mirror with ID 2 of /mnt/lustre/file1:
+.RS
+.EX
+.B # lfs mirror delete --mirror-id 2 /mnt/lustre/file1
+.EE
+.RE
+.PP
+Delete the mirror containing the component with ID 65537 of /mnt/lustre/file1:
+.RS
+.EX
+.B # lfs mirror delete --comp-id 65537 /mnt/lustre/file1
+.EE
+.RE
+.PP
+Split a mirror on pool ssd out of /mnt/lustre/file1 and destroy it:
+.RS
+.EX
+.B # lfs mirror delete --pool ssd /mnt/lustre/file1
+.EE
+.RE
+.SH AVAILABILITY
+The
+.B lfs mirror delete
+command is part of the
+.BR lustre (7)
+filesystem package since release 2.13.0
+.\" Added in commit v2_12_58-138-g6d0e247cfc
.SH SEE ALSO
.BR lfs (1),
-.BR lfs-setstripe (1),
.BR lfs-mirror-create (1),
.BR lfs-mirror-extend (1),
.BR lfs-mirror-resync (1),
.BR lfs-mirror-split (1),
-.BR lfs-mirror-verify (1)
+.BR lfs-mirror-verify (1),
+.BR lfs-setstripe (1)
-.TH LFS-MIRROR-EXTEND 1 2017-07-25 "Lustre" "Lustre Utilities"
+.TH LFS-MIRROR-EXTEND 1 2024-08-20 Lustre "Lustre User Utilities"
.SH NAME
lfs-mirror-extend \- add mirror(s) to an existing file
.SH SYNOPSIS
-.nh
-.ad l
-.B lfs mirror extend
-[\fB\-\-no\-verify\fR]
-[\fB\-\-mirror\-count\fR|\fB\-N\fR[\fIMIRROR_COUNT\fR]]
-[\fB\-\-bandwidth\-limit\fR|\fB\-W\fR \fIBANDWIDTH\fR]
-[\fB\-\-stats\fR|\fB\-\-stats\-interval\fR=\fISTATS_INTERVAL\fR]
-[\fISETSTRIPE_OPTIONS\fR|\fB\-f\fR \fIVICTIM_FILE\fR]
-\fIFILENAME\fR ...
+.SY "lfs mirror extend"
+.RB [ --no-verify ]
+.RB [ --mirror-count | -N\c
+.RI [ MIRROR_COUNT ]]
+.RB [ --bandwidth-limit | -W
+.IR BANDWIDTH ]
+.RB [ --stats | --stats-interval\c
+.RI = STATS_INTERVAL ]
+.RI [ SETSTRIPE_OPTIONS |\c
+.B -f
+.IR VICTIM_FILE ]
+.IR FILENAME " ..."
+.YS
.SH DESCRIPTION
This command adds mirror(s) to an existing file specified by the path name
-\fIFILENAME\fR.
-.br
-The file \fIFILENAME\fR can already be a mirrored file, or just a regular
-non-mirrored file. If it's a non-mirrored file, then the command will convert it
-to a mirrored file.
-.br
+.IR FILENAME .
+.P
+The file
+.I FILENAME
+can already be a mirrored file, or just a regular non-mirrored file.
+If it's a non-mirrored file,
+then the command will convert it to a mirrored file.
+.P
The
.BR --mirror-count | -N
option is optional and indicates how many
mirrors that have the same layout will be added. It can be repeated multiple
-times to separate mirrors that have different layouts. The \fIMIRROR_COUNT\fR
+times to separate mirrors that have different layouts. The
+.I MIRROR_COUNT
can be specified with a preceding '=' to indicate the number of total mirrors
desired for the layout, such as
-\fB\-\-mirror\-count\fR==\fITOTAL_MIRROR_COUNT\fR or
-\fB\-N\fR=\fITOTAL_MIRROR_COUNT\fR. This will create mirrors until the total
-number of mirrors in the layout match \fITOTAL_MIRROR_COUNT\fR, this also means
-that if there are already at least \fITOTAL_MIRROR_COUNT\fR mirrors in the
-layout then no new mirrors will be created. The \fIMIRROR_COUNT\fR argument is
-optional and defaults to 1 if it's not specified; if specified, it must follow
-the option without a space. If \fB\-\-mirror\-count\fR|\fB\-N\fR is not
-specified, the default value of 1 will be used.
-.br
-The \fISETSTRIPE_OPTIONS\fR specify the specific layout for the mirror. It can
+.BI --mirror-count== TOTAL_MIRROR_COUNT
+or
+.B -N=\c
+.IR TOTAL_MIRROR_COUNT .
+This will create mirrors until the total
+number of mirrors in the layout match
+.IR TOTAL_MIRROR_COUNT ,
+this also means that if there are already at least
+.I TOTAL_MIRROR_COUNT
+mirrors in the layout then no new mirrors will be created. The
+.I MIRROR_COUNT
+argument is optional and defaults to 1 if it's not specified;
+if specified, it must follow the option without a space. If
+.BR --mirror-count | -N
+is not specified, the default value of 1 will be used.
+.P
+The
+.I SETSTRIPE_OPTIONS
+specify the specific layout for the mirror. It can
be a plain layout with specific striping pattern or a composite layout like
-Progressive File Layout (PFL) (see \fBlfs-setstripe\fR(1)).
-If \fISETSTRIPE_OPTIONS\fR are not specified,
+Progressive File Layout (PFL) (see
+.BR lfs-setstripe (1)).
+If
+.I SETSTRIPE_OPTIONS
+are not specified,
then the stripe options inherited from the previous component will be used.
-If \fIVICTIM_FILE\fR exists, then the
+If
+.I VICTIM_FILE
+exists, then the
command will merge the layout from that file as a mirror added to the
mirrored file. After the command is finished, the victim file will be
-removed. The \fISETSTRIPE_OPTIONS\fR cannot be specified with
-\fB\-f\fR \fIVICTIM_FILE\fR option in one command line.
-.br
-If \fIVICTIM_FILE\fR is specified, the utility will verify that the file contents
-from \fIVICTIM_FILE\fR are the same as \fIFILENAME\fR. Otherwise the command
-will return failure. However, option \fB\-\-no\-verify\fR can be used to
-override this verification. The option can save significant time on file
-comparison if the file size is large, but use it only when the file contents
-are known to be the same.
-.br
+removed. The
+.I SETSTRIPE_OPTIONS
+cannot be specified with
+.B -f
+.I VICTIM_FILE
+option in one command line.
+.P
+If
+.I VICTIM_FILE
+is specified, the utility will verify that the file contents
+from
+.I VICTIM_FILE
+are the same as
+.IR FILENAME .
+Otherwise the command will return failure. However, option
+.B --no-verify
+can be used to override this verification.
+The option can save siginificant time on file
+comparison if the file size is large,
+but use it only when the file contents are known to be the same.
+.P
If no option is specified, then the command will return an error.
.SH OPTIONS
.TP
-.BR \-\-mirror\-count\fR|\fB\-N\fR[\fIMIRROR_COUNT\fR]
+.BR -N ", " --mirror-count [\fIMIRROR_COUNT ]
The number of mirrors that have the same layout to be added. The option can be
repeated multiple times to separate mirrors that have different layouts. The
-\fIMIRROR_COUNT\fR argument is optional and defaults to 1 if it's not specified;
+.I MIRROR_COUNT
+argument is optional and defaults to 1 if it's not specified;
if specified, it must follow the option without a space.
.TP
.I SETSTRIPE_OPTIONS
The layout of one mirror. The options are the same as those for
-\fBlfs-setstripe\fR(1) command.
-If \fISETSTRIPE_OPTIONS\fR are not specified, then the stripe options inherited
+.BR lfs-setstripe (1)
+command.
+If
+.I SETSTRIPE_OPTIONS
+are not specified, then the stripe options inherited
from the previous component will be used. This option cannot be specified with
-\fB\-f\fR \fIVICTIM_FILE\fR option.
+.B -f
+.I VICTIM_FILE
+option.
.TP
-.BR \-f\fR\ \fIVICTIM_FILE\fR
-The layout of \fIVICTIM_FILE\fR will be merged as a mirror added to the
-mirrored file. This option cannot be specified with \fISETSTRIPE_OPTIONS\fR
+.BI -f " VICTIM_FILE"
+The layout of
+.I VICTIM_FILE
+will be merged as a mirror added to the mirrored file.
+This option cannot be specified with
+.I SETSTRIPE_OPTIONS
option.
.TP
-.BR \-\-no\-verify
+.BR --no-verify
This option indicates not to verify the mirror(s) from victim file(s) in case
the victim file(s) contains the same data as the original mirrored file.
.TP
-.BR \-\-stats
+.BR --stats
This option enables progress updates every 5 seconds, in YAML format.
.TP
-.BR \-\-stats-interval=\fISTATS_INTERVAL
-This option enables progress updates every \fISTATS_INTERVAL\fR seconds, in YAML format.
+.BR --stats-interval =\fISTATS_INTERVAL
+This option enables progress updates every
+.I STATS_INTERVAL
+seconds, in YAML format.
.TP
-.BR \-\-bandwidth\-limit\fR|\fB\-W\fR\fIBANDWIDTH\fR
+.BR -W ", " --bandwidth-limit " \fIBANDWIDTH"
This option enables throttling so that mirror extending writes no more than
-\fIBANDWIDTH\fR bytes a second. An optional suffix can be used to
-specify the units in
+.I BANDWIDTH
+bytes a second. An optional suffix can be used to specify the units in
.BR K ilobytes,
.BR M egabytes
or
-.BR G igabytes.
+.BR G igabytes.
.SH EXAMPLES
-.TP
-.B lfs mirror extend -N2 /mnt/lustre/file1
Add 2 mirrors to /mnt/lustre/file1. If file1 is a non-mirrored file, then the
command will convert it to a mirrored file first and then add mirrors. Each
-mirror has the same default striping pattern with \fIstripe_count\fR and
-\fIstripe_size\fR inherited from filesystem-wide default values, and
-OST \fIpool_name\fR inherited from parent directory.
-.LP
-.B lfs mirror extend -N3 -E 1M -c 1 -E 32M -c 4 -S 16M -E eof -c -1
-.B /mnt/lustre/file1
-.in
+mirror has the same default striping pattern with
+.I STRIPE_COUNT
+and
+.I STRIPE_SIZE
+inherited from filesystem-wide default values, and OST
+.I POOL_NAME
+inherited from parent directory:
+.RS
+.EX
+.B # lfs mirror extend -N2 /mnt/lustre/file1
+.EE
+.RE
+.PP
Add 3 PFL mirrors to /mnt/lustre/file1. Each mirror has the same specified PFL
-layout.
-.LP
-.B lfs mirror extend -N -c 1 -S 4M -N -c 2 -o 2,3 -p flash
-.B -N -p none /mnt/lustre/file1
-.in
+layout:
+.RS
+.EX
+.B # lfs mirror extend -N3 -E 1M -c 1 -E 32M -c 4 -S 16M -E eof -c -1 \
+/mnt/lustre/file1
+.EE
+.RE
+.PP
Add 3 plain layout mirrors to /mnt/lustre/file1. The first mirror has a single
stripe and 4MB stripe size. The second mirror has two stripes and locates on
-OSTs with indices 2 and 3 allocated from the \fBflash\fR OST pool.
+OSTs with indices 2 and 3 allocated from the
+.B flash
+OST pool.
It also has 4MB stripe size inherited from the first mirror.
The third mirror has two stripes and 4MB stripe size inherited from the previous
-mirror, and also has inherited OST \fIpool_name\fR from parent directory.
-.LP
-.B lfs mirror extend -N2 -E 4M -c 2 --pool flash -E eof -c 4 -N3 -E 16M -c 4
-.B -S 16M --pool archive -E eof -c -1 /mnt/lustre/file1
-.in
+mirror, and also has inherited OST
+.I POOL_NAME
+from parent directory:
+.RS
+.EX
+.B # lfs mirror extend -N -c 1 -S 4M -N -c 2 -o 2,3 -p flash \
+-N -p none /mnt/lustre/file1
+.EE
+.RE
+.PP
Add 5 PFL mirrors to /mnt/lustre/file1. The first and second mirrors have the
same PFL layout. All of the components are allocated from the flash OST pool.
The last three mirrors have the same PFL layout. All of these components have a
-stripe size of 16MB and use OSTs in the archive pool.
-.LP
-.B lfs mirror extend --no-verify -N -f /mnt/lustre/file2 -N -f /mnt/lustre/file3
-.B /mnt/lustre/file1
-.in
+stripe size of 16MB and use OSTs in the archive pool:
+.RS
+.EX
+.B # lfs mirror extend -N2 -E 4M -c 2 --pool flash -E eof -c 4 -N3 -E 16M -c 4 \
+-S 16M --pool archive -E eof -c -1 /mnt/lustre/file1
+.EE
+.RE
+.PP
Merge the layouts from /mnt/lustre/file2 and /mnt/lustre/file3, which contain
the same data as /mnt/lustre/file1, use the layouts as mirrors and add them to
-/mnt/lustre/file1 without verification.
-.SH AUTHOR
-The \fBlfs mirror extend\fR command is part of the Lustre filesystem.
+/mnt/lustre/file1 without verification:
+.RS
+.EX
+.B # lfs mirror extend --no-verify -N -f /mnt/lustre/file2 -N -f \
+/mnt/lustre/file3 /mnt/lustre/file1
+.EE
+.RE
+.SH AVAILABILITY
+The
+.B lfs mirror extend
+command is part of the
+.BR lustre (7)
+filesystem package since release 2.11.0
+.\" Added in commit v2_10_55_0-55-g125f98fb5c
.SH SEE ALSO
.BR lfs (1),
-.BR lfs-setstripe (1),
.BR lfs-mirror-create (1),
.BR lfs-mirror-delete (1),
-.BR lfs-mirror-split (1),
.BR lfs-mirror-resync (1),
-.BR lfs-mirror-verify (1)
+.BR lfs-mirror-split (1),
+.BR lfs-mirror-verify (1),
+.BR lfs-setstripe (1)
-.TH LFS-MIRROR-READ 1 2018-08-16 "Lustre" "Lustre Utilities"
+.TH LFS-MIRROR-READ 1 2024-08-20 Lustre "Lustre User Utilities"
.SH NAME
lfs-mirror-read \- read a mirror's content of a mirrored file
.SH SYNOPSIS
-.B lfs mirror read
-{\fB\-\-mirror-id|\-N\fR <\fImirror_id\fR>}
-[\fB\-\-outfile|\-o\fR <\fIoutput_file\fR>]
-<\fImirrored_file\fR>
+.SY "lfs mirror read"
+.BR --mirror-id | -N
+.IR MIRROR_ID
+.RB [ --outfile | -o
+.IR OUTPUT_FILE ]
+.I MIRRORED_FILE
+.YS
.SH DESCRIPTION
This command reads the content of a file's mirror, the file is specified by the
-path name \fImirrored_file\fR, the mirror is specified by its mirror ID
-\fImirror_id\fR.
-.br
-If an \fIoutput_file\fR is specified, the content will be written to the file,
+path name
+.IR MIRRORED_FILE ,
+the mirror is specified by its mirror ID
+.IR MIRROR_ID .
+.P
+If an
+.I OUTPUT_FILE
+is specified, the content will be written to the file,
otherwise the standard output stream will be used.
.SH OPTIONS
.TP
-.BR \-\-mirror-id|\-N\fR\ <\fImirror_id\fR>
-This option indicates the content of which mirror specified by \fImirror_id\fR
-needs to be read. The \fImirror_id\fR is the numerical unique identifier for
-a mirror.
+.BR -N ", " --mirror-id " \fIMIRROR_ID"
+This option indicates the content of which mirror specified by
+.I MIRROR_ID
+needs to be read. The
+.I MIRROR_ID
+is the numerical unique identifier for a mirror.
.TP
-.BR \-\-outfile|\-o\fR\ <\fIoutput_file\fR>
+.BR -o ", " --outfile " \fIoutput_file"
The path name of the output file, if not specified, the standard output stream
will be used.
.SH EXAMPLES
-.TP
-.B lfs mirror read --mirror-id 3 /mnt/lustre/file1
-Dump the content of mirror with mirror ID 3 for /mnt/lustre/file1 to STDOUT.
-.TP
-.B lfs mirror read -N 2 -o /tmp/m2 /mnt/lustre/file1
+Dump the content of mirror with mirror ID 3 for /mnt/lustre/file1 to STDOUT:
+.RS
+.EX
+.B # lfs mirror read --mirror-id 3 /mnt/lustre/file1
+.EE
+.RE
+.PP
Dump the content of mirror with mirror ID 2 for /mnt/lustre/file1 to file
-/tmp/m2.
-.SH AUTHOR
-The \fBlfs mirror read\fR command is part of the Lustre filesystem.
+/tmp/m2:
+.RS
+.EX
+.B # lfs mirror read -N 2 -o /tmp/m2 /mnt/lustre/file1
+.EE
+.RE
+.SH AVAILABILITY
+The
+.B lfs mirror read
+command is part of the
+.BR lustre (7)
+filesystem package since release 2.12.0
+.\" Added in commit v2_11_56_0-70-g14171e787d
.SH SEE ALSO
.BR lfs (1),
-.BR lfs-setstripe (1),
.BR lfs-getstripe (1),
+.BR lfs-mirror-copy (1),
.BR lfs-mirror-create (1),
+.BR lfs-mirror-delete (1),
.BR lfs-mirror-extend (1),
+.BR lfs-mirror-resync (1),
.BR lfs-mirror-split (1),
-.BR lfs-mirror-verify (1)
-.BR lfs-mirror-write (1)
-.BR lfs-mirror-copy (1)
+.BR lfs-mirror-verify (1),
+.BR lfs-mirror-write (1),
+.BR lfs-setstripe (1)
-.TH LFS-MIRROR-RESYNC 1 2017-07-25 "Lustre" "Lustre Utilities"
+.TH LFS-MIRROR-RESYNC 1 2024-08-20 Lustre "Lustre User Utilities"
.SH NAME
lfs-mirror-resync \- resynchronize an out-of-sync mirrored file
.SH SYNOPSIS
-.B lfs mirror resync
-[\fB\-\-only\fR <\fImirror_id\fR[,...]>]
-<\fB\-\-bandwidth\-limit=\fR|\fB\-W\fR[\fIbandwidth_limit\fR]>
-[\fB\-\-stats\fR]
-<\fB\-\-stats\-interval\fR=\fIinterval_in_sec\fR>
-<\fImirrored_file\fR> [<\fImirrored_file2\fR>...]
+.SY "lfs mirror resync"
+.RB [ --only
+.IR MIRROR_ID [,...]]
+.RB [ --bandwidth-limit= | -W
+.IR BANDWIDTH_MB ]
+.RB [ --stats ]
+.RB [ --stats-interval=\c
+.IR INTERVAL_SECONDS ]
+.IR MIRRORED_FILE " [" MIRRORED_FILE2 " ...]"
+.YS
.SH DESCRIPTION
This command resynchronizes out-of-sync mirrored file(s) specified by the path
-name \fImirrored_file\fR.
-.br
-If there is no stale mirror for the \fImirrored_file(s)\fR, then the command does
-nothing. Otherwise, it will copy data from synced mirror to stale mirror(s), and
-mark all successfully copied mirror(s) as SYNC.
-.br
-If \fB\-\-only\fR option is not specified, the \fBnosync\fR mirror(s) (i.e.
+name
+.IR MIRRORED_FILE .
+.P
+If there is no stale mirror for the
+.IR MIRRORED_FILE (s),
+then the command does nothing.
+Otherwise, it will copy data from synced mirror to stale mirror(s),
+and mark all successfully copied mirror(s) as SYNC.
+.P
+If
+.B --only
+option is not specified, the
+.B nosync
+mirror(s) (i.e.
components that have this flag set) will not be synced.
-.br
-If \fB\-\-only\fR <\fImirror_id\fR[,...]> option is specified, then the
-command will resynchronize the mirror(s) specified by the \fImirror_id\fR(s),
+.P
+If
+.B --only
+.IR MIRROR_ID [,...]
+option is specified,
+then the command will resynchronize the mirror(s) specified by the
+IR MIRROR_ID (s),
even nosync mirror(s) will be resynchronized as well.
This option cannot be used when multiple mirrored files are specified.
.SH OPTIONS
.TP
-.BR \-\-only\fR\ <\fImirror_id\fR[,...]>
-This option indicates which mirror(s) specified by \fImirror_id\fR(s) needs to
-be resynchronized. The \fImirror_id\fR is the numerical unique identifier for
-a mirror. Multiple \fImirror_id\fRs are separated by comma. This option cannot
+.BR "--only \fIMIRROR_ID" [ , ...]
+This option indicates which mirror(s) specified by
+.IR MIRROR_ID (s)
+needs to be resynchronized. The
+.I MIRROR_ID
+is the numerical unique identifier for a mirror. Multiple
+.IR MIRROR_ID s
+are separated by comma. This option cannot
be used when multiple mirrored files are specified.
.TP
-.BR \-\-stats
+.BR --stats
This option enables progress updates every 5 seconds, in YAML format.
.TP
-.BR \-\-stats-interval=\fIstats_interval
-This option enables progress updates every \fIstats_interval\fR seconds, in YAML format.
+.BI --stats-interval= STATS_INTERVAL
+This option enables progress updates every
+.I STATS_INTERVAL
+seconds, in YAML format.
.TP
-.BR \-\-bandwidth\-limit\fR|\fB\-W\fR\fIbandwidth_limit\fR
+.BR -W ", " --bandwidth-limit " \fIBANDWIDTH_MB"
This option enables throttling so that mirror extending writes no more than
-\fIbandwidth_limit\fR bytes a second. An optional suffix can be used to
-specify the units in
+.I BANDWIDTH_MB
+(default unit megabyte) a second. An optional suffix can be used to specify the
+units in
.BR K ilobytes,
.BR M egabytes
or
-.BR G igabytes.
+.BR G igabytes.
.SH EXAMPLES
-.TP
-.B lfs mirror resync /mnt/lustre/file1 /mnt/lustre/file2
-Resynchronize all of the stale and sync-able mirror(s) for /mnt/lustre/file1 and /mnt/lustre/file2.
-.TP
-.B lfs mirror resync --only 4,5 /mnt/lustre/file1
+Resynchronize all of the stale and sync-able mirror(s) for /mnt/lustre/file1
+and /mnt/lustre/file2:
+.RS
+.EX
+.B # lfs mirror resync /mnt/lustre/file1 /mnt/lustre/file2
+.EE
+.RE
+.PP
Resynchronize mirrors with mirror ID 4 and 5 for /mnt/lustre/file1 even if they
-are not marked as STALE.
-.SH AUTHOR
-The \fBlfs mirror resync\fR command is part of the Lustre filesystem.
+are not marked as STALE:
+.RS
+.EX
+.B # lfs mirror resync --only 4,5 /mnt/lustre/file1
+.EE
+.RE
+.SH AVAILABILITY
+The
+.B lfs mirror resync
+command is part of the
+.BR lustre (7)
+filesystem package since release 2.11.0
+.\" Added in commit v2_10_55_0-57-g79da3738df
.SH SEE ALSO
.BR lfs (1),
-.BR lfs-setstripe (1),
.BR lfs-mirror-create (1),
.BR lfs-mirror-extend (1),
.BR lfs-mirror-split (1),
-.BR lfs-mirror-verify (1)
+.BR lfs-mirror-verify (1),
+.BR lfs-setstripe (1)
-.TH LFS-MIRROR-SPLIT 1 2017-07-25 "Lustre" "Lustre Utilities"
+.TH LFS-MIRROR-SPLIT 1 2024-08-20 Lustre "Lustre User Utilities"
.SH NAME
lfs-mirror-split \- split a specified mirror from an existing mirrored file
.SH SYNOPSIS
-.B lfs mirror split
-{\fB\-\-mirror\-id\fR <\fImirror_id\fR> | \fB\-\-component\-id\fR|\
-\fB\-\-comp\-id\fR|\fB\-I\fR
-<\fIcomp_id\fR> | \fB\-\-pool\fR <\fIpool\fR>}
-[\fB\-\-destroy\fR|\fB\-d\fR]
-[\fB\-f\fR <\fInew_file\fR>]
-<\fImirrored_file\fR>
+.SY "lfs mirror split"
+.RB { --mirror-id
+.I MIRROR_ID
+|
+.BR --component-id | --comp-id | -I
+.I COMP_ID
+|
+.B --pool
+.IR POOL }
+.RB [ --destroy | -d ]
+.RB [ -f
+.IR NEW_FILE ]
+.I MIRRORED_FILE
+.YS
.SH DESCRIPTION
-This command splits a mirror with mirror ID <\fImirror_id\fR> or containing
-a component with <\fIcomp_id\fR> or containing a component on <\fIpool\fR>
-out of a mirrored file specified by the path name \fImirrored_file\fR.
+This command splits a mirror with mirror ID
+.I MIRROR_ID
+or containing a component with
+.I COMP_ID
+or containing a component on
+.I POOL
+out of a mirrored file specified by the path name
+.IR MIRRORED_FILE .
By default, the layout of the split mirror will be stored into a new file named
-<\fImirrored_file\fR>.mirror~<\fImirror_id\fR>.
-If \fB\-f\fR <\fInew_file\fR> option is specified, then the layout of the split
-mirror will be stored into the named file.
-.br
-If \fImirrored_file\fR has only one mirror existing after split, it will be
-converted to a regular non-mirrored file.
-.br
-If the original \fImirrored_file\fR is not a mirrored file, then the command
-will return an error.
+.IR MIRRORED_FILE .mirror~ MIRROR_ID .
+If
+.B -f
+.I NEW_FILE
+option is specified,
+then the layout of the split mirror will be stored into the named file.
+.p
+If
+.I MIRRORED_FILE
+has only one mirror existing after split,
+it will be converted to a regular non-mirrored file.
+.P
+If the original
+.I MIRRORED_FILE
+is not a mirrored file, then the command will return an error.
.SH OPTIONS
.TP
-.BR \-\-mirror\-id\fR\ <\fImirror_id\fR>
+.BI --mirror-id " MIRROR_ID"
The numerical unique identifier for a mirror. The mirror ID is unique within a
mirrored file and is automatically assigned at file creation or extension time.
-It can be fetched by \fBlfs getstripe\fR command (see \fBlfs(1)\fR).
+It can be fetched by
+.B lfs getstripe
+command (see
+.BR lfs (1)).
.TP
-.BR \-\-comp\-id\fR\ <\fIcomp_id\fR>
+.BI --comp-id " COMP_ID"
The numerical unique identifier for a component contained within a mirror.
.TP
-.BR \-\-pool\fR\ <\fIpool\fR>
+.BI --pool " POOL"
The pool storing a component contained within a mirror.
.TP
-.BR \-\-destroy\fR|\fB\-d\fR
+.BR -d ", " --destroy
This option indicates the split mirror will be destroyed.
-.br
+.P
This option is mandatory on encrypted files when the encryption key is not
available. Otherwise operation results in
-.B
--ENOKEY.
+.BR -ENOKEY .
.TP
-.BR \-f\fR\ <\fInew_file\fR>
+.BI -f " NEW_FILE"
This option indicates the layout of the split mirror will be stored into
-<\fInew_file\fR>.
-.br
+.IR NEW_FILE .
+.P
This option cannot be used on encrypted files when the encryption key is not
available. It will result in
-.B
--ENOKEY.
+.BR -ENOKEY .
.SH EXAMPLES
-.TP
-.B lfs mirror split --mirror-id 1 /mnt/lustre/file1
Split a mirror with ID 1 out of /mnt/lustre/file1 and store it into
-/mnt/lustre/file1.mirror~1.
-.TP
-.B lfs mirror split --mirror-id 2 -d /mnt/lustre/file1
-Split a mirror with ID 2 out of /mnt/lustre/file1 and destroy it.
-.TP
-.B lfs mirror split --mirror-id 3 -f /mnt/lustre/file2 /mnt/lustre/file1
+/mnt/lustre/file1.mirror~1:
+.RS
+.EX
+.B # lfs mirror split --mirror-id 1 /mnt/lustre/file1
+.EE
+.RE
+.PP
+Split a mirror with ID 2 out of /mnt/lustre/file1 and destroy it:
+.RS
+.EX
+.B # lfs mirror split --mirror-id 2 -d /mnt/lustre/file1
+.EE
+.RE
+.PP
Split a mirror with ID 3 out of /mnt/lustre/file1 and store it into
-/mnt/lustre/file2.
-.TP
-.B lfs mirror split --comp-id 65537 -d /mnt/lustre/file1
+/mnt/lustre/file2:
+.RS
+.EX
+.B # lfs mirror split --mirror-id 3 -f /mnt/lustre/file2 /mnt/lustre/file1
+.EE
+.RE
+.PP
Split a mirror containing the component with ID 65537 out of /mnt/lustre/file1
-and destroy it.
-.TP
-.B lfs mirror split --pool lustre-nvme -d /mnt/lustre/file1
-Split a mirror on pool lustre-nvme out of /mnt/lustre/file1 and destroy it.
-.SH AUTHOR
-The \fBlfs mirror split\fR command is part of the Lustre filesystem.
+and destroy it:
+.RS
+.EX
+.B # lfs mirror split --comp-id 65537 -d /mnt/lustre/file1
+.EE
+.RE
+.PP
+Split a mirror on pool lustre-nvme out of /mnt/lustre/file1 and destroy it:
+.RS
+.EX
+.B # lfs mirror split --pool lustre-nvme -d /mnt/lustre/file1
+.EE
+.RE
+.SH AVAILABILITY
+The
+.B lfs mirror split
+command is part of the
+.BR lustre (7)
+filesystem package since release 2.11.0
+.\" Added in commit v2_10_58_0-2-g23b2d47818
.SH SEE ALSO
.BR lfs (1),
-.BR lfs-setstripe (1),
.BR lfs-mirror-create (1),
.BR lfs-mirror-delete (1),
.BR lfs-mirror-extend (1),
.BR lfs-mirror-resync (1),
-.BR lfs-mirror-verify (1)
+.BR lfs-mirror-verify (1),
+.BR lfs-setstripe (1)
-.TH LFS-MIRROR-VERIFY 1 2017-07-25 "Lustre" "Lustre Utilities"
+.TH LFS-MIRROR-VERIFY 1 2024-08-20 Lustre "Lustre User Utilities"
.SH NAME
lfs-mirror-verify \- verify mirrored file(s)
.SH SYNOPSIS
-.B lfs mirror verify
-[\fB\-\-only\fR <\fImirror_id\fR,\fImirror_id2\fR[,...]>]
-[\fB\-\-verbose\fR|\fB\-v\fR] <\fImirrored_file\fR> [<\fImirrored_file2\fR> ...]
+.SY "lfs mirror verify"
+.RB [ --only
+.IR MIRROR_ID [, MIRROR_ID2 ,...]]
+.RB [ --verbose | -v ]
+.IR MIRRORED_FILE " [" MIRRORED_FILE2 " ...]"
+.YS
.SH DESCRIPTION
This command verifies that each SYNC mirror of a mirrored file specified by the
-path name \fImirrored_file\fR contains exactly the same data. It supports
-specifying multiple mirrored files in one command line.
-.br
+path name
+.I MIRRORED_FILE
+contains exactly the same data.
+It supports specifying multiple mirrored files in one command line.
+.P
This is a scrub tool that should be run in regular basis to make sure that
mirrored files are not corrupted. The command won't repair the file if it turns
out to be corrupted. Usually administrator should check the file content from
-each mirror and decide which one is correct and then invoke \fBlfs\ mirror\
- resync\fR to repair it manually.
-.br
-If \fB\-\-only\fR <\fImirror_id\fR,\fImirror_id2\fR[,...]> option is specified,
-then the command will only verify the mirrors specified by \fImirror_id\fRs
-contain exactly the same data. At least two \fImirror_id\fRs are required.
+each mirror and decide which one is correct and then invoke
+.B lfs mirror resync
+to repair it manually.
+.P
+If
+.B --only
+.IR MIRROR_ID [, MIRROR_ID2 ,...]
+option is specified,
+then the command will only verify the mirrors specified by
+.IR MIRROR_ID s
+contain exactly the same data. At least two
+.IR MIRROR_ID s
+are required.
This option cannot be used when multiple mirrored files are specified.
-.br
-If \fB\-\-verbose\fR|\fB\-v\fR option is specified, then the command will print
-where the differences are if the data do not match. Otherwise, the command will
-just return an error in that case. This option can be repeated for multiple
-times to print more information.
+.P
+If
+.BR --verbose | -v
+option is specified,
+then the command will print where the differences are if the data do not match.
+Otherwise, the command will just return an error in that case.
+This option can be repeated for multiple times to print more information.
.SH OPTIONS
.TP
-.B \fB\-\-only\fR <\fImirror_id\fR,\fImirror_id2\fR[,...]>
-This option indicates which mirrors specified by \fImirror_id\fRs need to
-be verified. The \fImirror_id\fR is the numerical unique identifier for
-a mirror. Multiple \fImirror_id\fRs are separated by comma.
+.BR --only " \fIMIRROR_ID" [,\fIMIRROR_ID2 ,...]
+This option indicates which mirrors specified by
+.IR MIRROR_ID s
+need to be verified. The
+.I MIRROR_ID
+is the numerical unique identifier for a mirror. Multiple
+.IR MIRROR_ID s
+are separated by comma.
.TP
-.B \fB\-\-verbose\fR|\fB\-v\fR
+.BR -v ", " --verbose
This option indicates the command will print where the differences are if the
data do not match.
.SH EXAMPLES
-.TP
-.B lfs mirror verify /mnt/lustre/file1
-Verify that each mirror of /mnt/lustre/file1 contains exactly the same data.
-.TP
-.B lfs mirror verify -v /mnt/lustre/file1 /mnt/lustre/file2
+Verify that each mirror of /mnt/lustre/file1 contains exactly the same data:
+.RS
+.EX
+.B # lfs mirror verify /mnt/lustre/file1
+.EE
+.RE
+.PP
Separately verify that each mirror of /mnt/lustre/file1 and /mnt/lustre/file2
contain exactly the same data. Print where the differences are if the data do
-not match.
-.TP
-.B lfs mirror verify --only 4,5 /mnt/lustre/file1
+not match:
+.RS
+.EX
+.B # lfs mirror verify -v /mnt/lustre/file1 /mnt/lustre/file2
+.EE
+.RE
+.PP
Verify mirrors with mirror ID 4 and 5 of /mnt/lustre/file1 contain exactly
-the same data.
-.SH AUTHOR
-The \fBlfs mirror verify\fR command is part of the Lustre filesystem.
+the same data:
+.RS
+.EX
+.B # lfs mirror verify --only 4,5 /mnt/lustre/file1
+.EE
+.RE
+.SH AVAILABILITY
+The
+.B lfs mirror verify
+command is part of the
+.BR lustre (7)
+filesystem package since release 2.11.0
+.\" Added in commit v2_10_57_0-50-gf1daa8fc65
.SH SEE ALSO
.BR lfs (1),
-.BR lfs-setstripe (1),
.BR lfs-mirror-create (1),
.BR lfs-mirror-extend (1),
+.BR lfs-mirror-resync (1),
.BR lfs-mirror-split (1),
-.BR lfs-mirror-resync (1)
+.BR lfs-setstripe (1)
-.TH LFS-MIRROR-WRITE 1 2018-09-23 "Lustre" "Lustre Utilities"
+.TH LFS-MIRROR-WRITE 1 2024-08-20 Lustre "Lustre User Utilities"
.SH NAME
lfs-mirror-write \- write a mirror's content of a mirrored file
.SH SYNOPSIS
-.B lfs mirror write
-{\fB\-\-mirror-id|\-N\fR <\fImirror_id\fR>}
-[\fB\-\-inputfile|\-i\fR <\fIinput_file\fR>]
-<\fImirrored_file\fR>
+.SY "lfs mirror write"
+.BR --mirror-id | -N
+.IR MIRROR_ID
+.RB [ --inputfile | -i
+.IR INPUT_FILE ]
+.I MIRRORED_FILE
+.YS
.SH DESCRIPTION
This command writes the content of a file's mirror, the file is specified by the
-path name \fImirrored_file\fR, the mirror is specified by its mirror ID
-\fImirror_id\fR.
+path name
+.IR MIRRORED_FILE ,
+the mirror is specified by its mirror ID
+.IR MIRROR_ID .
.SH OPTIONS
.TP
-.BR \-\-mirror-id|\-N\fR\ <\fImirror_id\fR>
-This option indicates the content of which mirror specified by \fImirror_id\fR
-needs to be written. The \fImirror_id\fR is the numerical unique identifier for
-a mirror.
+.BR -N ", " --mirror-id " \fIMIRROR_ID"
+This option indicates the content of which mirror specified by
+.I MIRROR_ID
+needs to be written. The
+.I MIRROR_ID
+is the numerical unique identifier for a mirror.
.TP
-.BR \-\-inputfile|\-i\fR\ <\fIinput_file\fR>
-The path name of the input file, if not specified, the standard input stream
-will be used. The input stream or input_file cannot be the same mirrored file
-as the \fImirrored_file\fR. if you'd like to copy a mirror's content to
-another mirror of the same mirrored file, use \fBlfs mirror copy\fR command.
+.BR -i ", " --inputfile " \fIINPUT_FILE"
+The path name of the input file,
+if not specified, the standard input stream will be used.
+The input stream or input_file cannot be the same mirrored file as the
+.IR MIRRORED_FILE .
+if you'd like to copy a mirror's content to
+another mirror of the same mirrored file, use
+.B lfs mirror copy
+command.
.SH EXAMPLES
-.TP
-.B lfs mirror write --mirror-id 3 /mnt/lustre/file1 < /tmp/m2
-Write the content of /mnt/m2 to the mirror with mirror ID 3 for
-/mnt/lustre/file1.
-.TP
-.B lfs mirror write -N2 -i /tmp/m2 /mnt/lustre/file1
-Write the content of /mnt/m2 to the mirror with mirror ID 2 for
-/mnt/lustre/file1.
-.SH AUTHOR
-The \fBlfs mirror write\fR command is part of the Lustre filesystem.
+Write the content of /tmp/src_file to the mirror with ID 3 for
+/mnt/lustre/file1:
+.RS
+.EX
+.B # lfs mirror write --mirror-id 3 /mnt/lustre/file1 < /tmp/src_file
+.EE
+.RE
+.PP
+Write the content of /tmp/src_file to the mirror with mirror ID 2 for
+/mnt/lustre/file1:
+.RS
+.EX
+.B # lfs mirror write -N2 -i /tmp/src_file /mnt/lustre/file1
+.EE
+.RE
+.SH AVAILABILITY
+The
+.B lfs mirror write
+command is part of the
+.BR lustre (7)
+filesystem package since release 2.12.0
+.\" Added in commit v2_11_56_0-70-g14171e787d
.SH SEE ALSO
.BR lfs (1),
-.BR lfs-setstripe (1),
.BR lfs-getstripe (1),
+.BR lfs-mirror-copy (1),
.BR lfs-mirror-create (1),
.BR lfs-mirror-extend (1),
+.BR lfs-mirror-read (1),
.BR lfs-mirror-split (1),
.BR lfs-mirror-verify (1),
-.BR lfs-mirror-read (1)
-.BR lfs-mirror-copy (1)
+.BR lfs-setstripe (1)
-.TH lfs_migrate 1 "Dec 19, 2017" Lustre "utilities"
+.TH LFS_MIGRATE 1 2024-08-20 Lustre "Lustre User Utilities"
.SH NAME
-.B lfs_migrate
-\- migrate files between Lustre OSTs
+lfs_migrate \- migrate files between Lustre OSTs
.SH SYNOPSIS
-.B lfs_migrate
-.RB [ "-A " [ -C \fI<cap> \fR] [ -M \fI<min_free> \fR] [ -X \fI<max_free> \fR]]
+.SY "lfs_migrate"
+.RB [ -A
+.RB [ -C
+.IR CAP ]
+.RB [ -M
+.IR MIN_FREE ]
+.RB [ -X
+.I MAX_FREE ]]
.RB [ --cp ]
.RB [ --dry-run | -n ]
.RB [ --help | -h ]
.RB [ --no-rsync | --rsync ]
-.RB [ --pool | -p \fI<pool> \fR]
+.RB [ --pool | -p
+.IR POOL ]
.RB [ --quiet | -q ]
.RB [ --restripe | -R ]
-.RB [ --stripe-count | -c \fI<stripe_count> \fR]
-.RB [ --stripe-size | -S \fI<stripe_size> \fR]
+.RB [ --stripe-count | -c
+.IR STRIPE_COUNT ]
+.RB [ --stripe-size | -S
+.I STRIPE_SIZE ]
.RB [ --skip | -s ]
.RB [ --verbose | -v ]
.RB [ --yes | -y ]
.RB [ -D ]
.RB [ -0 ]
.RI [ FILE | DIR ] ...
-.br
+.YS
.SH DESCRIPTION
.B lfs_migrate
is a tool to assist migration of files between Lustre OSTs, possibly also
moving files off OSTs that are starting to show hardware problems but are still
functional, or OSTs that will be removed from the filesystem.
.PP
-Files to be migrated can be specified as command-line arguments. If a
+Files to be migrated can be specified as command-line arguments. If a
directory is specified on the command-line then all files within that
-directory are migrated. If no files are specified on the command-line,
+directory are migrated. If no files are specified on the command-line,
then a list of files is read from the standard input, making
.B lfs_migrate
suitable for use with
.BR lfs-setstripe (1)
for a complete list of options.
.PP
-To maintain backward compatibility, the \fI-n \fRoption is used by the
+To maintain backward compatibility, the
+.B -n
+option is used by the
script to indicate a dry-run (no modifications made), and is not passed to
.B lfs migrate
-as the non-block option. To specify non-block, use the long option
+as the non-block option. To specify non-block, use the long option
.BR --non-block .
.PP
The current file allocation policies on MDS dictate where the new files
to copy files instead of
.BR rsync (1).
.TP
-.B \\--dry-run|-n
+.BR -n ", " --dry-run
Only print the names of files to be migrated.
.TP
-.B \\-D
+.B -D
Do not use direct I/O to copy file contents.
.TP
-.B \\-A
+.B -A
Automatically determine the stripe count for the file, using the algorithm
-count = sqrt(filesize_in_GB) + 1. This option may not be specified at the
-same time as the \fB-c \fRor \\-R \fRoptions.
-.TP
-.B \\--stripe-count|-c \fI<stripe_count>
-Restripe file using the specified \fIstripe_count\fR. This option may not be
-specified at the same time as the \fB-A \fRor \fB-R \fRoptions.
-.TP
-.B \\-C \fI<cap>
-When \fB-A \fRis set, limit the migrated file to use on each OST at most
-1/\fIcap \fRof the available space of the smallest OST. If this option is not
+count = sqrt(filesize_in_GB) + 1. This option may not be specified at the
+same time as the
+.B -c
+or
+.B -R
+options.
+.TP
+.BR -c ", " --stripe-count \fISTRIPE_COUNT
+Restripe file using the specified
+.IR STRIPE_COUNT .
+This option may not be specified at the same time as the
+.B -A
+or
+.B -R
+options.
+.TP
+.BI -C " CAP"
+When
+.B -A
+is set, limit the migrated file to use on each OST at most
+.RI 1/ CAP
+of the available space of the smallest OST. If this option is not
set, a default value of 100 is used, limiting the object size to 1% of available
space.
.TP
-.B \\--help|-h
+.BR -h ", " --help
Display usage message.
.TP
-.B \\--no-rsync
+.B --no-rsync
Do not fall back to using rsync if
-.BR lfs-migrate (1) " fails."
-Cannot be used at the same time as \fB--rsync\fR.
-.TP
-.B \\--min-free|-M \fI<min_free>
-When \fB-A \fRis set, only consider OSTs with free space greater than the
-\fImin_free \fRvalue to be available for migration. The value is specified in
+.BR lfs-migrate (1)
+fails. Cannot be used at the same time as
+.BR --rsync .
+.TP
+.BR -M ", " --min-free \fIMIN_FREE
+When
+.B -A
+is set, only consider OSTs with free space greater than the
+.I MIN_FREE
+value to be available for migration. The value is specified in
KB. If this option is not set, a default of 256MB is used.
.TP
-.BR \\--pool | -q \fI<pool>
+.BR -p ", " --pool \fIPOOL
Migrate files to specified pool.
.TP
-.BR \\--quiet | -q
+.BR -q ", " --quiet
Run quietly (don't print filenames or status).
.TP
-.B \\--rsync
+.B --rsync
Force rsync to be used instead of
.BR lfs-migrate (1) .
May not be used at the same time as
.BR --no-rsync .
.TP
-.B \\--restripe|-R
+.BR -R ", " --restripe
Restripe file using default directory striping instead of keeping striping.
-This option may not be specified at the same time as the \fB-A\fR, \fB-c\fR, or
-\fB-S \fRoptions. (these options are passed through to
+This option may not be specified at the same time as the
+.BR -A ", " -c ,
+or
+.B -S
+options. (these options are passed through to
.BR "lfs migrate" ,
and are therefore not listed here).
.TP
-.B \\--skip|-s
-Skip file data comparison after migrate. Default is to compare migrated file
+.BR -s ", " --skip
+Skip file data comparison after migrate. Default is to compare migrated file
against original to verify correctness.
.TP
-.B \\--stripe-size|-S
-.I <stripe_size>
+.BR -S ", " --stripe-size \fISTRIPE_SIZE
Restripe file using the specified stripe size. This option may not be
-specified at the same time as the \fB-R \fRoption.
+specified at the same time as the
+.B -R
+option.
.TP
-.B \\--verbose|-v
+.BR -v ", " --verbose
Show verbose debug messages.
.TP
-.B \\--max-free|-X \fI<max_free>
-When \fB-A \fRis set, \fImax_free \fRis the maximum amount of free space that
-can be considered available for the migration of the file on each OST. The
-value is specified in KB. This option is useful for testing, by simulating
-OSTs that are nearly full.
+.BR -X ", " --max-free \fIMAX_FREE
+When
+.B -A
+is set,
+.I MAX_FREE
+is the maximum amount of free space that can be considered available
+for the migration of the file on each OST. The value is specified in KB.
+This option is useful for testing, by simulating OSTs that are nearly full.
.TP
-.B \\--yes|-y
+.BR -y ", " --yes
Answer 'y' to usage warning without prompt (--rsync only, use with caution).
.TP
-.B \\-0
+.B -0
Input file names on stdin are separated by a null character.
+.SH NOTES
+In versions prior to 2.5,
+.B lfs_migrate
+is
+.B not
+closely integrated with the MDS, and cannot determine whether a file
+is currently open and/or in-use by other applications or nodes. That makes
+it
+.B UNSAFE
+for use on files that might be modified by other applications, since the
+migrated file is only a copy of the current file. This will result in the
+old file becoming an open-unlinked file, and any modifications to that file
+will be lost.
.SH EXAMPLES
To rebalance all files within
.IR /testfs/jobs/2011 :
-.IP
-lfs_migrate /testfs/jobs/2011
+.RS
+.EX
+.B # lfs_migrate /testfs/jobs/2011
+.EE
+.RE
.PP
To migrate files within the
.I /testfs
many small ones), and older than two days (to avoid files that are in use) to
use auto-restriping for these files, after disabling file creation on
testfs-OST0004 (this is needed on all MDS nodes):
-.IP
-.nf
-mds# lctl set_param osp.testfs-OST0004*.max_create_count=0
-client# lfs find /testfs -obd testfs-OST0004 -size +4G -mtime +2d | lfs_migrate -A
-mds# lctl set_param osp.testfs-OST0004*.max_create_count=20000
-.fi
+.RS
+.EX
+.B "[ mds]#" lctl set_param osp.testfs-OST0004*.max_create_count=0
+.B "[client]#" lfs find /testfs -obd testfs-OST0004 -size +4G -mtime +2d \
+| lfs_migrate -A
+.B "[ mds]#" lctl set_param osp.testfs-OST0004*.max_create_count=20000
+.EE
+.RE
.PP
To use automatic restriping, and limit the object size per OST to 5% of
current free space:
-.IP
-lfs_migrate -A -C 20 /testfs/jobs/2011
-.SH NOTES
-In versions prior to 2.5,
-.B lfs_migrate
-is
-.B not
-closely integrated with the MDS, and cannot determine whether a file
-is currently open and/or in-use by other applications or nodes. That makes
-it
-.B UNSAFE
-for use on files that might be modified by other applications, since the
-migrated file is only a copy of the current file. This will result in the
-old file becoming an open-unlinked file, and any modifications to that file
-will be lost.
+.RS
+.EX
+.B # lfs_migrate -A -C 20 /testfs/jobs/2011
+.EE
+.RE
.SH AVAILABILITY
.B lfs_migrate
is part of the
-.BR Lustre (7)
-filesystem package. Added in the 1.8.4 release.
+.BR lustre (7)
+filesystem package. Added in release 1.8.4.
+.\" Added in commit v1_10_0_43-29-g1c3bb7cd68
.SH SEE ALSO
-.BR lfs (1)
+.BR lfs (1),
+.BR lfs-migrate (1)
#define SSM_SETSTRIPE_OPT \
"[--component-add|--component-del|--delete|-d]\n" \
- "\t\t[--comp-set --comp-id|-I COMP_ID|--comp-flags=COMP_FLAGS]\n" \
+ "\t\t[--comp-set --comp-id|-I COMP_ID|--comp-flags=COMP_FLAGS]\n" \
"\t\t[--component-end|-E END_OFFSET]\n" \
- "\t\t[--copy=SOURCE_LAYOUT_FILE]|--yaml|-y YAML_TEMPLATE_FILE]\n" \
+ "\t\t[--copy=SOURCE_LAYOUT_FILE]|--yaml|-y YAML_TEMPLATE_FILE]\n" \
"\t\t[--extension-size|--ext-size|-z EXT_SIZE]\n" \
"\t\t[--help|-h]\n" \
"\t\t[--foreign=FOREIGN_TYPE --xattr|-x LAYOUT]\n" \
"\t [-f NEW_FILE] MIRRORED_FILE ...\n" },
{ .pc_name = "read", .pc_func = lfs_mirror_read,
.pc_help = "Read the content of a specified mirror of a file.\n"
- "usage: lfs mirror read {--mirror-id|-N MIRROR_ID}\n"
- "\t\t[--outfile|-o <output_file>] <mirrored_file>\n" },
+ "usage: lfs mirror read --mirror-id|-N MIRROR_ID\n"
+ "\t\t[--outfile|-o OUTPUT_FILE] MIRRORED_FILE\n" },
{ .pc_name = "write", .pc_func = lfs_mirror_write,
.pc_help = "Write to a specified mirror of a file.\n"
"usage: lfs mirror write {--mirror-id|-N MIRROR_ID}\n"
- "\t\t[--inputfile|-i <input_file>] <mirrored_file>\n" },
+ "\t\t[--inputfile|-i INPUT_FILE] MIRRORED_FILE\n" },
{ .pc_name = "copy", .pc_func = lfs_mirror_copy,
.pc_help = "Copy a specified mirror to other mirror(s) of a file.\n"
- "usage: lfs mirror copy {--read-mirror|-i MIRROR_ID0}\n"
- "\t\t{--write-mirror|-o MIRROR_ID1[,...]} <mirrored_file>\n" },
+ "usage: lfs mirror copy --read-mirror|-i SRC_MIRROR_ID0\n"
+ "\t\t--write-mirror|-o TGT_MIRROR_ID1[,...] MIRROR_FILE\n" },
{ .pc_name = "resync", .pc_func = lfs_mirror_resync,
.pc_help = "Resynchronizes out-of-sync mirrored file(s).\n"
- "usage: lfs mirror resync [--only MIRROR_ID[,...]>]|\n"
- "\t\t--stats|--stats-interval=<sec>|\n"
- "\t\t--W <bandwidth>|--bandwidth-limit=<bandwidth>\n"
- "\t\t<mirrored_file> [<mirrored_file2>...]\n" },
+ "usage: lfs mirror resync [--only MIRROR_ID[,...]]|\n"
+ "\t\t[--stats|--stats-interval=SECONDS]\n"
+ "\t\t[--W |--bandwidth-limit=BANDWIDTH_MB]\n"
+ "\t\tMIRRORED_FILE [MIRRORED_FILE2...]\n" },
{ .pc_name = "verify", .pc_func = lfs_mirror_verify,
.pc_help = "Verify mirrored file(s).\n"
"usage: lfs mirror verify [--only MIRROR_ID[,...]]\n"
- "\t\t[--verbose|-v] <mirrored_file> [<mirrored_file2> ...]\n" },
+ "\t\t[--verbose|-v] MIRRORED_FILE [MIRRORED_FILE2 ...]\n" },
{ .pc_help = NULL }
};