Score:1

How to configure commands to get executed automatically when AWS ec2 instance cpu utilization goes above certain percentage

ng flag

The commands on the instance that has high CPU like taking java thread dump, checking processes running and upload to s3

jp flag
Where do you want to execute commands? On the same host? On some other host?
es flag
For the first part of triggering an alarm when cpu usage goes above a threshold, you can take a look at - https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/US_AlarmAtThresholdEC2.html
Score:1
in flag

You can use Cloudwatch to monitor the CPU and run command via SSM when the specific threshold is reached

Follow this document to set this up: https://docs.aws.amazon.com/AmazonCloudWatch/latest/events/EC2_Run_Command.html

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.