redis监控redis-stat安装教程

2021年4月7日 6点热度 0条评论 来源: AscendKing

redis集群监控(redis-stat)

本文来自互联网,由本人亲测,可行

ps:亲测,是这样写,可用,时间=2020-02-12 14:45

 

1. 环境

redis集群版本: 3.2.1

CentOS Linux release 7.2.1511 (Core)

2. 安装包

eventmachine-1.2.3.gem、redis-stat-0.4.14.gem、thin-1.5.1.gem、daemons-1.1.9.gem

 

gem下载网站:https://rubygems.org/gems

redis-stat下载:https://github.com/junegunn/redis-stat

 

3. 安装过程

本来想用redislive监控但是按照完发现使用的python redis模块不支持集群连接。

 

gem install eventmachine-1.2.3.gem

gem install thin-1.5.1.gem

gem uninstall daemons

gem install daemons-1.1.9.gem

 

[root@EPC-SH-COL-06 RedisLive]# gem install redis-stat --no-document

Successfully installed redis-stat-0.4.14

WARNING: Unable to pull data from 'https://rubygems.org/': no such name (https://rubygems.org/specs.4.8.gz)

WARNING: Unable to pull data from 'https://rubygems.org/': no such name (https://rubygems.org/specs.4.8.gz)

WARNING: Unable to pull data from 'https://rubygems.org/': no such name (https://rubygems.org/specs.4.8.gz)

WARNING: Unable to pull data from 'https://rubygems.org/': no such name (https://rubygems.org/specs.4.8.gz)

WARNING: Unable to pull data from 'https://rubygems.org/': no such name (https://rubygems.org/specs.4.8.gz)

WARNING: Unable to pull data from 'https://rubygems.org/': no such name (https://rubygems.org/specs.4.8.gz)

WARNING: Unable to pull data from 'https://rubygems.org/': no such name (https://rubygems.org/specs.4.8.gz)

WARNING: Unable to pull data from 'https://rubygems.org/': no such name (https://rubygems.org/specs.4.8.gz)

WARNING: Unable to pull data from 'https://rubygems.org/': no such name (https://rubygems.org/specs.4.8.gz)

WARNING: Unable to pull data from 'https://rubygems.org/': no such name (https://rubygems.org/specs.4.8.gz)

WARNING: Unable to pull data from 'https://rubygems.org/': no such name (https://rubygems.org/specs.4.8.gz)

WARNING: Unable to pull data from 'https://rubygems.org/': no such name (https://rubygems.org/specs.4.8.gz)

WARNING: Unable to pull data from 'https://rubygems.org/': no such name (https://rubygems.org/specs.4.8.gz)

WARNING: Unable to pull data from 'https://rubygems.org/': no such name (https://rubygems.org/specs.4.8.gz)

WARNING: Unable to pull data from 'https://rubygems.org/': no such name (https://rubygems.org/specs.4.8.gz)

1 gem installed

3. 问题&解决

[root@EPC-SH-COL-06 RedisLive]# redis-stat

/usr/local/share/gems/gems/redis-3.0.2/lib/redis.rb:182: warning: wrong element type nil at 0 (expected array)

/usr/local/share/gems/gems/redis-3.0.2/lib/redis.rb:182: warning: ignoring wrong elements is deprecated, remove them explicitly

/usr/local/share/gems/gems/redis-3.0.2/lib/redis.rb:182: warning: this causes ArgumentError in the next release

/usr/local/share/gems/gems/redis-3.0.2/lib/redis.rb:182: warning: wrong element type nil at 19 (expected array)

/usr/local/share/gems/gems/redis-3.0.2/lib/redis.rb:182: warning: ignoring wrong elements is deprecated, remove them explicitly

/usr/local/share/gems/gems/redis-3.0.2/lib/redis.rb:182: warning: this causes ArgumentError in the next release

解决方法:

https://github.com/redis/redis-rb/commit/aff1b8d0c4d466ff29214e72ce202224695783c9

 

Paste_Image.png

4. 启动和访问:

redis-stat 172.17.50.78:6379 172.17.50.77:6379 172.17.50.76:6379 172.17.50.75:6379 172.17.50.74:6379 172.17.50.73:6379 --daemon --server=9209 5

 

 

ps:亲测,是这样写,不是逗号分隔,是空格分隔,时间=2020-02-12 14:45

 

--server参数为web端口

 

http://127.0.0.1:9209

 

 

 

 

 

 

 

    原文作者:AscendKing
    原文地址: https://blog.csdn.net/wangwenzhe222/article/details/104826622
    本文转自网络文章,转载此文章仅为分享知识,如有侵权,请联系管理员进行删除。