Subscribe to How-To Geek

Change Your Forgotten Windows Password with the Linux System Rescue CD

So far in our series we’ve covered how to reset your Windows password with the Ultimate Boot CD, but if you are a little more technical you might want to simply use the excellent System Rescue CD, which is based on Linux.

Note that if you are using standard Windows encryption for your files, resetting the password will permanently disable access to those files. In that case you should crack the password, which is something we’ll cover in an upcoming article.

image

If you are an Ubuntu user and forgot your password, we’ve covered how to do that as well, either the easy way with the grub menu or alternately with the live cd.

Creating the System Rescue CD

Before you can do anything else, you’ll need to download a copy of the System Rescue CD and burn the ISO image to disc. For this task, I prefer the simple ImgBurn utility, but you are free to use whatever burning application you prefer instead.

If you are using ImgBurn, click the Write image file to disc button…

image

Click the File button near Source and then pick the ISO file, then click the Burn button near the bottom. That’s about all there is to it.

image 

Download the System Rescue CD from sysresccd.org

Resetting Your Password

Now that you have your boot CD, you’ll want to boot from it, which will take you to this very informative prompt, with some basic instructions on how to use the CD.

image

The first thing we’ll want to do is mount the hard drive, using this command. (Note that you might not need to use the –o force argument, it’s only really for when the system didn’t shut down correctly)

ntfs-3g /dev/sda1 /mnt/windows –o force

You can use the df –m command to verify that the drive has been mounted and that it’s the right drive. Note that it’s mounted on /mnt/windows at this point.

image

Now you’ll want to change directory into the Windows/System32/config directory inside of your windows installation. For mine, the full path was something like this, but it might be different on yours:

cd /mnt/windows/Windows/System32/config

Once you are in that directory, you should see that there is a SAM file, which is where we’ll want to change the passwords.

image

To change the password we’ll use the chntpw command, and it’s most useful to use the –l argument first to list out all the usernames in the file.

chntpw –l SAM

image

Now you can add the –u argument with your username, which will end up being something like this command, except you’ll want to replace geek with your username:

chntpw –u geek SAM

This will present you with a wizard type screen:

image

I’m going to assume that you want to set a new password, so just type “2″ at the prompt, add in your password, and remember to use the “y” key when prompted to save.

image

At this point your password has been changed, so you can issue the reboot command to restart the computer (should take the disc out of the drive)

image

And now you should be able to login with the new password:

image

Note that I tested this technique on both XP and Vista with good results.

The Geek is the founder of How-To Geek and a geek enthusiast. This article was written on 09/30/08 and tagged with: System Administration, Windows Vista

Daily Email Updates

You can get our how-to articles in your inbox each day for free. Just enter your name and email below:


Name:
Email:
Similar Articles Featured Wiki Articles
Latest Software Reviews Quick Linux Tips
Geek Arcade Popular Forum Threads

Comments (14)

  1. Mark

    Great tip, I use Ophcrack and it always works. Seems no one who I’ve helped with it uses very difficult passwords. If they did this would be a nice option.

  2. bassmadrigal

    Great info.

    But one thing I noticed in your article is that in your commands all the dashes showed weird characters (if it shows up here, – ). Not sure what caused it, but just figured I would give you a heads up.

  3. sul2005tan

    that is not work with me see photo

    http://i37.tinypic.com/2qc2vxi.gif

    my directory is

    C:\Windows\System32\config

    http://i34.tinypic.com/1z5i0zt.png

    please help me

  4. hdfghdfghdfgh

    try changing your directory to mnt/windows/WINDOWS/system32/config

    Trust me .. the case matters

  5. Night

    i am trying to do what you said i am haveing the same prob as that with the pics i tryed what the guy said under him with the caps but its still not working. i tryed that Ophcrack and it said could not found. its my girls computer she was mad and changed her pass and dose not know what it is now. any help would be good. thanx Night

  6. cindy

    I can’t find my windows config directory. I’ve tried every possible combination. Is there a way to search for this?

  7. fingerlicker

    For those who can’t find it, first make sure that you have correctly mounted the windows partition. This is quite likely where you’ve gone wrong. Your df command output should be similar to that shown in the article. Then, to search for the SAM file, or any other file, use these commands:
    cd /mnt/windows
    find . -iname ’sam*’ -print

  8. Password Genius

    The easiest way to get back into Windows is to use Windows Password Reset Pro.
    It has the best driver support, it automatically detects all versions of Windows.

    All you have to do is boot the disc and press one button to unlock any account.

  9. nick

    Than you for sharing such a solution, i don’t understand why they create operating systems that make your life difficult. I had stored the password by mistake in greek, and in the login screen i couldn’t change language to login!!! I tried everything but this straight forward method was really helpfull..

  10. Boris Bolgradov

    Thanks!

  11. SUREN

    hi i need help…my college gave me a acer laptop..with linux istalled of partially installed..i dont know…when i on the laptop its on dos promt..and i dont know how to load in to the system…and i wish to install xp on lt…it runs the cd…..and give me an error msg blue screen apear check ur harddisk or hdd controller…maybe damage or so on…and ask me to checkdisk/f…i cant run this too ad no c: apears on the dos promt…help me…im confused

    suren

  12. trobe

    Not working for me, XP pro don’t want the new password too, i think it’sn’t changed, i use the “-o force” switch too, maybe it’s because i use sp2 ?
    I try to unlock the account too, it works, but the password seem to don’t be changed when i reboot
    So i try blank password and then it’s work ! Maybe it’s because i use fr keyboard ?

    Thanks

  13. fiona

    You can create a new CD to reset your password, as following:

    ※.Login to a computer that can link to Internet. Download Windows Password Unlocker 4.0 and decompress it on that PC. Note that: there is a .ISO file. Burn the .ISO file to a CD.
    ※. Get out the newly created CD and insert it to the locked computer.
    ※. re-booted the locked computer and then followed the process of instructions. Just a few steps, the old password was removed.”’
    ※. Setting new password:
    Step one: Open the “Control Panel”
    Step two: Click the “User Account ”
    Step three: Select the account you wanna to set a new password.
    Step four: Click “changing Account ” and “set up password”, then fill out the form as listed. Click “Create Password”.
    Thus, you have a personal login ID and Password, any one has no right to login to your computer with out this info.

  14. danny

    There is a way to reset windows password without erasing anything.
    Follow the instructions:
    1.Free download the windows password reset 6.0 iso file :
    2.Burn it to a disk to create the boot disk, that simple.
    3.Configure your pc or laptop to boot in the cd drive,
    4.Insert the CD, reboot from CD drive, and then just follow the process of instruction. A few steps later, admin password would be cleared
    Took about 5 minutes for the whole proce


Leave a Comment




Leave your friendly comment here.

If you have a computer help question, click here to leave it on the forums instead.

Note: Your comment may not show up immediately on the site.

Sponsored Links
Getting Started
About How-To Geek
What Is That Process?
svchost.exe
jusched.exe
dwm.exe
ctfmon.exe
wmpnetwk.exe
wmpnscfg.exe
rundll32.exe
wfcrun32.exe
Ipoint.exe
Itype.exe
Wfica32.exe
Mobsync.exe
Cmd.exe
Dpupdchk.exe Adobe_Updater.exe

Copyright © 2006-2009 HowToGeek.com. All Rights Reserved.