Solution for passwd: Module is unknown issue in ubuntu

I have a AWS instance with Ubuntu installed.

When I add a new user, or try to change the password, I got the following error.

# passwd
passwd: Module is unknown
passwd: password unchanged

 

Let us check the auth.log for any issues.

root@ip-172-31-9-242:~# tail -n 2 /var/log/auth.log
Jun  3 14:06:01 ip-172-31-9-242 CRON[31435]: pam_unix(cron:session): session closed for user root
Jun  3 14:08:01 ip-172-31-9-242 CRON[31490]: PAM unable to dlopen(pam_cracklib.so): /lib/security/pam_cracklib.so: cannot open shared object file: No such file or directory

 

It means that it misses the pam_cracklib. Let us search for it.

root@ip-172-31-9-242:~# apt-cache search pam | grep crack
libpam-cracklib – PAM module to enable cracklib support

 

Good. Let us try installing it.

root@ip-172-31-9-242:~# apt-get install libpam-cracklib

Let us try now to change the password.

 

Great. It works now.

 

Lesson : Look for the log files, before googling.

 

3 thoughts on “Solution for passwd: Module is unknown issue in ubuntu

  1. Nice post, i like it. I read your blog fairly often and i love what you write.
    I shared this on my facebook fan page and my followers love it.

    Good work!

Leave a comment