PINE64
forgot sudo password - Printable Version

+- PINE64 (https://forum.pine64.org)
+-- Forum: General (https://forum.pine64.org/forumdisplay.php?fid=1)
+--- Forum: Getting Started (https://forum.pine64.org/forumdisplay.php?fid=21)
+--- Thread: forgot sudo password (/showthread.php?tid=11540)



forgot sudo password - 20 jason20 - 09-19-2020

im a complete beginner with linux,  i bought a pinebook pro with manjaro and i totally forgot the sudo password. any help would be greatly apprecited


RE: forgot sudo password - Arwen - 09-19-2020

Uh, the SUDO password is the same as your user's password. That's the whole purpose of SUDO. Not using the "root" password.

So if you know your login password, you can use SUDO.


RE: forgot sudo password - 20jasonduty20@yahoo.com - 09-20-2020

I'm afraid I set my keyboard up wrong then. The other day I got a pop up on something about something not working right because I wasn't set up right because it wasn't a german keyboard. Idk


RE: forgot sudo password - Doodenheimer - 09-26-2020

I have a similar question, if I may piggyback. When I type in my user password for SUDO, it gives me an error. It's the same password I use to unlock it when I cut it on.


RE: forgot sudo password - KC9UDX - 09-26-2020

In a terminal, type "passwd" and change your password to something new and write it down. This is the password for your user account.

Also type "passwd root" and give the root account a different password and write that one down.

When you use `sudo` and are prompted for a password, use your user account password. If that doesn't work, you'll need to log in as root, or, `su`, and add your username to a group that has permission to use `sudo`. Consult the manual for sudo, `man sudo`.


RE: forgot sudo password - Doodenheimer - 09-26-2020

(09-26-2020, 05:21 PM)KC9UDX Wrote: In a terminal, type "passwd" and change your password to something new and write it down.  This is the password for your user account.

Also type "passwd root" and give the root account a different password and write that one down.

When you use `sudo` and are prompted for a password, use your user account password.  If that doesn't work, you'll need to log in as root, or, `su`, and add your username to a group that has permission to use `sudo`.  Consult the manual for sudo, `man sudo`.
Thanks a bunch, but when I type "passed," it asks for the current password. When I type that in, I still get an Authentication failure error.


RE: forgot sudo password - KC9UDX - 09-26-2020

Then your user password isn't set to what you think it is. So you'll have to log in as root and "passwd <user>" replacing <user> with your username.

If you know the root password, you can probably become root by typing "su"

If you don't know the root password, you'll have to boot single user mode (does Linux do that?) Or, boot the same operating system from another drive (SD card versus eMMC or maybe USB) and manually edit your /etc/shadow file to delete the password. I'm assuming that even works in Linux; I haven't manually edited a shadow file since Solaris.

Also important: if you're using Manjaro, make sure to fully update the operating system. In some versions, the keyboard settings will be different when you login compared to after log in. If you can login with a password but can't authenticate after login, that could be the issue. You might be typing gibberish letters and don't even know it because the password is hidden when you're typing it at login.


RE: forgot sudo password - Doodenheimer - 09-26-2020

(09-26-2020, 06:54 PM)KC9UDX Wrote: Also important: if you're using Manjaro, make sure to fully update the operating system.  In some versions, the keyboard settings will be different when you login compared to after log in.  If you can login with a password but can't authenticate after login, that could be the issue.  You might be typing gibberish letters and don't even know it because the password is hidden when you're typing it at login.
I've got one of the PmOS ones that just came out, but that sounds familiar. When I boot the phone, the password is hidden, and the keyboard looks a certain way. When I try su or sudo bash or whatever, the keyboard looks completely different, and of course, nothing appears on screen when typing a password in the terminal.

So, make sure to update the OS? Well...the whole reason I wanna be rooted is so I can run a little program that'll randomize my MAC address. The whole point is to get that running before I connect to WiFi, otherwise it's moot.

So just download the update on a USB, right?


RE: forgot sudo password - KC9UDX - 09-26-2020

Well I only know about the PBP, and issues with the version of Manjaro that shipped with it. For some reason that version likes to revert to a curious keyboard layout called Catalan that for some reason doesn't resemble QWERTY in any way. Updating solves this problem.

I don't know much at all about the PinePhone; I don't have one. So I can't really comment on that. Sorry.

I do know from reading here that there are threads about password issues on the PinePhone though.