Redis集群监控及Redis桌面客户端

之前在生产环境部署了Redis集群,一直苦于没有工具监控,最近找了下网上推荐redmon和Redislive的比较多,查看了两个项目的github,都几年没有更新,这两个项目应该没有人在维护了,如果哪位有更好的替代方案麻烦告知!

仅将自己的部署方案贴出来,以供自己翻查!

具体步骤参考自redislive 的github安装文档:-----------------http://www.nkrode.com/article/real-time-dashboard-for-redis

环境:

CentOS7.2-1511 minimal 

python 2.7.5

安装依赖组件:

1、yum install epel-release

      yum install python-devel python-setuptools python-pip

      pip install redis

      pip install dateutil(内网通过挂载本地yum源安装的)

pip install tornado(内网通过下载tornado-1.2.1.tar.gz python setup.py install)

如果是python2.7以下,还需要安装pip install argparse 官方文档说明

      

2、安装过程中如有报错,安装相应的依赖即可(内网可通过外网虚机 yum install --downloadonly --downloaddir 方式下载安装)


3、下载github源码

    git clone https://github.com/nkrode/RedisLive.git 或者直接下载解压

4、配置文件更改

    #cd nkrode-RedisLive-6debcb6

   #cd src

    mv redis-live.conf.example redis-live.conf

  #vi redis-live.conf

注意打开的方式,部分编辑工具会进入非法字符

原始的配置文件如下:

   

[plain]  view plain  copy
  在CODE上查看代码片 派生到我的代码片
  1. {  
  2.         "RedisServers":  
  3.         [   
  4.                 {  
  5.                         "server": "154.17.59.99",  
  6.                         "port" : 6379  
  7.                 },  
  8.   
  9.                 {  
  10.                         "server": "localhost",  
  11.                         "port" : 6380,  
  12.                         "password" : "some-password"  
  13.                 }  
  14.         ],  
  15.   
  16.         "DataStoreType" : "redis",  
  17.   
  18.         "RedisStatsServer":  
  19.         {  
  20.                 "server" : "ec2-184-72-166-144.compute-1.amazonaws.com",  
  21.                 "port" : 6385  
  22.         },  
  23.   
  24.         "SqliteStatsStore" :  
  25.         {  
  26.                 "path":  "to your sql lite file"  
  27.         }  
  28. }  


部分配置参数说明:

RedisStatsServer: 如果存储类型选择了reids,就需要配置此项,即另外拿出一个redis来存储其他redis的状态信息,也就是上面说的元数据。

SqliteStatisStore: 如果存储类型选择了sqlite,就配置此项,指定一个路径保存sqlite文件。

5、服务启动

./redis-monitor.py --duration=120

./redis-live.py

http://192.168.1.101:8888/index.html


以上两个进程都是默认前台运行,可以后台去执行

nohup ./redis-monitor.py --duration=36000 --quiet &

        nohup ./redis-live.py --log_file_prefix=/home/user/log/redis_live --logging=warning &


6、redis-client

RedisDesktopManager下载地址 https://redisdesktop.com/ 有windows Linux mac版本,下载建立连接即可。

http://bbs.redis.cn/forum.php?mod=viewthread&tid=840


评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值