• The only way to fix an authentication token manipulation error on Raspberry Pi is by tweaking the files of the installed image.
  • In this article, we are going to show you two ways to do it.
  • The article is part of a more extensive list of materials dedicated to Raspberry Pi Errors, so you should check it out.
  • You can read useful information in the Developer Tools section on the website.
password not working raspberry pi

Oftentimes we forget or misspell login passwords we use for various accounts and there’s usually a method to recover them. But what if the system won’t accept the default credentials?

This can be the case with Raspberry Pi users. Sometimes, at the first login, the system won’t recognize the default passwords (eg. pi, for Linux OS, or ubuntu, for Ubuntu OS).

The common error message is Authentication token manipulation error. The only successful solution reported by the Raspberry community members is to tweak the password file in the image.

You will need another machine that runs on Windows, Mac, or Linux, where you can insert the SD card.


How do I fix authentication token manipulation error?change password raspberry pi

1. Modify the password file for Linux OS

  1. Insert the SD card in another device
  2. The card should contain a file named cmdline.txt
  3. Open it in Notepad (or other .txt file reader)
  4. Edit the text to have init=/bin/sh at the end. It should look like this:
    • dwc_otg.lpm_enable=0 console=serial0,115200 console=tty1 root=PARTUUID=04ceb741-02 rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait init=/bin/sh
  5. Save and exit > Insert the SD card into the Raspberry Pi
  6. When prompted type: mount -o remount, rw / (and repeat if an error message appears)
  7. Type passwd pi
  8. Type the new password
  9. Then type sync
  10. Type exec /sbin/init
  11. Safe exit Raspberry Pi

Then put the card into the PC again and delete the init=/bin/sh combination you added. Save the changes and insert the card into the Raspberry Pi. You should be able to use the new password.


Modify the password file for Ubuntu

  1. Insert the SD card in another device
  2. Look for the firmware directory > user-data file (in YAML format).
  3. Look for the following line: chpasswd: expire: true
  4. Change to expire: false
  5. Save and exit.

Insert the SD card into the Raspberry Pi and you should be able to log in using the ubuntu username and password.

We hope that one of these solutions was helpful. If you have any suggestions related to this topic, please leave a comment in the dedicated section below.


FAQ: Learn more about Raspberry Pi credentials

  • How do I reset my Raspberry Pi username and password?

In order to change your Raspberry Pi username and password, you need to insert the SD card in another PC and edit the cmdline.txt file so that it contains init=/bin/sh at the end.

  • What is the authentication token manipulation error?

It is an error that can occur on a Raspberry Pi device on the first boot or upon installing a fresh image and rebooting the system.

  • What is the default password for Raspberry Pi?

The default password for Raspberry Pi is username raspberry, password pi.