Lost Password

All Gurus once were Newbies
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Please stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions prefer the other forums within the support section.
Before you post please read this

Lost Password

Postby jimmyjoejetter on Fri Aug 24, 2012 10:18 am

Hi
I loaded Mint on a friends computer. His first. I am certain that I used the password that I know he knows and will remember as would I.
I used set up as always a standard user and two Admin accounts. For this type of situation I do this to keep it all easy at first. I also set the set the system to
auto log in as a standard user.
Anyway I tried to install some software he needs. The passwords for Admin or any of the admin users do not work
Not even sure if the password for the standard user is something I know as it is set to auto load.

So
I can not load anything. The password does not work.
I was tiered when I installed for him. maybe I did not use the password I thought I did
Regardless I have no idea what the password is OR the correct password does not work.
I want to change it but as a standard user I do not think it can be done.
What do you think. Is there anyway to change the Admin Password or add a new admin user so I can make changes etc..
I realy do not have the time for a reload and reconfiguration. Anyone have any idea what I can do?
Thank you.
Jim
jimmyjoejetter
Level 1
Level 1
 
Posts: 1
Joined: Fri Aug 24, 2012 9:59 am

Linux Mint is funded by ads and donations.
 

Re: Lost Password

Postby xenopeek on Fri Aug 24, 2012 10:38 am

You can easily reset passwords, though you must be careful. If a user has an encrypted home directory, you must not change the password this way! This will make all encrypted files inaccessible. You can only use this method on user that doesn't have an encrypted home directory.

Steps:

1. Get the GRUB menu to show. It is shown by default if you have multiple OS installed, else please hold shift key down during booting to get the GRUB menu to show.

2. In the GRUB menu, highlight the OS you want to boot (if only one is installed, it is already highlighted). Then press the "e" key to edit the boot parameters.

3. Using the arrow keys on your keyboard, move your cursor to the end of the line similar to:
Code: Select all
linux /boot/vmlinuz-3.2.0-23-generic root=UUID=b8080487-b557-4f55-b288-d7ef2c2b9cc1 ro   quiet splash $vt_handoff

and replace "$vt_handoff" with "rw init=/bin/bash" (or just add that on to the end if you don't have the "$vt_handoff"). So that it reads:
Code: Select all
linux /boot/vmlinuz-3.2.0-23-generic root=UUID=b8080487-b557-4f55-b288-d7ef2c2b9cc1 ro   quiet splash rw init=/bin/bash

then press F10 to continue the boot.

4. After a little while, and some error messages you can ignore, you are now logged in on the root console without having had to enter a password. Run the following command for each user (without an encrypted home directory!) that you want to give a new password. Replace "username" with the name of the user.
Code: Select all
passwd username

5. Then sync the file system so all changes are written to disk, and reboot:
Code: Select all
sync
reboot -f

And, to be clear, once you have rebooted you need to login as an admin user to make changes to the system (somebody member of the sudo group). And you confirm where need with the admin's own personal password. A standard user (not a member of the sudo group) is not allowed to make changes to the system.
Forum Rules | IRC Channel Rules
Image
Arch Linux / 64-bit / Gnome Shell
User avatar
xenopeek
Level 21
Level 21
 
Posts: 13682
Joined: Wed Jul 06, 2011 3:58 am
Location: The Netherlands

Re: Lost Password

Postby elbmek on Sun Oct 14, 2012 11:00 am

I get as far as F10 then get kernel panic - not syncing: unable etc etc. I lost my password so cannot do undates to software. After typing intial code line alteration I get a \ appearing after bash
elbmek
Level 1
Level 1
 
Posts: 13
Joined: Tue Aug 28, 2012 7:41 am

Re: Lost Password

Postby Legless on Thu Oct 18, 2012 9:15 am

Brilliant! Worked like a charm! Thank you! :D
Legless
Level 1
Level 1
 
Posts: 1
Joined: Thu Oct 18, 2012 9:12 am

Re: Lost Password

Postby user4 on Mon Nov 26, 2012 1:59 pm

i have the same problem of tiping another password then the one that i expect i wrote and the same proble of elbmek.
i have linux mint installed under vista and in the boot screen the "e" doesn't work to set the boot options. i have to start linux and then when i have to chose between the normal version or the repair version i can use the "e" to edit. in this screen there isn't any line:
linux /boot/vmlinuz-3.2.0-23-generic root=UUID=b8080487-b557-4f55-b288-d7ef2c2b9cc1 ro quiet splash $vt_handoff
but there is a similar one. changing with init=/bin/bash the part after "spalsh" and booting with F10 it locked on a black screen and i have to shut down it manually. any one knows how i can solve this problem?
user4
Level 1
Level 1
 
Posts: 1
Joined: Mon Nov 26, 2012 1:37 pm

Re: Lost Password

Postby mfs4360 on Sat Dec 01, 2012 11:54 am

I followed your directions but could not get past step 4. After I entered the command "mount -o remount,rw /" nothing happened. Not sure why or if i did something wrong. Help! I am presently using Mint 13 in a dual boot with Windows 7 and it has been working great.

Thanx,
Matt
mfs4360
Level 1
Level 1
 
Posts: 2
Joined: Sat Dec 01, 2012 11:47 am

Re: Lost Password

Postby BoscoBearbank on Sun Dec 02, 2012 7:46 pm

If a user has an encrypted home directory, you must not change the password this way! This will make all encrypted files inaccessible. You can only use this method on user that doesn't have an encrypted home directory.

If the users doesn't have an encrypted home directory, there's also this option (commands to be typed are in bold):
1. Boot from a live CD, DVD, or USB key
2. Open a terminal window
3. Become root su -
4. Identify your Linux Mint root partition (blkid -c /dev/null will list your partitions)
5. Mount your Linux Mint root partition (assuming it's /dev/sda5 in this example: mount /dev/sda5 /media)
5.1 chroot to /media (chroot /media)
6. You should now be able to change any user's password. Do it
7. Undo the chroot: exit
8. Unmount the Linux Mint partition umount /dev/sda5
9. Go back to being the default user: [b]exit/b]
10. Reboot (from your hard drive)
Last edited by xenopeek on Mon Dec 03, 2012 12:27 pm, edited 2 times in total.
Reason: Added warning about encrypted home directories.
User avatar
BoscoBearbank
Level 2
Level 2
 
Posts: 50
Joined: Sat Nov 14, 2009 8:13 pm

Re: Lost Password

Postby Mohito on Sun Dec 16, 2012 1:40 pm

3. Move your cursor to the end of the line similar to:
Code: Select all
linux /boot/vmlinuz-3.2.0-23-generic root=UUID=b8080487-b557-4f55-b288-d7ef2c2b9cc1 ro   quiet splash $vt_handoff

and replace $vt_handoff with init=/bin/bash. So that it reads:
Code: Select all
linux /boot/vmlinuz-3.2.0-23-generic root=UUID=b8080487-b557-4f55-b288-d7ef2c2b9cc1 ro   quiet splash init=/bin/bash

then press F10 to continue the boot.

after I do this I get a black screen for hours, nothing happens. i have mint 14 64 bit please help
Mohito
Level 1
Level 1
 
Posts: 5
Joined: Sun Dec 16, 2012 11:01 am

Re: Lost Password

Postby super_virgin on Tue May 28, 2013 2:29 pm

Thanks a lot for the post!
Works wonderfully for linux mint!
:)
super_virgin
Level 1
Level 1
 
Posts: 3
Joined: Sat Jul 28, 2012 3:14 pm

Linux Mint is funded by ads and donations.
 

Return to Newbie Questions

Who is online

Users browsing this forum: Google [Bot], markey164, nerdtron and 39 guests