• Home
  • About
  • AWS Management
  • Services
    • Complete Server Management
    • Dedicated Team
    • Semi Dedicated Team
    • Shared Plan
    • Help Desk Support
    • White Label Support
  • Platform
    • Cloud Computing
    • WordPress Management
  • Resources
    • FAQ
    • Blog
  • Contact

We3Cares infiltrated the Web Hosting Industry in 2008 and we began our operations harbouring our infrastructure, tech-support and competent in-house staff. We are proportional to mute agents who assist you with uncompromised palpable customer support on web hosting. The team exhibits high proficiency to furnish you with, 24/7 lucid, REAL-TIME support.

  • E1,MSM plaza,4th floor,Landmark Redwood Furnitures, Outer Ring Road, Service Lane, Near-Horamavu Underpass, Banasawadi,Bangalore 560043, Karnataka, India
  • +91 - 80 - 42214548
  • sales@We3cares.com
    • Home
    • About
    • AWS Management
    • Services
      • Complete Server Management
      • Dedicated Team
      • Semi Dedicated Team
      • Shared Plan
      • Help Desk Support
      • White Label Support
    • Platform
      • Cloud Computing
      • WordPress Management
    • Resources
      • FAQ
      • Blog
    • Contact
  • sales@We3cares.com
  • +91 93794 06374
We3cares
We3cares
  • Home
  • About
  • AWS Management
  • Services
    • Complete Server Management
    • Dedicated Team
    • Semi Dedicated Team
    • Shared Plan
    • Help Desk Support
    • White Label Support
  • Platform
    • Cloud Computing
    • WordPress Management
  • Resources
    • FAQ
    • Blog
  • Contact

AWS Custom Cloudwatch Alarm in AWS-Ubuntu-Linux

We3cares > IT Technology > AWS Custom Cloudwatch Alarm in AWS-Ubuntu-Linux

AWS Custom Cloudwatch Alarm in AWS-Ubuntu-Linux

Let us create custom alarm for disk space utilization metric on EBS Volume of EC2 instances with following steps.

  1. cd /tmp
  2. wget https://s3.amazonaws.com/amazoncloudwatch-agent/amazon_linux/amd64/latest/amazon- cloudwatch-agent.rpm
  3. sudo rpm -U amazon-cloudwatch-agent.rpm
  4. In IAM, you need to select necessary Role and attach necessary policy for CloudWatch
  5. Take backup of files under /opt/aws/amazon-cloudwatch-agent/etc/
  6. Run – sudo nano /opt/aws/amazon-cloudwatch-agent/etc/amazon-cloudwatch-agent.json
  7. Copy and Paste the following JSON string in amazon-cloudwatch-agent.json, change value for InstanceId and save

{

“agent”: { “metrics_collection_interval”: 60, “run_as_user”: “cwagent”

},

“metrics”: { “metrics_collected”: { “disk”: { “measurement”: [

“used_percent”

],

“resources”: [ “*”

],

“drop_device”: false

},

“processes”: { “measurement”: [ “running”, “sleeping”, “dead”

]

}

},

“append_dimensions”: { “InstanceId”: “i-xxxxxxxxxxxx”

}

}

}

  1. sudo systemctl restart amazon-cloudwatch-agent
  2. sudo /opt/aws/amazon-cloudwatch-agent/bin/amazon-cloudwatch-agent-ctl -m ec2 -a status
    1. “status” : “running” should appear
  3. tail -f /opt/aws/amazon-cloudwatch-agent/logs/amazon-cloudwatch-agent.log
  4. Any error should not appear in the log
  5. Open AWS Management Console, go to CouldWatch, select Alarms, Click “Create Alarm” and click “Select Metric”

Click Create Alarm

Click Select metric

Click CW Agent

Click device…

Select xvda1

Click Select metric

Go with default

Select as given in the above image and click Next


Give Topic Name and email as preferred and click Next

Provide Alarm name and description as preferred and click Next Then, Preview and Click Create alarm. Done

  1. You will get confirmation mail for new topic, you should confirm and few minutes status pending confirmation will go
  2. In the alarm screen, blue line for disk usage and red line for threshold should appear
  3. If disk usage is equal or greater (based on condition given), status goes into alarm, alarm email will be sent

Good Luck

–      Kuppuram, CTO, We3cares

  • Previous Average Ticket Resolution Time KPI

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

We3cares
We3Cares infiltrated the Web Hosting Industry in 2008 and we began our operations harbouring our infrastructure, tech-support and competent in-house staff. We are proportional to mute agents who assist you with uncompromised palpable customer support on web hosting. The team exhibits high proficiency to furnish you with, 24/7 lucid, REAL-TIME support.

Discover More

Contact Info

  • E1,MSM plaza,4th floor,Landmark Redwood Furnitures, Outer Ring Road, Service Lane, Near-Horamavu Underpass, Banasawadi,Bangalore 560043, Karnataka, India.
  • +91 - 80 - 42214548
  • sales@We3cares.com
  • Home
  • About
  • AWS Management
  • Services
    • Complete Server Management
    • Dedicated Team
    • Semi Dedicated Team
    • Shared Plan
    • Help Desk Support
    • White Label Support
  • Platform
    • Cloud Computing
    • WordPress Management
  • Resources
    • FAQ
    • Blog
  • Contact

© Copyright 2021 We3cares. All Rights Reserved.