How to boot Raspberry Pi into single user mode?

Single user mode Raspberry Pi boot

Posted by Amritpal Singh on March 22, 2018

You can configure Raspberry Pi to boot into single-user mode by editing the cmdline.txt using an external computer system. Single user mode on Raspberry Pi allows you the boot the system as user id 0 which the root user. Single user mode allows you to change forgotten user passwords and make other modification to correct your Raspberry Pi system with superuser permissions.

How to boot into single user mode?

  1. Insert the card in your Windows/Mac SD card reader
  2. Edit the file “cmdline.txt” and append “init=/bin/sh”
  3. Insert the card back into the Raspberry Pi again and boot up
  4. When prompt available, enter “su” to log as root (with no password)

That's it now you have successfully logged onto your Raspberry Pi into single user mode as root user without password, you can reset your passwords etc.


Jesse Girard

I was unsuccessful using this method. When I booted up and used Putty I got nothing. It occurs to me that perhaps SSH doesn't work when one adds init=/bin/sh to the file. Nothing whatsoever happens. Maybe I need to log in using a direct connection rather than SSH.

Amritpal Singh

Hi Jesse, yes you will need to connect using direct connection rather than SSH.

Add Comment