0

Is there any way I can get access to my server back without using SSH to log in? my private keys had the incorrect permissions and now I can't log in.

Tar
  • 265
  • 4
  • 11

1 Answers1

1

it depends on the circumstances. you haven't provided enough details to give a definitive answer.

if you know the password, you should be able to just login with the username and password at the console (either locally or via remote console) without needing to reboot.

otherwise, if you have physical access to the server, you can always boot with the 'init=/bin/bash' kernel command line arg, then you'll be able to fix the perms or change the password or reconfigure the system as required. alternatively boot with a rescue CD/USB-stick.

ditto if the server is in a remote data centre AND you have a remote console like ilom or drac or similar (depending on brand of server).

cas
  • 6,783
  • 32
  • 35
  • Does the `init=/bin/bash` thing still work? I vaguely recall they protect against that now. If it does work, remember to call `sync` when you've edited you're files, otherwise when you reboot, changes won't be committed. – Halfgaar Jun 25 '12 at 07:07
  • yep, it still works but grub can be configured to make it more difficult (password protection)...having physical access to the machine means it's just an inconvenience rather than an effective prevention measure. re: sync - yes, always a good idea, especially since normal 'shutdown -r now' won't work under init=/bin/bash, and you have to 'reboot -f'. – cas Jun 26 '12 at 00:04