Page 1 of 1

CentOS 7- Root account getting locked

Posted: 2021/09/06 04:21:46
by samuelraj
Hi All,

I am facing a strange issue on my CentOS VM which is hosted on Google Cloud. The root account getting locked whenever the servers are rebooted after some time. I checked the root user password config. It seems to be ok.

Please refer to the attached.

Is there anyone facing a similar issue?

Re: CentOS 7- Root account getting locked

Posted: 2021/09/06 17:30:44
by TrevorH
Nothing attached.

Never used google cloud but some providers disable root and make you use a non-root userid that then has full sudo ability.

Re: CentOS 7- Root account getting locked

Posted: 2021/09/08 09:04:40
by samuelraj
Thanks for your reply TrevorH.

My apologies, I have attached the root user password policy.
root_password_policy.png
root_password_policy.png (16.02 KiB) Viewed 684 times

Re: CentOS 7- Root account getting locked

Posted: 2021/09/08 12:26:33
by jlehtone
Is the "lock" really in passwd/shadow, or is it in sshd config, PAM access, etc?

Re: CentOS 7- Root account getting locked

Posted: 2021/09/08 12:34:00
by TrevorH
As I said, I would suspect this is policy at GCP. Check in /etc/cloud/cloud.cfg and see if it contains e.g. "disable_root: 1"