Oracle Linux - Unable to "su" to non-root user
Applies to
Linux x86_64 on Oracle Public Cloud
Symptoms
Unable to "su - user" from the "opc" user account, getting error message as below:
[opc@instance] su - user
Password:
su: Authentication failure
The "user" can login to the instance using the password created for the user, so the password is correct.
Cause
Incorrect permissions on /bin/su
# ls -l /bin/su
-rwxr-xr-x. 1 root root 50160 Jan 12 2023 /bin/su
# rpm -V util-linux
.M....... /usr/bin/su
The “M” indicates that the permissions have been changed.
Solution
The su command is part of the util-linux package, the correct permissions can be set using the following command: