I had enabled root login before and tried to change its password using this guide. But after successfully changing the password and locking it via sudo passwd -dl root. I cannot login back to SSH, it says Access is denied.

I have two users on my machine. root and admin, admin does not have su permission. When I try to use sudo on admin user, it says that admin is not in the sudoers file. That is why i need my su user back.

  • What account were you using when you executed sudo passwd -dl root? – techraf Aug 24 '16 at 2:03
  • i was logged in as root. @techraf – Hard Spocker Aug 24 '16 at 2:05
  • You don't need to add sudo when you are logged in as root. Now for the problem: you have locked yourself out of the machine and you won't be able to do anything without a physical access to the disk. Do you have one? – techraf Aug 24 '16 at 2:07
  • @techraf i dont have access to the physical machine. how screwed am i? – Hard Spocker Aug 24 '16 at 2:10
  • Possible duplicate of How do I reset a lost administrative password? – techraf Aug 24 '16 at 2:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.