Method and device for selecting master node in distributed system

A distributed system and distributed node technology, applied in the field of selection of master nodes in distributed systems, can solve problems such as occupying communication bandwidth and wasting resources, and achieve the effects of improving success rate, improving work efficiency, and saving communication bandwidth

Active Publication Date: 2017-06-30
HUAWEI TECH SERVICE
View PDF4 Cites 34 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0004] In the process of realizing the present invention, the inventor found that the prior art has at least the following problems: in the prior art, the master node in the distributed system needs to send heartbeat information to all the slave nodes in the distributed system according to a fixed cycle , occupying a large amount of communication bandwidth and wasting resources

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Method and device for selecting master node in distributed system
  • Method and device for selecting master node in distributed system
  • Method and device for selecting master node in distributed system

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0084] In order to make the object, technical solution and advantages of the present invention clearer, the embodiments of the present invention will be further described in detail below in conjunction with the accompanying drawings.

[0085] Before explaining the embodiment of the present invention in detail, the system architecture of the embodiment of the present invention is introduced first. Such as figure 1As shown, the system includes multiple distributed nodes and clients, the multiple distributed nodes are connected through a network, the multiple distributed nodes can be computers, and the multiple distributed nodes can form a distributed system , the distributed system can serve as the server side to provide data for the client, and the client can be installed on any one of the multiple distributed nodes, or installed outside the multiple distributed nodes on a computer, and the computer can be connected to the plurality of distributed nodes through a network. Whe...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The invention discloses a method and device for selecting a master node in a distributed system, belonging to the field of Internet. The method comprises the following steps: a first distributed node receives a first data access request sent by a client, wherein the first data access request is a request for implementing data access through the master node of the distributed system, and the first distributed node is any of the distributed nodes in the distributed system; and when the first distributed node is not the master node of the distributed system, sending the first data access request to the master mode of the distributed system based on a stored master node identifier, when determining that the first data access request cannot be sent to the master node of the distributed system, determining that the master node of the distributed system has failure, and initiating a master node election request; and if the first distributed node is successfully elected, determining the first distributed node as the master node of the distributed system. According to the method and device disclosed by the invention, the communication bandwidths can be greatly saved, and the working efficiency of the distributed system can be increased.

Description

technical field [0001] The invention relates to the field of the Internet, in particular to a method and device for selecting a master node in a distributed system. Background technique [0002] With the rapid development of Internet technology, the application range of distributed systems is becoming wider and wider. Since the distributed system is a cluster system composed of multiple autonomous computer nodes as distributed nodes through a communication network, and the distributed system can serve as the server side to provide data for the client, the client can pass the distributed system Any one of the distributed nodes in the data access. In order to ensure that the data accessed by the client through any distributed node in the distributed system is consistent, the distributed nodes in the distributed system are generally divided into a master node and multiple slave nodes. Not only can the data stored by itself be modified, but also the data stored in the multiple...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
Patent Type & Authority Applications(China)
IPC IPC(8): H04L29/08H04L12/24H04L12/26
CPCH04L41/06H04L41/0677H04L43/10H04L67/10
Inventor 关键
Owner HUAWEI TECH SERVICE
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products