Introduction:

If you’re having trouble accessing your server via SSH after a reboot, there are several common issues that you can check. Use the below steps to recover SSH access.

Prerequisite:

1. Server root login credentials.

Step 1:

Please check the SSH service status.

$ systemctl status ssh.service
Step 2:

Check the sshd configuration status.
If it shows an error like “Missing Privilege Separation Directory: /var/run/sshd”

$ sudo sshd -t

Step 3:

Please create the directory sshd

$ mkdir -p /var/run/sshd
Step 4:

Modify ownership to that directory

$ chown root:root /var/run/sshd
Step 5:

Restart the SSH service

systemctl restart ssh
Step 6:

Recheck the configuration of the OpenSSH server.

sudo sshd -t

Leave a Reply

This website stores cookies on your computer. These cookies are used to provide a more personalized experience and to track your whereabouts around our website in compliance with the European General Data Protection Regulation. If you decide to to opt-out of any future tracking, a cookie will be setup in your browser to remember this choice for one year.

Accept or Deny