X-Git-Url: https://git.whamcloud.com/?a=blobdiff_plain;f=lustre%2Futils%2Fobd.c;h=416c4df2e106b642efc0ee9e80aa535d9c0a7bc6;hb=8a770616a5;hp=6775a415ff63d1c5edfd0db5a1f18fed679d2894;hpb=bbfdc7c1670c92747a8f98d39e1e43dc39e59e30;p=fs%2Flustre-release.git diff --git a/lustre/utils/obd.c b/lustre/utils/obd.c index 6775a41..416c4df 100644 --- a/lustre/utils/obd.c +++ b/lustre/utils/obd.c @@ -4487,7 +4487,7 @@ int jt_nodemap_modify(int argc, char **argv) fprintf(stderr, "usage: nodemap_modify --name --property --value \n"); fprintf(stderr, - "valid properties: admin trusted map_mode squash_uid squash_gid deny_unknown audit_mode forbid_encryption\n"); + "valid properties: admin trusted map_mode squash_uid squash_gid squash_projid deny_unknown audit_mode forbid_encryption\n"); return -1; } @@ -4501,6 +4501,8 @@ int jt_nodemap_modify(int argc, char **argv) cmd = LCFG_NODEMAP_SQUASH_UID; } else if (strcmp("squash_gid", param) == 0) { cmd = LCFG_NODEMAP_SQUASH_GID; + } else if (strcmp("squash_projid", param) == 0) { + cmd = LCFG_NODEMAP_SQUASH_PROJID; } else if (strcmp("map_mode", param) == 0) { cmd = LCFG_NODEMAP_MAP_MODE; } else if (strcmp("audit_mode", param) == 0) { @@ -4558,7 +4560,7 @@ int jt_nodemap_add_idmap(int argc, char **argv) if (!nodemap_name || !idmap || !idtype) { fprintf(stderr, - "usage: %s --name --idtype [uid | gid] --idmap :\n", + "usage: %s --name --idtype [uid | gid | projid] --idmap :\n", argv[0]); return -1; } @@ -4567,9 +4569,11 @@ int jt_nodemap_add_idmap(int argc, char **argv) cmd = LCFG_NODEMAP_ADD_UIDMAP; } else if (strcmp("gid", idtype) == 0) { cmd = LCFG_NODEMAP_ADD_GIDMAP; + } else if (strcmp("projid", idtype) == 0) { + cmd = LCFG_NODEMAP_ADD_PROJIDMAP; } else { fprintf(stderr, - "usage: %s --name --idtype [uid | gid] --idmap :\n", + "usage: %s --name --idtype [uid | gid | projid] --idmap :\n", argv[0]); return -1; } @@ -4617,15 +4621,23 @@ int jt_nodemap_del_idmap(int argc, char **argv) if (!nodemap_name || !idmap || !idtype) { fprintf(stderr, - "usage: %s --name --idtype [uid | gid] --idmap :\n", + "usage: %s --name --idtype [uid | gid | projid] --idmap :\n", argv[0]); return -1; } - if (strcmp("uid", idtype) == 0) + if (strcmp("uid", idtype) == 0) { cmd = LCFG_NODEMAP_DEL_UIDMAP; - else + } else if (strcmp("gid", idtype) == 0) { cmd = LCFG_NODEMAP_DEL_GIDMAP; + } else if (strcmp("projid", idtype) == 0) { + cmd = LCFG_NODEMAP_DEL_PROJIDMAP; + } else { + fprintf(stderr, + "usage: %s --name --idtype [uid | gid | projid] --idmap :\n", + argv[0]); + return -1; + } rc = nodemap_cmd(cmd, NULL, 0, argv[0], nodemap_name, idmap, NULL); if (rc != 0) {