LCTL-NODEMAP_FILESET_MODIFY(8)

NAME
lctl-nodemap_fileset_modify - modifies an existing fileset of a nodemap

SYNOPSIS
lctl nodemap_fileset_modify --name NODEMAP_NAME --fileset SUBDIRECTORY [--rename|-r NEW_SUBDIRECTORY] [--primary|-p] [--alt|-a] [--rw] [--ro]

DESCRIPTION
nodemap_fileset_modify modifies the properties of an existing fileset within a nodemap. The fileset is identified by its SUBDIRECTORY path within the nodemap specified by its NODEMAP_NAME. Modifying a fileset can target the fileset's path, its type (primary or alternate), and its access permissions (read-write or read-only). This command cannot move filesets between nodemaps. The --name and --fileset options are mandatory.

nodemap_fileset_modify can be used with dynamic nodemaps. However, filesets in dynamic nodemaps cannot be modified to escape the namespace restrictions imposed by any fileset set on the parent's nodemap. Further, read-only filesets on the parent nodemap cannot become read-write on the child nodemap. If the parent nodemap has no fileset defined, the child nodemap can freely modify any fileset.

OPTIONS

-n, --name NODEMAP_NAME
    Specifies the nodemap containing the fileset to modify.

-f, --fileset SUBDIRECTORY
    Specifies the path of the fileset to modify.

-r, --rename NEW_SUBDIRECTORY
    Changes the fileset's path to the specified new subdirectory. The new path must begin with a slash ('/') and cannot yet exist as a fileset of that type on the same nodemap.

-p, --primary
    Converts the fileset to a primary fileset. The flag has no effect if the fileset is already primary. Note that --primary can only convert an alternate fileset to primary if there is currently no primary fileset set on the nodemap. This flag is mutually exclusive with --alt option.

-a, --alt
    Converts the fileset to an alternate fileset. The flag has no effect if the fileset is already alternate. This flag is mutually exclusive with --primary option.

--rw
    Sets the fileset to read-write access mode. The flag has no effect if the fileset is already set to read-write. This flag is mutually exclusive with --ro option.

--ro
    Sets the fileset to read-only access mode which is enforced when the fileset applies for a given SUBDIRECTORY at mount time. The flag has no effect if the fileset is already set to read-only. This flag is mutually exclusive with --rw option.

EXAMPLES
Rename a fileset. A fileset is unique, therefore the name suffices:
    # lctl nodemap_fileset_modify --name tenant1 --fileset '/dir1' --rename '/dir2'

Convert a primary fileset into an alternate fileset and vice versa:
    # lctl nodemap_fileset_modify --name tenant1 --fileset '/dir1' --alt
    # lctl nodemap_fileset_modify --name tenant1 --fileset '/dir1' --primary

Change the access mode of a fileset to read-only and back to read-write:
    # lctl nodemap_fileset_modify --name tenant1 --fileset '/dir1' --ro
    # lctl nodemap_fileset_modify --name tenant1 --fileset '/dir1' --rw

Combine all options to change a fileset's path, type, and access mode. Rename a primary fileset '/dir1' to '/dir2', convert it to an alternate fileset, and set it to read-only:
    # lctl nodemap_fileset_modify --name tenant1 --fileset '/dir1' --rename '/dir2' --alt --ro

AVAILABILITY
lctl nodemap_fileset_modify is part of the lustre(7) filesystem package since release 2.17.0.

SEE ALSO
lustre(7), lctl-nodemap-fileset-add(8), lctl-nodemap-fileset-del(8) lctl-nodemap-new(8),