Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Redis error failed: how to solve Hostname must not be empty or null

2025-01-30 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)05/31 Report--

The main content of this article is to explain "Redis error failed: how to solve Hostname must not be empty or null", interested friends may wish to have a look. The method introduced in this paper is simple, fast and practical. Let's let the editor take you to learn "Redis error failed: how to solve Hostname must not be empty or null"!

1. Received a large number of application alarms

Could not retrieve cluster information. CLUSTER NODES returned with error. -172.23.17.57 6379 failed: Hostname must not be empty or null

two。 Log in to the cluster machine to view

[root@aliyun-mb-welike-prod-rdc-1-b-01] # / usr/local/src/redis-4.0.8/src/redis-trib.rb check 172.23.13.194using node 6379 > Performing Cluster Check (using node 172.23.13.194purl 6379) S: aa30a9c5004d2492d01c90692f7de8d3b90fd4ed 172.23.13.194Performing Cluster Check 6379 slots: (0 slots) slave replicates 7122bb26444cb62228396e89ae3db97eda256926S: 39f2b3370729bf2e99f4b0efeb96b58cb849ac91 172.23.13.200 slots slots: (0 slots) slave replicates 1e3b30a7e08279067cb193a8d550c3b22230a629S: a6fb7fb6e9243c5cc9679daaa3d3aacbf71f0e5a 172 .23.13.195: 6379 slots: (0 slots) slave replicates c3bbc8f04e902d16cc0a40516a292715b74b4d19M: c3bbc8f04e902d16cc0a40516a292715b74b4d19 172.23.17.58 slots:2068-2105 master 2636-4996 additional replica 941-9771 master 10923-11417 (4096 slots) master 1 additional replica (s) M: 7122bb26444cb62228396e89ae3db97eda256926 172.23.17.55 additional replica (s) M: 7122bb26444cb62228396e89ae3db97eda256926 172.23.17.55 slots 6379 slots:28,431,1967-20677prima 7104-7284 1433-126440 14417-16383 (3968 slots) master 1 additional replica (s): 011401a43fbe38dad3ff6dfc429aa1e987436aa8 172.23.17.57 slots: (0 slots) ) slave replicates 5cb816f4c9f9d48c7bba5115b7a89c881bf6b46fS: 45b52d2692c3c16d91c360b3b4c18c4ae18e4f28 172.23.1755slave replicates a6dd59d54ffacbbe7ade84d4ffeaa746e99e724cS 6380 slots: (0 slots) slave replicates a6dd59d54ffacbbe7ade84d4ffeaa746e99e724cS: 600cb902806705526037d12ca94dfbde8d27318a 172.23.13.194slave replicates a6dd59d54ffacbbe7ade84d4ffeaa746e99e724cS 6380 slots: (0 slots) slave replicates a6dd59d54ffacbbe7ade84d4ffeaa746e99e724cM: a6dd59d54ffacbbe7ade84d4ffeaa746e99e724c 172.23.13.201719 slots master 2 additional replica (s) M: 5cb816f4c9f9d48c7bba5115b7a89c881bf6b46f 172.23.13.1966379 slots:861-1145Magi 1822-1966 2234-2635pct 6706-7103pint 9298-9718ju 9778-9782pint 9785-10922pc12618-13654pr 14025-14416 (4223 slots) master 1 additional Replica (s) M: 1e3b30a7e08279067cb193a8d550c3b22230a629 172.23.17.56 master 6379 slots:0-27 additional replica (s) [OK] All nodes agree about slots configuration. > > Check for open slots... > > Check slots coverage... [OK] All 16384 slots covered.

Yo, it seems that the status of the cluster is normal, and no information about this ip has been found.

3. Continue to view node information

[root@aliyun-mb-welike-prod-rdc-1-b-01] # / usr/local/redis//bin/redis-cli-an inH7HkD7iXoxKZCi-h 172.23.13.194-c cluster nodes1e54bab9fb0f02e634cf9c958613f3814d221d9f: 0,0slave,fail,noaddr 1e3b30a7e08279067cb193a8d550c3b22230a629 1552634222097 1552634217000 89 disconnectedaa30a9c5004d2492d01c90692f7de8d3b90fd4ed 172.23.13.1946379mm 16379 myself Slave 7122bb26444cb62228396e89ae3db97eda256926 01552876530000 67 connected39f2b3370729bf2e99f4b0efeb96b58cb849ac91 172.23.13.200 slave 1e3b30a7e08279067cb193a8d550c3b22230a629 01552876532139 89 connecteda6fb7fb6e9243c5cc9679daaa3d3aacbf71f0e5a 172.23.13.195379 slave c3bbc8f04e902d16cc0a40516a292715b74b4d19 01552876530134 90 connectedc3bbc8f04e902d16cc0a40516a292715b74b4d19 172.17.58 connected 2068-2105 2636-4996 5463-6374 72841-9771 10923-114177122bb26444cb62228396e89ae3db97eda256926 172.23.17.17.531 6379 16379 master-0 1552876531000 87 connected 28 431 1967-2067 7104-7282 8194-9106 919-940 11833-12436-12434 12436-12417-16383011401a43fbe38dad3ff6dfc429aa1e987436aa8 172.17 .57: 6379 "16379 slave 5cb816f4c9f9d48c7bba5115b7a89c881bf6b46f 01552876531000 91 connected45b52d2692c3c16d91c360b3b4c18c4ae18e4f28 172.23.17.55 slave a6dd59d54ffacbbe7ade84d4ffeaa746e99e724c 01552876531138 92 connected600cb902806705526037d12ca94dfbde8d27318a 172.23.13.194380" 16380 "slave a6dd59d54ffacbbe7ade84d4ffeaa746e99e724c 01552876533000 92 connecteda6dd59d54ffacbbe7ade84d4ffeaa746e99e724c 172.23.13.20192876533000 master-01552876533142 connected 124355cb816f4c9f9d48c7bba5115b7a89c881bf6b46f 172.23.13.19692876530000 91 connected 16379 master-01552876530000 91 connected 861-1966 2234-26356706-7103298-1966 2234-26356706-7103298-1966 2234-26356706-7103298-1966 2234-2635 6706-7103298-13654 14025-144161e3b30a7e08279067cb193a8d550c3b22230a629 172.56 -0 1552876534145 89 connected 0-27 29-430 432-860 1146-1821 2106-2233 4997-5462 6375-6705 7542-8193 9107-9297 9772-9777 9783-9784 11418-11832 13655-14024

It was caused by the first message.

4. Solution.

If a node is in the state of ": 0 master,fail,noaddr", executing "del-node" will report an error: [ERR] No such node ID 80560d0d97a0b3fa975203350516437b58251745 in this case, you only need to execute "CLUSTER FORGET" to remove it (note that it needs to be executed once on all nodes, otherwise ": 0 master,fail,noaddr" may still be seen on unexecuted nodes): execute cluster forget node-id on each node to this point I believe that you have a deeper understanding of "Redis error failed: how to solve Hostname must not be empty or null", you might as well do it in practice! Here is the website, more related content can enter the relevant channels to inquire, follow us, continue to learn!

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: 0

*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.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report