PINE64
suddenly the terminal won't accept me as root - Printable Version

+- PINE64 (https://forum.pine64.org)
+-- Forum: Pinebook Pro (https://forum.pine64.org/forumdisplay.php?fid=111)
+--- Forum: Linux on Pinebook Pro (https://forum.pine64.org/forumdisplay.php?fid=114)
+--- Thread: suddenly the terminal won't accept me as root (/showthread.php?tid=17378)



suddenly the terminal won't accept me as root - hayduke - 09-21-2022

After a couple of years of use, my pinebook pro won't accept my root password. It's okay in the UI, and okay to sign in,  but not in the terminal. Can I either reset the entire computer or fix this problem?


RE: suddenly the terminal won't accept me as root - wdt - 09-21-2022

(09-21-2022, 01:47 PM)hayduke Wrote: After a couple of years of use, my pinebook pro won't accept my root password. It's okay in the UI, and okay to sign in,  but not in the terminal. Can I either reset the entire computer or fix this problem?

This is not all that clear,,, can you login in sddm or lightdm or whatever as root? OR as $USER?
Since the password you type is not visible, type password in user line,, to be sure that it is correct
Then backspace it away
If sudo works,,, sudo su, then $USER password,,, then id to be sure that you are id 0
then passwd to reset (root) password (not visible, you have to type it twice)
OR
edit /etc/shadow (sudo or root),,, field seperators are ":",,, make 2nd field empty, as so
root::    .......other stuff,,,,typically 50-60 characters in 2nd field
A specific example
#cat /etc/shadow |grep root  (# prompt signifys you are root)
root:$6$cbqT.JlH5PRNQTWi$xQL9znIF6POOeWGO7TcryEnvAbDWlebudR7Tw0h8siZEpEJaSkEr29lW7nP4yrqJDL.clHzb8a3FwpsuT9.:18887:0:99999:7:::
make it
root::18887:0:99999:7:::
then root is passwordless