0

I'm playing around with ssh-with-rsa-key authorization instead of password authorization and because I'm not really clever I've locked password authorization for root(passwd -l root) on remote server. Also I've deleted my rsa key from local computer and removed authorized_keys from server(yes, I'm stupid) so now there is no way for me to log in as root on server.

As I understood now I have to run passwd -u root to enable password authorization again on server. But I can not log in so I can not run this command.

Please advise if there way to fix things or I just have to go and shot myself?

micgeronimo
  • 101
  • 2
  • Reboot to single-user mode, or from installation media in rescue mode, and fix the password file directly. – MadHatter Nov 26 '14 at 09:54
  • don't you have access to an account that has sudo rights? – Ale Nov 26 '14 at 10:13
  • Do you have hardware access to this server? If this is done through a hosting provider, they give you means to reload your server, VNC into it, everything basically. If no to these questions, surely someone has access to the server and can 1) interrupt the boot sequence, 2) enter bash 3) mount the drive 4) do the necessary changes in the recovery environment. – Proxy Nov 26 '14 at 10:23

0 Answers0