redis启动没反应_Promethues如何针对Redis进行监控
生活随笔
收集整理的这篇文章主要介绍了
redis启动没反应_Promethues如何针对Redis进行监控
小编觉得挺不错的,现在分享给大家,帮大家做个参考.
需求:采用redis_exporter 收集数据,promethus采集redis_exporter数据,granfana展示数据
一、简易安装redis
yum install -y redisrpm -qa |grep redislsof -i :6379rpm -ql redissystemctl start redis- 找到配置文件/etc/redis.conf,修改 requirepass QpMD61xo
- 重启动redis systemctl restart redis
二、下载redis_exporter 收集redis数据
wget https://github.com/oliver006/redis_exporter/releases/download/v1.4.0/redis_exporter-v1.4.0.linux-amd64.tar.gztar zxvf redis_exporter-v1.4.0.linux-amd64.tar.gzmv redis_exporter-v1.4.0.linux-amd64 /usr/local/exporter/redis_exportercd /usr/local/exporter/redis_exporter## 有密码nohup ./redis_exporter -redis.addr 127.0.0.1:6379 -redis.password QpMD61xo ## 无密码nohup ./redis_exporter -redis.addr 192.168.1.120:6379 &- 日志信息
- 查看redis_exporte是否开启 lsof -i:9121
三、配置promethus 采集数据
- 修改prometheus配置文件 vim /usr/local/prometheus/prometheus.yml
- 重载配置文件
四、granfna配置
- 配置prometheus数据源,添加prometheus插件,导入763模板 https://grafana.com/grafana/dashboards/763/revisions
注意 redis 添加密码后,一定要重启动redis服务,否则granfna获取不到数据。(折腾了半天没数据。。)
总结
以上是生活随笔为你收集整理的redis启动没反应_Promethues如何针对Redis进行监控的全部内容,希望文章能够帮你解决所遇到的问题。
- 上一篇: python运动目标检测与跟踪_基于Op
- 下一篇: 悲观锁和乐观锁_带你了解MySQL中的乐