"passwd: Module is unknown" error when attempting to change the root or vcf user password in SDDC manager
search cancel

"passwd: Module is unknown" error when attempting to change the root or vcf user password in SDDC manager

book

Article ID: 440957

calendar_today

Updated On:

Products

VMware SDDC Manager / VCF Installer

Issue/Introduction

  • Failed to change the root or vcf user password through the SDDC Manager's CLI
  • Changing the password using GRUB mode also fails with the following error.

Environment

VMware Cloud Foundation 4.5

Cause

The password reset issue was caused by a misconfiguration in the /etc/pam.d/system-password file which was either absent or incorrectly set up. This resulted in the failure of the password change command.

Resolution

Perform the following steps to reset the ownership, permissions, and content of the /etc/pam.d/system-password file.

  1. Take a snapshot of the SDDC manager appliance
  2. Make a backup of the /etc/pam.d/system-password file:
    • cp /etc/pam.d/system-password /home/vcf/
  3. Replace the contents of the file with the following content. The file should look exactly like the below content including the actual order of the lines:
    • # Begin /etc/pam.d/system-password
      
      # use sha512 hash for encryption, use shadow, and try to use any previously
      # defined authentication token (chosen password) set by any prior module
      password   requisite pam_cracklib.so ucredit=-1 lcredit=-1 dcredit=-1 difok=4 minlen=8 ocredit=-1 enforce_for_root
      password   requisite pam_pwhistory.so enforce_for_root use_authtok retry=3 remember=5
      password   required pam_unix.so sha512 shadow try_first_pass
      
      # End /etc/pam.d/system-password
  4. Run the following command to set the correct ownership and permissions:
    • chown root:root /etc/pam.d/system-password && chmod 644 /etc/pam.d/system-password
  5. Reboot the SDDC manager
  6. Perform the reset of the passwords
    • passwd vcf
    • passwd root