Changing root user into root role

On Oracle Solaris 11, to perform installation, you need to create root user. This means that a local user cannot assume the root role. After installation, you may want to turn root user into root role for a local user, who can log in as root.

  1. Log in as root user.

  2. Change the root account into role:

    # rolemod -K type=role root
    # getent user_attr root
    root::::type=role;auths=solaris.*;profiles=All;audit_flags=lo\
    :no;lock_after_retries=no;min_label=admin_low;clearance=admin_high
  3. Assign the root role to a local user who was unassigned the role:

    # usermod -R root admin

For more information, see the Oracle documentation on Oracle Solaris 11 operating system.