CN106656617A - Master-slave switching method and device - Google Patents
Master-slave switching method and device Download PDFInfo
- Publication number
- CN106656617A CN106656617A CN201611248792.XA CN201611248792A CN106656617A CN 106656617 A CN106656617 A CN 106656617A CN 201611248792 A CN201611248792 A CN 201611248792A CN 106656617 A CN106656617 A CN 106656617A
- Authority
- CN
- China
- Prior art keywords
- active
- load
- balancing device
- server state
- standby
- 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.)
- Granted
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L41/00—Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
- H04L41/06—Management of faults, events, alarms or notifications
- H04L41/0654—Management of faults, events, alarms or notifications using network fault recovery
- H04L41/0668—Management 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
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L43/00—Arrangements for monitoring or testing data switching networks
- H04L43/08—Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
- H04L43/0823—Errors, e.g. transmission errors
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Environmental & Geological Engineering (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
- Hardware Redundancy (AREA)
Abstract
The invention provides a master-slave switching method and device. In the application, after master-slave switching is carried out, first load balancing equipment can distribute the received service flow according to various server states sent to the local by second load balancing equipment at first; and, after the local obtains the server states through an active detection mechanism, the received service flow is distributed according to actively detected server states, so that the possible service interruption phenomenon under a master-slave switching condition can be eliminated.
Description
Technical field
The application is related to network communication technology field, more particularly to a kind of main/standby switching method and device.
Background technology
For improve network reliability, double-machine standby technology of mourning in silence have become in networking technology commonly use technological means it
One.In network environment as shown in Figure 1, load-balancing device employs double-machine standby technology of mourning in silence.Specifically, the networking
Environment is related to a Dual-Computer Hot-Standby System, and it is standby equipment that the system is included in before active-standby switch, be main equipment after active-standby switch
First load-balancing device, and be main equipment before active-standby switch, be the second load balancing of standby equipment after active-standby switch
Equipment.Wherein, before active-standby switch, the second load-balancing device is in normal operating conditions, and the first load-balancing device is in quiet
Silent state, under silent status, though the equipment goes up electricity, its business interface is closed, and does not process any service traffics;When second negative
When carrying balancing equipment failure, the first load-balancing device actively switches to main equipment, opens its business interface, and starts actively inspection
Survey mechanism, with each server state arrived according to the active detecting, the service traffics to receiving are allocated.But due to setting
It is required to expend the regular hour for starting the active detecting mechanism and carrying out each server state detection by the mechanism,
Therefore the first load-balancing device cannot according to the active detecting to each server state the service traffics for receiving are carried out and
When distribute, i.e., of short duration service disconnection phenomenon occurs in the case of active-standby switch.Wherein, active detecting mechanism is specifically referred to,
Whether load-balancing device periodically sends health detection message to each server, and returned in limiting time with each server
It is foundation to return health detection response message, determines each server state.
For this problem, prior art is shortened by the side that the first load-balancing device sends the health detection message cycle
Formula is accelerating to confirm each server state, but this scheme can only limitedly shorten service outage duration, and master can not be completely eliminated
The service disconnection phenomenon being likely to occur under standby switch instances.
The content of the invention
In view of this, the application provides a kind of main/standby switching method and device, to eliminate active-standby switch in the case of, may
The service disconnection phenomenon of appearance.
According to the first aspect of the embodiment of the present application, there is provided a kind of method of active-standby switch, methods described is applied to two-shipper
Hot-backup system, the Dual-Computer Hot-Standby System includes:It is standby equipment before active-standby switch, is the first of main equipment after active-standby switch
Load-balancing device, and be main equipment before active-standby switch, be the second load-balancing device of standby equipment after active-standby switch,
Methods described includes:
First load-balancing device carries out continuation by active detecting mechanism before active-standby switch to each server state
Ground active detecting, and receive second load-balancing device and send to local each server state;
It is determined that during the second load-balancing device failure, carrying out active-standby switch;
After active-standby switch, local service interface is opened, according to second load-balancing device nearest one before failure
Secondary to send to local each server state, the service traffics to receiving from the business interface are allocated;And continue
Routinely active detecting is carried out to each server state by the active detecting mechanism;
It is right according to the server state that this is obtained after active detecting obtains server state after the active-standby switch
The service traffics for receiving are allocated.
According to the second aspect of the embodiment of the present application, there is provided a kind of active-standby switch device, described device is applied to dual-locomotive heat
The first load-balancing device in standby system, the Dual-Computer Hot-Standby System includes:It is standby equipment before active-standby switch, cuts active and standby
It is the first load-balancing device of main equipment after changing, and is main equipment before active-standby switch, after active-standby switch is standby equipment
The second load-balancing device, described device includes:
Server state active detecting unit, for carrying out continuation to each server state by active detecting mechanism
Active detecting;
Server state receiving unit, sends to local each server shape for receiving second load-balancing device
State;
Active-standby switch unit, for it is determined that carrying out active-standby switch during the second load-balancing device failure;
Business interface opening unit, for opening local service interface after active-standby switch;
Service traffics allocation unit, for obtaining server shape after active-standby switch and by the detection of active detecting mechanism
Before state, according to second load-balancing device, the last time is sent to local each server state before failure, to receiving
To service traffics be allocated;And for obtaining server shape after active-standby switch and by the detection of active detecting mechanism
After state, according to each server state that the detection of active detecting mechanism is obtained, the service traffics to receiving are allocated.
In the application, the first load-balancing device, can be first according to the second load-balancing device after active-standby switch is carried out
Send to local each server state, the service traffics to receiving are allocated;When locally being obtained by active detecting mechanism
After obtaining server state, service traffics of the server state gone out further according to active detecting to receiving are allocated, so as to
Eliminate active-standby switch in the case of it is possible that service disconnection phenomenon.
Description of the drawings
Fig. 1 is that an a kind of exemplary scene of main/standby switching method of the application is illustrated;
Fig. 2 is a kind of flow chart of main/standby switching method of the application;
Fig. 3 is a kind of one embodiment flow chart of main/standby switching method of the application;
Fig. 4 is a kind of a kind of structural representation of active-standby switch device of the application;
Fig. 5 is a kind of another kind of structural representation of active-standby switch device of the application.
Specific embodiment
Here exemplary embodiment will be illustrated in detail, its example is illustrated in the accompanying drawings.Explained below is related to
During accompanying drawing, unless otherwise indicated, the same numbers in different accompanying drawings represent same or analogous key element.Following exemplary embodiment
Described in embodiment do not represent all embodiments consistent with the application.Conversely, they be only with it is such as appended
The example of the consistent apparatus and method of some aspects described in detail in claims, the application.
It is, only merely for the purpose of description specific embodiment, and to be not intended to be limiting the application in term used in this application.
" one kind ", " described " and " being somebody's turn to do " of singulative used in the application and appended claims is also intended to include majority
Form, unless context clearly shows that other implications.It is also understood that term "and/or" used herein is referred to and wrapped
Containing one or more associated any or all possible combinations for listing project.
It will be appreciated that though various information, but this may be described using term first, second, third, etc. in the application
A little information should not necessarily be limited by these terms.These terms are only used for that same type of information is distinguished from each other out.For example, without departing from
In the case of the application scope, the first information can also be referred to as the second information, and similarly, the second information can also be referred to as
One information.Depending on linguistic context, word as used in this " if " can be construed to " ... when " or " when ...
When " or " in response to determining ".
Referring to Fig. 1, Fig. 1 is an a kind of exemplary schematic diagram of a scenario of main/standby switching method of the application.The schematic diagram
It is related to client device, server cluster and a Dual-Computer Hot-Standby System.Wherein, Dual-Computer Hot-Standby System includes:In active-standby switch
Before be standby equipment, after active-standby switch be the first load-balancing device of main equipment, and be main equipment before active-standby switch,
It is the second load-balancing device of standby equipment after active-standby switch.Specifically, the first load-balancing device meeting real-time reception second is negative
The heartbeat message that balancing equipment periodically sends is carried, so that when the second load-balancing device stops sending heartbeat message, judging should
Second load-balancing device failure, and active-standby switch is carried out, become main equipment.It will be appreciated by persons skilled in the art that
Before active-standby switch, the second load-balancing device is in normal operating conditions, and the first load-balancing device is in silent status, mourns in silence
Under state, though the equipment goes up electricity, its business interface is closed, and does not process any service traffics, and to client device and
Server cluster is invisible equipment;When the second load-balancing device failure, the first load-balancing device can actively switch
For main equipment, its business interface is opened, and start active detecting mechanism, with each server state arrived according to the active detecting,
Service traffics to receiving are allocated.Wherein, invisible equipment can be understood as:MAC (the Media Access of the equipment
Control, media access control) information such as address is well known to other equipment, so and being not involved in the mistake of service communication
Journey.However, because the first load-balancing device is carried out from startup active detecting mechanism and by the mechanism to each server state
Detection, to according to the active detecting to each server state service traffics are allocated, be required to expend the regular hour,
That is the first load-balancing device cannot be after active-standby switch, and just the service traffics in time to receiving are allocated, so leading
Under standby switch instances, it may appear that of short duration service disconnection phenomenon.Wherein, active detecting mechanism is specifically referred to, load-balancing device
Periodically health detection message is sent to each server, and rung so that whether each server returns health detection in limiting time
Answer message to be foundation, determine each server state.
For this problem, prior art is shortened by the side that the first load-balancing device sends the health detection message cycle
Formula is accelerating to confirm each server state, but this scheme can only limitedly shorten service outage duration, and master can not be completely eliminated
The service disconnection phenomenon being likely to occur under standby switch instances.
In consideration of it, this application provides a kind of main/standby switching method, in this method, the first load-balancing device is being led
After standby switching, can be sent to local each server state, to the Business Stream for receiving according to the second load-balancing device first
Amount is allocated;After locally server state is obtained by active detecting mechanism, further according to the server that active detecting goes out
State is allocated to the service traffics for receiving, so as to eliminate active-standby switch in the case of it is possible that service disconnection show
As.
In order that those skilled in the art more fully understand the technical scheme in the embodiment of the present application, and make the application reality
Apply the above-mentioned purpose of example, feature and advantage can become apparent from it is understandable, below in conjunction with the accompanying drawings to technical side in the embodiment of the present application
Case is described in further detail.
Referring to Fig. 2, Fig. 2 is a kind of flow chart of main/standby switching method of the application, and the flow chart may comprise steps of:
Step 201:First load-balancing device is entered by active detecting mechanism before active-standby switch to each server state
Row routinely active detecting, and receive the second load-balancing device and send to local each server state.
In the present embodiment, the first load-balancing device is carried out routinely by active detecting mechanism to each server state
Active detecting, can be accomplished by:First load-balancing device sends healthy inspection to each server persistence
Text is observed and predicted, and judges whether each server returns health detection response message in setting duration, if it is, determining the clothes
Business device is in health status, otherwise, in malfunction.Also the regular hour can be expended due to starting active detecting mechanism, therefore
In the present embodiment, the first load-balancing device can will pass through the active detecting mechanism each to more than when in standby equipment state
Server state is detected, to save after active-standby switch the time for opening active detecting mechanism.
Step 202:It is determined that during the second load-balancing device failure, the first load-balancing device carries out active-standby switch, into
For main equipment.
In the present embodiment, the first load-balancing device can routinely be monitored the second load balancing and set before active-standby switch
It is standby periodically to send to local heartbeat message, and when heartbeat message stopping is listened to, determine second load balancing
Equipment fault, carries out active-standby switch.
Step 203:First load-balancing device opens local service interface after active-standby switch, equal according to the second load
Weighing apparatus equipment the last time before failure is sent to local each server state, to the service traffics received from the business interface
It is allocated;And continue through the active detecting mechanism carries out routinely active detecting to each server state.
In the present embodiment, the second load-balancing device, can be by local active detecting machine when in normal operating conditions
System detects to each server state, and when detecting each server state and changing, by a local backup interface,
Each server state after by change is sent to the first load-balancing device, so that the first load-balancing device can be into based on
After equipment, the service traffics for receiving are distributed temporarily according to the server state.Wherein, the first load-balancing device
Can be connected with the backup interface of opposite end by a local backup interface respectively with the second load-balancing device, with by connection this two
The backup link of end equipment backup interface, carries out data sharing.
Step 204:First load-balancing device after active detecting obtains server state after the active-standby switch, root
The server state obtained according to this, the service traffics to receiving are allocated.
In the present embodiment, because the first load-balancing device is by active detecting mechanism, obtain each server state when
Between may and differ, so the first load-balancing device can't when obtain server cluster in Servers-all state
Afterwards, just according to the active detecting to server state the service traffics for receiving are allocated, but in real time according to can be with
The newest testing result for acquiring, is allocated to flow, to ensure the reliability of assignment of traffic.
By above method as can be seen that the first load-balancing device is after active-standby switch is carried out, can be first according to second
Load-balancing device is sent to local each server state, and the service traffics to receiving are allocated;When local by master
Dynamic testing mechanism is obtained after server state, and service traffics of the server state gone out further according to active detecting to receiving are entered
Row distribution, so as to eliminate active-standby switch in the case of it is possible that service disconnection phenomenon.
Referring to Fig. 3, Fig. 3 is a kind of one embodiment flow chart of main/standby switching method of the application, and the flow chart can be wrapped
Include following steps:
Step 301:First load-balancing device is entered by active detecting mechanism before active-standby switch to each server state
Capable routinely active detecting, and each server state detected for active arranges invalid flag;Receive above-mentioned second load
Balancing equipment is sent to local each server state;Routinely monitor above-mentioned second load-balancing device to send to local
Heartbeat message.
In the present embodiment, before active-standby switch, the first load-balancing device is in silent status, therefore it is for server set
It is invisible equipment for group, so, even if the equipment is to save after active-standby switch the time for starting active detecting mechanism, and
During as standby equipment, just can pass through active detecting mechanism to server transmission health detection message, but due to each server simultaneously
Do not know the presence of the equipment, therefore health detection response message will not be returned to the equipment so that the equipment detect it is each
Server state is not the time of day of each server.In consideration of it, the present embodiment be the first load-balancing device as standby
The each server state detected during equipment is provided with invalid flag, with mark this to detect each server state as invalid,
So that the first load-balancing device becomes after main equipment, the false testing result can be ignored according to the invalid flag, and
Temporarily sent in normal work to local each server state, to the Business Stream for receiving using the second load-balancing device
Amount is allocated, so as to avoid the disruption of business.
Step 302:When the heartbeat message monitored stops, the first load-balancing device determines the second load-balancing device
Failure, and carry out active-standby switch.
The event of the second load-balancing device can be determined according to the heartbeat message for receiving with regard to the first load-balancing device
Whether hinder, be described in detail in step 202., so repeating no more.
Step 303:First load-balancing device opens local service interface after active-standby switch, and judges the first load
It is invalid flag or significant notation that balancing equipment is the mark set by the server state for actively detecting, if invalid
Mark, then according to above-mentioned second load-balancing device before failure the last time send to local each server state, to from
The service traffics that above-mentioned business interface is received are allocated;Continue through above-mentioned active detecting mechanism to enter each server state
Capable routinely active detecting, and each server state detected for active arranges significant notation.
In the present embodiment, if the first load-balancing device judges the mark that the server state to detect is arranged
For significant notation when, then according to each server state that this is detected, the service traffics to receiving are allocated.Now,
One load-balancing device has been completed the active detecting after an active-standby switch to each server state, and the testing result is true
It is real effective.Specifically, the first load-balancing device can be after active-standby switch, by outwards issuing gratuitous ARP (Address
Resolution Protocol, address resolution protocol) message mode, outwardly notice the information such as local MAC Address, with
The flow lead that each server is returned is to locally being processed.Such as, when between load-balancing device and server cluster
When there is a switch in administration, the first load-balancing device just can send the gratuitous ARP for carrying local mac address to the switch
Message, to update the ARP stored on the switch.It is pointed out that when load-balancing device and server cluster it
Between when not disposing switch, the first load-balancing device can also be by gratuitous ARP packet, directly in server cluster
Each server issues the information such as the MAC Address of oneself." issue " one word i.e. in the application, what restriction was given out information connects
Receipts person's specifically certain equipment or any number of equipment, and simply outwardly noticed the message.In the present embodiment,
In Dual-Computer Hot-Standby System, two load-balancing devices can share an IP (Internet Protocol, between network mutually
The agreement of connection) address, and use different MAC Address.Due to always having an equipment in the system in silent status, thus this two
The IP address of platform equipment can't produce conflict.When the ARP in switch establishes the IP address and the first load balancing
After the corresponding relation of device mac address, the flow for receiving will be forwarded to the first load-balancing device, so as to ensure that this
Normal process of the system to business.
Step 304:Server state is obtained in the active detecting after the active-standby switch, and judges that the active detecting is arrived
Server state when being provided with significant notation, the server state that the first load-balancing device is obtained according to this, to receiving
Service traffics be allocated.
In the present embodiment, when judging that server state is provided with significant notation, the first load-balancing device is according to this
The server state for obtaining, the service traffics to receiving are allocated.If the first load-balancing device judges the active
When the server state for detecting still is marked with invalid flag, just continue according to the second load-balancing device nearest one before failure
Secondary to send to local each server state, the service traffics to receiving from above-mentioned business interface are allocated.
By above example as can be seen that the first load-balancing device is after active-standby switch is carried out, can first according to the
Two load-balancing devices are sent to local each server state, and the service traffics to receiving are allocated;When locally passing through
Active detecting mechanism is obtained after server state, and the server state gone out further according to active detecting is to the service traffics that receive
Be allocated, so as to eliminate active-standby switch in the case of it is possible that service disconnection phenomenon.
It is corresponding with a kind of aforementioned embodiment of the method for control server shutdown, present invention also provides a kind of control clothes
The embodiment of the device of business device shutdown.
A kind of embodiment of the device of control server shutdown of the application can be applied on load-balancing device.Device reality
Applying example can be realized by software, it is also possible to be realized by way of hardware or software and hardware combining.As a example by implemented in software, make
For the device on a logical meaning, being will be right in nonvolatile memory by the processor on its place load-balancing device
The computer program instructions answered read what operation in internal memory was formed.
Referring to Fig. 4, Fig. 4 is a kind of a kind of structural representation of active-standby switch device of the application, and the device is applied to two-shipper
The first load-balancing device in hot-backup system, the Dual-Computer Hot-Standby System includes:It is standby equipment before active-standby switch, cuts active and standby
It is the first load-balancing device of main equipment after changing, and is main equipment before active-standby switch, after active-standby switch is standby equipment
The second load-balancing device, the device can include:Server state active detecting unit 410, server state receives single
Unit 420, active-standby switch unit 440, business interface opening unit 450, service traffics allocation unit 460.
Wherein, server state active detecting unit 410, for being carried out to each server state by active detecting mechanism
The active detecting of continuation;
Server state receiving unit 420, sends to local each server shape for receiving the second load-balancing device
State;
Active-standby switch unit 440, for it is determined that carrying out active-standby switch during the second load-balancing device failure;
Business interface opening unit 450, for opening local service interface after active-standby switch;
Service traffics allocation unit 460, for obtaining server after active-standby switch and by the detection of active detecting mechanism
Before state, according to the second load-balancing device, the last time is sent to local each server state, to receiving before failure
Service traffics be allocated;And for obtaining server state after active-standby switch and by the detection of active detecting mechanism
Afterwards, each server state for being obtained according to the detection of active detecting mechanism, the service traffics to receiving are allocated.
In a kind of specific embodiment of the application, server state active detecting unit 410, specifically for each
Server persistence ground sends health detection message, and judges whether each server returns health detection and ring in setting duration
Message is answered, if it is, the server is determined in health status, otherwise, it determines the server is in malfunction;
Service traffics allocation unit 460, specifically for the service traffics for receiving are distributed to the clothes in health status
Business device.
In a kind of specific embodiment of the application, server state active detecting unit 410 is additionally operable to be examined for active
The each server state for measuring arranges invalid flag or significant notation;
Service traffics allocation unit 460, specifically for being the server state institute that active is detected when flag setting unit
When the mark of setting is invalid flag, according to the second load-balancing device, the last time is sent to local each service before failure
Device state, to from business interface to service traffics be allocated;And when flag setting unit is actively detected
When mark set by server state is significant notation, server state is obtained according to the active detecting, to from business interface
The service traffics for receiving are allocated.
In a kind of specific embodiment of the application, said apparatus can also include:Heartbeat message monitoring unit 430,
Specifically can be found in Fig. 5.
Heartbeat message monitoring unit 430, for the first load-balancing device before active-standby switch, routinely monitors second
Load-balancing device is sent to local heartbeat message;
Then active-standby switch unit 440, is particularly used in the heartbeat message monitored when heartbeat message monitoring unit 430 and stops
When, determine the second load-balancing device failure.
In a kind of specific embodiment of the application, said apparatus can also include:Gratuitous ARP packet release unit
460, specifically can be found in Fig. 5.
Gratuitous ARP packet release unit 470, for after active-standby switch, issuing free ARP message,
To notice local media access control MAC addresses.
In the application, the first load-balancing device, can be first according to the second load-balancing device after active-standby switch is carried out
Send to local each server state, the service traffics to receiving are allocated;When locally being obtained by active detecting mechanism
After obtaining server state, service traffics of the server state gone out further according to active detecting to receiving are allocated, so as to
Eliminate active-standby switch in the case of it is possible that service disconnection phenomenon.
The function of unit and effect realizes that process specifically refers in said method correspondence step in said apparatus
Process is realized, be will not be described here.
For device embodiment, because it corresponds essentially to embodiment of the method, so related part is referring to method reality
Apply the part explanation of example.Device embodiment described above is only schematic, wherein illustrating as separating component
Unit can be or may not be physically separate, can be as the part that unit shows or may not be
Physical location, you can be located at a place, or can also be distributed on multiple NEs.Can be according to the actual needs
Select some or all of module therein to realize the purpose of application scheme.Those of ordinary skill in the art are not paying wound
In the case that the property made is worked, you can to understand and implement.
The preferred embodiment of the application is the foregoing is only, not to limit the application, all essences in the application
Within god and principle, any modification, equivalent substitution and improvements done etc. should be included within the scope of the application protection.
Claims (10)
1. a kind of main/standby switching method, methods described is applied to Dual-Computer Hot-Standby System, and the Dual-Computer Hot-Standby System includes:Active and standby
Be standby equipment before switching, after active-standby switch be the first load-balancing device of main equipment, and before active-standby switch based on set
The second load-balancing device that is standby, after active-standby switch being standby equipment, it is characterised in that methods described includes:
First load-balancing device carries out continuation landlord by active detecting mechanism before active-standby switch to each server state
Detection is moved, and receives second load-balancing device and sent to local each server state;
It is determined that during the second load-balancing device failure, carrying out active-standby switch;
After active-standby switch, local service interface is opened, according to second load-balancing device the last before failure
Local each server state is delivered to, the service traffics to receiving from the business interface are allocated;And continue through
The active detecting mechanism carries out routinely active detecting to each server state;
After active detecting obtains server state after the active-standby switch, according to the server state that this is obtained, to receiving
To service traffics be allocated.
2. method according to claim 1, it is characterised in that described each server state is entered by active detecting mechanism
Capable routinely active detecting, including:
Health detection message is sent to each server persistence, and judges each server whether in setting duration
Health detection response message is returned, if it is, the server is determined in health status, otherwise, it determines the server is in
Malfunction;
The described pair of service traffics for receiving are allocated, including:The service traffics for receiving are distributed in health status
Server.
3. method according to claim 1, it is characterised in that methods described also includes:
It is that each server state for actively detecting arranges invalid flag before active-standby switch;
It is that each server state for actively detecting arranges significant notation after active-standby switch;
Judge that the first load-balancing device is that the mark set by the server state for actively detecting is invalid flag or has
Criterion is remembered, if invalid flag, then the first load-balancing device is the last before failure according to the second load-balancing device
Send to local each server state, the service traffics to receiving from the business interface are allocated;If effectively
Mark, the then server state that the first load-balancing device is arrived according to the active detecting, to what is received from the business interface
Service traffics are allocated.
4. method according to claim 1, it is characterised in that methods described also includes:First load-balancing device is being led
Before standby switching, routinely monitor second load-balancing device and send to local heartbeat message;
The second load-balancing device failure of the determination, including:
When the heartbeat message monitored stops, the second load-balancing device failure is determined.
5. method according to claim 1, it is characterised in that methods described also includes:After active-standby switch, issue free
ARP message, to notice local media access control MAC addresses.
6. a kind of active-standby switch device, described device is applied to the first load-balancing device in Dual-Computer Hot-Standby System, described double
Machine hot-backup system includes:It is standby equipment before active-standby switch, is the first load-balancing device of main equipment after active-standby switch, with
And before active-standby switch be main equipment, be the second load-balancing device of standby equipment after active-standby switch, it is characterised in that it is described
Device includes:
Server state active detecting unit, for being carried out to each server state routinely actively by active detecting mechanism
Detection;
Server state receiving unit, sends to local each server state for receiving second load-balancing device;
Active-standby switch unit, for it is determined that carrying out active-standby switch during the second load-balancing device failure;
Business interface opening unit, for opening local service interface after active-standby switch;
Service traffics allocation unit, before obtaining server state after active-standby switch and by the detection of active detecting mechanism,
According to second load-balancing device, the last time is sent to local each server state, to the industry for receiving before failure
Business flow is allocated;And for obtaining after server state after active-standby switch and by the detection of active detecting mechanism,
According to each server state that the detection of active detecting mechanism is obtained, the service traffics to receiving are allocated.
7. method according to claim 6, it is characterised in that
The server state active detecting unit, specifically for sending health detection message to each server persistence,
And judge whether each server returns health detection response message in setting duration, if it is, determining the service
Device is in health status, otherwise, it determines the server is in malfunction;
The service traffics allocation unit, specifically for the service traffics for receiving are distributed to the service in health status
Device.
8. device according to claim 6, it is characterised in that
The server state active detecting unit, is additionally operable to:For each server state that active is detected, invalid flag is set
Or significant notation;
The service traffics allocation unit, specifically for being the server state institute that active is detected when the flag setting unit
When the mark of setting is invalid flag, according to the second load-balancing device, the last time is sent to local each service before failure
Device state, the service traffics to receiving from the business interface are allocated;And when the flag setting unit is for actively
When the mark set by server state for detecting is significant notation, server state is obtained according to the active detecting, to from
The service traffics that the business interface is received are allocated.
9. device according to claim 6, it is characterised in that described device also includes:
Heartbeat message monitoring unit, for the first load-balancing device before active-standby switch, routinely monitors described second negative
Carry balancing equipment to send to local heartbeat message;
The active-standby switch unit, specifically for when heartbeat message that the heartbeat message monitoring unit is monitored stops, really
Fixed second load-balancing device failure.
10. device according to claim 6, it is characterised in that described device also includes:
Gratuitous ARP packet release unit, for after active-standby switch, issuing free ARP message, to notice this
Ground MAC address.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201611248792.XA CN106656617B (en) | 2016-12-29 | 2016-12-29 | Main/standby switching method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201611248792.XA CN106656617B (en) | 2016-12-29 | 2016-12-29 | Main/standby switching method and device |
Publications (2)
Publication Number | Publication Date |
---|---|
CN106656617A true CN106656617A (en) | 2017-05-10 |
CN106656617B CN106656617B (en) | 2020-01-03 |
Family
ID=58835963
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201611248792.XA Active CN106656617B (en) | 2016-12-29 | 2016-12-29 | Main/standby switching method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106656617B (en) |
Cited By (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN108965493A (en) * | 2018-07-03 | 2018-12-07 | 中国电子科技集团公司第十四研究所 | Data transmission switching method in two-node cluster hot backup |
CN109815065A (en) * | 2019-01-31 | 2019-05-28 | 杭州迪普科技股份有限公司 | Main/standby switching method, device, the electronic equipment of two-shipper |
CN110266795A (en) * | 2019-06-20 | 2019-09-20 | 上海思询信息科技有限公司 | One kind being based on Openstack platform courses method |
CN110768848A (en) * | 2019-10-31 | 2020-02-07 | 杭州迪普科技股份有限公司 | Method and device for switching main server and standby server |
CN111182374A (en) * | 2019-12-31 | 2020-05-19 | 杭州迪普科技股份有限公司 | Health detection message sending method and DPX equipment |
CN111628880A (en) * | 2019-02-27 | 2020-09-04 | 深圳迈瑞生物医疗电子股份有限公司 | Method for transferring failure of in-hospital equipment and monitoring system |
CN112311896A (en) * | 2020-11-16 | 2021-02-02 | 杭州迪普科技股份有限公司 | Health examination method, device, equipment and computer readable storage medium |
CN112749009A (en) * | 2020-12-30 | 2021-05-04 | 杭州迪普科技股份有限公司 | Server scheduling method and device |
CN112995726A (en) * | 2019-12-12 | 2021-06-18 | 杭州海康威视数字技术股份有限公司 | Display system, hot standby switching method and video control device |
CN114338688A (en) * | 2021-12-28 | 2022-04-12 | 中国农业银行股份有限公司 | Data management method and device |
CN115242505A (en) * | 2022-07-21 | 2022-10-25 | 北京天融信网络安全技术有限公司 | Equipment switching method, electronic equipment and system |
Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
EP0960496A1 (en) * | 1997-02-11 | 1999-12-01 | Excel Switching Corporation | Redundancy arrangement for telecommunications system |
JP2006235837A (en) * | 2005-02-23 | 2006-09-07 | Nec Corp | Load balancing system, load balancer management server, switching method for load balancer and program |
CN102420746A (en) * | 2011-11-14 | 2012-04-18 | 中兴通讯股份有限公司 | Forwarding method for multicast flow and network equipment therefor |
CN102629906A (en) * | 2012-03-30 | 2012-08-08 | 浪潮电子信息产业股份有限公司 | Design method for improving cluster business availability by using cluster management node as two computers |
CN103346923A (en) * | 2013-07-30 | 2013-10-09 | 曙光信息产业(北京)有限公司 | Management method and management device for double-unit load balancing equipment |
CN104426694A (en) * | 2013-08-28 | 2015-03-18 | 杭州华三通信技术有限公司 | Method and device for adjusting virtual-machine resources |
CN105306356A (en) * | 2014-07-30 | 2016-02-03 | 上海博达数据通信有限公司 | Method for realizing master-slave switching of multicast routing on distributed system |
CN105760260A (en) * | 2016-02-19 | 2016-07-13 | 浙江大华系统工程有限公司 | Backup system and backup method |
-
2016
- 2016-12-29 CN CN201611248792.XA patent/CN106656617B/en active Active
Patent Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
EP0960496A1 (en) * | 1997-02-11 | 1999-12-01 | Excel Switching Corporation | Redundancy arrangement for telecommunications system |
JP2006235837A (en) * | 2005-02-23 | 2006-09-07 | Nec Corp | Load balancing system, load balancer management server, switching method for load balancer and program |
CN102420746A (en) * | 2011-11-14 | 2012-04-18 | 中兴通讯股份有限公司 | Forwarding method for multicast flow and network equipment therefor |
CN102629906A (en) * | 2012-03-30 | 2012-08-08 | 浪潮电子信息产业股份有限公司 | Design method for improving cluster business availability by using cluster management node as two computers |
CN103346923A (en) * | 2013-07-30 | 2013-10-09 | 曙光信息产业(北京)有限公司 | Management method and management device for double-unit load balancing equipment |
CN104426694A (en) * | 2013-08-28 | 2015-03-18 | 杭州华三通信技术有限公司 | Method and device for adjusting virtual-machine resources |
CN105306356A (en) * | 2014-07-30 | 2016-02-03 | 上海博达数据通信有限公司 | Method for realizing master-slave switching of multicast routing on distributed system |
CN105760260A (en) * | 2016-02-19 | 2016-07-13 | 浙江大华系统工程有限公司 | Backup system and backup method |
Cited By (16)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN108965493A (en) * | 2018-07-03 | 2018-12-07 | 中国电子科技集团公司第十四研究所 | Data transmission switching method in two-node cluster hot backup |
CN109815065A (en) * | 2019-01-31 | 2019-05-28 | 杭州迪普科技股份有限公司 | Main/standby switching method, device, the electronic equipment of two-shipper |
CN109815065B (en) * | 2019-01-31 | 2022-09-30 | 杭州迪普科技股份有限公司 | Main-standby switching method and device for dual computers and electronic equipment |
CN111628880A (en) * | 2019-02-27 | 2020-09-04 | 深圳迈瑞生物医疗电子股份有限公司 | Method for transferring failure of in-hospital equipment and monitoring system |
CN110266795A (en) * | 2019-06-20 | 2019-09-20 | 上海思询信息科技有限公司 | One kind being based on Openstack platform courses method |
CN110768848A (en) * | 2019-10-31 | 2020-02-07 | 杭州迪普科技股份有限公司 | Method and device for switching main server and standby server |
CN112995726A (en) * | 2019-12-12 | 2021-06-18 | 杭州海康威视数字技术股份有限公司 | Display system, hot standby switching method and video control device |
CN112995726B (en) * | 2019-12-12 | 2022-09-30 | 杭州海康威视数字技术股份有限公司 | Display system, hot standby switching method and video control device |
CN111182374A (en) * | 2019-12-31 | 2020-05-19 | 杭州迪普科技股份有限公司 | Health detection message sending method and DPX equipment |
CN112311896A (en) * | 2020-11-16 | 2021-02-02 | 杭州迪普科技股份有限公司 | Health examination method, device, equipment and computer readable storage medium |
CN112311896B (en) * | 2020-11-16 | 2023-03-24 | 杭州迪普科技股份有限公司 | Health examination method, device, equipment and computer readable storage medium |
CN112749009A (en) * | 2020-12-30 | 2021-05-04 | 杭州迪普科技股份有限公司 | Server scheduling method and device |
CN114338688A (en) * | 2021-12-28 | 2022-04-12 | 中国农业银行股份有限公司 | Data management method and device |
CN114338688B (en) * | 2021-12-28 | 2024-02-23 | 中国农业银行股份有限公司 | Data management method and device |
CN115242505A (en) * | 2022-07-21 | 2022-10-25 | 北京天融信网络安全技术有限公司 | Equipment switching method, electronic equipment and system |
CN115242505B (en) * | 2022-07-21 | 2023-11-10 | 北京天融信网络安全技术有限公司 | Equipment switching method, electronic equipment and system |
Also Published As
Publication number | Publication date |
---|---|
CN106656617B (en) | 2020-01-03 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106656617A (en) | Master-slave switching method and device | |
CN109951576A (en) | By the health monitoring for the service that calculating equipment provides | |
CN103581276B (en) | Cluster management device, system, service customer end and correlation method | |
US8134928B1 (en) | Technique for identifying a failed network interface card within a team of network interface cards | |
US20040240440A1 (en) | Virtual network addresses | |
CN108234191A (en) | The management method and device of cloud computing platform | |
US7653769B2 (en) | Management of devices connected to infiniband ports | |
JP2005073277A (en) | Reliable fault resolution in cluster | |
CN101304346B (en) | Method and apparatus for monitoring link | |
US11307945B2 (en) | Methods and apparatus for detecting, eliminating and/or mitigating split brain occurrences in high availability systems | |
US7545741B1 (en) | Technique for identifying a failed network interface card within a team of network interface cards | |
CN101447989A (en) | System and method for an improved high availability component implementation | |
CN102904818A (en) | Method and device for updating ARP (Address Resolution Protocol) information table | |
CN108075971A (en) | A kind of main/standby switching method and device | |
CN104243232B (en) | Virtual net fault detection and location method | |
JP2010034876A (en) | Fault monitoring server and network failure monitoring system | |
CN112291116A (en) | Link fault detection method and device and network equipment | |
US7676623B2 (en) | Management of proprietary devices connected to infiniband ports | |
JP2002009806A (en) | Lan communication path control system and control method | |
CA2401635A1 (en) | Multiple network fault tolerance via redundant network control | |
JP2007274635A (en) | Address notification system and address notification method | |
CN115720181A (en) | Control method and system of bare metal node, electronic device and readable storage medium | |
JP2000194627A (en) | Operating method and operating state monitoring device for network system and information communication device | |
US20140105261A1 (en) | METHOD AND DATA TRANSMISSION DEVICE FOR DATA TRANSMISSION WITHIN AN xDSL DATA TRANSMISSION SYSTEM CONNECTING AT LEAST TWO ETHERNET NETWORKS VIA xDSL LINKS | |
CN115378816B (en) | Network configuration detection method, device and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant | ||
TR01 | Transfer of patent right |
Effective date of registration: 20210617 Address after: 310051 05, room A, 11 floor, Chung Cai mansion, 68 Tong Xing Road, Binjiang District, Hangzhou, Zhejiang. Patentee after: Hangzhou Dip Information Technology Co.,Ltd. Address before: 6 / F, Zhongcai building, 68 Tonghe Road, Binjiang District, Hangzhou City, Zhejiang Province Patentee before: Hangzhou DPtech Technologies Co.,Ltd. |
|
TR01 | Transfer of patent right |