Unable to login with Root user PAM: User account has expired in Solaris

When i try to login to root user after installation using putty, i face some authentication error even though i give correct password.

When i checked the shadow file i can see some alphanumeric code in root entry like this

root@solaris:/# cat /etc/shadow |grep root

After sometime i searched over internet and find a solution to modify the shadow file only for root entry which was still not working


I got the below error

-bash-4.4$ su - root
Roles can only be assumed by authorized users
su: Permission denied


PAM: User account has expired

Then i checked /etc/user_attr file and found that root user was considered as a role but not a normal user

root@solaris:/# cat /etc/user_attr
# Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
# The system provided entries are stored in different files
# under "/etc/user_attr.d".  They should not be copied to this file.
# Only local changes should be stored in this file.

So i directly logged in to administrator account and modified the type from role to normal and it worked fine

-bash-4.4$ su - root
Oracle Corporation      SunOS 5.11      11.4    Aug 2018

Leave a Reply