Memory Usage Alarm Script

Source: Internet
Author: User

application mail alert, server to install SendMail service and start1. free memory 100MB, send email alerts, email messages, real-time monitoring #!/bin/bash# less than 100MB of usable memory, e-mail SMS alarm mem_free= ' free-m | awk '/cache:/ {print $4} 'if [$mem _free-lt] Thenecho " memory alarm " | Mail-s " memory less than 100Mb" [email protected] fi    2. memory utilization is greater than 85%, alarm #!/bin/bash# Memory usage is greater than 85%, mail SMS alarm #20161213mem_used= ' free-m | awk '/cache:/ {Print int ($3/($3+$4) *100)} 'if [$mem _used-gt] Thenecho " memory alarm " | Mail-s " memory utilization exceeds 85%" [email protected] fi 

Memory Usage Alarm Script

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.