Granfana設置郵件告警


  環境查看

 

   查看granfana版本

 

   也可以使用以下方法查看版本

grafana-server -v

 

 

   設置郵件發送者信息

  報警granfana配置文件添加郵件配置信息

/etc/grafana/grafana.ini 

 

[smtp]
#開啟smtp
enabled = true
#郵箱發送地址及端口
host = smtp.exmail.qq.com:25
#郵箱用戶名
user = xxx@xxx.xx 
# If the password contains # or ; you have to wrap it with triple quotes. Ex """#password;"""
#郵箱密碼
password = xxxx
;cert_file =
;key_file =
;skip_verify = false
from_address = xx@xxx.xx
from_name = xx
# EHLO identity in SMTP dialog (defaults to instance_name)
;ehlo_identity = dashboard.example.com
# SMTP startTLS policy (defaults to 'OpportunisticStartTLS')
;startTLS_policy = NoStartTLS

   重啟granfana服務器

systemctl restart grafana-server

   granfana添加告警

 

 

 

   設置好的郵箱會收到測試郵件

 

   針對具體監控項配置告警

 

   當觸發告警則發送郵件

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM