r/SteamDeck • Content Creator • Sep 05 '23 • Take My Energy 1 Bless Up 1 Heart of Silver 2 Mindblown 1 Heartwarming 1

Discussion Steam Deck Tutorial - UPDATED - reset forgotten sudo password in SteamOS the quick and easy way using root debug shell method

https://youtu.be/B1qfIdP2Ayo


This is an update to my previous method on how to reset a forgotten sudo password. This method utilizes root debug shell instead of init=/bin/bash method.

You just need a USB keyboard, activate root debug shell and be done in about 2mins

https://youtu.be/B1qfIdP2Ayo


If you have forgotten the sudo password for the Steam Deck then don't worry I will teach you how to reset the forgotten sudo password the quick and easy way!

This are the steps on how to reset a forgotten sudo password. You will need a keyboard attached to the Steam Deck to enter the commands easily -

  1. While the Steam Deck is powered off, hold the 3dots (QAM) and turn on the Steam Deck.
  2. The recovery menu will appear. On your keyboard highlight the 3rd option - CURRENT (OS Boot Menu) then press enter.
  3. The GRUB menu will appear. Highlight the 1st option - SteamOS then on your keyboard press "e" to edit the boot options.
  4. Press down cursor on the keyboard until steamenv_boot is highlighted. Press "end" to go to the end of the line.
  5. Enter the command - systemd.debug_shell
  6. Press CTRL-X to boot!
  7. Once SteamOS loads, press CTL-ALT-F9 on the keyboard to access the root debug shell.
  8. Enter the command - passwd deck
  9. Enter new password and retype the new password.
  10. Once done, press CTL-ALT-F1 on the keyboard to go back to game mode.

sudo password has been reset! You can now boot to desktop mode and use sudo commands using the new password!

https://youtu.be/B1qfIdP2Ayo

1.1k Upvotes

397 comments sorted by

View all comments

3

u/Traditional_Ocelot76 May 10 '24

Anyone know why the keyboard won't type on the ctrl alt f9 part.. Had no issues getting to it with all the methods but no input is showing at this stage for some reason

4

u/[deleted] May 12 '24

I had this same issue. It turns out that there shouldn't be a "-" in front of the "systemd.debug_shell" command. It worked when I redid it without the "-".

2

u/Disastrous-Car-6347 1TB OLED Sep 14 '24

Idk why he put the - there when it was not needed

1

u/DSG_Mycoscopic Mar 19 '25 edited Mar 19 '25

Wow, that really messed me up, especially since it's a completely reasonable thing to add (and there are hyphens right before in the same place). u/ryanrudolf thanks so much for this guide but please remove that hyphen?

(There also needs to be a SPACE before the command, for anyone reading this)

Edit: this ended up never working for me, best I can reckon is my keyboard needed the function key used to type F9 and it wasn't being recognized. This different method DID work for me, though: https://m.youtube.com/watch?v=jWFjZNxFHew

1

u/ryanrudolf Content Creator Mar 19 '25

Its like enter the command - abc

The command is after the hyphen

1

u/DSG_Mycoscopic Mar 19 '25

Yeah, fair, but lots of Linux commands or command line modifiers to commands start with a hyphen

1

u/ryanrudolf Content Creator Mar 19 '25 edited Mar 19 '25

In the guide I wrote it says enter the command - systemd.debug_shell

Linux commands doesnt start with a hyphen.

Regarding the function key - check if your keyboard has Fn. If it does you will need that in addition to the combination - CTL ALT Fn F9.

Either way I'm glad you got it working using the other guide! Both works but the systemd.debug_shell method is quicker and easier. Tested both also on the upcoming SteamOS 3.7 and this method works in there too.

Happy gaming!

1

u/[deleted] Jul 14 '25

[removed] — view removed comment

2

u/ryanrudolf Content Creator Jul 14 '25

Still working