-1

After I reboot my Ubuntu server I am not able to login via SSH. I have to go on site to login (using CLI) then I have the ability to login remotely. How I cane solve this issue.

I have installed SSH every thing works fine, only after rebooting the server I have to connect the screen and keyboard to enter username and password, then I can return to my office to login remotely

  • 2
    Your question doesn't have enough detail to help us answer it. The more accurate the information, more chance of us helping you. Please read the how to ask guide and improve your question. In your situation, the first thin I would try is sudo apt-get install openssh-client openssh-server – Katu Nov 20 '17 at 10:42
  • already installed – Ali Alaali Nov 20 '17 at 11:17
  • Does your machine have the same IP adress before and after reboot? – Marc Vanhoomissen Nov 20 '17 at 12:03

2 Answers2

0

I had the exact same issue, and it was probably due to power management. After the reboot, the server slept after few minutes. Logging in through console (maybe only switching to console by Ctrl+Alt+F3) temporarily disabled this feature, but it was restored by the reboot.

After switching it off (How do I disable my system from going to sleep?), problems disappeared.

zx485
  • 2,426
0


Assuming you have installed openssh-server, it will start from

 /etc/init.d/ssh

If the server has been installed and the

/etc/init.d/ssh

file exists but doesn't seem to work, I'd execute a dpkg-reconfigure openssh-server.