METHOD AND APPARATUS FOR HOT STANDBY OF CONTROLLERS IN DISTRIBUTED PROTECTION
20180269963 ยท 2018-09-20
Inventors
- Bikai LI (Shenzhen, Guangdong, CN)
- Gang LU (Shenzhen, Guangdong, CN)
- Guofang LI (Shenzhen, Guangdong, CN)
Cpc classification
H04L41/0631
ELECTRICITY
H04L41/0663
ELECTRICITY
H04Q2011/0081
ELECTRICITY
International classification
Abstract
A method and an apparatus for hot standby of controllers in distributed protection are provided. In some embodiments, the method includes: through an actuator, receiving a message transmitted from each of the controllers; determining the messages transmitted in response to a same fault according to a serial number of each message, maintaining a master-standby relationship of each of the controllers through the messages transmitted in response to the same fault; and executing a corresponding operation according to a message transmitted from a master controller; and in a protocol steady state, performing a master-standby switching if it is determined that a switching condition is met.
Claims
1. A method for hot standby of controllers in distributed protection, comprising: through an actuator, receiving a message transmitted from each of the controllers, determining messages transmitted by in response to a same fault according to a serial number of each message, maintaining a master-standby relationship of each of the controllers through the messages transmitted in response to the same fault, and executing a corresponding operation according to the message transmitted from a master controller, wherein the controllers are included in a protection group; and in a protocol steady state, through the actuator, performing a master-standby switching if it is determined that a switching condition is met.
2. The method according to claim 1, wherein the message transmitted from each of the controllers comprises protocol control information, protocol status information and the serial number.
3. The method according to claim 2, wherein maintaining the master-standby relationship of each of the controllers through the messages transmitted in response to the same fault comprises: when a first fault is detected, having the controller, from which the message transmitted in response to the same fault is first received, as the master controller, and having other controllers as standby controllers; once a fault is detected, recording the controller from which the message is first received, and adding a message issue number in master-standby relationship information by 1, wherein the message issue number indicates how many times the message transmitted from said controller is first received.
4. The method according to claim 1, further comprising: setting an expiration time T1; and when the message transmitted from a standby controller is actually first received by the actuator, executing, through the actuator, a protect switching operation in accordance with the message transmitted from the standby controller if no message transmitted from the master controller is received within the expiration time T1, wherein the protect switching operation is executed to switch services to be executed by the actuator.
5. The method according to claim 1, wherein the protocol steady state is as follows: an expiration time T2 is set, after the messages transmitted from the controllers are received by the actuator, if no message transmitted from any controller is received within the expiration time T2, it is determined that a protection protocol of the protection group is in a steady state; and the switching condition is as follows: in the protocol steady state, in current master-standby relationship information, a message issue number of a standby controller is greater than or equal to a first threshold N, and the message issue number of the master controller is less than N, wherein the message issue number indicates how many times the message transmitted from said controller is first received.
6. The method according to claim 5, wherein performing the master-standby switching comprises: through the actuator, comparing the message issue numbers of the standby controllers in the master-standby relationship information, switching the standby controller with largest message issue number as the master controller and switching original master controller as the standby controller, and resetting the message issue number of each of the controllers in the master-standby relationship information as 0.
7. The method according to claim 2, further comprising: through the actuator, verifying the protocol control information and the protocol status information of each of the controllers, and performing one of a protocol synchronization and protocol reset if there exists any inconsistency among the protocol control information and the protocol status information of each of the controllers, wherein the protocol synchronization is used for making the protocol control information and the protocol status information of each of the controllers consistent, and the protocol reset is used for reset the protocol control information and the protocol status information of each of the controllers.
8. The method according to claim 7, wherein through the actuator, verifying the protocol control information and the protocol status information of each of the controllers, and performing one of protocol synchronization and protocol reset if there exists any inconsistency among the protocol control information and the protocol status information of each of the controllers comprises: in the protocol steady state, through the actuator, classifying the controllers, the messages transmitted from which have same protocol control information and same protocol status information, into one type according to the protocol control information and the protocol status information in the messages transmitted from each of the controllers once a fault is detected, in the case that a total number of controllers of a certain type is maximum, through the actuator, transmitting a multicasting message including a protocol synchronization command and the protocol control information and protocol status information of such type of controllers to each of the controllers in the protection group, and each of the controllers in the protection group verifies own protocol control information and protocol status information after receiving the multicasting message; if there exists any inconsistency between the multicasting message and the controller's own protocol control information and protocol status information, performing a synchronization of a protection protocol through the actuator, and the synchronization is omitted if the multicasting message is consistent with the controller's own protocol control information and protocol status information; in the case that there is no type of controllers a total number of which is maximum, transmitting a multicasting message including merely a protocol reset command to each of the controllers in the protection group, so that each of the controllers in the protection group re-queries a network fault of a detector to execute a process according to the protocol after resetting the protection protocol.
9. An apparatus for hot standby of controllers in distributed protection, comprising a processor and a storage device for storing computer executable instructions that, when executed by the processor, cause the processor to perform the following method: receiving a message transmitted from each of the controllers; determining messages transmitted in response to a same fault according to a serial number of each message; maintaining a master-standby relationship of each of the controllers through the messages transmitted in response to the same fault; executing a corresponding operation according to the message transmitted from a master controller; and in a protocol steady state, performing a master-standby switching if it is determined that a switching condition is met.
10. The apparatus according to claim 9, wherein the message transmitted from each of the controllers comprises protocol control information, protocol status information and the serial number.
11. The apparatus according to claim 10, wherein the method further comprises: when a first fault is detected, setting the controller, from which the message transmitted in response to the same fault is first received, as the master controller, and setting other controllers as standby controllers; and once a fault is detected, recording the controller from which the message is first received, and adding a message issue number in master-standby relationship information by 1, wherein the message issue number indicates how many times the message transmitted from said controller is first received.
12. The apparatus according to claim 10, wherein the method further comprises: verifying the protocol control information and the protocol status information of each of the controllers, and performing one of protocol synchronization and protocol reset if there exists any inconsistency among the protocol control information and the protocol status information of each of the controllers, wherein the protocol synchronization is used for making the protocol control information and the protocol status information of each of the controllers consistent, and the protocol reset is used for reset the protocol control information and the protocol status information of each of the controllers.
13. An actuator, comprising the apparatus for hot standby of controllers in distributed protection according to claim 9.
14. A system for hot standby of controllers in distributed protection, comprising an actuator, a detector and a plurality of controllers, wherein: the detector is configured to, after performing a fault detection, inform each of the controllers of a network fault through transmitting a multicasting message; each of the controllers is configured to individually execute a process according to a protection protocol after receiving the multicasting message, and respectively transmit a message to the actuator after executing the process according to the protection protocol, wherein the message transmitted to the actuator comprises protocol control information, protocol status information and a serial number; and the actuator is configured to receive the messages transmitted from each of the controllers; determine messages transmitted in response to a same fault according to the serial number of each message; maintain a master-standby relationship of each of the controllers through the messages transmitted in response to the same fault; and execute a corresponding operation according to the message transmitted from a master controller; and in a protocol steady state, perform a master-standby switching if it is determined that a switching condition is met.
15. A non-transitory computer-readable storage medium storing a computer-executable instructions, wherein the computer-executable instructions are configured to cause a processor to execute the method according to claim 1.
16. An actuator, comprising the apparatus for hot standby of controllers in distributed protection according to claim 10.
17. An actuator, comprising the apparatus for hot standby of controllers in distributed protection according to claim 11.
18. An actuator, comprising the apparatus for hot standby of controllers in distributed protection according to claim 12.
Description
BRIEF DESCRIPTION OF DRAWINGS
[0052]
[0053]
[0054]
[0055]
[0056]
DETAILED DESCRIPTION
[0057] In an embodiment of the present disclosure, an actuator is arranged to receive a message transmitted from each controller, determine the message caused by the same protocol triggering according to a serial number of each message, and maintain a master-standby relationship of each controller by the message caused by the same protocol triggering, and execute the message transmitted from the master controller. In a protocol steady state, the actuator performs a master-standby switching when it is determined that a switching condition is met.
[0058] Embodiments of the present disclosure will be described below with reference to the accompanying drawings.
[0059] An embodiment of the present disclosure implements a method for hot standby of controllers in distributed protection. As shown in
[0060] In step 301, an actuator receives a message transmitted from each controller.
[0061] Prior to this step, the detector informs each controller of a network fault by transmitting a multicasting message after performing a fault detection. After receiving the multicasting message, each controller separately performs a protection protocol individually, and respectively transmits a message to the actuator after performing the protection protocol.
[0062] Herein, multiple controllers in each protection group need to join a multicast group. The multicasting message transmitted from the detector includes network fault information and a serial number uniquely identifying a protocol to be triggered by the fault information at this time. The generation of the serial number can be based on a timestamp or a sequence with an increment of 1.
[0063] The message transmitted to the actuator by the controller includes protocol control information, protocol status information and the serial number, where the protocol control information is a service single board actual switching crossover or on-off command transmitted to the actuator by the controller, the protocol status information is a collection of key variables of some protocols, and the serial number directly uses a serial number in the multicasting message transmitted from the detector.
[0064] In step 302, the actuator determines the message caused by the same protocol triggering according to the serial number of each message, and maintains a master-standby relationship of each controller through the message caused by the same protocol triggering.
[0065] The actuator determines messages caused by the same protocol triggering according to the serial number of each message, and has the controller, from which the message caused by the same protocol triggering is first received upon a first protocol triggering, as the master controller, and has other controllers as the standby controller. Upon each protocol triggering, the controller from which the message is first received is recorded and a message issue number of the controller in master-standby relationship information increases by 1.
[0066] In step 303, the actuator executes the message transmitted from the master controller.
[0067] The actuator actually executes the message transmitted from the master controller every time without executing the message transmitted from other standby controllers, and presets a first expiration time T1. When the message transmitted from the standby controllers is actually first received by the actuator, the actuator executes a protect switching operation in accordance with the message transmitted from the standby controller if no message transmitted from the master controller is received within the first expiration time T1.
[0068] In step 304, in the protocol steady state, the actuator performs a master-standby switching if it is determined that a switching condition is met.
[0069] In this step, the steady state of the protocol is as follows: a second expiration time T2 is preset, after the messages transmitted from the controllers are received by the actuator, if the actuator fails to receive a message transmitted from any controller within the second expiration time T2, a protection protocol of a protection group is determined to be in a steady state.
[0070] The switching condition is as follows: in the protocol steady state, in the current master-standby relationship information, the message issue number of a standby controller is greater than or equal to a first threshold N, and the message issue number of the master controller is less than N.
[0071] The master-standby switching includes: the actuator compares the message issue numbers of the standby controllers in the master-standby relationship information, and swathes the standby controller with the largest message issue number to be the master controller and switches the original master controller to be the standby controller; and the message issue number of each controller in the master-standby relationship information is reset as 0.
[0072] Herein, in the protocol steady state, when the message issue number of the master controller first reaches N, the master-standby switching is not performed and the message issue number of each controller in the master-standby relationship information is reset as 0.
[0073] The above method further includes: the actuator verifies the protocol control information and the protocol status information of each controller, and performs protocol synchronization or protocol reset if there exists any inconsistency among the protocol control information and the protocol status information of each controller.
[0074] In the protocol steady state, the actuator classifies the controllers, the messages transmitted by which have same protocol control information and same protocol status information, into one type according to the protocol control information and the protocol status information in the messages transmitted from each controller upon each protocol triggering. In the case that the number of the controllers belonging to one type is largest, a multicasting message including a protocol synchronization command, protocol control information and protocol status information of such type of controllers is transmitted to each controller, and each controller verifies own protocol control information and protocol status information after receiving the multicasting message. If there exists any inconsistency between the multicasting message and protocol control information and protocol status information of the controller, the actuator performs a protection protocol synchronization, and if the multicasting message is consistent with the protocol control information and protocol status information of the controller, the protection protocol synchronization is omitted. In the case that there exists no type of controllers with largest number, a multicasting message including only a protocol reset command is transmitted to each controller, and each controller re-queries a network fault of the detector to execute the protocol after performing the protection protocol reset.
[0075] To implement the method as described above, an embodiment of the present disclosure further provides an apparatus for hot standby of controllers in distributed protection, which is disposed on an actuator. As shown in
[0076] The receiving module 41 may be implemented by an interface of an actuator, and is arranged to receive a message transmitted from each controller.
[0077] The determination module 42 may be implemented by a processor of the actuator, and is arranged to determine messages caused by the same protocol triggering according to a serial number of each message.
[0078] The maintenance module 43 may be implemented by a memory of the actuator, and is arranged to maintain a master-standby relationship of each controller through the messages caused by the same protocol triggering.
[0079] The message execution module 44 may be implemented by the processor of the actuator, and is arranged to execute a message transmitted from a master controller.
[0080] The master-standby switching module 45 may be implemented by the processor of the actuator, and is arranged to, in a protocol steady state, perform a master-standby switching if it is determined that a switching condition is met.
[0081] The message transmitted from each controller includes protocol control information, protocol status information and the serial number, where the protocol control information is a service single board actual switching crossover or on-off command transmitted to the actuator by the controller, the protocol status information is a collection of key variables of some protocols, and the serial number directly uses a serial number in the multicasting message transmitted from the detector.
[0082] The maintenance module 43 is arranged to have the controller, from which the message caused by the same protocol triggering is first received upon a first protocol triggering, as the master controller and have other controllers as the standby controllers, and record the controller the message transmitted from which is first received and add a message issue number of the controller in the master-standby relationship information by 1 upon each protocol triggering.
[0083] The message execution module 44 is arranged to actually execute the message transmitted from the master controller every time without executing the message transmitted from other standby controllers, and preset a first expiration time T1. When the actuator actually first receives the message transmitted from the standby controller, the message execution module 44 executes a protect switching operation in accordance with the message transmitted from the standby controller if no message transmitted from the master controller is received within the first expiration time T1.
[0084] The protocol steady state is as follows: a second expiration time T2 is preset, after the messages transmitted from the controllers are received by the actuator, if the actuator fails to receive a message transmitted from any controller within the second expiration time T2, a protection protocol of a protection group is determined to be in the steady state.
[0085] The switching condition is as follows: in the protocol steady state, in the current master-standby relationship information, the message issue number of a standby controller reaches a first threshold N, and the message issue number of the master controller is less than N.
[0086] The master-standby switching module 45 is arranged to compare the message issue number of the standby controllers in the master-standby relationship information when it is determined that the switching condition is met, where the standby controller with the largest message issue number becomes the master controller and the original master controller becomes the standby controller, and the message issue number of each controller in the master-standby relationship information is reset as 0.
[0087] The apparatus further includes a verification module 46, which is arranged to verify the protocol control information and the protocol status information of each controller, and perform the protocol synchronization or protocol reset if there exists any inconsistency among the protocol control information and the protocol status information of each controller.
[0088] In the protocol steady state, the verification module 46 is further arranged to classify the controllers, messages transmitted by which have same protocol control information and protocol status information, into one type according to the protocol control information and the protocol status information in the messages transmitted from each controller upon each protocol triggering. In the case that the number of the controllers belonging to one type is largest, a multicasting message including a protocol synchronization command, protocol control information and protocol status information of such type of controllers is transmitted to each controller, so that each controller verifies own protocol control information and protocol status information after receiving the multicasting message. If there exists any inconsistency between the multicasting message and the protocol control information and protocol status information of the controller, the protection protocol synchronization is performed, and if the multicasting message is consistent with the protocol control information and protocol status information of the controller, the protection protocol synchronization is omitted. In the case that there exists no type of controllers with largest number, a multicasting message including only a protocol reset command is transmitted to each controller, so that each controller re-queries a network fault of the detector to execute the protocol after performing the protection protocol reset.
[0089] Based on the apparatus as described above, an embodiment of the present disclosure further provides an actuator, which includes the apparatus for hot standby of controllers in the distributed protection as shown in
[0090] Based on the actuator as described above, an embodiment of the present disclosure further provides a system for hot standby of controllers in distributed protection. As shown in
[0091] The detector 53 is arranged to, after performing a fault detection, inform each controller 52 of a network fault by transmitting a multicasting message.
[0092] The controllers 52 are arranged to individually execute a protection protocol after receiving the multicasting message, and respectively transmit a message including protocol control information, protocol status information and a serial number to the actuator 51 after performing the protection protocol.
[0093] The actuator 51 is arranged to receive the messages transmitted from each controller 52, determine messages caused by the same protocol triggering according to the serial number of each message, maintain a master-standby relationship of each controller 52 through the messages caused by the same protocol triggering, and execute the message transmitted from a master controller; and in the protocol steady state, perform the master-standby switching if it is determined that a switching condition is met.
[0094] The actuator 51 includes the apparatus for hot standby of controllers in the distributed protection as shown in
Embodiment I
[0095] The present embodiment relates to a 1:2 hot standby switching among a master controller and standby controllers.
[0096] A webmaster newly establishes a protection group of a distributed system, issues a configuration of the protection group to the controllers, actuator and detector. Herein, there are three controllers in total, which are in hot standby of each other. After the configuration is received by the actuator, the actuator maintains the master-standby relationship information of the three controllers in a memory. The master-standby relationship information is indicated in a form of a table in the present embodiment.
[0097] After the detector first reports a network fault to each controller to trigger the execution of the protocol, the controllers issue switching control command messages to the actuator. If the actuator receives 3 same control command messages and finds that the control command message transmitted from the controller 1 is first received, the controller 1 is temporarily determined as a master controller. A master-standby relationship field of the controller 1 is updated to be M, while a master-standby relationship fields of the other controllers are updated to be S. Moreover, a message issue number of the controller 1 is increased by 1, as shown in Table 1.
TABLE-US-00001 TABLE 1 Number of Master-standby Message issue number of the Controller Relationship controller 1 M 1 2 S 0 3 S 0
[0098] Through reporting the network fault information by the detector repeatedly, the actuator also receives a plurality of control command messages. As shown in Table 2, the recorded message issue number indicating how many times the message transmitted from the controller 2 is first received reaches 10. In the present embodiment, it is assumed that a condition of a master-standby switching opportunity is met when N equals to 10. A possible reason that the message issue number indicating how many times the message transmitted from the controller 2 is first received is maximal lies in: a communication channel between the actuator and the controller 2 is the most efficient or the protection group has the highest execution efficiency in the controller 2. Although the controller 1 is selected as the master controller in an initial establishment stage of the protection group, after a certain period of time, the actuator preferably selects the controller 2 as the master controller, which increases the switching execution efficiency.
TABLE-US-00002 TABLE 2 Number of Master-standby Message issue number of the Controller Relationship controller 1 M 3 2 S 10 3 S 1
[0099] As shown in Table 3, the actuator performs the master-standby switching of the controllers. The master-standby relationship field of the controller 2 in the table is updated to be M, the master-standby relationship field of the controller 1 is updated to be S, and the message issue number of each controller is reset as 0, and re-started to be counted.
TABLE-US-00003 TABLE 3 Number of Master-standby Message issue number of the Controller Relationship controller 1 S 0 2 M 0 3 S 0
Embodiment II
[0100] The present embodiment is an execution process that protection protocols of controllers for 1:2 hot standby are inconsistent.
[0101] In the present embodiment, a scenario where protocol control information and protocol status information are inconsistent in 1:2 hot standby of controllers is taken as an example. The detector reports a network fault and triggers the controllers 1 to 3 for working SF to execute protocols respectively, where the controller 1 is a master controller, and a protocol synchronization operation is performed after the protocol is in a steady state.
[0102] WSF, RR and the like are abbreviations of the protocol status information.
[0103] (1) In a message issued by the controller 1, the protocol control information is Switch and the protocol status information is WSF.
[0104] (2) In a message issued by the controller 2, the protocol control information is Switch and the protocol status information is WSF.
[0105] (3) In a message issued by the controller 3, the protocol control information is Idle and the protocol status information is RR.
[0106] There are two types of protocol control information and protocol status information, namely, Switch/WSF and Idle/RR. The controllers 1, 2 belong to the Switch/WSF type, and the controller 3 belongs to the Idle/RR type. In this case, the number of the controllers belonging to the Switch/WSF type is larger, thus this protocol is executed based on Switch/WSF, and the actuator transmits a multicasting message including Switch/WSF and protocol synchronization commands to each controller.
[0107] After the multicasting message is received by the controllers 1, 2, the multicasting message is compared with the controllers 1, 2's own protocol control and status information. If it is found that they are consistent with each other, no operation is performed. After the multicasting message is received by the controller 3, the multicasting message is compared with the controller 3's own protocol control and status information Idle/RR, and it is found that they are inconsistent with each other. Next, the controller 3 performs the protocol synchronization, and then transmits a message including protocol control information and protocol status information to the actuator. Then, the actuator performs the verification again. If it is found that they are still inconsistent with each other, it indicates that software or the hardware per se of the controller 3 has a problem or the controllers 1, 2 perform an incorrect protocol simultaneously, and an alarm or event is reported to the webmaster for manual processing.
[0108] The detector reports the network fault to trigger the controllers 1 to 3 for protecting SD to execute protocols respectively, where the controller 1 is the master controller, then
[0109] (1) In the message issued by the controller 1, the protocol control information is Idle and the protocol status information is RR.
[0110] (2) In the message issued by the controller 2, the protocol control information is Switch and the protocol status information is RR; and
[0111] (3) In the message issued by the controller 3, the protocol control information is Idle and the protocol status information is PSD.
[0112] There are three types of protocol control information and protocol status information, namely, Idle/RR, Switch/RR and Idle/PSD. The controller 1 belongs to the Idle/RR type, the controller 2 belongs to the Switch/RR type, and the controller 3 belongs to the Idle/PSD type. This protocol verification fails to distinguish which controller shall prevail, thus the actuator transmits a multicasting message merely including protocol reset commands to the controllers.
[0113] After the three controllers all perform the protocol reset, it is required to re-query network fault information of the detector, and a message including protocol control information and status information is transmitted to the actuator again after the protocol is triggered.
[0114] It will be understood by those ordinary skilled in the art that all or a portion of steps of the embodiments described above may be implemented with a computer program flow. The computer program may be stored in a computer-readable storage medium, and is executed on a corresponding hardware platform (such as a system, a device, an apparatus, a means, and the like). The computer program, when being executed, includes one or a combination of the steps of a method embodiment.
[0115] Alternatively, all or part of the steps of the embodiments described above may also be implemented by an integrated circuit. These steps may be achieved by separately making them into individual integrated circuit modules or achieved by making a plurality of modules or steps into a single integrated circuit module.
[0116] The apparatus/functional modules/functional units in the embodiments described above may be implemented by a general-purpose computing apparatus, and may be concentrated on a single computing apparatus or may be distributed over a network composed of a plurality of computing apparatuses.
[0117] The apparatus/functional modules/functional units in the embodiments described above may be implemented in a form of a software functional module and may be stored in a computer-readable storage medium when being sold or used as a standalone product. The above-mentioned computer-readable storage medium may be a read-only memory, a magnetic disk, or an optical disk, and the like.
INDUSTRIAL APPLICABILITY
[0118] According to the embodiments of the present disclosure, each controller normally runs the protocol, the controller per se does not belong to a master controller or a standby controller fixedly, and does not maintain a master-standby status per se. The master-standby relationship of controllers is dynamically maintained by an actuator of each protection group, so that a 1:N (N>=1) hot standby scenario of the controllers in the distributed protection is supported. Moreover, in the case where a protocol is in a steady state, the actuator can perform the synchronization of the protection protocols without performing a protocol synchronization among the master controller and the standby controllers.