Go to main content

Managing User Accounts and User Environments in Oracle® Solaris 11.4

Exit Print View

Updated: August 2021

How to Modify a User Account

The usermod command is used to change the definition of a user's login and make appropriate login-related file system changes for the user.

  1. Become an administrator or a user with the User Management rights profile.

    See Using Your Assigned Administrative Rights in Securing Users and Processes in Oracle Solaris 11.4.

  2. Modify the user account, as required.

    For example, to add a role to a user, you would type:

    # usermod -R role username

    See the usermod(8) man page for details about the arguments and options that you can specify with the usermod command.

Example 1  Setting Per-User PAM Policy by Modifying a User's Account

This example shows how to modify a user to set PAM policy. This particular modification specifies that user jdoe should only be authenticated with the Kerberos V5 protocol for all PAM services. For more information, see the pam_user_policy(7) man page.

# usermod -K pam_policy=krb5_only jdoe

See Also

For additional information, see Creating a Role in Securing Users and Processes in Oracle Solaris 11.4.