[Recipes] Using Amazon CloudWatch with Amazon EC2

Problem: 

Get famiiar with Amazon CloudWatch and use it to monitor Amazon EC2.

Solution Summary: 

Amazon CloudWatch is a monitoring service for AWS cloud resources and the applications you run on AWS. Amazon CloudWatch Events delivers a near real-time stream of system events that describe changes in Amazon Web Services (AWS) resources. You can use Amazon CloudWatch Logs to monitor, store, and access your log files from EC2 instances, AWS CloudTrail, and other sources. The CloudWatch Alarms feature allows you to watch CloudWatch metrics and to receive notifications. Read more here.

Solution Steps: 

Steps:

  1. Get inside AWS console and go to CloudWatch.

  2. Click on Metrics and explore the metrics available.

  3. Click on Dashboards and then click on ‘Create Dashboard’.

  4. Give a name (e.g. Buddy Overview), Select the widget type as Metric Graph, Click Configure.

  5. Go to per-instance metrics under EC2 metrics section. You will find CPU, Disk, Network and Status metrics, but not Memory. Select CPU Utilization and go to next page.

  6. Change few parameters for the widget (e.g. last 1 hour) and verify.

  7. Add a new widget to your dashboard by clicking on ‘Add Widget’.

  8. Click on Events and read the description and examples provided.

  9. Click on Logs and read the description about CloudWatch logs.

  10. Click on Alarms and create an alarm to email you, if cpu utilization goes beyond 50% in 1 minute. Have a look at other actions available such as Autoscaling, EC2 Action.

Learn Serverless from Serverless Programming Cookbook

Contact

Please first use the contact form or facebook page messaging to connect.

Offline Contact
We currently connect locally for discussions and sessions at Bangalore, India. Please follow us on our facebook page for details.
WhatsApp (Primary): (+91) 7411174113
Phone (Escalations): (+91) 7411174114

Business newsletter

Complete the form below, and we'll send you an e-mail every now and again with all the latest news.

About

CloudMaterials is my blog to share notes and learning materials on Cloud and Data Analytics. My current focus is on Microsoft Azure and Amazon Web Services (AWS).

I like to write and I try to document what I learn to share with others. I believe that knowledge is useless unless you share it; the more you share, the more you learn.

Recent comments

Photo Stream