acerole validate
Verifies given user roles for ACEs exists in the
/opt/mapr/conf/m7_permissions_roles_refimpl.conf
file.
This command returns true
if role exists in the
/opt/mapr/conf/m7_permissions_roles_refimpl.conf
file and
false
if given role is not in the file. If the
MAPR_ROLES_LIB_ENABLE_TRACE
environment variable is set to
TRUE
, the command returns also the number of users assigned to the
specified role and the number of roles in the file.
Syntax
- CLI
-
maprcli acerole validate -role role which need to be validate
- REST
-
Request Type GET Request URL http[s]://<host:port>/rest/acerole/validate?<parameters>
Parameters
Parameter |
Description |
---|---|
|
(Required) The role to validate. |
Examples
Verifies whether given role exists when the MAPR_ROLES_LIB_ENABLE_TRACE
environment variable is not set:
- CLI
-
maprcli acerole validate -role Role_1 maprcli acerole validate command returned : true
- REST
-
curl -X GET 'https://server.sj.us:8443/rest/acerole/validate?role=Role_1' --user <username>:<password>
Verifies whether given role exists when the MAPR_ROLES_LIB_ENABLE_TRACE
environment variable is set:
- CLI
-
export MAPR_ROLES_LIB_ENABLE_TRACE=TRUE echo $MAPR_ROLES_LIB_ENABLE_TRACE TRUE maprcli acerole validate -role Role_1 RoleMap: Added user 500 with role 'Role_1' RoleMap: Added user 1000 with role 'Role_1' RoleMap: found 2 users and 2 roles. maprcli acerole validate command returned : true
- REST
-
export MAPR_ROLES_LIB_ENABLE_TRACE=TRUE echo $MAPR_ROLES_LIB_ENABLE_TRACE TRUE curl -X GET 'https://abc.sj.us:8443/rest/acerole/validate?role=Role_1' --user <username>:<password>