I’m stuck on the C2_W3 Lab 2 assignment. Following the lab instructions, I open the AWS console and try to connect to the bastion host using EC2 Instance Connect, but the connection always fails with this error:
No se pudo conectar a la instancia Error al establecer la conexión SSH con la instancia. Inténtelo de nuevo más tarde.
(In English: “Could not connect to the instance — Error establishing SSH connection to the instance. Please try again later.”)
What I have already checked, and everything looks correct:
- The instance
de-c2w3lab2-bastion-hostis in staterunning, and both status checks areok - The public IP shown in the console matches the instance’s actual public IP
- The security group allows inbound TCP port 22 from
0.0.0.0/0(confirmed withdescribe-security-groups) - The
user_datascript completed successfully — the instance console output shows cloud-init finished andpostgresql-clientwas installed - The SSH key
de-c2w3lab2-bastion-host-keyis present in/home/ubuntu/.ssh/authorized_keys - I restarted the lab session and re-ran
source scripts/setup.sh; AWS credentials work fine (aws sts get-caller-identityreturns my voclabs ARN) - The lab says to connect to the DB through the bastion host, but it doesn’t describe what to do when this error appears.