Test Amazon CloudWatch Alarms for EC2 CPU Utilization | SysOps Administrator Exam Answer | [Your Website Name]

Testing Amazon CloudWatch Alarms for EC2 CPU Utilization

Question

A critical financial application is deployed on Amazon EC2 instances.

Amazon CloudWatch Alarms are created to notify Amazon SNS topics when Amazon EC2 instance CPU utilization exceeds 70%

The team lead is looking to test these alarms before deploying EC2 instances to production. How should a Sysops administrator perform testing of the Amazon CloudWatch Alarms in the most effective way?

Answers

Explanations

Click on the arrows to vote for the correct answer

A. B. C. D.

Correct Answer: C.

For testing of alarms created using Amazon CloudWatch Alarms, SetAlarmState API action or the set-alarm-state command in the AWS CLI can be used.

This will temporarily change the alarm state to ALARM, which will initiate a notification to the Amazon SNS topic.

Option A is incorrect as using third-party tools on Amazon EC2 instances to elevate CPU is not a suggested option to test CloudWatch alarms.

Option B is incorrect as this rule will check if CloudWatch alarms have at least one alarm action & will not perform alarm testing.

Option D is incorrect as this rule will check if CloudWatch alarms have specific settings & will not perform alarm testing.

For more information on testing Amazon CloudWatch Alarms, refer to the following URL,

https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/AlarmThatSendsEmail.html

To test the Amazon CloudWatch Alarms before deploying EC2 instances to production, the SysOps administrator can use the SetAlarmState API call or the cloudwatch-alarm-action-check rule from AWS Config.

Option A: Use third-party tools on Amazon EC2 instances to elevate CPU load which in turn will trigger an alarm sending notification to Amazon SNS topic. This option can be used to test the CloudWatch Alarms, but it may not be the most effective way as it requires additional configuration and setup of the third-party tools on the EC2 instances.

Option B: Use cloudwatch-alarm-action-check rule from AWS Config to trigger an alarm sending notification to Amazon SNS topic. This option is a better way to test the CloudWatch Alarms as it allows the administrator to simulate the alarm by triggering the alarm action. The cloudwatch-alarm-action-check rule from AWS Config checks whether CloudWatch alarm actions have been triggered correctly by evaluating the latest state of each alarm and the actions that have been triggered.

Option C: Use SetAlarmState API call to trigger an alarm sending notification to Amazon SNS topic. This option can also be used to test the CloudWatch Alarms. The SetAlarmState API call can be used to set the state of an alarm to a specified value, which in turn will trigger the alarm action. However, this option requires the administrator to have knowledge of the API call and its usage.

Option D: Use cloudwatch-alarm-settings-check rule from AWS Config to trigger an alarm sending notification to Amazon SNS topic. This option is not relevant to the scenario as the cloudwatch-alarm-settings-check rule from AWS Config checks whether CloudWatch alarms are configured with recommended settings.

In conclusion, the most effective way to test the Amazon CloudWatch Alarms in this scenario is to use the cloudwatch-alarm-action-check rule from AWS Config or the SetAlarmState API call.