Tuesday, March 26, 2013

How to reset Windows 7 user password

The instructions here work really well. But assuming you don't have a Windows setup disc on hand, you'll need to make do with other tools. Here's where the Ubuntu LiveCD comes in handy.

You'll need to boot into a LiveCD session, then mount the Windows partition. The below steps assume it's mounted at /mnt/sda1. Change it accordingly.

~$ cd /mnt/sda1/Windows/System32
~$ mv sethc.exe sethc.exe_backup
~$ cp cmd.exe sethc.exe

Reboot to Windows this time.

At the login screen press Shift 5 times to invoke a administrator command prompt. Now you can change the password you forgot to something new.

:\> net user username password

Replace username with your login name and password with the new password. You can even do this:

:\> net user username *

The press Enter twice to set a blank password. You should now be able to login to Windows.

Remember to restore sethc.exe back to the original once you're done.

Related posts:

Reset your Windows password with SystemRescueCD
How to activate a locked Windows Administrator account