参考网页:https://my.oschina.net/wangyunlong/blog/3060776

global:

scrape_interval:             15s

evaluation_interval:        15s

alerting:

alertmanagers:

- static_configs:

- targets:

rule_files:

- /usr/local/prometheus/rule/node.yml       #配置recording rules

- /usr/local/prometheus/rule/alert.yml        #配置alert rules

scrape_configs:

-  job_name: 'prometheus'                        #监控prometheus本身

static_configs:

- targets: [""]

- job_name: 'node'                             #配置target

file_sd_configs:                                #可自动刷新

- files:

- /usr/loal/prometheus/conf/node.yml

- job_name: 'mysql'                               #配置target

file_sd_configs:                                #可自动刷新

- files:

- /usr/loal/prometheus/conf/mysql.yml

###### /usr/loal/prometheus/conf/node.yml配置#############

- targets: ["xxxx"]

labels:

type:

host:

alias:

######## /usr/local/prometheus/rule/alert.yml ###############

groups:

- name: alert

rules:

-  alert: cpu_utilization_ratio

expr: 100 - (avg by (instance) (irate(node_cpu_seconds_tital[5m]))*100) >90

for: 10m

labels:

severity: page

annotations:

summary: High request latency

最新文章

  1. Sublime中Markdown的安装与使用
  2. Jetty应用服务器的安装详解
  3. 【bzoj2049】洞穴勘测
  4. 【转载】Unix Shell中用[-n]判断字符串不为NULL
  5. iOS开发如何提高(from 唐巧的博客)
  6. Android之自定义控件入门
  7. python抓取性感尤物美女图
  8. HDOJ 1226 超级密码
  9. 设备\Device\Harddisk1\DR1 有一个不对的区块
  10. ASP.NET- LinkButton 传递多个参数
  11. string.Format 日期格式化
  12. CreateLiveCMSV4.0 漏洞,无需后台Get shell
  13. mybatis和hibernate对比
  14. Windows phone 8 学习笔记
  15. 排序算法门外汉理解-Shell排序
  16. 主成分分析(Principal components analysis)-最大方差解释
  17. 如何在container中编译dotnet的eShopOnContainers
  18. h5开发app之在线生成二维码
  19. Discuz搜索改为指向帖子
  20. mybatis源码之MapperMethod

热门文章

  1. [Codeforces #615 div3]1294E Obtain a Permutation
  2. LCS(Longest Common Subsequence)最长公共子序列
  3. 使用onclick报SyntaxError: identifier starts immediately after numeric literal
  4. spring中的@Transactional注解
  5. vs2010编译C++ 静态成员函数的引用
  6. string.xml中的空格
  7. Ubuntu18.04 LTS 搭建Cassandra集群
  8. poj 2456 Aggressive cows 贪心+二分
  9. python --- mysql数据库的操作
  10. POJ 3916:Duplicate Removal 将相近的重复元素删除