LFS-PROJECT(1)

NAME
lfs-project - Change or list project attribute for specified file or directory.

SYNOPSIS
lfs project [-d|-r] <file|directory...>
lfs project {-p ID |-s} [-r] <file|directory...>
lfs project -c [-d|-r [-p ID] [-0]] <file|directory...>
lfs project -C [-d|-r] [-k] <file|directory...>

DESCRIPTION

lfs project [-d|-r]
    <file|directory...>

List project ID and flags on file(s) or directories.

-d  Show the directory's own project ID and flags, override -r option.

-r  Recursively list all descendants'(of the directory) project attribute.

lfs project {-p ID |-s} [-r]
    <file|directory...>

Set project ID and/or inherit flag for specified file(s) or directories.

-p <ID>
    Set project ID with given value for the specified file or directory

-s  Set the PROJID_INHERIT attribute on directories, so that new files and subdirectories created therein will inherit the project ID and attribute from the parent.

-r  Set project ID with the directory's project ID for all its descendants (with -p specified). For descendant directories, also set inherit flag (if -s specified).

lfs project -c [-d|-r [-p ID] [-0]]
    <file|directory...>

Check project ID and flags on file(s) or directories, print outliers.

-c  Check project ID and inherit flag on specified file(s) or directory. If -p is not given, then use the project ID on the top-level directory , otherwise use the ID specified with -p. if checking a directory and or recursively, print only files that do not match.

-0  Print pathnames found by -c with a trailing NUL for use by 'xargs(1) -0'.

lfs project -C [-d|-r] [-k]
    <file|directory...>

Clear the project inherit flag and ID on the file(s) or directories

-C  Clear inherit attribute and reset project ID to 0 for file or directory.

-d  Clear only the directory itself.

-r  Clear the directory and all its descendants recursively.

    If neither -d nor -r is specified, clear the directory and its immediate children.

-k  Keep the project ID unchanged.

EXAMPLES

$ lfs project -srp 1000 /mnt/lustre/dir1
    set directory quota on /mnt/lustre/dir1, all descendants' project ID and inherit attribute are set.

$ lfs project -cr -p 1000 /mnt/lustre/dir1
    check directory /mnt/lustre/dir1, whether all files and directories ID are 1000, inherit attribute is properly set for all directories, print mismatch if any are found.

SEE ALSO
lfs(1) xargs(1)