what to do if lost password

Top Page
Attachments:
Message as email
+ (text/plain)
+ (text/html)
+ (text/plain)
Delete this message
Reply to this message
Author: Michael Havens
Date:  
To: PLUG
Subject: what to do if lost password
I got a friend upon whose computer (old XP) I installed Linux. She called
me last night because she forgot the password. Well, I asked the Florida
user group about what to do and this is what they had to say:


Just use GRUB to boot into single user mode / recovery mode.

Append *init=/bin/sh* to the kernel command line, then mount the root
filesystem (if it isn't already done for you) and run *passwd *to reset the
root password or *password user *to reset user's password.


http://www.debuntu.org/how-to-recover-root-password-under-linux-with-single-user-mode/
I'd bring a CD containing System Rescue CD just in case.

http://www.sysresccd.org/SystemRescueCd_Homepage

By the way, you can bust back into borked VMs with System Rescue CD ISO
files, too.

By the way, if you use System Rescue CD, do something like this,
assuming her / is the mountpoint for /dev/sda1:

mount /dev/sda1 /mnt
chroot /mnt/ bash
cd /etc
vi passwd

Now delete the x between the first and second colons, for both user
root and her ordinary username, then quit vi

exit
umount /mnt
reboot

Now, when asked for her password, leave it blank and she'll get in.
Then she can change her password as desired. Same thing's true the
first time she logs in as root.

If she's not trustworthy enough to leave with blank passwords, you
could probably use the passwd program after the chroot to change the
passwords.
:-)~MIKE~(-:
---------------------------------------------------
PLUG-discuss mailing list -
To subscribe, unsubscribe, or to change your mail settings:
http://lists.phxlinux.org/mailman/listinfo/plug-discuss