redis集群开不起来,用redis-cli连接的时候出现如下错误:

CLUSTERDOWN The cluster is down

然后使用redis-trib.rb检查:

./redis-trib.rb check 10.10.25.243:6379

出现如下错误:

Connecting to node 10.10.20.243:6379: OK

>>> Performing Cluster Check(using node 10.10.20.243:6379)

[OK] All nodes agree about slotsconfiguration.

>>> Check for open slots...

>>> Check slots coverage...

[ERR] Not all 16384 slots are covered by nodes.

因为我只有一个节点,单节点集群,所以使用如下方法来修复节点:

./redis-trib.rb fix 10.10.20.243:6379

之后输出如下:

.......
>>> Covering slot 16276 with 10.10.25.243:6379
>>> Covering slot 16277 with 10.10.25.243:6379
>>> Covering slot 16278 with 10.10.25.243:6379
>>> Covering slot 16279 with 10.10.25.243:6379
>>> Covering slot 16280 with 10.10.25.243:6379
>>> Covering slot 16281 with 10.10.25.243:6379
>>> Covering slot 16282 with 10.10.25.243:6379
>>> Covering slot 16283 with 10.10.25.243:6379
>>> Covering slot 16284 with 10.10.25.243:6379
>>> Covering slot 16285 with 10.10.25.243:6379
>>> Covering slot 16286 with 10.10.25.243:6379
>>> Covering slot 16287 with 10.10.25.243:6379
>>> Covering slot 16288 with 10.10.25.243:6379
>>> Covering slot 16289 with 10.10.25.243:6379
>>> Covering slot 16290 with 10.10.25.243:6379
>>> Covering slot 16291 with 10.10.25.243:6379
>>> Covering slot 16292 with 10.10.25.243:6379
>>> Covering slot 16293 with 10.10.25.243:6379
>>> Covering slot 16294 with 10.10.25.243:6379
>>> Covering slot 16295 with 10.10.25.243:6379
>>> Covering slot 16296 with 10.10.25.243:6379
>>> Covering slot 16297 with 10.10.25.243:6379
>>> Covering slot 16298 with 10.10.25.243:6379
>>> Covering slot 16299 with 10.10.25.243:6379
>>> Covering slot 16300 with 10.10.25.243:6379
>>> Covering slot 16301 with 10.10.25.243:6379
>>> Covering slot 16302 with 10.10.25.243:6379
>>> Covering slot 16303 with 10.10.25.243:6379
>>> Covering slot 16304 with 10.10.25.243:6379
>>> Covering slot 16305 with 10.10.25.243:6379
>>> Covering slot 16306 with 10.10.25.243:6379
........

然后再检查下集群的情况:

redis-trib.rb check 10.10.25.243:6379

输出如下:

>>> Performing Cluster Check (using node 10.10.25.243:6379)
M: 4df1b649c1d0d08c2fa2a55e13d8d95c6d4f2b22 10.10.25.243:6379
slots:0-16383 (16384 slots) master
0 additional replica(s)
[OK] All nodes agree about slots configuration.
>>> Check for open slots...
>>> Check slots coverage...
[OK] All 16384 slots covered.

检查下集群信息:

root@nick-VirtualBox:/home/nick/software/redis-3.2.8# redis-cli -h 10.10.25.243 -p 6379
10.10.25.243:6379> cluster info
cluster_state:ok
cluster_slots_assigned:16384
cluster_slots_ok:16384
cluster_slots_pfail:0
cluster_slots_fail:0
cluster_known_nodes:1
cluster_size:1
cluster_current_epoch:0
cluster_my_epoch:0
cluster_stats_messages_sent:0
cluster_stats_messages_received:0

最后用redis-cli连下,正常了。可以连接,并且放入值和取出值也正常。

[ERR] Not all 16384 slots are covered by nodes.的更多相关文章

  1. redis初试Not all 16384 slots are covered by nodes

    按照这里的步骤玩redis集群,http://www.redis.cn/topics/cluster-tutorial.html ./src/redis-trib.rb create --replic ...

  2. redis 集群 slots are covered by nodes.

    原因数据数据损坏.需要修复 1.检测 redis-cli --cluster check 127.0.0.1:7000 2.检测结果 slots are covered by nodes3.进行修复 ...

  3. Redis 3.0.5 集群的命令、使用、维护

    cluster命令 CLUSTER INFO 打印集群的信息 CLUSTER NODES 列出集群当前已知的所有节点(node),以及这些节点的相关信息. //节点 CLUSTER MEET < ...

  4. Windows 部署 Redis 群集

    1,下载Redis for windows 的最新版本,解压到 c:\Redis 目录下备用https://github.com/MSOpenTech/redis/releases当前我使用的是 3. ...

  5. 部署 Redis 群集

    Windows 部署 Redis 群集   1,下载Redis for windows 的最新版本,解压到 c:\Redis 目录下备用https://github.com/MSOpenTech/re ...

  6. Windows 部署 Redis 群集(转)

    1,下载Redis for windows 的最新版本,解压到 c:\Redis 目录下备用https://github.com/MSOpenTech/redis/releases当前我使用的是 3. ...

  7. Redis单机多节点集群实验

    第一步:安装Redis 前面已经安装过了 不解释, Reids安装包里有个集群工具,要复制到/usr/local/bin里去 cp redis-3.2.9/src/redis-trib.rb /usr ...

  8. Redis多机多节点集群实验

    第一步:环境准备 我们搞两台虚拟机 局域网IP 分别是 192.168.1.109和192.168.1.110 我们约定把192.168.1.109作为集群控制端,需要安装redis-trib.rb ...

  9. redis集群部署+节点端口修改+数据恢复

    环境:OS:Centos 7Redis: 3.2.11主 从192.168.1.118:7001 192.168.1.118:8001192.168.1.118:7002 192.168.1.118: ...

随机推荐

  1. hashcode 知识点

    java中常用的哈希码的算法. Object类的hashCode.返回对象的内存地址经过处理后的结构,由于每个对象的内存地址都不一样,所以哈希码也不一样. String类的hashCode.根据Str ...

  2. kibana 与 grafana

    Kibana 和 Grafana 是两个开源工具,能可视化和推断大量日志数据内的趋势.Kibana 是一个分析和可视化平台,它可以让你浏览.可视化存储在Elasticsearch集群上排名靠前的日志数 ...

  3. framework4.0 IIS7下urlrewriter设置问题

    framework4.0 IIS7下urlrewriter设置问题 http://www.cnblogs.com/litian/articles/alex.html IIS开启伪静态后html静态页面 ...

  4. O(n)空间复杂度,打印杨辉三角形的前n行

    做小米的笔试题,给出一个整数n,求出它在杨辉三角形中第一次出现的行号. 想了半天,只能暴力法,从第1行开始找,一直找到第n行,若找得到则返回行号,若找不到则返回n+1(因为第n+1行第2列肯定是n). ...

  5. Java学习——Eclipse下载,java配置,新建,输入输出

    Eclipse下载,java配置:  基本的软件是JDK,它可以编译.运行Java程序,下载地址是:https://www.oracle.com/technetwork/java/javase/dow ...

  6. 去除adb传输中的^M

    学习sed过程中,在文本中每行追加内容,发现使用adb会在行末追加一个看不到^M. 场景一:adb保存到文件 adb shell ps|head -n 10 > text.txt,使用sed进行 ...

  7. java study1

    java安装 java优势-跨平台:一次编写,到处运行. jdk开发工具包,提供了开发人员需要的开发工具.jdk中包含了jre jre java的运行环境,负责程序的运行,jre中,包含程序运行时需要 ...

  8. keras中调用tensorboard:from keras.callbacks import TensorBoard

    from keras.models import Sequential from keras.layers import Dense from keras.wrappers.scikit_learn ...

  9. 第4章 文件和目录(5)_贯穿案例2:mini shell(1)

    6. 贯穿案例2:mini shell(1) [阶段性任务]实现cd.pwd和quit命令 //job.h #ifndef __JOB_H__ #define __JOB_H__ //接收命令行参数 ...

  10. 从线性回归到CNN【转】

    原地址:http://zhangliliang.com/2014/06/14/from-lr-to-cnn/ csdn:    http://blog.csdn.net/t0903/article/d ...