Redis Overview
redis_exporter for redis
Redis_exporter
1.下载配置
下载文件:redis_exporter-v1.31.4.linux-amd64.tar.gz 解压:
tar -C /home -xvf redis_exporter-v1.31.4.linux-amd64.tar.gz && cd /home
mv redis_exporter-v1.31.4.linux-amd64 redis_exporter
配置systemd选项:
vim /usr/lib/systemd/system/redis_exporter.service
[Unit]
Description=Redis exporter
After=network.target
[Service]
User=prometheus
Group=prometheus
ExecStart=/home/redis_exporter/redis_exporter -redis.addr 10.1xx.1.2xx:6379
Type=simple
[Install]
WantedBy=multi-user.target
启动:
systemctl daemon-reload
systemctl start redis_exporter
systemctl status redis_exporter
systemctl enable redis_exporter
2.配置prometheus
添加至prometheus.yml:
- job_name: 'redis_exporter_targets' static_configs: - targets: - "10.1xx.1.2xx:6379" - "10.1xx.1.2xx:6379" - "10.1xx.1.2xx:6379" metrics_path: '/scrape' relabel_configs: - source_labels: [__address__] target_label: __param_target - source_labels: [__param_target] target_label: instance - target_label: __address__ replacement: "10.1xx.1.2xx:9121" # config for scraping the exporter itself - job_name: 'redis_exporter' static_configs: - targets: - "10.19.1.2xx:9121"
Data source config
Collector config:
Upload an updated version of an exported dashboard.json file from Grafana
Revision | Description | Created | |
---|---|---|---|
Download |
Redis
Monitor Redis with Grafana. Easily monitor your Redis deployment with Grafana Cloud's out-of-the-box monitoring solution.
Learn more