A connection to the ECC2 t2 micro instance could not be established


When trying to access my website I get the error: "ERR_CONNECTION_TIMED_OUT". When trying to investigate and connect to my EC2 instance, I get the following errors:

  • A connection to the instance could not be established
  • This instance type is not supported by the EC2 Serial Console. As additional information, the instance and the site were only working a few days ago, I have not made any changes neither on the instance nor on any configuration file.
asked 6 months ago137 views
1 Answer
Accepted Answer

Hello there!

The connection timed out error could be due to various factors such as:

  • Your security groups and network access control lists (NACLs) blocking traffic to and from your website.

  • The operating system has a firewall.

  • There is a firewall between the client and the server.

  • The host does not exist.

  • The following AWS video helps to solve the above mentioned factors:


    Please note that the above is a third-party video, therefore you must test the recommendations in a test environment before applying them on production.

AWS ec2 system level logs provides more details on operating system level problems such as use of proxy or system being overloaded till it fails to process the incoming requests on time (see reference 1).

To resolve this, you can configure the inbound traffic for your website to allow traffic from your ip address or your selected network of addresses in your security groups and NACLs (see reference 2).

The reason for the second issue is that the instance type you are trying to use is not supported for the EC2 serial console.

For supported instance types, please refer to the documentation on the provided link (see reference 3). 

To connect to your instance using the EC2 serial console, the instance type must be built on the AWS Nitro System, excluding bare metal instances.

For information about Instances built on the Nitro System, please see reference 4.

You can change the instance type by following the documentation (see reference 5). 


[1] https://docs.aws.amazon.com/managedservices/latest/userguide/access-to-logs-ec2.html

[2] https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/TroubleshootingInstancesConnecting.html#TroubleshootingInstancesConnectionTimeout

[3] https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/connect-to-serial-console.html#sc-prerequisites

[4] https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-types.html?icmpid=docs_ec2_console#ec2-nitro-instances

[5] https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-instance-resize.html

answered 6 months ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions