python - Alarm Action "Terminate EC2 Instance" failed -


when start type of instance userdata-script creates metric + alarm via boto. metric delivers data cloudwatch correctly. alarm should terminate instance action if condition based on metric matches. in cloudwatch alarm seems created correctly , switches alarm-states desired.

but: when comes execute action fails following "history" entry: alarm updated from

  • ok alarm. reason: threshold crossed: 5 datapoints greater threshold (200.0). recent datapoints: 999.0, 999.0.
  • arn:aws:automate:eu-west-1:ec2:terminate in progress.
  • terminate ec2 instance 'i-xxx' action failed. aws not able validate provided access credentials.

screenshot of alarm history

i've granted policy "administratoraccess" "userdata"-role attached instance.

any hints?

regards tom

i believe issue. developer guide:

if using iam role (e.g., amazon ec2 instance profile), cannot stop or terminate instance using alarm actions. however, can still see alarm state , perform other actions such amazon sns notifications or auto scaling policies.

i posted in aws forum issue myself: https://forums.aws.amazon.com/message.jspa?messageid=601951


Comments

Popular posts from this blog

php - mySql Join with 4 tables -

css - Text drops down with smaller window -

c# - DetailsView in ASP.Net - How to add another column on the side/add a control in each row? -