1

http://mapledyne.com/ideas/2015/8/4/reset-lost-admin-password-for-raspberry-pi

I follow this guide and the many that there are available to reset my password for my raspberry pi. However when it boots up in the terminal it shows this message which might be relevant or not

/bin/sh 0 can't access tty

But I can't use the keyboard. Booting up normally into my Raspberry PI, keyboard works fine. It is a bluetooth keyboard from logitech if it makes a difference, connected via USB adapter.

Anrpiu9
  • 19
  • 1
  • 1
  • 2

2 Answers2

5

You tried to boot with init=/bin/sh appended to /boot/cmdline.txt but it seems it does not initialize the keyboard. Instead you can append this to cmdline.txt:

systemd.unit=emergency.target

Special systemd units explains:

In many ways booting into emergency.target is similar to the effect of booting with "init=/bin/sh" on the kernel command line, except that emergency mode provides you with the full system and service manager, and allows starting individual units in order to continue the boot process in steps.

There is a big chance to have the usb keyboard initialized with this. If it does not work you can also try booting with:

systemd.unit=rescue.target

It will boot into single user mode.

Ingo
  • 42,961
  • 20
  • 87
  • 207
0

This message

/bin/sh 0 can't access tty

itself isn't a problem. Just try another USB keyboard. Not all keyboards work with rpi. The Apple keyboard, USB id 1c4f:0002, doesn't.

With the lucky keyboard, just press enter and see the prompt.