EC2 Instances: Status Checks
EC2 Instances: Status Checks
Status checks will get performed each and every minute, while returning a status of either a pass or a fail. In case every single one of the checks pass, the final status of the instance is going to be OK. In case 1 or more checks tend to fail, the final status will be impaired. Status checks will be built into Amazon EC2, which means that they are not capable of being disabled or deleted.
The moment a status check fails, the associated CloudWatch metric for status checks will get incremented. You get the chance to utilize those metrics for the sake of creating CloudWatch alarms which get triggered according to the result of status checks. As an example, you may possibly get an alarm created for the sake of warning you when any status checks fail on a particular chosen instance.
You get the chance to create an Amazon CloudWatch alarm as well which will be monitoring an Amazon EC2 instance and automatically recovering it in case it turns impaired because of an underlying issue occurring.
Status Checks types:
You can find that there are 2 types of status checks:
- System status checks
- Instance status checks
Ho do System Status Checks Work?
– To monitor the AWS systems where your instance tends to be running.
– Those checks can detect underlying problems found within your instance and need the AWS involvement for getting it repaired.
– The moment a system status check tends to fail, you get the possibility to either go with waiting for AWS till it fixes the issue, or you can simply go ahead and resolve it on your own. Instances that are backed by Amazon EBS, are capable of being stopped and started by your own doing, and this will in a lot of cases end up in the instance getting migrated to another new host. Instances that are backed by the instance store, may be terminated and replaced by you.
The below mentioned are a couple of examples regarding problems that may result in system status checks failure:
– Network connectivity lost
– System power lost
– The physical host having software issues
– The physical host having hardware issues which affect the network’s reachability
How do Instance Status Checks Work?
– To monitor the network and also software configuration of individual instances.
– Amazon EC2 will start checking the health of your instance through sending an address resolution protocol -ARP- request straight to the network interface (NIC).
– Those checks are going to start detecting problems which need your help in getting them repaired.
– The moment an instance status check tends to fail, you will mainly need to get the problem addressed by yourself, such as tending to reboot the instance or through performing a couple of instance configuration alterations.
The below listed show examples of hardships which may cause the failure of instance status checks:
– Failed system status checks
– Incorrect networking / startup configuration
– Overloaded memory
– File system which is Corrupt
– Kernel which is Incompatible
View Status Checks
Amazon EC2 allows you to view and also work with status checks using several ways.
How to View Status Through the Console?
It is possible for you to view status checks through the use of AWS Management Console.
For viewing status checks using the console
- Go to the Amazon EC2 console using this link https://console.aws.amazon.com/ec2/.
- From navigation pane, select Instances.
- From the Instances page, you can find the Status Checks column which lists the operational status of every single instance.
- For viewing the status of a particular instance, choose the instance you want, and later on click on the Status Checks
In you have gotten an instance having a failed status check and this instance was in an unreachable state for more than 20 minutes, select AWS Support so that you get to submit a request for having some assistance.
- For reviewing the CloudWatch metrics for your status checks, choose the instance you want, and later on click on the Monitoring Scroll down till you can finally see the graphs displayed for the below listed metrics:
– Status Check Failed (Any)
– Status Check Failed (Instance)
– Status Check Failed (System)
How to View Status Through the Command Line?
It is possible to start viewing status checks for your running instances through the use of the describe-instance-status command of AWS CLI.
for viewing the status of every one of the instances, you can utilize the below shown command.
aws ec2 describe-instance-status
For getting the status of every one of the instances having an instance status of impaired, you can utilize the below shown command.
aws ec2 describe-instance-status –filters Name=instance-status.status,Values=impaired
For getting the status of just one instance, you can utilize the below shown command.
aws ec2 describe-instance-status –instance-ids i-1234567890abcdef0
Otherwise, you can alternatively rely on the below commands:
- Get-EC2InstanceStatus –AWS Tools for Windows PowerShell–
- DescribeInstanceStatus –Amazon EC2 Query API–
EC2 instances status check alarms