暂无图片
暂无图片
1
暂无图片
暂无图片
暂无图片
prometheus配置MySQL邮件报警.pdf
61
7页
2次
2024-08-15
免费下载
2020/2/27 prometheus配置MySQL邮件报警
https://mp.weixin.qq.com/s?__biz=MzU0MTczNzA1OA==&mid=2247485355&idx=1&sn=968de9be971b87703b20ad3cae0d51c0&chksm=fb242ea…
1/7
prometheus配置MySQL邮件报警
作者 李文航 · 沃趣科技数据库技术专家
出品 沃趣科技
前两期文章(引用沃趣技术——《prometheus监控多个MySQL实例》《构建狂拽炫酷屌的MySQL监控平
台》)介绍了prometheus、grafana、exporter的安装以及集中监控mysql节点的方法,这篇文章介绍一下
prometheus的邮件报警配置。
alertmanager下载
prometheus报警配置需要用到alertmanager组件,这个组件可以到prometheus官网上进行下载。
https://prometheus.io/download/
由于最新版本的alertmanager组件配置邮箱通讯存在一些问题,我们这里选择在github上下载0.14版本的
alertmanager。
https://github.com/prometheus/alertmanager
2020/2/27 prometheus配置MySQL邮件报警
https://mp.weixin.qq.com/s?__biz=MzU0MTczNzA1OA==&mid=2247485355&idx=1&sn=968de9be971b87703b20ad3cae0d51c0&chksm=fb242ea…
2/7
附具体下载地址:
https://github.com/prometheus/alertmanager/releases/download/v0.14.0/alertmanager-0.14.0.linux-
amd64.tar.gz
alertmanager安装配置
将下载的alertmanager包进行解压安装。
tar -xf alertmanager-0.14.0.linux-amd64.tar.gz
mv alertmanager-0.14.0.linux-amd64 /data/alertmanager
编辑alertmanager的配置文件,添加邮箱信息。
# cd /data/alertmanager
# cat alertmanager.yml
global:
smtp_smarthost: smtp.exmail.xxx.com:465 # 发件人邮箱smtp地址
smtp_auth_username: xxxx@xxx.com # 发件人邮箱账号
smtp_from: xxx@xxx.com # 发件人邮箱账号
smtp_auth_password: xxxxxx # 发件人邮箱密码
resolve_timeout: 5m
smtp_require_tls: false
route:
# group_by: ['alertname'] # 报警分组依据
group_wait: 10s # 最初即第一次等待多久时间发送一组警报的通知
group_interval: 10s # 在发送新警报前的等待时间
repeat_interval: 1m # 发送重复警报的周期 对于email配置中多频繁
receiver: 'email'
receivers:
- name: email
email_configs:
- send_resolved: true
to: xxx@xxx.com # 收件人邮箱账号
of 7
免费下载
【版权声明】本文为墨天轮用户原创内容,转载时必须标注文档的来源(墨天轮),文档链接,文档作者等基本信息,否则作者和墨天轮有权追究责任。如果您发现墨天轮中有涉嫌抄袭或者侵权的内容,欢迎发送邮件至:contact@modb.pro进行举报,并提供相关证据,一经查实,墨天轮将立刻删除相关内容。

评论

关注
最新上传
暂无内容,敬请期待...
下载排行榜
Top250 周榜 月榜