Password changing error: passwd: User not known to the underlying authentication module
Issue
Regular non-root user is not able to change password.
-
When regular user is changing password, error
passwd: User not known to the underlying authentication module
is returned:[bob@server ~]$ passwd Changing password for user bob. Current password: New password: Retype new password: passwd: User not known to the underlying authentication module
-
root is able to change the user's password:
[root@server ~]# passwd bob Changing password for user bob. New password: Retype new password: passwd: all authentication tokens updated successfully.
-
Both
passwd
andshadow
have correct file ownership/permission and SELinux file label:# ls -alZ passwd shadow -rw-r--r--. 1 root root system_u:object_r:passwd_file_t:s0 1575 Oct 30 19:35 passwd ----------. 1 root root system_u:object_r:shadow_t:s0 911 Oct 30 20:55 shadow # lsattr passwd shadow -------------------- passwd -------------------- shadow
-
The user is a local user with valid entry in
/etc/passwd
and/etc/shadow
:# cat /etc/passwd | grep bob bob:x:1002:1002::/home/bob:/bin/bash # cat /etc/shadow | grep bob bob:$6$V5wHc/NmRGVX.QPB$BaY<...>:19296:1:30:7:30::
Environment
- Red Hat Enterprise Linux 7
- Red Hat Enterprise Linux 8
- Red Hat Enterprise Linux 9
- passwd
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.