Watching The Net • Computer - Internet - Technology Tips And Tutorials
Latest Articles Submit Tip-Article or Question Advertise On WTN
 

Get a 3 licensed copy of Windows 7 Home Premium at a big discount

You better hurry.... before Microsoft comes to their senses

Are your dual monitors taking up too much space on your desk? If so, get your space back with an adjustable dual monitor mounting stand and declutter your desk with out throwing anything out!

How I added more disk space with out any hassles or costing me an arm and a leg!

Check it out: Quickly Solve Low Disk Space Problems

Ubuntu Guide For Windows Users: Reset Your Password When You Have Forgotten It

35

ubuntulogo.jpgFor Windows users, several solutions exist if you have forgotten your password such as creating a password reset disk.

But how about if you are on an unfamiliar system such as Ubuntu (or any Linux distribution) and you forgot your password. Do you know what steps to take to reset your password so you can log back in to your computer?

Unlike Windows, this process is a lot easier.

To get started, just boot your computer and when you see "Loading Grub" press the ESC (Escape) key. If you missed it, just reboot and try again.

Once you see the Grub prompt, press 'e' to enter Edit mode (as shown by the arow in below screen shot).

ubunturesetpwd1.png

Next, highlight the line that begins with kernel and press 'e'.

ubunturesetpwd2.png

Now, what you see may seem a little odd, but go the very end of the line, hit the space bar once, then type the following command after the word 'splash':

rw init=/bin/bash

ubunturesetpwd3.png

and press enter, then b to reboot.

After Ubuntu has restarted, instead of loading the GUI, you will see a passwordless root shell. At the prompt, type the following command and replace 'username' with the name of the account you want to change the password.

passwd username

ubunturesetpwd4.png

Type in a new password and retype to verify, once you see the confirmation that your password was updated successfully, reboot.

When GNOME loads enter your new password and you should be good as new again.

Filed under Ubuntu And Linux Tips by Mike Boyds #

Related Posts

  • How To Easily Remember Answers To Website Security Questions
  • Why Web Sites Security Questions Can Be Bad News
  • Linux Tip: Tighten Up Security And Disable SSH Login For Root Account
  • How To Configure Automatic Updates Schedule In Ubuntu
  • Restore Panels In Ubuntu Back To Their Default Settings

What Next?

  • Join The WTN Tips Newsletter
  • Leave a comment
  • Subscribe to Watching The Net
  • Comments on Ubuntu Guide For Windows Users: Reset Your Password When You Have Forgotten It Leave a Comment

    May 19, 2008
    Reply

    Silver @ 11:06 am #

    I am not sure why this is considered easier than Windows, but that is a typical comment to make.

    Anyway, what if you have ab encrypted rootfs or use SELinux?

    Reply

    Watching The Net @ 6:06 pm #

    @Silver

    With Windows, if you don't have another account (with rights to change user account passwords)you either need to create a password reset disk or use a third party utility just to change your password (when you have forgotten it).

    Compare that to Linux, the above method is much easier.

    As for ab encrypted rootfs or SELinux, I'll need to do some digging if the method can be used.

    May 20, 2008
    Reply

    caveman @ 5:29 pm #

    There's an even easier way: just select the recovery mode option, select "root" (Drop to root shell prompt) and change your password that way. No need to alter any lines or anything of that sort.

    Reply

    Jimmy @ 6:57 pm #

    How can this be secured against? If I won't forget my password and would rather reinstall than leave root access open this easily?

    Reply

    Nick @ 9:28 pm #

    Isn't that what the "recovery mode" option is for? I haven't used Ubuntu in a while, but on Gentoo that means a root prompt in single user mode. (i.e this)

    And to answer Jimmy, there is no way to stop access to the root prompt on your computer (if you have physical access), but you CAN encrypt the hard disk. Then you have to enter a password to boot up at all. There are many howtos on this, but you only want it if you really care about security.

    May 21, 2008
    Reply

    MTecknology @ 8:56 am #

    WOW!!!

    You guys need some serious help. First of all, yes those will work.

    If you don't want people to edit GRUB in this way, then password protect it. This guide goes over using encrypted passwords, but plain text passwords are also possible. The idea is to protect 1. booting into recovery mode, and 2. editing the configuration file.
    http://www.debiantutorials.org/content/view/40/227/

    I also added a comment in there to explain some things.

    The will pretty securely cover GRUB. BUT, I know of a way around this. You can boot to a live CD and change the systems /etc/shadow file which contains system passwords. You can replace any users password with another hash. But once GRUB is locked down, going through that process would be pretty painstaking since you can no longer just wipe the root password and boot into recovery mode.

    Anyway, how some of that has been cleared up for you.

    Reply

    mngrif @ 1:43 pm #

    No amount of security will help if the attacker has physical access to the machine. There are even ways around drive encryption, especially if the drive is still mounted when the machine is 'attacked'. Boot passwords and BIOS passwords are easily circumvented to even the slightest determination. All you need is a livecd and a screwdriver!

    The above shouldn't ever be used unless you really know what you're doing and won't work for encrypted volumes (in most cases you WILL run in to trouble if you set init to a shell, such as the environment not being set up (thus making vim and other editors useless)). Use the recovery mode to properly boot in to single user mode, as it will run through essential init scripts.

    On most Linux installs, setting init=/bin/sh will boot with / in read only mode too since remounting it is handled by a init script.

    It's called recovery mode for a reason! Use it!

    October 30, 2008
    Reply

    diptimoy @ 8:15 am #

    It did not work. It is showing that command not found.

    November 30, 2008
    Reply

    Dan @ 10:39 am #

    To secure against this:

    1. Disable boot from anything except hard disk in BIOS and password-protect
    2. Make grub password ( http://ubuntuforums.org/showthread.php?t=7353 )

    Sorted.

    December 11, 2008
    Reply

    Debbie @ 6:33 pm #

    hey iam asking for help for a friend, i told him there is a free disk that i can download for him. He has a vista P.C. and has forgotten or someone was playing aroung with his P.C. and changed his password, he needs passwoed to open enternet, so could you please send me an email about disk, i would appercite very much….

    thanking you in addvance Debbie

    Reply

    Watching The Net @ 7:31 pm #

    @Debbie

    I believe your looking for this post –> Reset your Windows Password When You Have Forgotten It.

    July 3, 2009
    Reply

    Daniel @ 6:23 pm #

    Hello all:

    I'm stuck. I forgot my password.

    I "tried" to follow the above procedure, yet, I am unable to "see" grub.

    When linux starts to boot, I press ESC and it still loads.

    Would it be because I'm using Linux Mint and the panel (starting panel when we turn on the computer) is not the same?

    Signe: Eternal Newbee
    Daniel.

    July 26, 2009
    Reply

    1fastbullet @ 7:30 pm #

    @ Eternal Newbee

    Daniel, you must shut the machine down.
    When you reboot (restart) it, the machine goes through it's POST (Power On Self Test) and scrolls through a list of information including things such as the BIOS version, the hard drive and memory the machine sees. Then it will enter the GRUB loading stage. If it does not enter GRUB loading, you would never get to a welcome screen.

    What you need to look for is in the UPPER, LEFT-HAND corner of your screen, after the POST completes. It will say simply "Loading GRUB 1.5" or something to that effect.

    It is while this message is showing in the upper left-hand corner of your screen that you must press the Esc key.

    July 27, 2009
    Reply

    Daniel @ 7:46 pm #

    It worked.

    Thank you, THANK YOU, T H A N K Y O U

    It took me a couple of tries and I got it OK.

    Rolling again.

    Tks so much.

    If I can be of help. Please let me know

    Daniel.

    January 8, 2010
    Reply

    ermaldemi @ 2:38 am #

    @Silver:

    January 9, 2010
    Reply

    daniel @ 10:07 am #

    @Daniel:

    I did get complete satisfaction.

    Tks.

    Daniel.

    February 22, 2010
    Reply

    mario @ 4:49 pm #

    hi all,

    i have a problem here.

    i put a password for the bios of my laptop before a very long time and i didnt use it at all so i forgot it. everytime i format my laptop i just press f12 and it asks me to boot from cd and i do, but i cant enter to the bios setup. i installed the ubunto and i hope that there will be a solution for my problem.
    so the password is only for the bios setup.
    i tried by taking out the battery it didnt work. the motherboard has no jumpers ……
    the laptop is fujitsu siemens s7020. bios is phoenix ver. 1.14
    thanks.

    May 11, 2010
    Reply

    jus @ 1:32 am #

    what should I do if no matter how fast I press ESC it just won't go to grub prompt?

    June 11, 2010
    Reply

    Lexi @ 1:43 am #

    Im a VERY new user to the Linux OS Ubuntu. If you look down at the tool bar there's a place where it says the user that is logged ins name. If you right click it brings up options. I clicked on "Edit Personal Information" And in the right hand top corner there's a place where it says your username and underneath that it says something about a password. I set up a password and forgot it now I can't remember it. So the case is It won't let me download anything. Although I can download videos and add-ons, small things. Would this guide your offering me be helpful in my situation?

    November 2, 2010
    Reply

    Abdul @ 1:49 am #

    @mario
    Laptop BIOS since the early 90's have been made to write all changes to CMOS, so even when the battery is removed the information is kept. This is to keep stolen laptops, if the BIOS is password protected, from being usable. You might want to try the manufacturer of your laptop, and more than likely, you will have to show proof of ownership and even then there is no guarantee that they will provide you the master key. Best of luck!

    September 19, 2011
    Reply

    Felipe @ 3:35 am #

    rw init=/bin/bash

    that was perfect.
    thank you.

    but, what does it means?

    is it something like "the initialization will be at directory /bin/bash (where I can execute comands as root) and I can read and write"?

    March 22, 2012
    Reply

    Steve @ 1:19 am #

    Hi a friend installed Linux mint release 10 Julia on my desk top computer however is no longer with us, I don't have a password, have looked on a few sites talking about changing the kernel line in but I don't have a line starting with kernel help help

    Reply

    Daniel @ 2:51 am #

    I think, with the info your giving here that the how to that is posted above on this same page would do it.

    If you have more info you need, don't hesitate.

    Daniel.

    March 23, 2012
    Reply

    Steve B @ 12:20 am #

    Yes don't have any passwords or username can I get round the password ?

    March 27, 2012
    Reply

    Steve B @ 4:12 pm #

    Can you help?

    March 28, 2012
    Reply

    Daniel @ 3:08 am #

    Hello Steve,

    Did you follow the above mentionned procedure? If no, give it a try, it works when you work it!

    Daniel.

    Reply

    Steve B @ 1:58 pm #

    I don't have a line starting with kernal

    Reply

    Daniel @ 8:00 pm #

    Dunno what to say

    March 31, 2012
    Reply

    Steve B @ 3:48 am #

    My email addy is [email protected] I'll send you a picture to show you

    May 30, 2012
    Reply

    Amanda @ 6:05 am #

    i had been away from the whole ubuntu experience for now 2 years. don't remember my user anme or logini .. :( and have just tried these instructions .. please i hope you can bear through my newbie lingo and not having everything written down from what occurred afterward
    my kernel line , after splash ro ended with "single".
    i entered in the rw = … as written above .. after about ten seconds .. an error came to bottom of screen, with a non syncing issue and dump something about ftrace .. what is this all about !? i really am concerned i may have done some permanent to my system / disk .. i restarted , and have had no luck getting any further
    Please PLEASE i would appreciate some guidance here >. <

    August 1, 2012
    Reply

    ian heria @ 5:15 am #

    what if theres no kernel shows up omly 'crubchbang linux"

    Reply

    francis ian heria @ 5:17 am #

    what if thers no kernel shows up only crunch bang linux

    August 19, 2012
    Reply

    Alesia @ 5:50 pm #

    I desperately need help so please try to help me out!! My problem is when I get to my grub screen where I am supposed to replace "ro quiet splash" with rw init=/bin/bash, in between "ro" and "quiet splash" is my crashkernel sequence: crashkernel=384m-2G:64M,2G-:128M. Before this crashkernel sequence is ro andd after is quietsplash. How do i get to the passwordless prompt? Where do I write rw init=/bin/bash?? Thank you in advance!! If at all possible please email me- my email is [email protected]. Thnks.

    September 4, 2012
    Reply

    lewis @ 3:07 pm #

    after i applied the rw init=/bin/bash and boot i got this: splash no such a file or directory kernel panic no syncing attempted to kill ini. any thoughts? thanks

    January 11, 2014
    Reply

    flrty vishal @ 8:24 am #

    this answer was very helpful for me….when u'll press escape button u'll see an option that says restore system settings just click on that and don't worry ur imp. files won't' b deleted they'll b backed up

    Leave a Comment

    Click here to cancel reply.

    Fields marked by an asterisk (*) are required.

    Subscribe without commenting

    Feed-icon.jpg
    Subscribe To
    WatchingTheNet.com
    via RSS feed

    Or Get Updates By Email

    Categories

    • Computer How-To
    • Firefox and Internet Explorer Tips
    • Google and Yahoo Tips
    • Internet Technologies
    • Microsoft Office Tips
    • MP3 and Media Players
    • Ubuntu And Linux Tips
    • VMware Tips
    • Web Master Tips
    • Windows Tips
    • Windows Vista Tips
    • Window 7 Tips
    • Android Phone
    • Social Media

    Check It Out!

    Read Our Most Recent How-To Articles

    Popular How-To Articles

    Record Online Internet Radio Stations On Your PC

    Take The Poll: When Do You Change Your Email Password?

    How To Print A Directory Tree From Windows Explorer

    How to Watch TV Online - A Satellite TV for PC Review

    Windows XP Tip: View Previously Open Folders After Shutdown or Logoff

    Create A Batch File To Open Multiple Programs At Once

    Resource Guide For Installing And Troubleshooting Vista Service Pack 1

    Force Vista To Connect To Wireless Network When SSID Is Not Broadcasting

    Get Detailed Statistics By Running Windows Vista Disk Defragmenter From The Command Prompt

    Ubuntu Guide For Windows Users: Getting Help At The Command Prompt

    Ubuntu Guide For Windows Users: Managing Packages With Synaptic And Aptitude Part 1

    Ubuntu Guide For Windows Users: Managing Packages With Synaptic And Aptitude Part 2

    Firefox Tip: Easily Find Version Information For QuickTime Java And Adobe Flash Player

    Firefox Tip:Save Memory Usage By Disabling Add Ons

    Download And Transfer Music Movies Games From Your PC To Nintendo Wii

    About Watching The Net

    * About Us
    * Contact Us
    * Advertising
    * Privacy Policy

    Getting Started

    * Windows Vista Tips
    * Windows Tips
    * Ubuntu Guide For Windows Users
    * Firefox & Internet Explorer Tips

    Home
    Copyright 2007-2015 Watching The Net. All Rights Reserved