Forgotten Passwords

From Info Wiki
Revision as of 22:37, 12 September 2016 by Rpeters (talk | contribs) (added password change procedures)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

User Passwords

User passwords can be reset as follows:

  1. log in as "root"
  2. switch to user account, eg for user "fred"
  3. # su fred
  4. execute password command to change password for user "fred"

$ passwd

Root Password

Root password can be reset only via booting another Linux on the same computer - either:

  • another installed Linux
  • a utility USB/CD booted on the computer - these generally run from the root account
  1. mount the partition containing the root filesystem of the installation for which password reset is required - eg for /dev/sda10
  2. # mount /dev/sda10 /mnt
  3. change to the mounted partition
  4. # chroot /mnt
  5. execute password command to change password for user "fred"
  6. $ passwd