elasticsearch watcher 郵件通知配置


elasticsearch各節點操作


# 安裝郵件發送客戶端工具mailx
yum install -y mailx

# elasticsearch.yml 添加以下配置
xpack.notification.email.account:
    work:
        profile: standard
        email_defaults:
            from: sender@domain.com
        smtp:
            auth: true
            starttls.enable: false     # 使用TLS無法連接,原因未知
            host: smtp.exmail.qq.com   # 騰訊企業郵箱
            port: 21
            user: sender@domain.com

# 執行以下命令設置發送者的郵箱秘密
/usr/share/elasticsearch/bin/elasticsearch-keystore add xpack.notification.email.account.work.smtp.secure_password
- Enter value for xpack.notification.email.account.work.smtp.secure_password:     

# 執行以下命令查看密碼文件是否生成
/usr/share/elasticsearch/bin/elasticsearch-keystore list
- keystore.seed
- xpack.notification.email.account.work.smtp.secure_password

# 重啟各節點的elasticsearch 服務
systemctl restart elasticsearch

登錄kibana配置watcher



測試發送郵件

測試郵件接收


免責聲明!

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



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