wesupport

25% off on first invoice for all services*

SPRING SALE

Use coupon

*Offer valid for new customers only

25% off on first invoice for all services*

SPRING SALE

Use coupon

*Offer valid for new customers only

Need help?

Our experts have had an average response time of 11.43 minutes in March 2024 to fix urgent issues.

We will keep your servers stable, secure, and fast at all times for one fixed price.

Instance terminates immediately error AWS – Fix it now

by | Aug 30, 2020

Trying to find a solution to ‘instance terminates immediately error’ in AWS? We can help you with it.

Here at Bobcares, we have seen several such AWS related queries as part of our AWS Support Services for AWS users, and online service providers.

Today we’ll take a look at the causes for this error and see how to fix it.

 

Why does ‘instance terminates immediately’ error occurs in AWS

There are different reasons for an instance to terminate immediately after launching or starting it. Here are some of them.

  • Reaching the EBS volume limit.
  • Corruption of EBS snapshot
  • You do not have permission to access the KMS key for decryption since the root EBS volume is encrypted.
  • The instance store-backed AMI that you used to launch the instance is missing a required part (an image.part.xx file).

 

How to fix ‘Instance terminates immediately’ error in AWS

First, we need to find the reason for this error in order to resolve it. We can find it through the Amazon EC2 console or AWS Command Line Interface to get the termination reason.

 

Here are the steps to find the termination reason through the Amazon EC2 console

  1. First, open the Amazon EC2 console using the link: https://console.aws.amazon.com/ec2/
  2. Then in the left navigation pane, choose Instances, and select the instance.
  3. After that, from the Description tab, you can find the reason next to the State transition reason label. Now, note it down.

 

Here are the steps to find the termination reason through the AWS Command Line Interface

  1. Run the below describe-instances command and specify the instance ID.
  2. aws ec2 describe-instances –instance-id instance_id
  3. As a result, of the above command, a JSON result is received. Now, please note down the values in the StateReason response element.

For example, here is a code of ‘StateReason’ response element.

“StateReason”: {
“Message”: “Client.VolumeLimitExceeded: Volume limit exceeded”,
“Code”: “Server.InternalError”
},

 

The solution to ‘Instance terminates immediately’ error in AWS

Now let’s see the solution part of this error.

For instance, if the reason for the error is “Client.VolumeLimitExceeded: Volume limit exceeded” then you have reached the EBS volume limit.

In case, if the reason for the error is “Client.InternalError: Client error on launch” then it indicates that the root volume is encrypted but you have no permissions to access the KMS key for decryption. To get permission to access the required KMS key, add the appropriate KMS permissions to your IAM user.

[Need any further assistance in fixing AWS errors? – We are here to help you.]

 

Conclusion

In short, this immediate termination error occurs due to different reasons. Today, we saw how to find the reason for this error and solve it accordingly.

Get 24x7 monitoring for your AWS servers

There are proven ways to get even more out of your AWS Infrastructure! Let us help you.

Spend your time in growing business and we will take care of AWS Infrastructure for you.

GET STARTED

var google_conversion_label = "owonCMyG5nEQ0aD71QM";

0 Comments

Submit a Comment

Your email address will not be published. Required fields are marked *

Categories

Tags