Prometheus 監控 Redis

前言

Prometheus Exporter for Redis Metrics. Supports Redis 2.x, 3.x, 4.x, and 5.xlinux

Prometheus 監控 Redis

更新歷史

2019年03月23日 - 初稿git

閱讀原文 - https://wsgzao.github.io/post...github

擴展閱讀redis

redis_exporter - https://github.com/oliver006/...bash


Redis export 安裝和使用

# 下載redis_exporter
https://github.com/oliver006/redis_exporter/releases
cd /tmp
wget https://github.com/oliver006/redis_exporter/releases/download/v0.30.0/redis_exporter-v0.30.0.linux-amd64.tar.gz 
tar xf redis_exporter-v0.30.0.linux-amd64.tar.gz

# 後臺啓動redis_exporter
nohup ./redis_exporter -redis.addr redis://<IP>:<PORT> &

# iptables rule for Prometheus Redis 
-A INPUT -s xxx -p tcp --dport 9121 -j ACCEPT

# 測試URL獲取metrics
curl http://<IP>:9121/metrics

Grafana

Memory Usage 中 redis_config_maxmemory 若是沒法獲取到數據請自行定義 value

https://grafana.com/dashboard...curl

參考文獻

https://prometheus.io/docs/in...tcp

相關文章
相關標籤/搜索