Derkomai
Posts: 10
Joined: Wed Aug 08, 2012 10:07 pm

Password issues

Wed Aug 08, 2012 10:23 pm

I've been playing around with my pi for a couple of days. I changed the default password (or so i thought) and everything went fine except if i restarted the x server. Then the login window refused my password and i was forced to restart my pi so the autologin could do the job.
Now i've stopped autostarting xfce and when i get to the login prompt, i have the same problem.

I'm using wheezy and i've read a lot of similar password issues, but none of solutions proposed has worked for me.
Neither default pi/raspberry login nor the pass i chose work for me (i think this last one is caused because i used 'sudo psswrd' instead of just 'psswrd', so the pass was temporal - or so i've read).

Has anyone had the same problem?. I can't log to the pi so i'm trapped with this issue. Any help would be much appreciated.

bredman
Posts: 1415
Joined: Tue Jan 17, 2012 2:38 pm

Re: Password issues

Thu Aug 09, 2012 8:32 am

Do you have access to another Linux PC? Or maybe you can put a Ubuntu live CD into a Windows PC.

In this case, you can edit the contents of the RPi SD card. The file /etc/inittab controls the bootup sequence. Look at page 3 of the July edition of the MagPi magazine for instructions of how to bypass the password request during startup.
www.themagpi.com

This will allow you to boot up your RPi. Then reset your password using the command
passwd

User avatar
redhawk
Posts: 3465
Joined: Sun Mar 04, 2012 2:13 pm
Location: ::1

Re: Password issues

Thu Aug 09, 2012 9:15 am

"sudo passwd" would have only changed the password for root not for PI.

Have you tried all password combinations possible there must be something that works??

Fixing this problem without the ability to login as root is not going to be easy however you only need to mount the SD Card with another copy of Linux and edit (sdcard)/etc/shadow
Locate pi and root then change their lines to:
root:*:15540:0:99999:7:::
pi:$6$gxqrzdO6$eduJhvI9vWXOW1z52NJ9CCt9SBsM2GAFnF.03aGQQ7rDwG.A0wKESCUVAYnLpSxh9FD4EYre1vUWEOXra0XmE1:15540:0:99999:7:::

This removes the password set for root it should also restore the password for pi to raspberry
There are programs which can crack shadow passwords but they require a lot of time and brute force so patching it with a known password is the faster option.

I assume you're using Raspbian Wheezy as your distro if not then these instructions won't work.

Richard S.

Derkomai
Posts: 10
Joined: Wed Aug 08, 2012 10:07 pm

Re: Password issues

Thu Aug 09, 2012 1:45 pm

Thank you both for your answers. I tried bredman's and after reading magpi almost everything works fine, but i just can't change my password once logged in.
When i try 'passwd' and set my new pass, message 'Authentification token manipulation error' is shown (that was the reason i used sudo before). Some people is experimenting this problem when system date is wrong set, but mine appears to be ok.

Derkomai
Posts: 10
Joined: Wed Aug 08, 2012 10:07 pm

Re: Password issues

Thu Aug 09, 2012 1:57 pm

Sorry, i meant: when i type (current) UNIX password i get that message. It seems it's not accepting raspberry as pass (neither my old pass).

bredman
Posts: 1415
Joined: Tue Jan 17, 2012 2:38 pm

Re: Password issues

Thu Aug 09, 2012 2:02 pm

May I suggest...

You could create a new user (for example derkomai)
http://elinux.org/RPi_Beginners#Create_ ... privileges

Then, copy any important files from /home/pi to /home/derkomai.

Delete the user pi

All tidy, and you have personalised your system.

Derkomai
Posts: 10
Joined: Wed Aug 08, 2012 10:07 pm

Re: Password issues

Thu Aug 09, 2012 2:08 pm

Ok, i answer myself. I was typing just 'passwd' instead of 'passwd pi' (stupid me). Everything fixed.
And yes, i think i'll give a try to what you say, bredman.

Once again, thank you all. You've been a great help.

rjbsmiley
Posts: 4
Joined: Tue Jul 07, 2015 10:08 am

Re: Password issues

Wed Jul 08, 2015 7:55 am

I've got the same problem but with me it won't autologin so i edited the file /boot/cmdline.txt by adding init=/bin/sh, but it will show the same, or just refuse to boot.
what can I do?

assadollahi
Posts: 22
Joined: Sun Jul 26, 2015 6:39 pm

Re: Password issues

Thu Aug 27, 2015 6:48 pm

i just read in another thread that there must be a blank between the rootwait and the init=/bin/sh and windows is handling the new line differently. if you go into that textfile again and delete everything between the "t" and the "i" and add a fresh blank, it works. (at least it did for me, now i'm stuck with that "authentication token manipulation error")

saminjapan
Posts: 1
Joined: Fri Jan 22, 2016 12:23 pm

Re: Password issues

Fri Jan 22, 2016 12:27 pm

OOOOOOOKAY i just fixed this my self:

After you type "init=/bin/sh" into cmdline.txt in the recovery boot up, and your RasPi has booted up, you
should be on the cmd line. BEFORE you type "passwd pi" , type
mount -rw -o remount /
then try changing the password.
This worked for me :D

DirkS
Posts: 10307
Joined: Tue Jun 19, 2012 9:46 pm
Location: Essex, UK

Re: Password issues

Fri Jan 22, 2016 3:18 pm

Indeed. And as explained a long time ago at http://www.raspberrypi-spy.co.uk/2014/0 ... -password/
(Posted for people stumbling into this topic)

hamwong
Posts: 2
Joined: Sat Jan 07, 2017 6:45 am

Re: Password issues

Sat Jan 07, 2017 6:48 am

I am a newbie either to Raspberry or linux/unix
I facing same issue as yours
I found you have to use sudo before passwd to solve this issue,
so type "sudo passwd pi" than no error come out after password input

User avatar
Dixonge
Posts: 9
Joined: Thu Sep 10, 2015 6:39 pm
Location: Austin, TX
Contact: Website

Re: Password issues

Thu Jul 06, 2017 2:39 am

hamwong wrote:I am a newbie either to Raspberry or linux/unix
I facing same issue as yours
I found you have to use sudo before passwd to solve this issue,
so type "sudo passwd pi" than no error come out after password input
BINGO! LOL I can't believe that was it. Was driving me crazy. Thank you!

capaz
Posts: 1
Joined: Tue Feb 19, 2019 4:15 am

Re: Password issues

Tue Feb 19, 2019 4:21 am

This just solves the issue.
saminjapan wrote:
Fri Jan 22, 2016 12:27 pm
OOOOOOOKAY i just fixed this my self:

After you type "init=/bin/sh" into cmdline.txt in the recovery boot up, and your RasPi has booted up, you
should be on the cmd line. BEFORE you type "passwd pi" , type
mount -rw -o remount /
then try changing the password.
This worked for me :D

Return to “Beginners”