Whamcloud - gitweb
LU-930 utils: add --help option to lfs sub-commands
[fs/lustre-release.git] / lustre / doc / lfs-getstripe.1
index 98c1156..aa3a8df 100644 (file)
@@ -8,9 +8,11 @@ lfs getstripe \- Lustre client command to print layout parameters of a file
       [\fB--component-flags\fR|\fB--comp-flags\fR[\fB=\fIflags\fR]]
       [\fB--component-id\fR|\fB--comp-id\fR[=\fIid\fR]|\fB-I\fR[\fIid\fR]]
       [\fB--component-start\fR[\fB=\fR[\fB+-\fR]\fIstart\fR[\fBKMGTPE\fR]]]
+      [\fB--extension-size\fR|\fB--ext-size\fR|\fB-z\fR]
       [\fB--directory\fR|\fB-d\fR]
 [\fB--fid\fR|\fB-F\fR]
 [\fB--generation\fR|\fB-g\fR]
+[\fB--help\fR|\fB-h\fR]
       [\fB--layout\fR|\fB-L\fR]
 [\fB--mdt\fR|\fB--mdt-index\fR|\fB-m\fR]
 [\fB--ost\fR|\fB-O\fR <\fIuuid\fR>]
@@ -20,10 +22,11 @@ lfs getstripe \- Lustre client command to print layout parameters of a file
       [\fB--raw\fR|\fB-R\fR]
 [\fB--stripe-count\fR|\fB-c\fR]
 [\fB--stripe-index\fR|\fB-i\fR]
-      [\fB--stripe-size\fR|\fB-S\fR]
-[\fB--verbose\fR|\fB-v\fR]
+      [\fB--stripe-size\fR|\fB-S\fR] [\fB--mirror-count\fR|\fB-N\fR]
+      [[\fB!\fR] \fB--mirror-index\fR=[\fB+-\fR]\fI<index>\fR | [\fB!\fR] \fB--mirror-id\fR=[\fB+-\fR]\fI<id>\fR]
+      [\fB--verbose\fR|\fB-v\fR]
 [\fB--yaml\fR|\fB-y\fR]
-      <\fIdirname\fR|\fIfilename\fR> ...
+<\fIdirname\fR|\fIfilename\fR> ...
 .SH DESCRIPTION
 .B lfs getstripe
 is used to list the layout/striping information for a given filename or
@@ -32,6 +35,7 @@ and allocated OST objects for each file will be shown. If you only want
 specific layout information to be printed, then the
 .BR --stripe-count ,
 .BR --stripe-size ,
+.BR --extension-size ,
 .BR --stripe-index ,
 .BR --layout ,
 .BR --fid ,
@@ -41,18 +45,24 @@ specific layout information to be printed, then the
 .BR --component-count ,
 .BR --component-start ,
 .BR --component-end ,
-or
 .BR --pool
+or
+.BR --mirror-index
+or
+.BR --mirror-id
 options, or equivalent single-character options, can be used without an
 argument to return only the specified field(s).
 .PP
-You can limit the displayed content to one or more specific components of
-a composite file layout by specifying the matching parameter(s) for the
+You can limit the displayed content to one or more specific components or
+mirror of a composite file layout by specifying the matching
+parameter(s) for the
 .BR --component-id ,
 .BR --component-flags ,
 .BR --component-start ,
-and
 .BR --component-end ,
+.BR --mirror-index ,
+or
+.BR --mirror-id ,
 or their single-character options. For single-character options, the
 argument must follow the option without a space, and for long options an
 .RB ' = '
@@ -105,6 +115,11 @@ before they can be accessed again.
 Replicated (mirrored) components that are preferred for read or write.
 For example, because they are located on SSD-based OSTs, or are more
 local on the network to clients.
+.TP
+.B nosync
+Replicated (mirrored) components that do not resync using \fB
+lfs mirror resync\fR.  Files with the \fBnosync\fR flag will also
+print the timestamp when the flag was set on the replica.
 .RE
 .TP
 .BR --component-id | --comp-id [ =\fIid ]| -I [ \fIid ]
@@ -138,9 +153,12 @@ Get striping information for only the specified directory, like
 .BR --fid | -F
 Show only the 128-bit unique Lustre File Identifier (FID).
 .TP
-.B --generation | -g
+.BR --generation | -g
 Print only the layout generation number.
 .TP
+.BR --help | -h
+Print usage message.
+.TP
 .BR --layout
 Show only the file layout, which is one of:
 .RS 1.2i
@@ -158,6 +176,46 @@ Files that have the first data component on an MDT.
 .BR --mdt | --mdt-index | -m
 Show the MDT index on which the file or directory inode is located.
 .TP
+.BR --mirror-count | -N
+Print the number of mirrors on the file.
+.TP
+.BR --mirror-index = [\fB+-\fR]\fR<\fIindex\fR>
+Print only the components of \fI<index>\fR-th mirror, based on the order
+that the mirror components are stored in the file layout. The \fIindex\fR
+starts at 1. If
+.BI + index
+or
+.BI - index
+is used, print components of mirror(s) respectively later or earlier than
+the \fIindex\fR-th mirror.
+.RS 1.2i
+.TP
+.B !
+Negates the meaning. Using + before \fIindex\fR means mirror appears 'later
+than \fIindex\fR',
+- before \fIindex\fR means mirror appears 'earlier than \fIindex\fR'. If
+neither is used, it means 'equal to \fIindex\fR'.
+.RE
+.TP
+.BR --mirror-id = [\fB+-\fR]\fR<\fIid\fR>
+Print only the components of the mirror with ID of \fIid\fR. The mirror IDs
+are assigned to new mirrors as they are created, but may not be sequential
+if some mirrors are removed. If
+.BI + id
+or
+.BI - id
+is used, print components of mirror(s) with respectively a larger or smaller
+mirror ID of
+.I id
+.
+.RS 1.2i
+.TP
+.B !
+Negates the meaning. Using + before \fIid\fR means mirror with ID 'larger
+than \fIid\fR', - before \fIid\fR means mirror with ID 'smaller than \fIid\fR'.
+If neither is used, it means 'equal to \fIid\fR'.
+.RE
+.TP
 .BR --ost | -O
 Print the starting OST index for the file layout.
 .TP
@@ -186,6 +244,10 @@ Print the starting OST index for the file layout.
 Print the stripe size in bytes.  For composite files this is the stripe
 size of the last initialized component.
 .TP
+.BR --extension-size | --ext-size | -z
+Print the extension size in bytes. For composite files this is the extension
+size of the first extension component.
+.TP
 .BR --verbose | -v
 Also print the layout magic, FID sequence, FID object ID, and FID, in
 addition to the normally-printed attributes.
@@ -202,11 +264,17 @@ List the detailed object allocation of the given file.
 .B $ lfs getstripe -v -I2 /mnt/lustre/file1
 List the detailed information of only component with ID 2 of the given file.
 .TP
+.B $ lfs getstripe --mirror-index=+1 /mnt/lustre/file1
+Print the mirror(s) appearing later than the first mirror in the the file.
+.TP
+.B $ lfs getstripe ! --mirror-id=2 /mnt/lustre/file1
+Print the mirror(s) with mirror ID other than 2 in the file.
+.TP
 .B $ lfs getstripe --component-flags=^init -I /mnt/lustre/file1
 Print only the component IDs for all the uninitialized components.
 .TP
 .B $ lfs getstripe --component-flags=init,^stale -I /mnt/lustre/file1
-Print only the component(s) that are instantiated but not stale
+Print only the component(s) that are instantiated but not stale.
 .TP
 .B $ lfs getstripe -E-64M /mnt/lustre/file1
 List information of components in a file with extent end less than 64MiB.