No relevant resource is found in the selected language.

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Read our privacy policy>Search

Reminder

To have a better experience, please upgrade your IE browser.

upgrade

Command Reference for Block

OceanStor Dorado V3 Series V300R002

This document is applicable to OceanStor Dorado3000 V3, Dorado5000 V3, Dorado6000 V3 and Dorado18000 V3. Based on the CLI provided by the DeviceManager, this document describes how to use various commands classified by functions and how to set the CLI and manage the storage system through these commands.
Rate and give feedback:
Huawei uses machine translation combined with human proofreading to translate this document to different languages in order to help you better understand the content of this document. Note: Even the most advanced machine translation cannot match the quality of professional translators. Huawei shall not bear any responsibility for translation accuracy and it is recommended that you refer to the English document (a link for which has been provided).
change user

change user

Function

The change user command is used to operate users, including resetting users' login passwords, changing user levels, changing user role IDs, forcing users offline, modifying user login method and setting a specified user's password to never expire.

Format

change user user_name=? { { level=? | role_id=? } * | action=? | login_method_list=? | password_never_expire=? }

Parameters

Parameter

Description

Value

user_name=?

User name.

To obtain the value, run "show user".

level=?

New user level.

The value can be "admin" or "guest", where:

  • "admin": administrator.
  • "guest": read-only user.

action=?

Operation on the user.

The value can be "reset_password" or "offline", where:

  • "reset_password": A user's password will be reset.
  • "offline": A user will be forced offline.
  • "change_password_next_login": The user must change its password upon next login.

role_id=?

New user role ID.

In the system view, you can run the "show role system" command to obtain the system group role.

login_method_list=?

Valid login method set for a system user.

The value can be one or multiple of "SFTP", "CLI", "Serial", "DeviceManager", and "RESTful", where multiple values are separated by commas (,).

password_never_expire=?

Whether a user password is set to never expire. If this parameter is set to "yes", the password does not expire. If this parameter is set to "no", the password expiration check is performed based on the system security policy.

The value is "yes" or "no", where:

  • "yes": A password never expires.
  • "no": The setting of a password to never expire is cancelled.

Level

Super administrator

Usage Guidelines

  • Run the "change user user_name=? level=?" command to specify a user's level. This command can only be used to change the levels of administrators and read-only users.
  • Run the "change user user_name=? role_id=?" command to specify a user's role ID. This command can only be used to change the role IDs of administrators and read-only users.
  • Run the "change user user_name=? level=? role_id=?" command to specify a user's level and role ID. This command can only be used to change the levels and the role IDs of administrators and read-only users.
  • Run the "change user user_name=? action=reset_password" command to reset users' login password. This command can only be used to reset the passwords of administrators and read-only users. If the password of a user is entered incorrectly for three consecutive times within five minutes, the user is forced to log out.
  • Run the "change user user_name=? action=offline" command to force a specific user offline. This command can only be used to force administrators and read-only users offline.
  • Run the "change user user_name=? action=change_password_next_login" command to enable a specified user to change its password upon next login. This command can only be used to enable administrators and read-only users to change their passwords upon next login.
  • Run the "change user user_name=? login_method_list=?" command to set a valid login method for a system user.
  • Run the "change user user_name=? password_never_expire=yes" command to set a specified user's password to never expire.

Example

  • Change the level of "testuser" to read-only and the role ID of "testuser" to "6".
    admin:/>change user user_name=testuser level=guest role_id=6 
    WARNING: You are about to change the user level or role ID. This operation will change the user's operation permission. 
    Suggestion: Before performing this operation, ensure that the selected user level or role ID is correct. 
    Have you read warning message carefully?(y/n)y 
    Are you sure you really want to perform the operation?(y/n)y 
    Command executed successfully.
  • Reset the login password of "testuser".
    admin:/>change user user_name=testuser action=reset_password 
    New password:********** 
    Reenter password:********** 
    Password:********** 
    Command executed successfully.
  • Force "testuser" offline.
    admin:/>change user user_name=testuser action=offline 
    DANGER: You are about to log off the selected user. After this operation, the user can no longer manage the device unless relogs in to the device. 
    Suggestion: Before performing this operation, learn about the impact of this operation on the user. 
    Have you read danger alert message carefully?(y/n)y 
    Are you sure you really want to perform the operation?(y/n)y 
    Command executed successfully.
  • Run the "show user user_name=?" command to query the operation result.
    admin:/>show user user_name=testuser  
    Name Level Status Type Lock Status Create Time Domain User Group  
    -------- ----- ------- ----- ----------- ----------------------------- -----------------  
    testuser Guest Offline Local Unlocked 2015-07-29/16:37:30 UTC+08:00 --
  • Enable "testuser" to change its password upon next login.
    admin:/>change user user_name=testuser action=change_password_next_login 
    WARNING: You are about to set changing the password at the next login. The user must change the password upon the next login. 
    Suggestion: Before performing this operation, learn about the impact of this operation on the user. 
    Have you read warning message carefully?(y/n)y 
    Are you sure you really want to perform the operation?(y/n)y 
    Command executed successfully.
  • Set the login method of "testuser" to "CLI" and "SFTP".
    change user user_name=testuser login_method_list=CLI,SFTP 
    DANGER: You are about to modify the account login method list. 
    This operation will cause the account to fail to log in to the storage array in methods not recorded in the list. 
    Suggestion: Before performing this operation, ensure that the login method configuration is correct. 
    Have you read danger alert message carefully?(y/n)y 
    Are you sure you really want to perform the operation?(y/n)y 
    Command executed successfully.
  • Set the password of "testuser" to never expire.
    admin:/>change user user_name=testuser password_never_expire=yes 
    Command executed successfully.

System Response

None

Translation
Download
Updated: 2019-07-16

Document ID: EDOC1100049140

Views: 124262

Downloads: 155

Average rating:
This Document Applies to these Products
Related Documents
Related Version
Share
Previous Next