Saltar al contenido

Lightsail SSH connect failed

0

I am using a Lightsail instance. SSH connection is not working. I have tried rebooting and restarting, but the connection still does not work. I would appreciate your help.

preguntada hace 3 meses68 visualizaciones
1 Respuesta
1

I understand you're experiencing SSH connection issues with your Lightsail instance. This is a common problem that can have several causes. Here are some troubleshooting steps you can try:

  1. Verify your instance status in the Lightsail console to ensure it's running properly.

  2. Check that port 22 (for SSH) is open in your instance's firewall/security group settings. Sometimes these settings can change unexpectedly.

  3. The issue might be caused by a firewall on the Lightsail OS side. When you can access the instance, you could try running these commands to disable the firewall and reset iptables:

sudo ufw disable
sudo iptables -F
sudo mv /etc/hosts.deny /etc/hosts.deny_backup
sudo touch /etc/hosts.deny
sudo systemctl enable sshd
sudo systemctl restart sshd
  1. Monitor your instance's resource usage. High CPU or memory utilization can impact SSH responsiveness. Check the metrics in the Lightsail console.

  2. If the problem persists, consider upgrading to a larger Lightsail plan as resource constraints could be causing the issue.

  3. As a last resort, create a snapshot of your instance's root volume. This will allow you to recover your data and potentially attach it to a new, functioning instance.

If none of these steps resolve the issue, I recommend contacting AWS Support for further assistance as there might be underlying issues with the instance or host system that aren't visible to you.
Sources
Lightsail SSH connect timing out | AWS re:Post
Lightsail SSH - Connection (Request) Port 22: Connection timed out Issue . | AWS re:Post
Blank screen on web based SSH console and terminal SSH | AWS re:Post
Can not connect to lightsail server even on web ssh, port is open | AWS re:Post

respondido hace 3 meses
AWS
EXPERTO
revisado hace 3 meses

No has iniciado sesión. Iniciar sesión para publicar una respuesta.

Una buena respuesta responde claramente a la pregunta, proporciona comentarios constructivos y fomenta el crecimiento profesional en la persona que hace la pregunta.