WO2024045012A1 - Appareil et procédé de commutation maître-secours, dispositif informatique et support de stockage - Google Patents

Appareil et procédé de commutation maître-secours, dispositif informatique et support de stockage Download PDF

Info

Publication number
WO2024045012A1
WO2024045012A1 PCT/CN2022/116086 CN2022116086W WO2024045012A1 WO 2024045012 A1 WO2024045012 A1 WO 2024045012A1 CN 2022116086 W CN2022116086 W CN 2022116086W WO 2024045012 A1 WO2024045012 A1 WO 2024045012A1
Authority
WO
WIPO (PCT)
Prior art keywords
standby
sending
machine
host
switching
Prior art date
Application number
PCT/CN2022/116086
Other languages
English (en)
Chinese (zh)
Inventor
卢艳华
余东旭
Original Assignee
宁德时代未来能源(上海)研究院有限公司
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 宁德时代未来能源(上海)研究院有限公司 filed Critical 宁德时代未来能源(上海)研究院有限公司
Priority to PCT/CN2022/116086 priority Critical patent/WO2024045012A1/fr
Publication of WO2024045012A1 publication Critical patent/WO2024045012A1/fr

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04BTRANSMISSION
    • H04B5/00Near-field transmission systems, e.g. inductive loop type
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L5/00Arrangements affording multiple use of the transmission path
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/80Services using short range communication, e.g. near-field communication [NFC], radio-frequency identification [RFID] or low energy communication
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W76/00Connection management
    • H04W76/10Connection setup
    • H04W76/14Direct-mode setup
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W76/00Connection management
    • H04W76/10Connection setup
    • H04W76/15Setup of multiple wireless link connections

Definitions

  • the present application relates to the field of communication technology, and in particular to an active/standby switching method, device, computer equipment, storage medium and computer program product.
  • the communication management machine As a communication hub of a monitoring system, the communication management machine has been widely used in systems in various fields. For example, in the field of power system energy storage, for the battery management system in the field of power system energy storage, to avoid equipment failure and environmental impact, communication management master and backup machine connection methods are usually used.
  • the current switching mechanism of active and standby machines in communication management is to transmit the information received on the current uplink or downlink communication media link to the standby machine through the host. There is a situation where it is the master or the standby machine at the same time, which leads to the reliability of the system and Low stability.
  • this application provides a primary and secondary machine switching method.
  • the methods include:
  • the service messages include at least one of uplink messages, downlink messages, and uplink and downlink messages;
  • the switching between the active and standby machines is started and completed during the idle time period for sending service messages.
  • the master and backup machine switching is started and completed during the idle time period for sending service messages, and the master and backup machine switch is started and completed to receive the service.
  • the device of the message shields the master and backup machine switching process to avoid transmitting the information that the master and backup machines are active at the same time or the master and backup machines are both backup to the device that receives the service message; and avoid performing the master and backup at the time of sending the service message.
  • Machine switching improves the reliability and stability of the system corresponding to the main and backup machines.
  • starting and completing the master-standby switchover during the idle time period for sending service messages includes:
  • the current host generates a switching instruction, and the current host switches to the standby machine;
  • the current host sends a switching instruction to the current standby machine, and the switching instruction instructs the current standby machine to switch to the host.
  • the current host when the master and backup machine switching conditions are met and it is within the idle time period for sending service messages, the current host generates a switching instruction and switches to the backup machine, and sends the switching instruction to the current backup machine so that the current master machine The standby machine switches to the master machine.
  • the host does not need to receive feedback from the current standby machine to switch to the host machine before switching to the standby machine. This enables seamless switching between the active and standby machines, avoids the situation where the current active and standby machines are the master at the same time, and ensures the reliability and continuity of communication.
  • starting and completing the master-standby switchover during the idle time period for sending service packets includes:
  • the current host During the idle period of sending service messages, the current host generates a switching instruction; the current host sends the switching instruction to the current standby machine, and receives feedback that the current standby machine switches to the host in response to the switching instruction. , the current host is switched to the standby machine.
  • the master and backup machines are switching, after the master sends the switching command and receives feedback that the backup machine has successfully switched, the master switches to the backup machine to ensure that the master and backup machines complete the switch.
  • the sending cycle and sending time point of the current host machine sending service messages are obtained, and the sending cycle and sending time point of the current standby machine sending service messages are obtained;
  • the standby machine needs to learn the message sending method of the host. This ensures that the sending time of the host after switching is consistent when the idle time period begins and is completed, ensuring that the time at which the host sends messages before and after switching is consistent, ensuring accuracy and system stability.
  • determining the idle time period for the host to send service messages includes:
  • the idle time period for the host to send the service message is determined.
  • the interaction message includes a start byte, a check byte, and an information byte; the information byte stores a status instruction used to characterize the fault level and a control instruction whether to switch between active and standby switching. ; The verification byte stores verification information used to verify the integrity of the interaction message.
  • the main and backup machines communicate according to the set message format, making full use of each byte to convey the fault level status of the main and backup machines, as well as whether the main and backup machines need to be switched and the integrity of the message is verified. information, improving the transmission rate of the message and the utilization of each byte in the message.
  • first fault level is higher than the second fault level, it is determined that the main and backup machine switching conditions are met.
  • the second fault level of the backup machine is obtained.
  • the fault level is used to determine whether the conditions for switching between the active and standby machines are met. If the first fault level is higher than the second fault level, it is determined that the conditions for switching between the active and standby machines are met, ensuring the accuracy of the switching between the active and standby machines.
  • the method before determining that if the first fault level is higher than the second fault level, determining that the primary and backup machine switching conditions are met, the method further includes:
  • first fault level is a set fault level for active/standby switching. If the first fault level is the set fault level, determine whether the first fault level is higher than the second fault level. .
  • the switch when the main and standby machines meet the conditions for switching, by further determining whether the fault level of the host is the set fault level for main and standby switching, if the host reaches the set fault level for main and standby switching, the switch will be reduced. times to improve stability.
  • the method before obtaining the information bytes, the method further includes:
  • the interactive message is verified according to the verification information. If the verification result is that the interactive message is a complete interactive message, the information bytes are obtained.
  • the integrity of the interactive message is ensured by verifying the integrity of the message in advance based on the verification information in the interactive message. performance to further ensure the accuracy of packet switching.
  • determining the idle time period for the host to send service messages includes:
  • the idle time period of the sending cycle is determined as the idle time period for the host to send service messages.
  • the idle time period of the transmission cycle is determined from the transmission cycle of the current host sending service messages, and the idle time period of the transmission cycle is determined as the idle time period of the host sending service messages, so as to avoid sending services when the current host
  • the master and backup machines are switched during the non-idle period of the message sending cycle. There may be situations where the machine is the master machine or the backup machine at the same time, which improves the stability of the system.
  • determining the idle time period of the sending cycle includes:
  • the idle time period of the sending cycle is determined according to the service message sending time point.
  • the accuracy of the idle time period is ensured.
  • determining the idle time period for the host to send service messages includes:
  • the idle time period of the first sending cycle is determined as the idle time period for the host to send the service message.
  • the idle time period of the first sending cycle is determined as the idle time period for the host to send service messages, that is to say, If the current host has communication behaviors with multiple devices at the same time and the communication cycles are inconsistent, the idle time period of the first sending cycle is determined as the idle time period for the host to send service messages, and is used as the time period for the master and backup machine switching to avoid uplink messages.
  • the sending cycle is inconsistent with the downlink message sending cycle, which has an impact on the system.
  • the method further includes:
  • the status of the switched master and backup machines is maintained for a period of time to prevent the master and backup machines from frequently switching between the master and backup machines, causing system instability.
  • the communication rate between the current host machine and the current standby machine supports at least one of 5Mbps and 10Mbps.
  • the communication rate between the current host and the current standby machine supports at least one of 5Mbps and 10Mbps, which can flexibly configure the communication between the primary and standby machines and improve the versatility of the main and standby machine switching method.
  • this application also provides an active and standby machine switching device.
  • the device includes:
  • a switching judgment module used to determine the idle time period for the current host to send service messages when the master and backup machine switching conditions are met;
  • the service messages include at least one of uplink messages, downlink messages and uplink and downlink messages. ;
  • the active-standby switching module is used to start and complete the active-standby switching during the idle time period for sending service messages.
  • the master and backup machine switching is started and completed during the idle time period for sending service messages, and the master and backup machine switch is started and completed to receive the service.
  • the device of the message shields the master and backup machine switching process to avoid transmitting the information that the master and backup machines are active at the same time or the master and backup machines are both backup to the device that receives the service message; and avoid performing the master and backup at the time of sending the service message.
  • Machine switching improves the reliability and stability of the system corresponding to the main and backup machines.
  • this application also provides a computer device.
  • the computer device includes a memory and a processor, the memory stores a computer program, and the processor implements the following steps when executing the computer program:
  • the service messages include at least one of uplink messages, downlink messages, and uplink and downlink messages;
  • the switching between the active and standby machines is started and completed during the idle time period for sending service messages.
  • this application also provides a computer-readable storage medium.
  • the computer-readable storage medium has a computer program stored thereon, and when the computer program is executed by the processor, the following steps are implemented:
  • the switching between the active and standby machines is started and completed during the idle time period for sending service messages.
  • this application also provides a computer program product.
  • the computer program product includes a computer program that implements the following steps when executed by a processor:
  • the service messages include at least one of uplink messages, downlink messages, and uplink and downlink messages;
  • the switching between the active and standby machines is started and completed during the idle time period for sending service messages.
  • Figure 1 is an application architecture diagram of the primary and secondary machine switching method in one embodiment
  • Figure 2 is a schematic flowchart of a method for switching between active and standby machines in one embodiment
  • Figure 3 is a schematic flowchart of a method for determining an idle time period for sending service messages in one embodiment
  • Figure 4 is a schematic flowchart of the steps of switching between active and standby machines in one embodiment
  • Figure 5 is a schematic flowchart of a method for switching between active and standby machines in another embodiment
  • Figure 6 is a schematic diagram of the main and backup machine interconnection of the battery management system in the field of energy storage power stations in one embodiment
  • Figure 7 is a schematic diagram of seamless switching between active and standby machines in one embodiment
  • Figure 8 is a schematic flowchart of a method for switching between active and standby machines in another embodiment
  • Figure 9 is a schematic flowchart of a method for switching between active and standby machines in another embodiment
  • Figure 10 is a structural block diagram of an active/standby switching device in one embodiment
  • Figure 11 is an internal structure diagram of a computer device in one embodiment.
  • an embodiment means that a particular feature, structure or characteristic described in connection with the embodiment can be included in at least one embodiment of the present application.
  • the appearances of this phrase in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. Those skilled in the art understand, both explicitly and implicitly, that the embodiments described herein may be combined with other embodiments.
  • multiple refers to more than two (including two).
  • multiple groups refers to two or more groups (including two groups), and “multiple pieces” refers to It is more than two pieces (including two pieces).
  • the host For the switching between the main and standby machines of the communication management machine, the host only needs to transmit the information received on the current uplink or downlink communication media link to the standby machine to achieve seamless switching between the main and standby machines of the communication management machine. Then, when switching between active and standby machines in this way, it is easy for the two machines to be active or standby at the same time, and the information that the two machines are active or standby at the same time will be transmitted to the upper and lower level devices connected to it. An exception is generated.
  • the process of switching between active and standby machines is shielded, so for upstream devices and/or downstream devices, the host and standby machines will not be active at the same time, or the standby machine and the host will be standby at the same time. This improves This ensures the stability and reliability of the system where the main and backup machines are located.
  • the application architecture includes an upper device 102, a lower device 104, a first device 106 and a second device 108.
  • the first device 106 and the second device 108 may communicate interactively, for example, based on optical fiber communication.
  • the first device 106 and the second device 108 are in a dual redundant configuration.
  • the second device 108 is the backup device.
  • the first device 106 is the backup device.
  • the first device 106 sends uplink messages to the upper device 102 and may also send downlink messages to the lower device 104 .
  • the application architecture can be adjusted according to business needs. For example, the main and backup machines only need to communicate with the upper-layer device. At this time, the first device 106 and the second device 108 only need to send messages to the upper-layer device 102. Uplink message. Another example is that the active and backup machines only need to communicate with lower-layer devices for business purposes. At this time, the first device 106 and the second device 108 only need to send downlink messages to the lower-layer device 104.
  • the battery management system includes a host machine 106 and a backup machine 108.
  • the idle time period for the current host to send business messages is determined; the switchover between the active and standby machines starts and is completed during the idle time period for sending business messages.
  • the master machine and the backup machine may be predefined key devices in the battery management system, for example, they may be a battery management unit.
  • a method for switching between master and backup machines is provided. This method is explained by taking the method applied to the master machine or the backup machine in Figure 1 as an example, and includes the following steps:
  • Step 202 When the master and backup machine switching conditions are met, determine the idle time period for the current host to send service messages.
  • the service packets include at least one of uplink packets, downlink packets and uplink and downlink packets.
  • the main and backup machines can be the main and backup machines of systems in different application fields.
  • the main and backup machines can be the main and backup machines of communication management machines, and the main and backup machines can be the main and backup machines used in battery management systems in the energy storage field.
  • the main and backup machines can be predetermined key devices in the battery management system, for example, they can be battery management units.
  • the main and backup machines of the battery management system in the energy storage field are used as an example for explanation.
  • a main and backup machine switching is provided in the battery management system in the energy storage field.
  • the number of backup machines in the battery management system can be one or multiple.
  • the number of backup machines can be determined according to the needs of the battery management system, and is not limited here. In this application, the number of master machines and the number of standby machines are both one for description.
  • the switching conditions of the main machine and the backup machine are preset.
  • the switching condition of the main machine and the backup machine can be that the fault level of the main machine is higher than that of the backup machine, or it can be that the fault level of the main machine reaches the preset fault.
  • the fault level of the main machine is higher than the fault level of the standby machine.
  • the preset fault level can be understood as, when the host's fault level reaches the preset fault level, it will have an impact on the battery management system and it will not be able to send control instructions normally, affecting system performance and system stability.
  • the host has an upper-layer device with communication behavior and/or a lower-layer device with communication behavior.
  • the lower-layer equipment of the host can be charging piles and other equipment, and the upper-layer equipment of the host can be monitoring equipment, etc.
  • Service messages refer to messages sent by the active and standby machines for business communication with upper-layer devices and/or lower-layer devices. If the active and standby machines are only connected to upper-layer devices, the service packets include uplink packets. Upper-layer messages refer to the service messages sent by the host to the upper-layer device. If the master and backup machines are only connected to lower-layer devices, the service messages include downlink messages, which refer to the service messages sent by the host to the lower-layer devices.
  • service packets include uplink packets and downlink packets.
  • the sending periods of the host for sending uplink messages and sending downlink messages may be the same or different. It can be understood that when the host sends uplink messages and downlink messages, it can be sent according to a fixed sending cycle. For example, it is sent once every 0.1s, and an uplink message or downlink message is sent once in the first 0.1s. message, the second uplink message or downlink message is sent in the second 0.2s.
  • the idle period refers to the period of time when the host does not send packets. It can be the period when the host does not send uplink packets, or the period when the host does not send uplink packets or downlink packets.
  • the idle period can also be understood as a service window for switching between the primary and secondary servers.
  • the time for the host to send service messages can be understood as a service window for sending up and down messages.
  • the idle time period for the current host to send service messages is determined based on the sending cycle of the current host sending service messages and the sending time point of the service messages.
  • Step 204 Start and complete the active and standby machine switching during the idle time period for sending service packets.
  • the execution time point of the switching between the active and standby machines is any time point in the idle time period for sending business messages that can ensure that the active and standby machines are completed within the idle time period for sending business messages.
  • the time point for switching between the active and standby machines may also be determined based on the time when the standby machine receives the switching instruction. It can be understood that the switchover between the active and standby machines is started and completed during the idle period for sending service packets. At this time, the switched host is about to start sending uplink packets or downlink packets.
  • the master and backup machines have completed the switching between the master and backup machines. This switching process shields the host's upstream equipment (can also be understood as upper-layer equipment) and downstream equipment (can also be understood as Lower-layer equipment), the transient process of active and standby machine switching has no impact on upstream and downstream equipment.
  • the master-standby machine switchover starts during the idle period of sending service messages.
  • the current host machine is switched to the backup machine, and the switched backup machine is obtained.
  • the current backup machine is switched to the master machine, and the switched master machine is obtained.
  • the idle time period for the current host to send service messages is determined.
  • the host generates a switching command, and sends the interactive message carrying the switching command to the current standby machine.
  • the time point when the current standby machine receives the interactive message is determined.
  • the time point when the current standby machine receives the interactive message determines the execution time point of the master/backup machine switchover.
  • the execution time point of the active/standby switchover is a time point in the idle time period of service packets.
  • the current host when the master and backup machine switching conditions are met and it is within the idle time period for sending business messages, the current host generates a switching command and switches to the backup machine, and sends the switching command to the current backup machine.
  • the host does not need to receive feedback from the current standby machine to switch to the host machine before switching to the standby machine. This enables seamless switching between the active and standby machines and avoids the situation where the current active and standby machines are the master at the same time.
  • the idle time period for sending business packets is used to complete the switching between the active and standby machines, and the transient process of switching between the active and standby machines is shielded from the upper and lower devices to ensure the reliability and continuity of communication.
  • a method for determining an idle time period for sending service messages including the following steps:
  • Step 302 Obtain the first sending cycle of the current host for sending uplink messages and the second sending cycle of downlink messages.
  • the service packets may include uplink packets and downlink packets.
  • the format of the service packets sent by the host is preset and is not limited here.
  • the first sending cycle of the current host for sending uplink messages and the second sending cycle of downlink messages may be fixed.
  • Step 304 Determine whether the first transmission period is equal to the second transmission period. If they are equal, execute step 306; otherwise, execute step 310.
  • Step 306 Use either the first sending cycle or the second sending cycle as the sending cycle for the current host to send the service message.
  • Step 308 Determine the idle time period of the sending cycle as the idle time period for the host to send service messages.
  • the idle time period of the service message sending cycle may be fixed, or may be determined based on the service message sending time point.
  • the idle time period of the sending cycle is determined as the idle time period of the host sending the service message. That is, determine the idle time period of the sending cycle from the sending cycle of the current host sending business messages, and determine the idle time period of the sending cycle as the idle time period of the host sending business messages, so as to avoid sending business messages during the current host.
  • the main and backup machines are switched during the periodic non-idle period. There may be situations where the machine is the master or the backup machine at the same time, which improves the stability of the system.
  • the idle time period of the service message sending cycle is non-fixed, when determining the idle time period for the host to send the service message, the service message sending time point of the host in the sending cycle is determined; according to the service message The sending time point determines the idle time period of the sending cycle. By determining the idle time period of the transmission cycle based on the service message transmission time point, the idle time period of the transmission cycle is accurately determined.
  • Step 310 Determine the idle time period of the first sending cycle as the idle time period for the host to send service messages.
  • the communication cycles are inconsistent, such as communication behaviors between the host and the upper-layer device, and communication behaviors between the host and the lower-layer device.
  • the communication cycle between the host and the upper-layer device is inconsistent with the communication cycle between the lower-layer device. If the idle time period of the host is determined based on the communication cycle between the host and the lower-layer device, it will have a great impact on the system. Therefore, in order to minimize the impact on the system, it is necessary to determine the idle time period of the host based on the communication cycle between the host and the upper-layer device, that is, the first sending cycle for sending uplink messages.
  • the idle time period of the first sending cycle is determined as the idle time period for the host to send the service message.
  • the idle time period of the sending cycle is determined as the idle time period of the host sending the service message. That is, the idle time period of the sending cycle is determined from the sending cycle of the current host sending uplink messages, and the idle time period of the sending cycle is determined as the idle time period of the host sending service messages, so as to avoid sending business messages during the current host.
  • the main and backup machines are switched during the periodic non-idle period. There may be situations where the machine is the master or the backup machine at the same time, which improves the stability of the system.
  • the idle time period of the uplink message sending cycle is non-fixed, when determining the idle time period for the host to send the uplink message, the uplink message sending time point of the host in the sending cycle is determined; according to the uplink message sending time Click to determine the idle time period of the sending cycle. By determining the idle time period of the transmission cycle based on the service message transmission time point, the idle time period of the transmission cycle is accurately determined.
  • the sending cycle of the current host and the current standby machine is consistent with the sending time point. If the sending cycle of the current host and the current standby machine is consistent with the sending time point, In this case, after the current standby machine is switched to the master machine, the sending time point of the next service message is consistent with the sending time point of the service message of the host before the switch. At this time, after the current host generates the switch command, To switch to the standby machine, you do not need to wait for feedback from the current standby machine to switch to the master machine before switching to the standby machine. In one embodiment, the switchover between the active and standby machines is started and completed during the idle period for sending service packets. The steps for switching between the active and standby machines are shown in Figure 4 and include the following steps:
  • Step 402 When the master and backup machine switching conditions are met, determine the idle time period for the current host to send service messages.
  • the condition for switching between the active and standby machines is that the fault level of the main machine is higher than that of the standby machine. It can also be that when the fault level of the main machine reaches the preset fault level, the fault level of the main machine is higher than that of the standby machine.
  • obtaining the fault level of the active and standby machines is determined based on the interactive messages between the host and the standby machine. It can be understood that the host interacts with the standby machine while sending service packets, and determines the fault information of the current standby machine and the active and standby status of the local machine based on the interactive messages with the standby machine.
  • the second fault level of the current standby machine is obtained.
  • the second fault level of the current standby machine is used to determine whether the first fault level is higher than the second fault level. If the first fault level is higher than the second fault level, the main and standby machine switching conditions are met.
  • the interactive message between the master and the backup machine includes a start byte, a check byte, and an information byte; the information byte stores status instructions used to represent the fault level and control instructions for whether to switch between the main and backup machines;
  • the check byte stores the verification information used to verify the integrity of the interactive message.
  • the message format of the interactive message is determined according to the needs of the active and standby machine switching, avoiding the use of complex encoding methods.
  • the length of the interactive messages between the active and standby machines affects the timeliness of the current standby machine switching to the host.
  • the main and backup machines communicate according to the set message format, making full use of each byte to convey the fault level status of the main and backup machines, as well as whether the main and backup machines need to be switched and the verification information of the message integrity, improving It increases the transmission rate of the message, shortens the transmission time and makes full use of every bit in the bytes of the message.
  • the interaction message includes three bytes, namely the start byte, the check byte, and the information byte.
  • Each byte includes 8 bits, and each bit is used to represent specific information, as shown in Table 1
  • Table 1 As shown in the figure, an example of an interactive message for the master-standby switching protocol: 8 bits of the first start byte are used to store the start symbol.
  • the start symbol can be represented by 0x5A, and the second information byte is 8
  • the bits are used to store specific information, Bit1 ⁇ 0 are used as backup, Bit3 ⁇ 2 are the main and backup status bits of the local machine, of which 1 represents the main machine, 2 represents the backup machine, and the others represent invalid; Bit5 ⁇ 4 represents the fault level of the local machine.
  • bit7 ⁇ 6 represents the host request switching, 1 represents the request is invalid, 2 represents the request is valid, and the others represent invalid data.
  • the third check byte, 8 bits are CRC check bits.
  • the interaction message between the current host and the current standby machine when obtaining the interaction message between the current host and the current standby machine, by obtaining the check byte of the interaction message; reading the check information in the check byte; The interactive message is verified based on the verification information. If the verification result is that the interactive message is a complete interactive message, the information bytes are obtained to determine whether the current host and the current standby machine meet the conditions for switching between the active and standby machines.
  • the active and standby machines During the switchover between the active and standby machines, if the interactive message contains errors or is damaged, the active and standby machines will misjudge the results, leading to switching errors between the active and standby machines. Therefore, it is necessary to judge whether the active and standby machines meet the requirements based on the information in the interactive messages.
  • the integrity of the message is verified in advance based on the verification information in the interaction message to ensure the integrity of the interaction message and further ensure the accuracy of message switching.
  • the communication rate between the active and standby machines is fixed and cannot be flexibly configured.
  • the communication rate between the active and standby machines cannot match the actual application scenario, and there are problems such as delay and inaccuracy.
  • the communication rate between the current host machine and the current standby machine supports at least one of 5Mbps and 10Mbps. That is, the communication between the active and standby machines can be flexibly configured and the versatility of the switching method between the active and standby machines can be improved.
  • Step 404 The current host generates a switching instruction and switches the current host to a standby machine.
  • the host when it detects that the conditions for switching between the active and standby machines are met, that is, when it detects that the fault level of the host is higher than that of the standby machine, and it is currently in the idle period of business packets, it generates a switching command.
  • the current host is controlled by the host.
  • the status is switched to the standby machine state, and the standby machine after the switch is obtained.
  • Step 406 The current master machine sends a switching instruction to the current standby machine, and the switching instruction instructs the current backup machine to switch to the master machine.
  • the current host receives the switch from the current standby machine to the host and then performs the switch, seamless switching between the active and standby machines cannot be ensured. Therefore, the current host generates a switching command, and the current host switches to the standby machine.
  • the current standby machine receives the switching command, it responds to the switching command, switches the current standby machine from the standby machine state to the master state, and obtains the switched master machine, realizing seamless switching between the master and backup machines.
  • the current host during the idle period of sending service messages, the current host generates a switching instruction; the current host sends a switching instruction to the current standby unit, and when receiving feedback that the current standby unit responds to the switching instruction and switches to the main unit, the current host switches For backup.
  • the current host generates a switching command, and only when the current host receives feedback that the current standby machine switches to the host, the current host will switch to the standby machine.
  • Active/standby switchover avoids the situation of dual active or dual standby caused by unsuccessful switchover.
  • the current host when the conditions for switching between the active and standby machines are met and it is within the idle time period for sending business messages, the current host generates a switching command and switches to the standby machine, and sends the switching command to the current standby machine. , to switch the current standby machine to the master machine.
  • the host does not need to receive feedback from the current standby machine to switch to the host machine before switching to the standby machine. This enables seamless switching between the active and standby machines, avoids the situation where the current active and standby machines are the master at the same time, and ensures the reliability and continuity of communication.
  • a method for switching between master and backup machines is provided. This method is explained by taking the method applied to the master machine or the backup machine in Figure 1 as an example, and includes the following steps:
  • Step 502 After the current host completes sending the last service message, it obtains the interaction message with the current standby machine.
  • the current host and the current backup machine have upper-layer devices and lower-layer devices that have communication behaviors.
  • Figure 6 it is a schematic diagram of the interconnection of the master and backup machines suitable for the battery management system in the field of energy storage power stations in one embodiment.
  • the master and backup machines Optical fiber is used for communication between the host and the standby machine. There are upper-layer devices with common behaviors.
  • the host and standby machine use optical fiber for communication to transmit interactive messages.
  • the interactive messages include the start byte, status instructions representing the fault level, and Control instructions for whether to switch between active and standby switches, and verification information for verifying the integrity of interactive messages.
  • Step 504 If it is detected based on the interaction message that the master and backup machine switching conditions are met, determine the idle time period for the host to send service messages.
  • the current host when the current host obtains the interaction message with the current standby machine, it parses the interaction message and obtains the start byte, check byte, and information byte in the interaction message. According to the check byte
  • the verification information in the verification message is used to verify the integrity of the interactive message.
  • the fault level information of the current standby machine is read from the target bit of the information byte. The level is compared with the second fault level of the current standby machine. When the first fault level is higher than the second fault level, the switching conditions of the active and standby machines are met, and the idle time period for the host to send service messages is determined.
  • the message parsing method can be implemented by existing methods and is not limited here.
  • the verification of the CRC check digit can be implemented by existing methods, and is not limited here.
  • the fault level is set by judging whether the first fault level is the master-standby switchover. If The first fault level is the set fault level, and then it is determined whether the first fault level is higher than the second fault level. If the first fault level is higher than the second fault level, it is determined that the main and backup machine switching conditions are met.
  • the active and standby machines meet the conditions for switching, by further judging whether the host's fault level is the set fault level for active and standby switching, if the host reaches the set fault level for active and standby switching, the number of switchovers will be reduced and stability will be improved. .
  • Step 506 During the idle time period for sending service packets, the current host generates a switching instruction, and the current host switches to the standby machine.
  • Step 508 The current host sends a switching command to the current standby machine.
  • the switching command instructs the current standby machine to switch to the host machine, and the switched host sends the next service message.
  • Figure 7 illustrates the host sending an uplink message.
  • the host sends the first uplink message, it determines the time required to send the uplink message within the sending cycle, which can be understood as the uplink message service window.
  • the uplink message enters the idle time period when the host is sending, it can be understood that the service window is switched between the active and standby machines. Determine the idle time period for sending uplink messages.
  • the switchover between the active and standby computers will be completed before the second uplink message is sent.
  • the time required to send the uplink message is determined within the sending cycle. After sending the uplink message, enter the idle time period when the host is sending, and determine the idle time period for sending the uplink message. If it is detected that the current host and the current standby machine meet the requirements for master-standby switchover, the master-standby switchover is completed before the third uplink message is sent.
  • the current host during the idle time period when sending business messages, the current host generates a switching instruction, and the current host switches to the standby machine.
  • the current standby machine receives the switching instruction, switches to the master in response to the switching instruction, and obtains the switched host.
  • the next host sends the next service message.
  • Switching conditions During the idle time period when the current host sends service packets, the current host generates a switching command and switches to the standby machine, and sends the switching command to the current standby machine so that the current standby machine switches to the master machine.
  • the host does not need to receive feedback from the current standby machine to switch to the host machine before switching to the standby machine. This achieves seamless switching between the active and standby machines, avoids the situation where the current active and standby machines are the master at the same time, and does not affect the normal reporting of business packets. Send messages to ensure the reliability and continuity of communication.
  • a method for switching between master and backup machines is provided. This method is explained by taking the method applied to the master machine and the backup machine in Figure 1 as an example, and includes the following steps:
  • Step 802 After the current host completes sending the last service message, it obtains the interaction message with the current standby machine.
  • the sending cycle of the current host to send the service message is determined, the time point at which the current host sends the service message in the sending cycle is determined, and after the current host completes the sending of the last service message, the interactive message with the current standby machine is obtained.
  • Step 804 Parse the interaction message and obtain information bytes.
  • Step 806 Read the first fault level of the master machine and the second fault level of the standby machine from the target bits of the information byte.
  • Step 808 If the first fault level is higher than the second fault level, it is determined that the master and backup machine switching conditions are met.
  • Step 810 Determine the idle time period for the current host to send service messages.
  • the idle time period of the sending cycle in which the current host sends the service message is determined. It can be understood that message interaction and switching between the active and standby machines are completed sequentially during the idle time period of the sending cycle of sending service messages.
  • Step 812 During the idle time period for sending service packets, the current host generates a switching instruction, and the current host switches to the standby machine.
  • Step 814 The current master machine sends a switching instruction to the current standby machine, and the switching instruction instructs the current standby machine to switch to the master machine.
  • Step 816 Determine the freezing time period for the master and backup machine switching, and maintain the current status of the master and backup machines during the freezing period for the master and backup machine switching.
  • the freezing time period can be understood as the freezing window for switching between the primary and backup servers.
  • the freezing time period is a set time period.
  • the set time period can be, but is not limited to, 10 seconds, or 8 seconds, etc.
  • During the freezing period maintain the current status of the active and standby machines to ensure that the switched host and the switched standby machine do not switch between active and standby machines.
  • the master machine after the switch needs to maintain its status as the master machine for a set period of time, and the backup machine after the switchover needs to maintain its status as the backup machine. Within this set time period, the operation of switching between the active and standby machines will not be performed.
  • the current host After the last service message is sent, during the idle time period when the host sends service messages, if it is detected based on the interaction messages between the current host and the current standby machine that the current host and the current standby machine satisfy the need for master-standby switchover, Conditions, the current host generates a switching command and switches to the standby machine, and sends the switching command to the current standby machine, so that the current standby machine switches to the host machine, and the switch between the main and standby machines is completed before the next message is sent.
  • the host does not need to receive feedback from the current standby machine to switch to the host machine before switching to the standby machine.
  • a method for switching between master and backup machines is provided. This method is explained by taking the method applied to the master machine and the backup machine in Figure 1 as an example, and includes the following steps:
  • Step 902 After the current host machine and the current standby machine are powered on, obtain the sending cycle and sending time point of the current host machine sending business messages, and obtain the sending cycle and sending time point of the current standby machine sending business messages.
  • Step 904 If the current host and the current standby machine send service packets at different sending time points, synchronize the sending cycles and sending time points of the current standby host and the current standby machine.
  • the sending cycles of the current host and the current standby machine are the same. If the sending time points in the sending cycles of the current host and the current standby machine are different, synchronize the sending cycles and sending time points of the current standby host and the current standby machine. That is, the sending cycle and sending time point in the current standby machine are set to the sending cycle and sending time point of the current master machine. For example, the sending period of the current host and the current standby machine is both 100us, the sending time point of the current host is 85us, the next sending time point is 100us, and the transmission time of the interactive message between the current host and the current standby machine is 5us. Before the current standby machine is switched, the sending period is 100us and the sending time point is 20us. After the current standby machine is switched to the master machine, it synchronizes its own sending time point to 10us and then sends the service message.
  • Step 906 When the master and backup machine switching conditions are met, determine the idle time period for the current host to send service messages.
  • Determining the idle time period for the current host to send service packets can be achieved through the above method, which will not be described in detail here.
  • Step 908 During the idle time period for sending service packets, the current host generates a switching instruction.
  • Step 910 The current host sends a switching command to the current standby machine.
  • the current host machine switches to the standby machine.
  • the master and backup machines after the master and backup machines are powered on, if the message sending time points of the master and backup machines are inconsistent, by synchronizing the sending cycle and sending time point of the current master and the current backup machine, it is ensured that the sending time of the current master is determined to be the same.
  • the switching between the active and standby machines will begin and be completed during the idle time period when business packets are sent. This ensures that the time at which the host sends packets before and after the switch is consistent, and that the host sends messages to the receiving service at the same time.
  • the device of the message shields the master and backup machine switching process to avoid transmitting the information that the master and backup machines are active at the same time or that the master and backup machines are both backup at the same time to the device that receives the business message, which improves the reliability and stability of the system corresponding to the master and backup machines. sex.
  • embodiments of the present application also provide an active-standby machine switching device for implementing the above-mentioned active-standby machine switching method.
  • the solution to the problem provided by this device is similar to the solution recorded in the above method. Therefore, the specific limitations in the embodiments of one or more master and backup machine switching devices provided below can be found in the above article on master and backup machine switching. The limitations of the method will not be repeated here.
  • an active and standby machine switching device including: a switching judgment module 1002 and an active and standby switching module 1004, wherein:
  • the switching judgment module 1002 is used to determine the idle time period for the current host to send service messages when the master and backup machine switching conditions are met.
  • Service messages include at least one of uplink messages, downlink messages, and uplink and downlink messages;
  • the active and standby switching module 1004 is used to start and complete the active and standby switching during the idle time period for sending service messages.
  • the master and backup machine switching device after determining that the current host is in the idle time period for sending business messages, and if the master and backup machine switching conditions are also met at the same time, the master and backup machine switching is started and completed during the idle time period for sending business messages. Shield the active and standby machine switching process from the device that receives the service message, and avoid transmitting the information that the active and standby machines are active at the same time or the active and standby machine are both standby to the device that receives the service message; and avoid sending the service message at the same time. Switching between active and standby machines improves the reliability and stability of the system corresponding to the active and standby machines.
  • an active/standby switching device In addition to the switching judgment module 1002 and the active/standby switching module 1004, it also includes: a message interaction module, a message parsing module, a time synchronization module, and a calibration module. Verification module, freezing module and idle time period determination module, among which:
  • the active/standby switching module 1004 is also used to generate a switching instruction from the current host during the idle period of sending service messages, and the current host switches to the standby machine; the current host sends a switching instruction to the current standby machine, and the switching instruction instructs the current standby machine to switch to the master .
  • the active/standby switching module 1004 is also used to generate a switching instruction from the current host during the idle period of sending service messages; the current host sends a switching instruction to the current standby unit, and receives feedback that the current standby unit switches to the main unit in response to the switching instruction.
  • the master machine is switched to the standby machine.
  • the time synchronization module is used to obtain the sending cycle and sending time point of the business message sent by the current host machine after the current host machine and the current standby machine are powered on, and to obtain the sending cycle and sending time point of the business message sent by the current standby machine;
  • the message interaction module is used to obtain the interaction message with the current standby machine after the current host completes sending the last business message.
  • the switching judgment module 1002 is also used to determine the idle time period for the host to send service messages if it is detected based on the interaction message that the master and backup machine switching conditions are met.
  • the interaction message includes a start byte, a check byte, and an information byte; the information byte stores a status instruction used to characterize the fault level and a control instruction whether to switch between active and backup; the check byte Stores verification information used to verify the integrity of interactive messages.
  • the message parsing module is used to parse interactive messages and obtain information bytes; read the first fault level of the host and the second fault level of the standby machine from the target bits of the information bytes;
  • the switching judgment module 1002 is also configured to determine that the master-standby machine switching condition is met if the first fault level is higher than the second fault level.
  • the switching judgment module 1002 is also used to judge whether the first fault level is a set fault level for active/standby switchover. If the first fault level is the set fault level, determine whether the first fault level is higher than the second fault level.
  • Verification module used to obtain the verification byte of the interactive message; read the verification information in the verification byte; verify the interactive message based on the verification information. If the verification result is that the interactive message is complete Interaction messages to obtain information bytes.
  • the idle time period determination module is used to determine the sending cycle of the current host to send the service message; determine the idle time period of the sending cycle as the idle time period of the host to send the service message.
  • the idle time period determination module is also used to determine the service message sending time point of the host in the sending cycle; determine the idle time period of the sending cycle based on the service message sending time point.
  • the idle time period determination module is also used to determine the first sending cycle of the host's uplink message and the second sending cycle of the host's downlink message; if the first sending cycle and the second sending cycle are different, the first sending cycle
  • the idle time period of the cycle is determined to be the idle time period for the host to send service messages.
  • a freezing module is used to determine the freezing time period for the switching of the main and standby machines, and maintain the current status of the main and standby machines during the freezing period of the switching of the main and standby machines.
  • the communication rate between the current host machine and the current standby machine supports at least one of 5Mbps and 10Mbps.
  • Each module in the above-mentioned active and standby switching device can be implemented in whole or in part by software, hardware, and combinations thereof.
  • Each of the above modules may be embedded in or independent of the processor of the computer device in the form of hardware, or may be stored in the memory of the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.
  • a computer device is provided.
  • the computer device may be a server or a terminal device, and its internal structure diagram may be as shown in Figure 11.
  • the computer device includes a processor, memory, and network interfaces connected through a system bus.
  • the processor of the computer device is used to provide computing and control capabilities.
  • the memory of the computer device includes non-volatile storage media and internal memory.
  • the non-volatile storage medium stores operating systems, computer programs and databases. This internal memory provides an environment for the execution of operating systems and computer programs in non-volatile storage media.
  • the database of the computer device is used to store data such as interactive messages of the host and standby machines, the sending cycle of the host, and so on.
  • the network interface of the computer device is used to communicate with external terminals through a network connection. When the computer program is executed by the processor, a method for switching between primary and secondary computers is implemented.
  • Figure 11 is only a block diagram of a partial structure related to the solution of the present application, and does not constitute a limitation on the computer equipment to which the solution of the present application is applied.
  • Specific computer equipment can May include more or fewer parts than shown, or combine certain parts, or have a different arrangement of parts.
  • a computer device including a memory and a processor.
  • a computer program is stored in the memory.
  • the processor executes the computer program, it implements the steps in the above method embodiments.
  • a computer-readable storage medium on which a computer program is stored.
  • the computer program is executed by a processor, the steps in the above method embodiments are implemented.
  • a computer program product including a computer program that implements the steps in each of the above method embodiments when executed by a processor.
  • data involved in this application are all information and data authorized by the user or fully authorized by all parties.
  • the computer program can be stored in a non-volatile computer-readable storage.
  • the computer program when executed, may include the processes of the above method embodiments.
  • Any reference to memory, database or other media used in the embodiments provided in this application may include at least one of non-volatile and volatile memory.
  • Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive memory (ReRAM), magnetic variable memory (Magnetoresistive Random Access Memory (MRAM), ferroelectric memory (Ferroelectric Random Access Memory, FRAM), phase change memory (Phase Change Memory, PCM), graphene memory, etc.
  • Volatile memory may include random access memory (Random Access Memory, RAM) or external cache memory, etc.
  • RAM Random Access Memory
  • RAM random access memory
  • RAM Random Access Memory
  • the databases involved in the various embodiments provided in this application may include at least one of a relational database and a non-relational database.
  • Non-relational databases may include blockchain-based distributed databases, etc., but are not limited thereto.
  • the processors involved in the various embodiments provided in this application may be general-purpose processors, central processing units, graphics processors, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, etc., and are not limited to this.

Abstract

La présente demande concerne un appareil et un procédé de commutation maître-secours, un dispositif informatique, un support de stockage et un produit programme d'ordinateur. Le procédé consiste à : lorsqu'une condition de commutation maître-secours est satisfaite, déterminer une période temporelle de repos lorsqu'un paquet de service est envoyé par le serveur maître actuel ; et démarrer et achever la commutation maître-secours au niveau de la période temporelle de repos lorsque le paquet de service est envoyé. À l'aide du procédé, un dispositif recevant le paquet de service peut être protégé du processus de commutation maître-secours, et la commutation maître-secours est évitée au moment de l'envoi du paquet de service, ce qui permet d'améliorer la fiabilité et la stabilité du système correspondant à un serveur maître/secours.
PCT/CN2022/116086 2022-08-31 2022-08-31 Appareil et procédé de commutation maître-secours, dispositif informatique et support de stockage WO2024045012A1 (fr)

Priority Applications (1)

Application Number Priority Date Filing Date Title
PCT/CN2022/116086 WO2024045012A1 (fr) 2022-08-31 2022-08-31 Appareil et procédé de commutation maître-secours, dispositif informatique et support de stockage

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2022/116086 WO2024045012A1 (fr) 2022-08-31 2022-08-31 Appareil et procédé de commutation maître-secours, dispositif informatique et support de stockage

Publications (1)

Publication Number Publication Date
WO2024045012A1 true WO2024045012A1 (fr) 2024-03-07

Family

ID=90099957

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/116086 WO2024045012A1 (fr) 2022-08-31 2022-08-31 Appareil et procédé de commutation maître-secours, dispositif informatique et support de stockage

Country Status (1)

Country Link
WO (1) WO2024045012A1 (fr)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101071407A (zh) * 2007-06-22 2007-11-14 中兴通讯股份有限公司 主备系统及主备系统间实现外部部件互连设备切换的方法
CN101447858A (zh) * 2008-01-17 2009-06-03 中兴通讯股份有限公司 双机热备份系统中实现虚拟路由冗余协议同步倒换的方法
EP2560348A2 (fr) * 2011-08-19 2013-02-20 Schneider Electric Industries SAS Procédé d'adressage automatique de plusieurs esclaves dans un réseau maître-esclave
CN111107526A (zh) * 2019-10-08 2020-05-05 珠海市杰理科技股份有限公司 标准时隙的双无线蓝牙设备主从切换方法、设备和系统
CN111106853A (zh) * 2019-10-08 2020-05-05 珠海市杰理科技股份有限公司 双无线蓝牙设备主从切换方法、装置、设备和音频系统

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101071407A (zh) * 2007-06-22 2007-11-14 中兴通讯股份有限公司 主备系统及主备系统间实现外部部件互连设备切换的方法
CN101447858A (zh) * 2008-01-17 2009-06-03 中兴通讯股份有限公司 双机热备份系统中实现虚拟路由冗余协议同步倒换的方法
EP2560348A2 (fr) * 2011-08-19 2013-02-20 Schneider Electric Industries SAS Procédé d'adressage automatique de plusieurs esclaves dans un réseau maître-esclave
CN111107526A (zh) * 2019-10-08 2020-05-05 珠海市杰理科技股份有限公司 标准时隙的双无线蓝牙设备主从切换方法、设备和系统
CN111106853A (zh) * 2019-10-08 2020-05-05 珠海市杰理科技股份有限公司 双无线蓝牙设备主从切换方法、装置、设备和音频系统

Similar Documents

Publication Publication Date Title
JP5548829B2 (ja) 計算機システム、データ管理方法及びデータ管理プログラム
EP1510921A2 (fr) Systeme de stockage avec copie a distance
CN108628717A (zh) 一种数据库系统及监控方法
CN101163036B (zh) 实现网络设备管理软件双机热备份的方法
CN105786405A (zh) 一种在线升级方法、装置及系统
CN106685735B (zh) Epa片上系统、epa通信系统及通信方法
CN112131237A (zh) 数据同步方法、装置、设备及计算机可读介质
US20230098190A1 (en) Data processing method, apparatus, device and medium based on distributed storage
CN104424048A (zh) 用于数据存储的方法和装置
CN108833164B (zh) 服务器控制方法、装置、电子设备及存储介质
US11809295B2 (en) Node mode adjustment method for when storage cluster BBU fails and related component
US11256640B2 (en) File transfer method, apparatus, device between BMCs and storage medium
US8984333B2 (en) Automatic computer storage medium diagnostics
CN114218193A (zh) 数据迁移方法、装置、计算机设备和可读存储介质
WO2024045012A1 (fr) Appareil et procédé de commutation maître-secours, dispositif informatique et support de stockage
US20240095019A1 (en) Out-of-band updating method and system of expander
WO2024051454A1 (fr) Procédé et appareil de traitement de journal de transactions
CN112650629A (zh) 区块链索引数据恢复方法、装置、设备和计算机存储介质
CN110707824A (zh) 一种测控装置的冗余配置方法、装置、设备和存储介质
CN114827967B (zh) 软件更新方法、蓝牙设备及存储介质
EP2777215A1 (fr) Procédé, appareil et système pour transmettre ou recevoir simultanément de multiples objets gérés
CN111309515A (zh) 一种容灾控制方法、装置及系统
WO2021244500A1 (fr) Procédé, appareil et système de détermination d'état de sauvegarde
CN110661869B (zh) 一种节点上线方法、系统、装置、设备及计算机存储介质
CN113472891A (zh) 一种sdn控制器集群数据处理方法、设备及介质

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 22956843

Country of ref document: EP

Kind code of ref document: A1