CN105141445A - Method and device for realizing multiple backups of multiple flow groups in high-availability cluster system - Google Patents

Method and device for realizing multiple backups of multiple flow groups in high-availability cluster system Download PDF

Info

Publication number
CN105141445A
CN105141445A CN201510442344.2A CN201510442344A CN105141445A CN 105141445 A CN105141445 A CN 105141445A CN 201510442344 A CN201510442344 A CN 201510442344A CN 105141445 A CN105141445 A CN 105141445A
Authority
CN
China
Prior art keywords
node
flow group
priority level
listing
correspondence
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201510442344.2A
Other languages
Chinese (zh)
Inventor
孙震
胡锦亚
黄畅
申志军
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
GUANGZHOU SUNRUN NETWORKS TECHNOLOGY Co Ltd
Original Assignee
GUANGZHOU SUNRUN NETWORKS TECHNOLOGY Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by GUANGZHOU SUNRUN NETWORKS TECHNOLOGY Co Ltd filed Critical GUANGZHOU SUNRUN NETWORKS TECHNOLOGY Co Ltd
Priority to CN201510442344.2A priority Critical patent/CN105141445A/en
Publication of CN105141445A publication Critical patent/CN105141445A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/06Management of faults, events, alarms or notifications
    • H04L41/0654Management of faults, events, alarms or notifications using network fault recovery
    • H04L41/0668Management of faults, events, alarms or notifications using network fault recovery by dynamic selection of recovery network elements, e.g. replacement by the most appropriate element after failure

Abstract

The invention discloses a method and device for realizing multiple backups of multiple flow groups in a high-availability cluster system. The method comprises the following steps: establishing the multiple flow groups, and generating corresponding node lists in the flow groups; respectively distributing the priority in the corresponding flow group to each node in each node list, and synchronizing priority information in the corresponding node; periodically and mutually sending the priority information among various nodes belonging to the same flow group; and comparing each node with other nodes belonging to the same flow group, setting self as a current use node in the corresponding flow group if the self priority in the corresponding flow group is the highest, and or else, setting self as a spare node in the corresponding flow group. According to the invention, one master node and multiple spare nodes can be distributed to each flow group; therefore, the resource utilization rate of each node is ensured; and furthermore, the multi-machine warm backup purpose is achieved.

Description

A kind of method and device realizing the many backups of various flow group in highly available cluster system
Technical field
The present invention relates to net application technology field, be specifically related to a kind of method and the device that realize the many backups of various flow group in highly available cluster system.
Background technology
Highly available cluster system mainly in order to make the integrity service of cluster can use as far as possible, being that the impact of fault on business caused is reduced to minimum degree because of software/hardware/people.If certain node failure, its redundant node is by within the time in a few second or shorter its responsibility of time inner connecting tube.
Existing high-availability cluster mainly contains several mode: the two-node cluster hot backup mode realized based on VRRP (virtual Routing Protocol), the one master and multiple slaves mode realized based on Paxos algorithm (a kind of consistency algorithm being applied to distributed system).The former is mainly used in network application environment, but can only support the working method that a master one is standby, and the latter is mainly used in distributed system, and can not support the pattern that multiple flow group is standby mutually, and failover needs to carry out vote by ballot, switch speed is slow.
Summary of the invention
In order to overcome the deficiencies in the prior art, the object of the present invention is to provide a kind of method realizing the many backups of various flow group in highly available cluster system, make each node can become the primary node of one or more flow group, also the secondary node of one or more flow group can be become, and each flow group can be assigned to a primary node and multiple secondary node, not only ensure that the resource utilization of each node but also reach the object of multiple-node backup.
For solving the problem, the technical solution adopted in the present invention is as follows:
Scheme one:
Realize a method for the many backups of various flow group in highly available cluster system, comprise the following steps:
S1: create multiple flow group, according to the node that user distributes for each flow group, generates corresponding node listing in each flow group;
S2: be respectively the priority level of each peer distribution in corresponding flow group in each node listing, and by the synchronizing information of priority level in corresponding node;
S3: periodically mutually send heartbeat message between each node corresponding to same flow group, heartbeat message comprises the priority level of this node in the flow group of correspondence;
S4: the priority level and the priority level of self that are arranged in other node of same flow group compare by each node, if the highest from the priority level in this flow group, then self is set to the current use node of this flow group, otherwise self is set to the secondary node of this flow group.
Preferably, also comprise after step s4:
S5: when certain node does not send heartbeat message within the cycle of presetting, then the priority level of this node in the flow group of correspondence is set to unavailable, temporarily exits from the flow group of correspondence to make this node.
Preferably, also comprise in step s 5: when this node sends heartbeat message again, then the priority level of this node in the flow group of correspondence is set to minimum or returns to original priority level.
Preferably, in step s 2, being respectively each peer distribution in each node listing about the method for the priority level of corresponding flow group is: according to the sequence of the node in node listing, be followed successively by the priority level of peer distribution in the flow group that this node listing is corresponding in this node listing from high to low.
Scheme two:
Realize a device for the many backups of various flow group in highly available cluster system, comprise with lower module:
Initialization module, for creating multiple flow group, according to the node that user distributes for each flow group, generates corresponding node listing in each flow group;
Priority level module is set, for being respectively the priority level of each peer distribution in corresponding flow group in each node listing, and by the synchronizing information of priority level in corresponding node;
Information interaction module, periodically mutually send heartbeat message for making between each node corresponding to same flow group, heartbeat message comprises the priority level of this node in the flow group of correspondence;
Priority level judges Executive Module, for making each node, the priority level and the priority level of self that are arranged in other node of same flow group are compared, if the highest from the priority level in this flow group, then self is set to the current use node of this flow group, otherwise self is set to the secondary node of this flow group.
Preferably, also comprise after judging Executive Module:
Breakdown judge Executive Module, for not sending heartbeat message when certain node within the cycle of presetting, is then set to unavailable by the priority level of this node in the flow group of correspondence, temporarily exits to make this node from the flow group of correspondence.
Preferably, also comprise in breakdown judge Executive Module: when this node sends heartbeat message again, then the priority level of this node in the flow group of correspondence is set to minimum or returns to original priority level.
Preferably, arranging in priority level module, being respectively each peer distribution in each node listing about the method for the priority level of corresponding flow group is: according to the sequence of the node in node listing, be followed successively by the priority level of peer distribution in the flow group that this node listing is corresponding in this node listing from high to low.
Compared to existing technology, beneficial effect of the present invention is: make each node in a cluster can become the primary node of one or more flow group, also the secondary node of one or more flow group can be become, and each flow group can be assigned to a primary node and multiple secondary node, not only ensure that the resource utilization of each node but also reach the object of multiple-node backup.In addition, when certain one malfunctions, rapidly this node can be exited isolation from the flow group of correspondence, and re-elect the highest node of priority as primary node in affected flow group, guaranteed flow group can keep normal operation.
Accompanying drawing explanation
Fig. 1 is the flow chart realizing the method for the many backups of various flow group in highly available cluster system of the present invention.
Embodiment
Below, by reference to the accompanying drawings and embodiment, the present invention is described further:
Be a kind of method realizing the many backups of various flow group in highly available cluster system of the present invention with reference to figure 1, comprise the following steps:
S1: create multiple flow group, according to the node that user distributes for each flow group, generates corresponding node listing in each flow group;
S2: be respectively the priority level of each peer distribution in corresponding flow group in each node listing, and by the synchronizing information of priority level in corresponding node;
S3: periodically mutually send heartbeat message between each node corresponding to same flow group, heartbeat message comprises the priority level of this node in the flow group of correspondence;
S4: the priority level and the priority level of self that are arranged in other node of same flow group compare by each node, if the highest from the priority level in this flow group, then self is set to the current use node of this flow group, otherwise self is set to the secondary node of this flow group.
S5: when certain node does not send heartbeat message within the cycle of presetting, then the priority level of this node in the flow group of correspondence is set to unavailable, temporarily exits from the flow group of correspondence to make this node; When this node sends heartbeat message again, then the priority level of this node in the flow group of correspondence is set to minimum or returns to original priority level.
For above-mentioned steps, before step S1, first configure the unique identification of each node, sync cap information and heart beat interface information etc. and make each node initializing.Then in step sl, multiple flow group is created according to business demand, flow group can be understood as the group representing certain business or certain system and formed, node is for maintaining the normal operation of flow group, and user can be chosen as each flow component and join multiple node, and node assigned in different flow group can be identical, also can be different, after distribution node, node listing can be generated in corresponding flow group, in node listing, record the node that user distributes for this flow group.
In step s 2, be respectively the priority level of each peer distribution in corresponding flow group in each node listing, and by the synchronizing information of priority level in corresponding node.The method of distributing priority level can be specifically: according to the sequence of the node in node listing, be followed successively by the priority level of peer distribution in the flow group that this node listing is corresponding in this node listing from high to low.Such as, 4 nodes are had in flow group 1, be respectively node 3, node 6, node 7 and node 9, its sequence in node listing is node 7, node 3, node 9 and node 6, and the mode of sequence can be that user manually sorts, and also can be to sort according to the sort criteria preset, that, node 7 is TP top priority, is secondly node 3, is then that node 9 arrives node 6 again.The identification method of priority level can be: carry out priority level sequence by digital 1-254, and wherein 254 is highest ranking, successively decreases successively to 1, namely above-mentioned node 7 for priority level be 254, node 3 is 253, and node 9 is 252, and node 6 is 251.Certainly, the identification means of its priority level can also be other mode, is described in the description just below the present embodiment with above-mentioned priority level identification method.After being assigned with priority level mark, can by its synchronizing information in corresponding node, i.e. advised nodes 7, the priority level of flow group 1 is designated 254, by that analogy.
In step s3, periodically mutually heartbeat message can be sent between each node in same flow group, inform the priority level of this node of the other side in this flow group, its objective is the priority level making each node in same flow group can be informed in all nodes in this flow group, is the basis judged below.After mutual transmission heartbeat message, node 7 just knows the priority level that node 3, node 9 and node 6 are respective in flow group 1.
In step s 4 which, the priority level of other node that each node is received in the flow group of correspondence compares with from the priority level in corresponding flow group, such as, the priority level 254 and 253 of node 3 of self, 251 of 252 and the node 6 of node 9 compare by node 7 meeting.Relatively, if the highest from the priority level in the flow group of correspondence, then self is set to the current use node of corresponding flow group, therefore, node 7 is the current use node of flow group 1, and node 3, node 9 and node 6 are the secondary node of flow group 1.
In step s 5, when certain node does not send heartbeat message within the cycle of presetting, then the priority level of this node in the flow group of correspondence is set to unavailable.Such as, node 7 does not all send heartbeat message within 3 cycles, then think that node 7 is for malfunctioning node, now its priority level in flow group 1 is set to 0,0 represents unavailable, is equivalent to this node temporarily to exit from the flow group of correspondence, waits for fault recovery, if node 7 also has priority level in other flow group, can be set as unavailable so equally.After node 7 exits flow group 1, flow group 1 is remaining node 3, node 9 and node 6 also, and the priority level now about flow group 1 compares, and only remaining node 3, node 9 and node 6 compare, the priority level 253 of node 3 is the highest, then node 3 becomes the current use node of flow group 1.When node 7 sends heartbeat message again, represent that it recovers again, now there are two kinds of recovery schemes, a kind of next stage being the priority level of node 7 in flow group 1 and being set to current lowest priority, namely current preference grade is 251 of node 6, then the priority level of node 7 is set to 250, becomes the secondary node of flow group 1; Another be node 7 is returned to before priority level, namely 254, if return to 254, then node 7 can become the current use node of flow group 1 again.
By method of the present invention, make each node in a cluster can become the primary node of one or more flow group, also the secondary node of one or more flow group can be become, and each flow group can be assigned to a primary node and multiple secondary node, not only ensure that the resource utilization of each node but also reach the object of multiple-node backup.In addition, when certain one malfunctions, rapidly this node can be exited isolation from the flow group of correspondence, and re-elect the highest node of priority as primary node in affected flow group, guaranteed flow group can keep normal operation.
The invention also discloses a kind of device realizing the many backups of various flow group in highly available cluster system, comprise with lower module:
Initialization module, for creating multiple flow group, according to the node that user distributes for each flow group, generates corresponding node listing in each flow group;
Priority level module is set, for being respectively the priority level of each peer distribution in corresponding flow group in each node listing, and by the synchronizing information of priority level in corresponding node;
Information interaction module, periodically mutually send heartbeat message for making between each node corresponding to same flow group, heartbeat message comprises the priority level of this node in the flow group of correspondence;
Priority level judges Executive Module, the priority level of other node received for making each node in the flow group of correspondence compares with from the priority level in corresponding flow group, if the highest from the priority level in the flow group of correspondence, then self is set to the current use node of corresponding flow group, otherwise self is set to the secondary node of corresponding flow group.
Preferably, also comprise after judging Executive Module:
Breakdown judge Executive Module, for not sending heartbeat message when certain node within the cycle of presetting, is then set to unavailable by the priority level of this node in the flow group of correspondence, temporarily exits to make this node from the flow group of correspondence.
Preferably, also comprise in breakdown judge Executive Module: when this node sends heartbeat message again, then the priority level of this node in the flow group of correspondence is set to minimum or returns to original priority level.
Preferably, arranging in priority level module, being respectively each peer distribution in each node listing about the method for the priority level of corresponding flow group is: according to the sequence of the node in node listing, be followed successively by the priority level of peer distribution in the flow group that this node listing is corresponding in this node listing from high to low.
To one skilled in the art, according to technical scheme described above and design, other various corresponding change and deformation can be made, and all these change and deformation all should belong within the protection range of the claims in the present invention.

Claims (8)

1. realize a method for the many backups of various flow group in highly available cluster system, it is characterized in that, comprise the following steps:
S1: create multiple flow group, according to the node that user distributes for each flow group, generates corresponding node listing in each flow group;
S2: be respectively the priority level of each peer distribution in corresponding flow group in each node listing, and by the synchronizing information of priority level in corresponding node;
S3: periodically mutually send heartbeat message between each node corresponding to same flow group, heartbeat message comprises the priority level of this node in the flow group of correspondence;
S4: the priority level and the priority level of self that are arranged in other node of same flow group compare by each node, if the highest from the priority level in this flow group, then self is set to the current use node of this flow group, otherwise self is set to the secondary node of this flow group.
2. the method realizing the many backups of various flow group in highly available cluster system according to claim 1, is characterized in that, also comprise after step s4:
S5: when certain node does not send heartbeat message within the cycle of presetting, then the priority level of this node in the flow group of correspondence is set to unavailable, temporarily exits from the flow group of correspondence to make this node.
3. the method realizing the many backups of various flow group in highly available cluster system according to claim 2, it is characterized in that, also comprise in step s 5: when this node sends heartbeat message again, then the priority level of this node in the flow group of correspondence is set to the next stage of current lowest priority or returns to original priority level.
4. the method realizing the many backups of various flow group in highly available cluster system according to claim 1, it is characterized in that, in step s 2, being respectively each peer distribution in each node listing about the method for the priority level of corresponding flow group is: according to the sequence of the node in node listing, be followed successively by the priority level of peer distribution in the flow group that this node listing is corresponding in this node listing from high to low.
5. realize a device for the many backups of various flow group in highly available cluster system, it is characterized in that, comprise with lower module:
Initialization module, for creating multiple flow group, according to the node that user distributes for each flow group, generates corresponding node listing in each flow group;
Priority level module is set, for being respectively the priority level of each peer distribution in corresponding flow group in each node listing, and by the synchronizing information of priority level in corresponding node;
Information interaction module, periodically mutually send heartbeat message for making between each node corresponding to same flow group, heartbeat message comprises the priority level of this node in the flow group of correspondence;
Priority level judges Executive Module, for making each node, the priority level and the priority level of self that are arranged in other node of same flow group are compared, if the highest from the priority level in this flow group, then self is set to the current use node of this flow group, otherwise self is set to the secondary node of this flow group.
6. the device realizing the many backups of various flow group in highly available cluster system according to claim 5, is characterized in that, also comprise after judging Executive Module:
Breakdown judge Executive Module, for not sending heartbeat message when certain node within the cycle of presetting, is then set to unavailable by the priority level of this node in the flow group of correspondence, temporarily exits to make this node from the flow group of correspondence.
7. the device realizing the many backups of various flow group in highly available cluster system according to claim 6, it is characterized in that, also comprise in breakdown judge Executive Module: when this node sends heartbeat message again, then the priority level of this node in the flow group of correspondence is set to minimum or returns to original priority level.
8. the device realizing the many backups of various flow group in highly available cluster system according to claim 5, it is characterized in that, arranging in priority level module, being respectively each peer distribution in each node listing about the method for the priority level of corresponding flow group is: according to the sequence of the node in node listing, be followed successively by the priority level of peer distribution in the flow group that this node listing is corresponding in this node listing from high to low.
CN201510442344.2A 2015-07-24 2015-07-24 Method and device for realizing multiple backups of multiple flow groups in high-availability cluster system Pending CN105141445A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510442344.2A CN105141445A (en) 2015-07-24 2015-07-24 Method and device for realizing multiple backups of multiple flow groups in high-availability cluster system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510442344.2A CN105141445A (en) 2015-07-24 2015-07-24 Method and device for realizing multiple backups of multiple flow groups in high-availability cluster system

Publications (1)

Publication Number Publication Date
CN105141445A true CN105141445A (en) 2015-12-09

Family

ID=54726663

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510442344.2A Pending CN105141445A (en) 2015-07-24 2015-07-24 Method and device for realizing multiple backups of multiple flow groups in high-availability cluster system

Country Status (1)

Country Link
CN (1) CN105141445A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114301960A (en) * 2021-12-15 2022-04-08 山石网科通信技术股份有限公司 Processing method and device for asymmetric flow of cluster, electronic equipment and storage medium
CN114301763A (en) * 2021-12-15 2022-04-08 山石网科通信技术股份有限公司 Distributed cluster fault processing method and system, electronic device and storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20010056461A1 (en) * 2000-05-02 2001-12-27 Sun Microsystems, Inc. Cluster configuration repository
CN1512375A (en) * 2002-12-31 2004-07-14 联想(北京)有限公司 Fault-tolerance approach using machine group node interacting buckup
CN1855916A (en) * 2005-04-20 2006-11-01 大唐移动通信设备有限公司 Method and system for realizing virtual IP protocol
CN101651560A (en) * 2009-07-23 2010-02-17 中国科学院声学研究所 Two-way routing network and reliability supporting method
CN101656624A (en) * 2008-08-18 2010-02-24 中兴通讯股份有限公司 Multi-node application-level disaster recovery system and multi-node application-level disaster recovery method
CN104506357A (en) * 2014-12-22 2015-04-08 国云科技股份有限公司 High-usability cluster node management method

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20010056461A1 (en) * 2000-05-02 2001-12-27 Sun Microsystems, Inc. Cluster configuration repository
CN1512375A (en) * 2002-12-31 2004-07-14 联想(北京)有限公司 Fault-tolerance approach using machine group node interacting buckup
CN1855916A (en) * 2005-04-20 2006-11-01 大唐移动通信设备有限公司 Method and system for realizing virtual IP protocol
CN101656624A (en) * 2008-08-18 2010-02-24 中兴通讯股份有限公司 Multi-node application-level disaster recovery system and multi-node application-level disaster recovery method
CN101651560A (en) * 2009-07-23 2010-02-17 中国科学院声学研究所 Two-way routing network and reliability supporting method
CN104506357A (en) * 2014-12-22 2015-04-08 国云科技股份有限公司 High-usability cluster node management method

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114301960A (en) * 2021-12-15 2022-04-08 山石网科通信技术股份有限公司 Processing method and device for asymmetric flow of cluster, electronic equipment and storage medium
CN114301763A (en) * 2021-12-15 2022-04-08 山石网科通信技术股份有限公司 Distributed cluster fault processing method and system, electronic device and storage medium
CN114301960B (en) * 2021-12-15 2024-03-15 山石网科通信技术股份有限公司 Processing method and device for cluster asymmetric traffic, electronic equipment and storage medium

Similar Documents

Publication Publication Date Title
TWI724106B (en) Business flow control method, device and system between data centers
JP6382454B2 (en) Distributed storage and replication system and method
CN105406980B (en) A kind of multinode backup method and device
JP5933689B2 (en) Method and apparatus for supplying electrical energy
CN100391193C (en) Method and device for implementation of resynchronization of topological data base in communication network having topological state routing protocol
CN108632067B (en) Disaster recovery deployment method, device and system
CN109729129A (en) Configuration modification method, storage cluster and the computer system of storage cluster
CN103188110B (en) Based on the heat backup method that the cloud platform of zookeeper is served
EP3433759A1 (en) Method and apparatus for expanding high-availability server cluster
EP3016316A1 (en) Network control method and apparatus
CN105337780B (en) A kind of server node configuration method and physical node
WO2019128670A1 (en) Method and apparatus for enabling self-recovery of management capability in distributed system
CN111190736A (en) Low-intrusion distributed timing task scheduling system and method based on microservice
CN103019889A (en) Distributed file system and failure processing method thereof
US20120179826A1 (en) Address Distribution Method, Device and System Thereof
CN101588304A (en) Implementation method of VRRP
US9231779B2 (en) Redundant automation system
CN105635199A (en) Method and device for implementation of self-organization cluster server supporting load balancing
CN105141445A (en) Method and device for realizing multiple backups of multiple flow groups in high-availability cluster system
WO2014060465A1 (en) Control system and method for supervisory control and data acquisition
KR20110046897A (en) Method to elect master nodes from nodes of a subnet
KR101233607B1 (en) Method for managing path of osek networks
US9015518B1 (en) Method for hierarchical cluster voting in a cluster spreading more than one site
CN114338670B (en) Edge cloud platform and network-connected traffic three-level cloud control platform with same
CN109218386A (en) A kind of high availability method managing Hadoop NameSpace

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20151209

RJ01 Rejection of invention patent application after publication