Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I forgot my Ubuntu password so I booted into recovery and dropped into a root shell prompt and this is what happened:

root@username-PC:~# passwd username
Enter new UNIX password:
Retype new UNIX password:
passwd: Authentication token manipulation error
passwd: password unchanged
share|improve this question

marked as duplicate by Eliah Kagan, Mateo, Radu Rădeanu, Alvar, RolandiXor Aug 3 '13 at 19:28

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

4 Answers 4

up vote 75 down vote accepted

Also make sure you are mounting the file system read/write.

After immediately selecting 'Drop into root shell prompt' I found the filesystem was mounted read only, which prevents resetting the password.

Choosing the option to remount / as read/write and going back into the root shell prompt enabled the password change.

The command to run prior to changing the password is: mount -rw -o remount /

share|improve this answer
    
Thank you, that worked. –  Somebody Apr 7 at 16:54
    
even after following these steps it will not accept my password –  angela Aug 14 at 15:09

I'm not sure how it happened. A sudo user created my account then deleted it then created it again.

Here is what I found

mount -o remount,rw /
passwd
passwd: Authentication token manipulation error

No change.

sudo pwck

Showed no errors.

sudo grpck

Showed no errors.

ls -l /etc/passwd /etc/group /etc/shadow /etc/shadow-
-rw-r--r-- 1 root root    767 May  7 16:45 /etc/group
-rw-r--r-- 1 root root   1380 May  7 16:45 /etc/passwd
-rw-r----- 1 root shadow 1025 May  8 09:11 /etc/shadow
-rw------- 1 root root   1025 May  7 16:46 /etc/shadow-

Looks normal.

sudo cat /etc/shadow |grep oracle
oracle:$6$FsPqyplr$DrIvjFDSx0ipHmECMw1AU5hTrbNMnnkGRdFlaQcM.p3Rdu2OLjY20tzUTW61HlFH16cal56rKlLuW4j2mK9D.:15833:0:99999:7:::

Showed user and encrypted password.

sudo cat /etc/shadow- |grep oracle

Showed nothing. Not sure what that means but doesn't look right.

sudo passwd -d oracle
passwd

So the solution was to delete the password then reset new password.

Hope this helps.

I originally posted here Getting an "Authentication token manipulation" error when trying to change my user password but google shows this result first so, I re-posted.

share|improve this answer

I got this error by changing password with device where date was not set. (ie. it was random after boot)

Basically what happened was that when I changed the password the illegal timestamp got updated to /etc/shadow. After that one could not use that account to login or change its password. Even with root account it was impossible to change that password again.

To fix the account I had to:

  1. Set the correct date
  2. Edit sane expiration/last password change dates to /etc/shadow file (I used last working shadow file)
  3. Change the password with root-rights to new one.
share|improve this answer

Check the permissions on your /etc/shadow file. They must be set to 000 or you cannot edit user password data. see this and this superuser question

share|improve this answer
4  
/etc/shadow's permissions should be 0640, not 000. –  Jordan Uggla Jan 3 '13 at 0:32

protected by Community May 13 '12 at 12:36

Thank you for your interest in this question. Because it has attracted low-quality answers, posting an answer now requires 10 reputation on this site.

Would you like to answer one of these unanswered questions instead?

Not the answer you're looking for? Browse other questions tagged or ask your own question.