prometheus监控带安全认证的elasticsearch

1.下载elasticsearch_exporter

wget 下载二进制包并解压、运行:

wget https://github.com/prometheus-community/elasticsearch_exporter/releases/download/v1.3.0/elasticsearch_exporter-1.3.0.linux-amd64.tar.gz

tar -xvf elasticsearch_exporter-1.3.0.linux-amd64.tar.gz

mv elasticsearch_exporter-1.3.0.linux-amd64/ elasticsearch_exporter

cd elasticsearch_exporter

2.运行elasticsearch_exporter:

nohup ./elasticsearch_exporter --es.all --es.indices --es.cluster_settings --es.indices_settings --es.shards --es.snapshots --es.timeout=10s --web.listen-address=":9114" --web.telemetry-path="/metrics" --es.uri http://elastic:FtBMPT31rPiQ@192.168.2.40:9200 &

(uri中要写成自己es的用户和密码)

查看输出日志:

3.看指标信息:

web 访问

4.启动好后来prometheus添加配置

编辑prometheus.yml

  • job_name: "es"

static_configs:

  • targets: "192.168.2.40:9114"

  • targets: "192.168.2.41:9114"

  • targets: "192.168.2.42:9114"

  1. 登录prometheus http://192.168.2.xx:9090/上

6.配置完成后在Grafana官网中下载es的监控模板 Dashboards | Grafana Labs 下载es的模板

Elasticsearch Exporter Quickstart and Dashboard | Grafana Labs

7.添加Prometheus 数据源

8.选择 Prometheus

9.导入监控 Dashboard 模板

10.查看指标信息是否有数据

至此,配置完成!

相关推荐
吴声子夜歌几秒前
Docker入门与实战——常见问题总结
运维·docker·容器
是jin奥6 分钟前
最新 FFmpeg 安装脚本:Linux x86_64
linux·运维·ffmpeg
全栈技术负责人26 分钟前
AI 自动化单元测试技术方案
运维·单元测试·自动化
Shadow(⊙o⊙)27 分钟前
仿muduo实现高并发服务器——EventLoop.hpp初步设计(未纳入超时管理模块)
运维·服务器
nlp研究牲1 小时前
Linux 常用命令速查手册:英文全称、中文释义、巧记方法与实战示例
linux·运维·php
众壹新能源科技1 小时前
逆变器半夜停机等备件48小时少发10万度电,备件安全库存怎么算
大数据·运维·安全
广州智造1 小时前
Radioss破坏模型FAILJOHNSON (Johnson-cook) 和 FAILTAB1
运维·数据库·自动化·仿真·建模·后处理·前处理
味悲1 小时前
Nginx笔记
linux·运维·笔记·nginx
电商全栈程序猿1 小时前
2026 开源商城系统选型指南:开发者实测对比Tigshop、ShopXO、CRMEB
java·运维·开源
时间售卖铺1 小时前
MySQL 库表设计:数据库范式详解
运维·数据库·mysql·云原生