Unable to connect to EC2 instance using Public IP address with ssh

0

Hi.. i am new to AWS and learning.
I've launched a new Amazon Linux 2 EC2 instance, but not able to connect to it using SSH with the public IP address allocated.
Please note that I created a new VPC ( with new CIDR block - 10.77.0.0/16 ) and assigned here.

Prior to this, when I created the same Amazon Linux 2 EC2 instance with default VPC, i was able to connect with ssh.
Any help would be highly appreciated.

Thank you,

Edited by: NewOnCloud on May 6, 2020 11:38 AM

preguntada hace 4 años2656 visualizaciones
3 Respuestas
0
  1. did you confirm the security group has an inbound rule to allow port 22 from your ip address (Don't open it to all traffic!!!)
  2. Is the ec2 launched in a public subnet? A public subnet is defined as one that has an associated route table with an entry for 0.0.0.0/0 to an Internet Gateway (igw).

It's either one of those two issues, or you have a firewall issue on the ec2..which is unlikely.

respondido hace 4 años
0

Thank you very much my friend.
Looks like I needed to create a new internet gateway and add it to the route table that was missing.

respondido hace 4 años
0

Anytime.

respondido hace 4 años

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.

Pautas para responder preguntas