# kernel panic after adding init=/bin/bash to grub linux line

## e3k

i am using btrfs. the system boots normaly. when i was trying to reset the password once again via grub by adding 'rw init=/bin/bash' to the grub 'linux' line a kernel panic message was welcoming me (the one with the blinking caps lock on the keyboard)

```

could not find /bin/bash

...

Kernel panic - not syncing: Attempted to kill init!

...

```

could please anyone try to reproduce? or if you know the answer please tell!

----------

## quilosaq

Try instead use 'rw init=/bin/sh'.

----------

## Roman_Gruber

Which password do you want to change?

Ususually a sysrescue-cd is the way to go for such tasks.

if it is just booting the box, as said earlier, /bin/sh

you can do a bit but not much if you have added busybox to your initrd before. but the busybox binary is very very limited. uses ash shell.

----------

## e3k

yes i tried /bin/sh too. that could not be found either.

when i was playing with rootfstype i have got into busybox. i could mount / but i could not find the passwd command.

i already did reset the password with a gentoo admin cd after chrooting. but usually when i want to reset the root password the grub way of doing it was working also with /bin/bash.

----------

## quilosaq

If you get down into the busybox you must:

remount root fs in rw mode

edit /etc/shadow file and delete the hash field (second field) in the root entry

reboot

login as root (whitout password)

change the password whit password command

----------

