X-Git-Url: https://git.whamcloud.com/?a=blobdiff_plain;f=UserUtilities.xml;h=3f6d562bd8f4ef054fe6ddb2109f1d5bed935f5f;hb=689465077486fa6fcc1865cf923e8650fef75f65;hp=cd2ba01e09f79599498a2b0b314c2bd6982f47cc;hpb=e71e97e9533c977c31992315e28ced53e4bd4b2e;p=doc%2Fmanual.git diff --git a/UserUtilities.xml b/UserUtilities.xml index cd2ba01..3f6d562 100644 --- a/UserUtilities.xml +++ b/UserUtilities.xml @@ -1,5 +1,4 @@ - - + User Utilities This chapter describes user utilities and includes the following sections: @@ -10,9 +9,6 @@ - - - @@ -30,59 +26,59 @@
Synopsis lfs -lfs changelog [--follow] <mdtname> [startrec [endrec]] -lfs changelog_clear <mdtname> <id> <endrec> -lfs check <mds|osts|servers> -lfs df [-i] [-h] [--pool]-p <fsname>[.<pool>] [path] +lfs changelog [--follow] mdt_name [startrec [endrec]] +lfs changelog_clear mdt_name id endrec +lfs check mds|osts|servers +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>] - [--print|-p] [--print0|-P] [[!] --obd|-O <uuid[s]>] + [[!] --ctime|-C [-+]N] [--maxdepth|-D N] [--name|-n pattern] + [--print|-p] [--print0|-P] [[!] --obd|-O ost_name[,ost_name...]] [[!] --size|-S [+-]N[kMGTPE]] --type |-t {bcdflpsD}] - [[!] --gid|-g|--group|-G <gname>|<gid>] - [[!] --uid|-u|--user|-U <uname>|<uid>] - <dirname|filename> + [[!] --gid|-g|--group|-G gname|gid] + [[!] --uid|-u|--user|-U uname|uid] + dirname|filename lfs getname [-h]|[path...] -lfs getstripe [--obd|-O <uuid>] [--quiet|-q] [--verbose|-v] +lfs getstripe [--obd|-O ost_name] [--quiet|-q] [--verbose|-v] [--count|-c] [--index|-i | --offset|-o] [--size|-s] [--pool|-p] [--directory|-d] - [--recursive|-r] [--raw|-R] [-M] <dirname|filename> ... -lfs setstripe [--size|-s stripe_size] [--count|-c stripe_cnt] - [--index|-i|--offset|-o start_ost_index] - [--pool|-p <pool>] - <dirname|filename> -lfs setstripe -d <dir> + [--recursive|-r] [--raw|-R] [-M] dirname|filename ... +lfs setstripe [--size|-s stripe_size] [--count|-c stripe_count] + [--index|-i|--offset|-o start_ost_index] + [--pool|-p pool] + dirname|filename +lfs setstripe -d dir lfs osts [path] -lfs poollist <filesystem>[.<pool>]|<pathname> -lfs quota [-q] [-v] [-o obd_uuid|-I ost_idx|-i mdt_idx] - [-u <uname>|-u <uid>|-g <gname>|-g <gid>] - <filesystem> -lfs quota -t <-u|-g> <filesystem> -lfs quotacheck [-ug] <filesystem> -lfs quotachown [-i] <filesystem> -lfs quotainv [-ug] [-f] <filesystem> -lfs quotaon [-ugf] <filesystem> -lfs quotaoff [-ug] <filesystem> -lfs setquota <-u|--user|-g|--group> <uname|uid|gname|gid> - [--block-softlimit <block-softlimit>] - [--block-hardlimit <block-hardlimit>] - [--inode-softlimit <inode-softlimit>] - [--inode-hardlimit <inode-hardlimit>] - <filesystem> -lfs setquota <-u|--user|-g|--group> <uname|uid|gname|gid> - [-b <block-softlimit>] [-B <block-hardlimit>] - [-i <inode-softlimit>] [-I <inode-hardlimit>] - <filesystem> -lfs setquota -t <-u|-g> - [--block-grace <block-grace>] - [--inode-grace <inode-grace>] - <filesystem> -lfs setquota -t <-u|-g> - [-b <block-grace>] [-i <inode-grace>] - <filesystem> +lfs poollist 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 +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 + [--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 + [-b block_softlimit] [-B block_hardlimit] + [-i inode-softlimit] [-I inode_hardlimit] + /mount_point +lfs setquota -t -u|-g + [--block-grace block_grace] + [--inode-grace inode_grace] + /mount_point +lfs setquota -t -u|-g + [-b block_grace] [-i inode_grace] + /mount_point lfs help - In the above example, the <filesystem> parameter refers to the mount point of the Lustre file system. The default mount point is /mnt/lustre + In the above example, the /mount_point parameter refers to the mount point of the Lustre file system. The old lfs quota output was very detailed and contained cluster-wide quota statistics (including cluster-wide limits for a user/group and cluster-wide usage for a user/group), as well as statistics for each MDS/OST. Now, lfs quota has been updated to provide only cluster-wide statistics, by default. To obtain the full report of cluster-wide limits, usage and statistics, use the -v option with lfs quota. @@ -97,9 +93,9 @@ lfs help The various lfs options are listed and described below. For a complete list of available options, type help at the lfs prompt. - - - + + + @@ -124,7 +120,7 @@ lfs help changelog_clear - Indicates that changelog records previous to <endrec> are no longer of interest to a particular consumer <id>, potentially allowing the MDT to free up disk space. An <endrec> of 0 indicates the current last record. Changelog consumers must be registered on the MDT node using lctl. + Indicates that changelog records previous to endrec are no longer of interest to a particular consumer id, potentially allowing the MDT to free up disk space. An endrec of 0 indicates the current last record. Changelog consumers must be registered on the MDT node using lctl. @@ -137,10 +133,28 @@ lfs help - df [-i] [-h] [--pool|-p <fsname>[.<pool>] [path] - - - Report file system disk space usage or inode usage (with -i) of each MDT/OST or a subset of OSTs if a pool is specified with -p. By default, prints the usage of all mounted Lustre file systems. Otherwise, if path is specified, prints only the usage of that file system. If -h is given, the output is printed in human-readable format, using SI base-2 suffixes for Mega-, Giga-, Tera-, Peta-, or Exabytes. + df [-i] [-h] [--pool|-p + fsname[.pool] + [path] [--lazy] + + + Use -i to report file system disk space usage or inode + usage of each MDT or OST or, if a pool is specified with the -p + option, a subset of OSTs. + By default, the usage of all mounted Lustre file systems is reported. If the + path option is included, only the usage for the specified + file system is reported. If the -h option is included, the + output is printed in human-readable format, using SI base-2 suffixes for Mega-, Giga-, Tera-, Peta-, or + Exabytes. + If the --lazy option is specified, any OST that is + currently disconnected from the client will be skipped. Using the + --lazy option prevents the df output from + being blocked when an OST is offline. Only the space on the OSTs that can + currently be accessed are returned. The llite.*.lazystatfs + tunable can be enabled to make this the default behaviour for all + statfs() operations. @@ -159,7 +173,13 @@ lfs help File was last accessed N*24 hours ago. (There is no guarantee that atime is kept coherent across the cluster.) - OSTs store a transient atime that is updated when clients do read requests. Permanent atime is written to the MDS when the file is closed. However, on-disk atime is only updated if it is more than 60 seconds old (/proc/fs/lustre/mds/*/max_atime_diff). Lustre considers the latest atime from all OSTs. If a setattr is set by user, then it is updated on both the MDS and OST, allowing the atime to go backward. + OSTs store a transient atime that is updated when clients + do read requests. Permanent atime is written to the MDS when + the file is closed. However, on-disk atime is only updated if it is more than 60 + seconds old (/proc/fs/lustre/mds/*/max_atime_diff). The Lustre + software considers the latest atime from all OSTs. If a + setattr is set by user, then it is updated on both the MDS + and OST, allowing the atime to go backward. @@ -214,7 +234,8 @@ lfs help --type - File has the type (block, character, directory, pipe, file, symlink, socket or Door [Solaris]). + File has the type - block, character, directory, pipe, file, symlink, socket + or door (used in Solaris operating system). @@ -288,7 +309,9 @@ lfs help osts [path] - Lists all OSTs for the file system. If a path located on a Lustre-mounted file system is specified, then only OSTs belonging to this file system are displayed. + Lists all OSTs for the file system. If a path located on a mounted Lustre file + system is specified, then only OSTs belonging to this file system are + displayed. @@ -296,8 +319,10 @@ lfs help getname [path...] - List each Lustre instance associated with each Lustre mount point. - If no path is specified, all Lustre mounts points are interrogated. If a list of paths is provided, the instance of each path is provided. If the path is not a Lustre instance 'No such device' is returned. + List each Lustre file system instance associated with each Lustre mount + point. If no path is specified, all Lustre mount points are interrogated. If a + list of paths is provided, the instance of each path is provided. If the path is + not a Lustre instance 'No such device' is returned. @@ -307,7 +332,10 @@ lfs help Lists striping information for a given filename or directory. By default, the stripe count, stripe size and offset are returned. If you only want specific striping information, then the options of --count,--size,--index or --offset plus various combinations of these options can be used to retrieve specific information. - If the --raw option is specified, the stripe information is printed without substituting the filesystem's default values for unspecified fields. If the striping EA is not set, 0, 0, and -1 will be printed for the stripe count, size, and offset respectively. + If the --raw option is specified, the stripe information is + printed without substituting the file system default values for unspecified + fields. If the striping EA is not set, 0, 0, and -1 will be printed for the stripe + count, size, and offset respectively. The -M prints the index of the MDT for a given directory. See . @@ -316,7 +344,7 @@ lfs help   - --obd <uuid> + --obd ost_name Lists files that have an object on a specific OST. @@ -471,7 +499,7 @@ lfs help   - --pool <pool> + --pool pool Name of the pre-defined pool of OSTs (see ) that will be used for striping. The stripe_cnt, stripe_size and start_ost values are used as well. The start-ost value must be part of the pool or an error is returned. @@ -495,7 +523,7 @@ lfs help - quota [-q] [-v] [-o obd_uuid|-i mdt_idx|-I ost_idx] [-u|-g <uname>|<uid>|<gname>|<gid>] <filesystem> + quota [-q] [-v] [-o obd_uuid|-i mdt_idx|-I ost_idx] [-u|-g uname|uid|gname|gid] /mount_point   @@ -504,7 +532,7 @@ lfs help - quota -t <-u|-g> <filesystem> + quota -t -u|-g /mount_point Displays block and inode grace times for user (-u) or group (-g) quotas. @@ -520,7 +548,7 @@ lfs help - quotacheck [-ugf] <filesystem> + quotacheck [-ugf] /mount_point Scans the specified file system for disk usage, and creates or updates quota files. Options specify quota for users (-u), groups (-g), and force (-f). @@ -528,7 +556,7 @@ lfs help - quotaon [-ugf] <filesystem> + quotaon [-ugf] /mount_point Turns on file system quotas. Options specify quota for users (-u), groups (-g), and force (-f). @@ -536,7 +564,7 @@ lfs help - quotaoff [-ugf] <filesystem> + quotaoff [-ugf] /mount_point Turns off file system quotas. Options specify quota for users (-u), groups (-g), and force (-f). @@ -544,7 +572,7 @@ lfs help - quotainv [-ug] [-f] <filesystem> + quotainv [-ug] [-f] /mount_point Clears quota files (administrative quota files if used without -f, operational quota files otherwise), all of their quota entries for users (-u) or groups (-g). After running quotainv, you must run quotacheck before using quotas. @@ -555,17 +583,18 @@ lfs help - setquota <-u|-g> <uname>|<uid>|<gname>|<gid> [--block-softlimit <block-softlimit>] [--block-hardlimit <block-hardlimit>] [--inode-softlimit <inode-softlimit>] [--inode-hardlimit <inode-hardlimit>] <filesystem> + setquota -u|-g uname|uid|gname|gid} [--block-softlimit block_softlimit] [--block-hardlimit block_hardlimit] [--inode-softlimit inode_softlimit] [--inode-hardlimit inode_hardlimit] /mount_point Sets file system quotas for users or groups. Limits can be specified with --{block|inode}-{softlimit|hardlimit} or their short equivalents -b, -B, -i, -I. Users can set 1, 2, 3 or 4 limits. - The old setquota interface is supported, but it may be removed in a future Lustre release. + The old setquota interface is supported, but it may be + removed in a future Lustre software release. Also, limits can be specified with special suffixes, -b, -k, -m, -g, -t, and -p to indicate units of 1, 2^10, 2^20, 2^30, 2^40 and 2^50, respectively. By default, the block limits unit is 1 kilobyte (1,024), and block limits are always kilobyte-grained (even if specified in bytes). See . - setquota -t <-u|-g> [--block-grace <block-grace>] [--inode-grace <inode-grace>] <filesystem> + setquota -t -u|-g [--block-grace block_grace] [--inode-grace inode_grace] /mount_point Sets the file system quota grace times for users or groups. Grace time is specified in 'XXwXXdXXhXXmXXs' format or as an integer seconds value. See . @@ -599,7 +628,7 @@ lfs help $ lfs setstripe -d /mnt/lustre/dir Lists the detailed object allocation of a given file. $ lfs getstripe -v /mnt/lustre/file1 - List all the mounted lustre filesystems and corresponding Lustre instances. + List all the mounted Lustre file systems and corresponding Lustre instances. $ lfs getname Efficiently lists all files in a given directory and its subdirectories. $ lfs find /mnt/lustre @@ -614,10 +643,10 @@ lfs help Lists inode usage per OST and MDT. $ lfs df -i List space or inode usage for a specific OST pool. - $ lfs df --pool <filesystem>[.<pool>] | <pathname> + $ lfs df --pool filesystem[.pool] | pathname List quotas of user 'bob'. $ lfs quota -u bob /mnt/lustre - Show grace times for user quotas on /mnt/lustre. + Show grace times for user quotas on /mnt/lustre. $ lfs quota -t -u /mnt/lustre Changes file owner and group. $ lfs quotachown -i /mnt/lustre @@ -660,7 +689,7 @@ lfs help The lfs_migrate utility is a simple tool to migrate files between Lustre OSTs.
Synopsis - lfs_migrate [-c|-s] [-h] [-l] [-n] [-y] [file|directory ...] + lfs_migrate [-c stripecount] [-h] [-l] [-n] [-q] [-R] [-s] [-y] [file|directory ...]
Description @@ -689,26 +718,21 @@ lfs help - -c + + -c stripecount - Compares file data after migrate (default value, use -s to disable). + Restripe file using the specified stripe count. This option may not be + specified at the same time as the -R option. - -s + + -h - Skips file data comparison after migrate (use -c to enable). - - - - - -h - - - Displays help information. + Display help information. @@ -716,7 +740,9 @@ lfs help -l - Migrates files with hard links (skips, by default). Files with multiple hard links are split into multiple separate files by lfs_migrate, so they are skipped, by default, to avoid breaking the hard links. + Migrate files with hard links (skips, by default). Files with multiple hard + links are split into multiple separate files by lfs_migrate, so + they are skipped, by default, to avoid breaking the hard links. @@ -724,7 +750,7 @@ lfs help -n - Only prints the names of files to be migrated. + Only print the names of files to be migrated. @@ -732,15 +758,29 @@ lfs help -q - Runs quietly (does not print filenames or status). + Run quietly (does not print filenames or status). + -R + Restripe file using default directory striping instead of keeping striping. + This option may not be specified at the same time as the -c + option. + + + + -s + Skip file data comparison after migrate. Default is to compare migrated file + against original to verify correctness. + + - --y + + -y - Answers 'y' to usage warning without prompting (for scripts). + Answer 'y' to usage warning without prompting + (for scripts, use with caution). @@ -759,117 +799,6 @@ lfs help
-
- <indexterm><primary>lfsck</primary></indexterm> - <literal>lfsck</literal> - - lfsck ensures that objects are not referenced by multiple MDS files, that there are no orphan objects on the OSTs (objects that do not have any file on the MDS which references them), and that all of the objects referenced by the MDS exist. Under normal circumstances, Lustre maintains such coherency by distributed logging mechanisms, but under exceptional circumstances that may fail (e.g. disk failure, file system corruption leading to e2fsck repair). To avoid lengthy downtime, you can also run lfsck once Lustre is already started. - The e2fsck utility is run on each of the local MDS and OST device file systems and verifies that the underlying ldiskfs is consistent. After e2fsck is run, lfsck does distributed coherency checking for the Lustre file system. In most cases, e2fsck is sufficient to repair any file system issues and lfsck is not required. -
- Synopsis - lfsck [-c|--create] [-d|--delete] [-f|--force] [-h|--help] [-l|--lostfound] [-n|--nofix] [-v|--verbose] --mdsdb mds_database_file --ostdb ost1_database_file [ost2_database_file...] <filesystem> - - - As shown, the <filesystem> parameter refers to the Lustre file system mount point. The default mount point is /mnt/lustre. - - - For lfsck, database filenames must be provided as absolute pathnames. Relative paths do not work, the databases cannot be properly opened. - -
-
- Options - The options and descriptions for the lfsck command are listed below. - - - - - - - - Option - - - Description - - - - - - - -c - - - Creates (empty) missing OST objects referenced by MDS inodes. - - - - - -d - - - Deletes orphaned objects from the file system. Since objects on the OST are often only one of several stripes of a file, it can be difficult to compile multiple objects together in a single, usable file. - - - - - -h - - - Prints a brief help message. - - - - - -l - - - Puts orphaned objects into a lost+found directory in the root of the file system. - - - - - -n - - - Does not repair the file system, just performs a read-only check (default). - - - - - -v - - - Verbose operation - more verbosity by specifying the option multiple times. - - - - - --mdsdb - mds_database_file - - - MDS database file created by running e2fsck --mdsdb mds_database_file <device> on the MDS backing device. This is required. - - - - - --ostdb ost1_database_file - [ost2_database_file...] - - - OST database files created by running e2fsck --ostdb ost_database_file <device> on each of the OST backing devices. These are required unless an OST is unavailable, in which case all objects thereon are considered missing. - - - - - -
-
- Description - The lfsck utility is used to check and repair the distributed coherency of a Lustre file system. If an MDS or an OST becomes corrupt, run a distributed check on the file system to determine what sort of problems exist. Use lfsck to correct any defects found. - For more information on using e2fsck and lfsck, including examples, see (Commit on Share). For information on resolving orphaned objects, see (Working with Orphaned Objects). -
-
<indexterm><primary>filefrag</primary></indexterm> <literal>filefrag</literal> @@ -883,11 +812,15 @@ lfs help <title>Description The filefrag utility reports the extent of fragmentation in a given file. Initially, filefrag attempts to obtain extent information using FIEMAP ioctl, which is efficient and fast. If FIEMAP is not supported, then filefrag uses FIBMAP. - Lustre only supports FIEMAP ioctl. FIBMAP ioctl is not supported. + The Lustre software only supports FIEMAP ioctl. FIBMAP + ioctl is not supported. In default mode The default mode is faster than the verbose/extent mode. - , filefrag returns the number of physically discontiguous extents in the file. In extent or verbose mode, each extent is printed with details. For Lustre, the extents are printed in device offset order, not logical offset order. + , filefrag returns the number of physically discontiguous + extents in the file. In extent or verbose mode, each extent is printed with details. For a + Lustre file system, the extents are printed in device offset order, not logical offset + order.
Options @@ -912,7 +845,8 @@ lfs help -b - Uses the 1024-byte blocksize for the output. By default, this blocksize is used by Lustre, since OSTs may use different block sizes. + Uses the 1024-byte blocksize for the output. By default, this blocksize is + used by the Lustre file system, since OSTs may use different block sizes. @@ -976,7 +910,10 @@ ext: device_logical: start..end physical: <indexterm><primary>mount</primary></indexterm> <literal>mount</literal> - Lustre uses the standard mount(8) Linux command. When mounting a Lustre file system, mount(8) executes the /sbin/mount.lustre command to complete the mount. The mount command supports these Lustre-specific options: + The standard mount(8) Linux command is used to mount a Lustre file + system. When mounting a Lustre file system, mount(8) executes the + /sbin/mount.lustre command to complete the mount. The mount command + supports these options specific to a Lustre file system: @@ -1010,12 +947,28 @@ ext: device_logical: start..end physical: + nomgs + + + Start a MDT with a co-located MGS without starting the MGS + + + + exclude Starts with a dead OST + + + md_stripe_cache_size + + + Sets the stripe cache size for server side disk with a striped raid configuration + + @@ -1036,10 +989,10 @@ ext: device_logical: start..end physical: - flock + flock/noflock/localflock - Enables/disables flock support + Enables/disables global flock or local flock support @@ -1052,6 +1005,14 @@ ext: device_logical: start..end physical: + user_fid2path/nouser_fid2path + + + Enables/disables FID to path translation by regular users + + + + retry=