X-Git-Url: https://git.whamcloud.com/?a=blobdiff_plain;f=UserUtilities.xml;h=a3eb0c35c703cfc1a0d03e6f71b168c797b26c5f;hb=fcafa5bebef80213b4a1822edd83edc26894eccb;hp=a596173a351b3b2a6c56e336b8364c20c0c6be44;hpb=e5e0f290be2179ed9ad2a9390e7e8338f8f75ed4;p=doc%2Fmanual.git
diff --git a/UserUtilities.xml b/UserUtilities.xml
index a596173..a3eb0c3 100644
--- a/UserUtilities.xml
+++ b/UserUtilities.xml
@@ -22,6 +22,7 @@ lfs
lfs changelog [--follow] mdt_name [startrec [endrec]]
lfs changelog_clear mdt_name id endrec
lfs check mds|osts|servers
+lfs data_version [-nrw] filename
lfs df [-i] [-h] [--pool]-p fsname[.pool] [path] [--lazy]
lfs find [[!] --atime|-A [-+]N] [[!] --mtime|-M [-+]N]
[[!] --ctime|-C [-+]N] [--maxdepth|-D N] [--name|-n pattern]
@@ -46,27 +47,27 @@ lfs setstripe -d dir
lfs osts [path]
lfs pool_list filesystem[.pool]| pathname
lfs quota [-q] [-v] [-h] [-o obd_uuid|-I ost_idx|-i mdt_idx]
- [-u username|uid|-g group|gid] /mount_point
-lfs quota -t -u|-g /mount_point
+ [-u username|uid|-g group|gid|-p projid] /mount_point
+lfs quota -t -u|-g|-p /mount_point
lfs quotacheck [-ug] /mount_point
lfs quotachown [-i] /mount_point
lfs quotainv [-ug] [-f] /mount_point
lfs quotaon [-ugf] /mount_point
lfs quotaoff [-ug] /mount_point
-lfs setquota {-u|--user|-g|--group} uname|uid|gname|gid
+lfs setquota {-u|--user|-g|--group|-p|--project} uname|uid|gname|gid|projid
[--block-softlimit block_softlimit]
[--block-hardlimit block_hardlimit]
[--inode-softlimit inode_softlimit]
[--inode-hardlimit inode_hardlimit]
/mount_point
-lfs setquota -u|--user|-g|--group uname|uid|gname|gid
+lfs setquota -u|--user|-g|--group|-p|--project uname|uid|gname|gid|projid
[-b block_softlimit] [-B block_hardlimit]
[-i inode-softlimit] [-I inode_hardlimit]
/mount_point
-lfs setquota -t -u|-g [--block-grace block_grace]
+lfs setquota -t -u|-g|-p [--block-grace block_grace]
[--inode-grace inode_grace]
/mount_point
-lfs setquota -t -u|-g [-b block_grace] [-i inode_grace]
+lfs setquota -t -u|-g|-p [-b block_grace] [-i inode_grace]
/mount_point
lfs help
@@ -171,6 +172,40 @@ lfs help
+
+ data_version [-nrw]
+ filename
+
+
+
+ Displays the current version of file data. If
+ -n is specified, the data version is read
+ without taking a lock. As a consequence, the data version could
+ be outdated if there are dirty caches on filesystem clients, but
+ this option will not force data flushes and has less of an
+ impact on the filesystem. If -r is specified,
+ the data version is read after dirty pages on clients are
+ flushed. If -w is specified, the data version
+ is read after all caching pages on clients are flushed.
+
+
+ Even with -r or -w, race
+ conditions are possible and the data version should be checked
+ before and after an operation to be confident the data did not
+ change during it.
+
+
+ The data version is the sum of the last committed transaction
+ numbers of all data objects of a file. It is used by HSM policy
+ engines for verifying that file data has not been changed during
+ an archive operation or before a release operation, and by OST
+ migration, primarily for verifying that file data has not been
+ changed during a data copy, when done in non-blocking mode.
+
+
+
+
+
df [-i] [-h] [--pool|-p
fsname[.
pool] [
@@ -732,8 +767,8 @@ lfs help
quota [-q] [-v] [-o
obd_uuid|-i
mdt_idx|-I
- ost_idx] [-u|-g
- uname|uid|gname|gid]
+ ost_idx] [-u|-g|-p
+ uname|uid|gname|gid|projid]
/mount_point
@@ -741,11 +776,11 @@ lfs help
Displays disk usage and limits, either for the full file
system or for objects on a specific OBD. A user or group name
- or an ID can be specified. If both user and group are omitted,
- quotas for the current UID/GID are shown. The
- -q option disables printing of additional
- descriptions (including column titles). It fills in blank
- spaces in the
+ or an usr, group and project ID can be specified. If all user,
+ group project ID are omitted, quotas for the current UID/GID
+ are shown. The -q option disables printing
+ of additional descriptions (including column titles). It fills
+ in blank spaces in the
grace column with zeros (when there is no
grace period set), to ensure that the number of columns is
consistent. The
@@ -757,14 +792,15 @@ lfs help
quota -t
- -u|-g
+ -u|-g|-p
/mount_point
Displays block and inode grace times for user (
-u) or group (
- -g) quotas.
+ -g) or project (
+ -p) quotas.
@@ -849,9 +885,9 @@ lfs help
- setquota -u|-g
-
- uname|uid|gname|gid}[--block-softlimit
+ setquota {-u|-g|-p
+ uname|uid|gname|gid|projid}
+ [--block-softlimit
block_softlimit]
[--block-hardlimit
block_hardlimit]
@@ -863,8 +899,8 @@ lfs help
- Sets file system quotas for users or groups. Limits can
- be specified with
+ Sets file system quotas for users, groups or one project.
+ Limits can be specified with
--{block|inode}-{softlimit|hardlimit} or
their short equivalents
-b,
@@ -886,7 +922,7 @@ lfs help
- setquota -t -u|-g [--block-grace
+ setquota -t -u|-g|-p [--block-grace
block_grace] [--inode-grace
inode_grace]
/mount_point
@@ -986,6 +1022,10 @@ $ lfs df --pool
$ lfs quota -u bob /mnt/lustre
+ List quotas of project ID '1'.
+
+$ lfs quota -p 1 /mnt/lustre
+
Show grace times for user quotas on
/mnt/lustre.
@@ -1066,7 +1106,7 @@ $ lfs setstripe --pool my_pool /mnt/lustre/dir
-
+
lfs_migrate
@@ -1074,50 +1114,54 @@ $ lfs setstripe --pool my_pool /mnt/lustre/dir
lfs_migrate
The
- lfs_migrate utility is a simple tool to migrate files
- between Lustre OSTs.
+ lfs_migrate utility is a simple to migrate file
+ data between OSTs.
Synopsis
-lfs_migrate [-c stripecount] [-h] [-l] [-n] [-q] [-R] [-s] [-y]
-[file|directory ...]
+lfs_migrate [lfs_setstripe_options]
+ [-h] [-n] [-q] [-R] [-s] [-y] [-0] [file|directory ...]
Description
The
- lfs_migrate utility is a simple tool to assist
- migration of files between Lustre OSTs. The utility copies each specified
- file to a new file, verifies the file contents have not changed, and then
- renames the new file to the original filename. This allows balanced space
- usage between OSTs, moving files off OSTs that are starting to show
- hardware problems (though are still functional) or OSTs that will be
- discontinued.
+ lfs_migrate utility is a tool to assist migration
+ of file data between Lustre OSTs. The utility copies each specified
+ file to a temporary file using supplied lfs setstripe
+ options, if any, optionally verifies the file contents have not changed,
+ and then swaps the layout (OST objects) from the temporary file and the
+ original file (for Lustre 2.5 and later), or renames the temporary file
+ to the original filename. This allows the user/administrator to balance
+ space usage between OSTs, or move files off OSTs that are starting to show
+ hardware problems (though are still functional) or will be removed.
For versions of Lustre before 2.5,
- lfs_migrate is not closely integrated with the MDS,
- it cannot determine whether a file is currently open and/or in-use by
- other applications or nodes. This makes it 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 results in the old file becoming
- an open-unlinked file and any modifications to that file are
- lost.
+ lfs_migrate was not integrated with the MDS at all.
+ That made it UNSAFE for use on files that were being modified by other
+ applications, since the file was migrated through a copy and rename of
+ the file. With Lustre 2.5 and later, the new file layout is swapped
+ with the existing file layout, which ensures that the user-visible
+ inode number is kept, and open file handles and locks on the file are
+ kept.
Files to be migrated can be specified as command-line arguments. If
a directory is specified on the command-line then all files within the
directory are migrated. If no files are specified on the command-line,
then a list of files is read from the standard input, making
lfs_migrate suitable for use with
- lfs find to locate files on specific OSTs and/or
- matching other file attributes.
- The current file allocation policies on the MDS dictate where the
- new files are placed, taking into account whether specific OSTs have been
- disabled on the MDS via
- lctl(preventing new files from being allocated there),
- whether some OSTs are overly full (reducing the number of files placed on
- those OSTs), or if there is a specific default file striping for the
- target directory (potentially changing the stripe count, stripe size, OST
- pool, or OST index of a new file).
+ lfs find to locate files on specific OSTs and/or
+ matching other file attributes, and other tools that generate a list
+ of files on standard output.
+ Unless otherwise specified through command-line options, the
+ file allocation policies on the MDS dictate where the new files
+ are placed, taking into account whether specific OSTs have been
+ disabled on the MDS via lctl (preventing new
+ files from being allocated there), whether some OSTs are overly full
+ (reducing the number of files placed on those OSTs), or if there is
+ a specific default file striping for the parent directory (potentially
+ changing the stripe count, stripe size, OST pool, or OST index of a
+ new file).
The
lfs_migrate utility can also be used in some cases to
@@ -1249,21 +1293,31 @@ lfs_migrate [-c stripecount] [-h] [-l] [-n] [-q] [-R]
scripts, use with caution).
+
+
+ -0
+
+ Expect NUL-terminated filenames on standard input, as
+ generated by lfs find -print0 or
+ find -print0. This allows filenames with
+ embedded newlines to be handled correctly.
+
+
Examples
- Rebalances all files in
- /mnt/lustre/dir.
+ Rebalance all files in
+ /mnt/lustre/dir:
-$ lfs_migrate /mnt/lustre/file
+$ lfs_migrate /mnt/lustre/dir
- Migrates files in /test filesystem on OST004 larger than 4 GB in
- size.
+ Migrate files in /test filesystem on OST0004 larger than 4 GB in
+ size and older than a day old:
-$ lfs find /test -obd test-OST004 -size +4G | lfs_migrate -y
+$ lfs find /test -obd test-OST0004 -size +4G -mtime +1 | lfs_migrate -y
@@ -1577,7 +1631,7 @@ File size of /mnt/lustre/foo is 1468297786 (1433888 blocks of 1024 bytes)
- Enables/disables FID to path translation by
+ Enables/disables FID to path translation by
regular users