In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)06/01 Report--
Redis cluster command line. Log in to cluster to execute the following command, which is unique to the cluster.
Cluster (cluster)
CLUSTER INFO prints information about the cluster
CLUSTER NODES lists all the nodes (node) currently known to the cluster, as well as relevant information about these nodes
Node (node)
CLUSTER MEET adds the nodes specified by ip and port to the cluster to make it part of the cluster
CLUSTER FORGET removes nodes specified by node_id from the cluster
CLUSTER REPLICATE sets the current node as the slave node of the node specified by node_id
CLUSTER SAVECONFIG saves the configuration file of the node to the hard disk
Slot (slot)
CLUSTER ADDSLOTS [slot...] Assign one or more slots (slot) to the current node
CLUSTER DELSLOTS [slot...] Remove the assignment of one or more slots to the current node
CLUSTER FLUSHSLOTS removes all slots assigned to the current node, making the current node a node without any slots assigned
CLUSTER SETSLOT NODE assigns the slot slot to the node specified by node_id. If the slot is already assigned to another node, let the other node delete the slot > before assigning it.
CLUSTER SETSLOT MIGRATING migrates the slot slot of this node to the node specified by node_id
CLUSTER SETSLOT IMPORTING imports slot slot from the node specified by node_id to this node
CLUSTER SETSLOT STABLE cancels import (import) or migration (migrate) of slot slot
Key (key)
CLUSTER KEYSLOT calculates which slot the key key should be placed on
CLUSTER COUNTKEYSINSLOT return slot number of key-value pairs currently contained in slot
CLUSTER GETKEYSINSLOT returns keys in count slot slots
Verify whether a node in the cluster can join the cluster automatically after forcing kill:
View the redis cluster relationship:
[root@192-13168-77] # redis-cli-h 192.13.168.77-p 2002-c-a "ysBhqkYHDifB" cluster nodes
06031e33797ef0aa6427bddb1ff958f7af0f1a4a 192.13.168.77 connected 4004mm 14004 master-01575439453000 3 connected 10923-16383
D49ebf2a5f3605487ea4c8deee7e2aa2782667e6 192.13.168.77 connected 2002 myself,master-01575439454000 1 connected 0-5460
532ef94c81188111827fef599ee73c0996a04e5e 192.13.168.77 connected 7007 slave 06031e33797ef0aa6427bddb1ff958f7af0f1a4a 01575439455000 6 connected
46233f6d8b508be0cedafc5f07aca04210f654ea 192.13.168.77 virtual 6006 slave ef76f232efb578249e8d0ec8fef8ec02b3524010 01575439455742 5 connected
Ef76f232efb578249e8d0ec8fef8ec02b3524010 192.13.168.77 connected 3003 connected 13003 master-01575439454743 2
B11fc826c15cdee6e026a59ed98f31c9fa490aaa 192.13.168.77 connected 5005 slave d49ebf2a5f3605487ea4c8deee7e2aa2782667e6 0 1575439454000 4 connected
View the redis cluster process:
[root@192-13,168-77 ~] # ps-ef | grep redis
Root 2039 1 0 14:00? 00:00:01 / usr/local/redis-4.0.9/bin/redis-server 0.0.0.0:2002 [cluster]
Root 2236 1 0 14:00? 00:00:01 / usr/local/redis-4.0.9/bin/redis-server 0.0.0.0:3003 [cluster]
Root 2335 1 0 14:00? 00:00:01 / usr/local/redis-4.0.9/bin/redis-server 0.0.0.0:4004 [cluster]
Root 2365 1 0 14:00? 00:00:01 / usr/local/redis-4.0.9/bin/redis-server 0.0.0.0:5005 [cluster]
Root 2391 1 0 14:00? 00:00:01 / usr/local/redis-4.0.9/bin/redis-server 0.0.0.0:6006 [cluster]
Root 2418 1 0 14:00? 00:00:01 / usr/local/redis-4.0.9/bin/redis-server 0.0.0.0:7007 [cluster]
[root@192-13168-77] # redis-cli-h 192.13.168.77-p 2002-c-a "ysBhqkYHDifB" cluster nodes
06031e33797ef0aa6427bddb1ff958f7af0f1a4a 192.13.168.77 connected 4004mm 14004 master-01575439453000 3 connected 10923-16383
D49ebf2a5f3605487ea4c8deee7e2aa2782667e6 192.13.168.77 connected 2002 myself,master-01575439454000 1 connected 0-5460
532ef94c81188111827fef599ee73c0996a04e5e 192.13.168.77 connected 7007 slave 06031e33797ef0aa6427bddb1ff958f7af0f1a4a 01575439455000 6 connected
46233f6d8b508be0cedafc5f07aca04210f654ea 192.13.168.77 virtual 6006 slave ef76f232efb578249e8d0ec8fef8ec02b3524010 01575439455742 5 connected
Ef76f232efb578249e8d0ec8fef8ec02b3524010 192.13.168.77 connected 3003 connected 13003 master-01575439454743 2
B11fc826c15cdee6e026a59ed98f31c9fa490aaa 192.13.168.77 connected 5005 slave d49ebf2a5f3605487ea4c8deee7e2aa2782667e6 0 1575439454000 4 connected
View the master-slave relationship through redis cluster slots:
[root@192-13-16877 ~] # redis-cli-h 192.13.168.77-p 2002-c-a "ysBhqkYHDifB" cluster slots | xargs-N8 | awk'{print $3 ":" $4 "- >" $6 ":" $7}'| sort-nk2-t':'| uniq
192.13.168.77Viru 2002-> 192.13.168.77purl 5005
192.13.168.77VR 3003-> 192.13.168.77VR 6006
192.13.168.77VR 7007-> 192.13.168.77VR 4004
Force kill:
[root@192-13-168-77] # kill-9 2418
[root@192-13,168-77 ~] # ps-ef | grep redis
Root 2039 1 0 14:00? 00:00:02 / usr/local/redis-4.0.9/bin/redis-server 0.0.0.0:2002 [cluster]
Root 2236 1 0 14:00? 00:00:02 / usr/local/redis-4.0.9/bin/redis-server 0.0.0.0:3003 [cluster]
Root 2335 1 0 14:00? 00:00:02 / usr/local/redis-4.0.9/bin/redis-server 0.0.0.0:4004 [cluster]
Root 2365 1 0 14:00? 00:00:02 / usr/local/redis-4.0.9/bin/redis-server 0.0.0.0:5005 [cluster]
Root 2391 1 0 14:00? 00:00:02 / usr/local/redis-4.0.9/bin/redis-server 0.0.0.0:6006 [cluster]
View the log of 7007 from 4004, 4004 upgrade to the new master:
[root@192-13-168-77 log] # cat redis_4004.log
23377:C 04 Dec 13:40:40.502 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
23377:C 04 Dec 13:40:40.502 # Redis version=4.0.9, bits=64, commit=00000000, modified=0, pid=23377, just started
23377:C 04 Dec 13:40:40.502 # Configuration loaded
23378:M 04 Dec 13:40:40.517 # Server initialized
23378:M 04 Dec 13:40:40.517 # WARNING overcommit_memory is set to 0! Background save may fail under low memory condition. To fix this issue add 'vm.overcommit_memory=1' to / etc/sysctl.conf and then reboot or run the command' sysctl vm.overcommit_memory=1' for this to take effect.
23378 THP M 04 Dec 1340 THP 40.517 # support enabled in your kernel. This will create latency and memory usage issues with Redis. To fix this issue run the command 'echo never > / sys/kernel/mm/transparent_hugepage/enabled' as root, and add it to your / etc/rc.local in order to retain the setting after a reboot. Redis must be restarted after THP is disabled.
23378:M 04 Dec 13:57:15.782 # User requested shutdown...
23378:M 04 Dec 13:57:15.783 # Redis is now ready to exit, bye bye...
2334:C 04 Dec 14:00:25.888 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
2334:C 04 Dec 14:00:25.888 # Redis version=4.0.9, bits=64, commit=00000000, modified=0, pid=2334, just started
2334:C 04 Dec 14:00:25.889 # Configuration loaded
2335:M 04 Dec 14:00:25.896 # Server initialized
2335:M 04 Dec 14:00:25.896 # WARNING overcommit_memory is set to 0! Background save may fail under low memory condition. To fix this issue add 'vm.overcommit_memory=1' to / etc/sysctl.conf and then reboot or run the command' sysctl vm.overcommit_memory=1' for this to take effect.
2335 THP M 04 Dec 14 THP 00 25 896 # WARNING you have Transparent Huge Pages (THP) support enabled in your kernel. This will create latency and memory usage issues with Redis. To fix this issue run the command 'echo never > / sys/kernel/mm/transparent_hugepage/enabled' as root, and add it to your / etc/rc.local in order to retain the setting after a reboot. Redis must be restarted after THP is disabled.
2335:M 04 Dec 14:01:24.003 # configEpoch set to 3 via CLUSTER SET-CONFIG-EPOCH
2335:M 04 Dec 14:01:24.180 # IP address for this node updated to 192.13.168.77
2335:M 04 Dec 14:01:29.005 # Cluster state changed: ok
2335:M 04 Dec 14:06:56.069 # Manual failover requested by slave 532ef94c81188111827fef599ee73c0996a04e5e.
2335:M 04 Dec 14:06:56.258 # Failover auth granted to 532ef94c81188111827fef599ee73c0996a04e5e for epoch 7
2335:M 04 Dec 14:06:56.263 # Connection with slave 192.13.168.77:7007 lost.
2335:M 04 Dec 14:06:56.266 # Configuration change detected. Reconfiguring myself as a replica of 532ef94c81188111827fef599ee73c0996a04e5e
2335:S 04 Dec 14:06:56.538 # Master replication ID changed to 880dfbbc29acda08aa0f997ec0d3d9238f987cca
2335:S 04 Dec 14:46:13.970 # Connection with master lost.
2335:S 04 Dec 14:46:14.427 # Error condition on socket for SYNC: Connection refused
2335:S 04 Dec 14:46:15.427 # Error condition on socket for SYNC: Connection refused
2335:S 04 Dec 14:46:16.430 # Error condition on socket for SYNC: Connection refused
2335:S 04 Dec 14:46:17.433 # Error condition on socket for SYNC: Connection refused
2335:S 04 Dec 14:46:18.436 # Error condition on socket for SYNC: Connection refused
2335:S 04 Dec 14:46:19.438 # Error condition on socket for SYNC: Connection refused
2335:S 04 Dec 14:46:20.441 # Error condition on socket for SYNC: Connection refused
2335:S 04 Dec 14:46:21.443 # Error condition on socket for SYNC: Connection refused
2335:S 04 Dec 14:46:22.445 # Error condition on socket for SYNC: Connection refused
2335:S 04 Dec 14:46:23.448 # Error condition on socket for SYNC: Connection refused
2335:S 04 Dec 14:46:24.449 # Error condition on socket for SYNC: Connection refused
2335:S 04 Dec 14:46:25.451 # Error condition on socket for SYNC: Connection refused
2335:S 04 Dec 14:46:26.453 # Error condition on socket for SYNC: Connection refused
2335:S 04 Dec 14:46:27.455 # Error condition on socket for SYNC: Connection refused
2335:S 04 Dec 14:46:28.457 # Error condition on socket for SYNC: Connection refused
2335:S 04 Dec 14:46:29.459 # Error condition on socket for SYNC: Connection refused
2335 milliseconds S 04 Dec 14 milliseconds 46 milliseconds 29.960 # Start of election delayed for 658 (rank # 0, offset 3738)
2335:S 04 Dec 14:46:30.461 # Error condition on socket for SYNC: Connection refused
2335:S 04 Dec 14:46:30.662 # Starting a failover election for epoch 8.
2335:S 04 Dec 14:46:30.667 # Failover election won: I'm the new master.
2335:S 04 Dec 14:46:30.667 # configEpoch set to 8 after successful failover
2335:M 04 Dec 14:46:30.667 # Setting secondary replication ID to 880dfbbc29acda08aa0f997ec0d3d9238f987cca, valid up to offset: 3739. New replication ID is 8ae5eb556fbfd6c13ec33b1123c87de1fbe4db05
Delete nodes-7007.conf under the 7007data directory:
[root@192-13-168-77] # cd / u02/redis/7007/
[root@192-13-168-77 7007] # ls
Conf data log pid
[root@192-13-168-77 7007] # cd data/
[root@192-13-168-77 data] # ls
Nodes-7007.conf redis_7007_dump.rdb
[root@192-13-168-77 data] # rm-rf nodes-7007.conf
[root@192-13,168-77 data] # ps-ef | grep redis
Root 2039 1 0 14:00? 00:00:02 / usr/local/redis-4.0.9/bin/redis-server 0.0.0.0:2002 [cluster]
Root 2236 1 0 14:00? 00:00:02 / usr/local/redis-4.0.9/bin/redis-server 0.0.0.0:3003 [cluster]
Root 2335 1 0 14:00? 00:00:02 / usr/local/redis-4.0.9/bin/redis-server 0.0.0.0:4004 [cluster]
Root 2365 1 0 14:00? 00:00:02 / usr/local/redis-4.0.9/bin/redis-server 0.0.0.0:5005 [cluster]
Root 2391 1 0 14:00? 00:00:02 / usr/local/redis-4.0.9/bin/redis-server 0.0.0.0:6006 [cluster]
Root 32397 30103 0 14:49 pts/1 00:00:00 grep redis
Root 37840 10 Nov05? 00:25:35 / usr/sbin/glusterfs-volfile-server=10.66.5.10-volfile-id=/volume-10-0-5-16-db01 / sharedisk/
Start the 7007 process:
[root@192-13,168-77 data] # / usr/local/redis-4.0.9/bin/redis-server / u02/redis/7007/conf/redis_7007.conf
Unable to join the cluster automatically due to forced kill:
[root@192-13,168-77 data] # redis-cli-h 192.13.168.77-p 2002-c-a "ysBhqkYHDifB" cluster nodes
06031e33797ef0aa6427bddb1ff958f7af0f1a4a 192.13.168.77 connected 4004mm 14004 master-01575442290000 8 connected 10923-16383
D49ebf2a5f3605487ea4c8deee7e2aa2782667e6 192.13.168.77 virtual 2002 myself,master-01575442289000 1 connected 0-5460
532ef94c81188111827fef599ee73c0996a04e5e: 0 master,fail,noaddr-1575441974024 1575441972822 7 disconnected
46233f6d8b508be0cedafc5f07aca04210f654ea 192.13.168.77 connected 6006mm 16006 slave ef76f232efb578249e8d0ec8fef8ec02b3524010 01575442290483 5
Ef76f232efb578249e8d0ec8fef8ec02b3524010 192.13.168.77 connected 3003 connected 13003 master-01575442291483 2 1461-10922
B11fc826c15cdee6e026a59ed98f31c9fa490aaa 192.13.168.77 connected 5005 slave d49ebf2a5f3605487ea4c8deee7e2aa2782667e6 0 1575442289481 4
Execute on each node:
CLUSTER FORGET 06031e33797ef0aa6427bddb1ff958f7af0f1a4a
[root@192-13-168-77 data] # redis-cli-h 192.13.168.77-p 2002-c-a "ysBhqkYHDifB"
192.13.168.77Viru 2002 > CLUSTER FORGET 532ef94c81188111827fef599ee73c0996a04e5e
OK
192.13.168.77Viru 3003 > CLUSTER FORGET 532ef94c81188111827fef599ee73c0996a04e5e
OK
192.13.168.77Viru 5005 > CLUSTER FORGET 532ef94c81188111827fef599ee73c0996a04e5e
OK
192.13.168.77Viru 6006 > CLUSTER FORGET 532ef94c81188111827fef599ee73c0996a04e5e
OK
Restart the 7007 redis process:
[root@192-13,168-77 data] # / usr/local/redis-4.0.9/bin/redis-server / u02/redis/7007/conf/redis_7007.conf
[root@192-13,168-77 data] # ps-ef | grep redis
Root 2039 1 0 14:00? 00:00:03 / usr/local/redis-4.0.9/bin/redis-server 0.0.0.0:2002 [cluster]
Root 2236 1 0 14:00? 00:00:03 / usr/local/redis-4.0.9/bin/redis-server 0.0.0.0:3003 [cluster]
Root 2335 1 0 14:00? 00:00:03 / usr/local/redis-4.0.9/bin/redis-server 0.0.0.0:4004 [cluster]
Root 2365 1 0 14:00? 00:00:03 / usr/local/redis-4.0.9/bin/redis-server 0.0.0.0:5005 [cluster]
Root 2391 1 0 14:00? 00:00:03 / usr/local/redis-4.0.9/bin/redis-server 0.0.0.0:6006 [cluster]
Root 2931 1 0 15:07? 00:00:00 / usr/local/redis-4.0.9/bin/redis-server 0.0.0.0:7007 [cluster]
Rejoin 7007 as a 4004 slave
[root@192-13-168-77 data] # redis-trib.rb add-node-- slave-- master-id 06031e33797ef0aa6427bddb1ff958f7af0f1a4a 192.13.168.77 redis-trib.rb add-node 7007 192.13.168.77
> Adding node 192.13.168.77 to cluster 7007 192.13.168.77
> Performing Cluster Check (using node 192.13.168.77)
M: d49ebf2a5f3605487ea4c8deee7e2aa2782667e6 192.13.168.77:2002
Slots:0-5460 (5461 slots) master
1 additional replica (s)
M: 06031e33797ef0aa6427bddb1ff958f7af0f1a4a 192.13.168.77:4004
Slots:10923-16383 (5461 slots) master
0 additional replica (s)
S: 46233f6d8b508be0cedafc5f07aca04210f654ea 192.13.168.77:6006
Slots: (0 slots) slave
Replicates ef76f232efb578249e8d0ec8fef8ec02b3524010
M: ef76f232efb578249e8d0ec8fef8ec02b3524010 192.13.168.77:3003
Slots:5461-10922 (5462 slots) master
1 additional replica (s)
S: b11fc826c15cdee6e026a59ed98f31c9fa490aaa 192.13.168.77:5005
Slots: (0 slots) slave
Replicates d49ebf2a5f3605487ea4c8deee7e2aa2782667e6
[OK] All nodes agree about slots configuration.
> Check for open slots...
> Check slots coverage...
[OK] All 16384 slots covered.
> Send CLUSTER MEET to node 192.13.168.77 Send CLUSTER MEET to node 7007 to make it join the cluster.
Waiting for the cluster to join.
>
[OK] New node added correctly.
Check the redis cluster status:
[root@192-13-168-77 data] # redis-trib.rb check 192.13.168.772002
> Performing Cluster Check (using node 192.13.168.77)
M: d49ebf2a5f3605487ea4c8deee7e2aa2782667e6 192.13.168.77:2002
Slots:0-5460 (5461 slots) master
1 additional replica (s)
M: 06031e33797ef0aa6427bddb1ff958f7af0f1a4a 192.13.168.77:4004
Slots:10923-16383 (5461 slots) master
1 additional replica (s)
S: 46233f6d8b508be0cedafc5f07aca04210f654ea 192.13.168.77:6006
Slots: (0 slots) slave
Replicates ef76f232efb578249e8d0ec8fef8ec02b3524010
M: ef76f232efb578249e8d0ec8fef8ec02b3524010 192.13.168.77:3003
Slots:5461-10922 (5462 slots) master
1 additional replica (s)
S: 1dba8274e36bde79a215a77d1f241ae6fc81c03e 192.13.168.77:7007
Slots: (0 slots) slave
Replicates 06031e33797ef0aa6427bddb1ff958f7af0f1a4a
S: b11fc826c15cdee6e026a59ed98f31c9fa490aaa 192.13.168.77:5005
Slots: (0 slots) slave
Replicates d49ebf2a5f3605487ea4c8deee7e2aa2782667e6
[OK] All nodes agree about slots configuration.
> Check for open slots...
> Check slots coverage...
[OK] All 16384 slots covered.
Re-check the cluster status:
[root@192-13,168-77 data] # redis-cli-h 192.13.168.77-p 3003-c-a "ysBhqkYHDifB" cluster nodes
B11fc826c15cdee6e026a59ed98f31c9fa490aaa 192.13.168.77 connected 5005 slave d49ebf2a5f3605487ea4c8deee7e2aa2782667e6 0 1575452066959 4
1dba8274e36bde79a215a77d1f241ae6fc81c03e 192.13.168.77 connected 7007 slave 06031e33797ef0aa6427bddb1ff958f7af0f1a4a 01575452066000 8
46233f6d8b508be0cedafc5f07aca04210f654ea 192.13.168.77 connected 6006 slave ef76f232efb578249e8d0ec8fef8ec02b3524010 01575452065958 5 connected
06031e33797ef0aa6427bddb1ff958f7af0f1a4a 192.13.168.77 connected 4004 connected 14004 master-0 1575452067960 8
Ef76f232efb578249e8d0ec8fef8ec02b3524010 192.13.168.77 connected 3003 connected 13003 myself,master-0 1575452065000 2
D49ebf2a5f3605487ea4c8deee7e2aa2782667e6 192.13.168.77 virtual 2002 master-01575452067000 1 connected 0-5460
Rejoin the cluster after a node is normally shtudown:
[root@192-13,168-77 data] # redis-cli-h 192.13.168.77-p 4004-c-a "ysBhqkYHDifB" shutdown
[root@192-13-168-77 log] # cat redis_7007.log
4540:S 04 Dec 18:03:32.106 # Connection with master lost.
4540:S 04 Dec 18:03:32.921 # Error condition on socket for SYNC: Connection refused
4540:S 04 Dec 18:03:33.924 # Error condition on socket for SYNC: Connection refused
4540:S 04 Dec 18:03:34.925 # Error condition on socket for SYNC: Connection refused
4540:S 04 Dec 18:03:35.928 # Error condition on socket for SYNC: Connection refused
4540:S 04 Dec 18:03:36.930 # Error condition on socket for SYNC: Connection refused
4540:S 04 Dec 18:03:37.932 # Error condition on socket for SYNC: Connection refused
4540:S 04 Dec 18:03:38.934 # Error condition on socket for SYNC: Connection refused
4540:S 04 Dec 18:03:39.935 # Error condition on socket for SYNC: Connection refused
4540:S 04 Dec 18:03:40.936 # Error condition on socket for SYNC: Connection refused
4540:S 04 Dec 18:03:41.938 # Error condition on socket for SYNC: Connection refused
4540:S 04 Dec 18:03:42.940 # Error condition on socket for SYNC: Connection refused
4540:S 04 Dec 18:03:43.942 # Error condition on socket for SYNC: Connection refused
4540:S 04 Dec 18:03:44.943 # Error condition on socket for SYNC: Connection refused
4540:S 04 Dec 18:03:45.945 # Error condition on socket for SYNC: Connection refused
4540:S 04 Dec 18:03:46.948 # Error condition on socket for SYNC: Connection refused
4540 milliseconds S 04 Dec 18 3 milliseconds 47.550 # Start of election delayed for 554 (rank # 0, offset 17724)
4540:S 04 Dec 18:03:47.950 # Error condition on socket for SYNC: Connection refused
4540:S 04 Dec 18:03:48.150 # Starting a failover election for epoch 9.
4540:S 04 Dec 18:03:48.155 # Failover election won: I'm the new master.
4540:S 04 Dec 18:03:48.155 # configEpoch set to 9 after successful failover
4540:M 04 Dec 18:03:48.155 # Setting secondary replication ID to 8ae5eb556fbfd6c13ec33b1123c87de1fbe4db05, valid up to offset: 17725. New replication ID is e44a29dcbf3dce8e1d29c06bd310ba2ba3d0c41b
View the cluster status:
Redis-cli-h 192.13.168.77-p 4004-c-a "ysBhqkYHDifB" cluster nodes
Could not connect to Redis at 192.13.168.77:4004: Connection refused
[root@192-13,168-77 log] # redis-cli-h 192.13.168.77-p 2002-c-a "ysBhqkYHDifB" cluster nodes
06031e33797ef0aa6427bddb1ff958f7af0f1a4a 192.13.168.77 disconnected 4004mm 14004 master,fail-1575453812190 1575453808482 8
D49ebf2a5f3605487ea4c8deee7e2aa2782667e6 192.13.168.77 connected 2002 myself,master-01575453939000 1 connected 0-5460
46233f6d8b508be0cedafc5f07aca04210f654ea 192.13.168.77 virtual 6006 slave ef76f232efb578249e8d0ec8fef8ec02b3524010 01575453940773 5 connected
Ef76f232efb578249e8d0ec8fef8ec02b3524010 192.13.168.77 connected 3003 13003 master-01575453939000 2 connected 5461-10922
1dba8274e36bde79a215a77d1f241ae6fc81c03e 192.13.168.77 connected 7007 17007 master-01575453939770 9 connected 10923-16383
B11fc826c15cdee6e026a59ed98f31c9fa490aaa 192.13.168.77 connected 5005 slave d49ebf2a5f3605487ea4c8deee7e2aa2782667e6 0 1575453940000 4
Restart the 4004 process:
[root@192-13,168-77 log] # / usr/local/redis-4.0.9/bin/redis-server / u02/redis/4004/conf/redis_4004.conf
Check the cluster status: (4004 is automatically added and becomes slave)
[root@192.13.168.77 log] # redis-cli-h 192.13.168.77-p 2002-c-a "ysBhqkYHDifB" cluster nodes
06031e33797ef0aa6427bddb1ff958f7af0f1a4a 192.13.168.77 connected 4004 connected 14004 slave 1dba8274e36bde79a215a77d1f241ae6fc81c03e 0 1575454019000 9
D49ebf2a5f3605487ea4c8deee7e2aa2782667e6 192.13.168.77 connected 2002 myself,master-01575454018000 1 connected 0-5460
46233f6d8b508be0cedafc5f07aca04210f654ea 192.13.168.77 connected 6006 "16006 slave ef76f232efb578249e8d0ec8fef8ec02b3524010 0 15754540199 5 connected
Ef76f232efb578249e8d0ec8fef8ec02b3524010 192.13.168.77 connected 3003 connected 13003 master-015754540209442
1dba8274e36bde79a215a77d1f241ae6fc81c03e 192.13.168.77 connected 7007 17007 master-01575454018000 9 connected 10923-16383
B11fc826c15cdee6e026a59ed98f31c9fa490aaa 192.13.168.77 connected 5005 slave d49ebf2a5f3605487ea4c8deee7e2aa2782667e6 0 1575454020000 4
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 240
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.