Changing root user into root role

Last published : Sep 18, 2026
On Oracle Solaris 11, you need to create root user to perform installation. 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
  1. 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.