Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Amazon Cloudwatch alarm not triggered

I have a cloudwatch alarm configured :

Threshold : "GreaterThan 0" for 1 consecutive period,

Period : 1 minute,

Statistic : Sum

The alarm is configured on top of AWS SQS NumberOfMessagesSent. The queue was empty and no messages were being published to it. I sent a message manually. I could see the spike in metric but state of alarm was still OK. I am a bit confused why this alarm is not changing its state even though all the conditions to trigger this are met.

like image 374
Juhi Kulshreshtha Avatar asked Jul 09 '15 19:07

Juhi Kulshreshtha


People also ask

Why didn't ti receive SNS notification for my CloudWatch alarm trigger?

To determine why you're not receiving SNS notifications, check the history of the CloudWatch alarm to find the status of the trigger action. SNS restricts the sources that can publish messages to the topic using access policies.

How do I turn on my CloudWatch alarm?

Open the Amazon EC2 console at https://console.aws.amazon.com/ec2/ . In the navigation pane, choose Instances. Select the instance and choose Actions, Monitor and troubleshoot, Manage CloudWatch alarms. On the Manage CloudWatch alarms detail page, under Add or edit alarm, select Create an alarm.

How do I test my AWS CloudWatch alarm?

To test notifications to configured chat clientsOpen the CloudWatch console at https://console.aws.amazon.com/cloudwatch/ . In the navigation pane, choose Alarms, Create alarm. Select the correct AWS Region at the top right of the AWS console, that contains the Amazon SNS topic you need.


1 Answers

I just overcame this problem with the help of AWS support. You need to set the period on your alarm to ~15 minutes. It's got to do with how SQS marks the event's timestamps as it pushes them to CloudWatch.

Don't worry, as setting the period to a greater number will not affect how quickly you are alerted of an alarm. It will still get data from SQS every 5 minutes.

like image 163
Joe Essey Avatar answered Nov 16 '22 00:11

Joe Essey