AWS Classroom notes 09/Feb/2024

Combining metrics and Alarms

  • Create an ec2 instance with ubuntu
  • install a tool called stress
sudo apt update
sudo apt install stress -y
  • Then we will use stress to increase cpu utilzation then lets take some action
stress --cpu 8 --io 4 --vm 2 --vm-bytes 128M --timeout 15m -v
  • Try to figure out a way to restart ec2 when cpu utilzation > 80% for last 5 minutes



Scheduling starts and stops of ec2 instances

  • Scheduling ec2 instances with tag env:dev to
    • start ec2 instances on every weekday at 10:00 AM
    • stop ec2 instances on every weekday at 5:00 PM
  • In AWS if we have to perform activities on schedule
  • AWS supports create a scheduler with EventBridge Refer Here and Refer Here
  • TBD: We will solve this in next session
Published
Categorized as Uncategorized Tagged

By continuous learner

devops & cloud enthusiastic learner

Leave a comment

Turn on JavaScript to leave a comment.

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Please turn AdBlock off
Floating Social Media Icons by Acurax Wordpress Designers
Exit mobile version
%%footer%%