Redundancy scheduling system and method and electronic equipment
By designing hot standby redundant groups and cold standby redundant groups, and using heartbeat signals for real-time monitoring and scheduling, the problem of single user selectivity in the existing technology is solved, and the flexibility and stability of the redundant scheduling system is achieved.
Patent Information
- Application Number
- CN202510110291.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-23
- Publication Date
- 2025-05-06
- Estimated Expiration
- 2045-01-23
AI Technical Summary
In the intelligent manufacturing process of the steel industry, the existing redundant scheduling system has a single user's selectivity and cannot flexibly choose cold backup or hot backup redundancy methods, which affects the stability of the data collection or data transmission process.
A redundant scheduling system is designed, including a hot standby redundant group and a cold standby redundant group. Through the transmission and reception of heartbeat signals, the redundant scheduling platform monitors and dispatches gateway controllers in real time to realize flexible switching between hot standby redundant group and cold standby redundant group.
It improves user selection flexibility, ensures the stability and reliability of data acquisition or data transmission processes, reduces the risk of single point of failure, and reduces operation and maintenance costs.
Smart Images

Figure CN119937278A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of metallurgy and intelligent manufacturing technology, and in particular to a redundant scheduling system, method and electronic equipment. Background Art
[0002] In the intelligent manufacturing process of the modern steel industry, data collection or data transmission is an essential function for realizing intelligent manufacturing. The stability of data collection or data transmission directly affects key links such as report calculation, model analysis and equipment control. However, industrial sites often face a variety of unstable factors such as operating system failures, network anomalies, power outages and equipment failures. These problems threaten the reliability of the underlying links, thereby causing the risk of single point failures.
[0003] At present, the relevant technologies mainly adopt cold standby or hot standby redundancy to ensure the continuity and reliability of data in the process of data collection or data transmission. The cold standby redundancy usually requires that only one main link is in operation, while the hot standby redundancy allows multiple links to run simultaneously. However, since the cold standby redundancy and the hot standby redundancy are implemented separately, after deploying one of the redundancy modes, the user can only select and use the redundancy mode, resulting in the user's selectivity being relatively single and inflexible. Therefore, the redundant scheduling system in the relevant technology is improved. Summary of the invention
[0004] In view of the above-mentioned shortcomings of the prior art, the present application provides a redundant scheduling system, method and electronic device to solve the above-mentioned technical problems.
[0005] According to one aspect of an embodiment of the present application, a redundant scheduling system is provided, including: a hot standby redundant group, including a first main gateway controller and a first standby gateway controller in a startup state, the first main gateway controller being used to send a heartbeat signal to a redundant scheduling center, recorded as a first heartbeat signal; and the first standby gateway controller being used to send a heartbeat signal to the redundant scheduling center, recorded as a second heartbeat signal; a cold standby redundant group, including a second main gateway controller in a startup state and a second standby gateway controller that is not in a startup state, the second main gateway controller being used to send a heartbeat signal to the redundant scheduling center, recorded as a third heartbeat signal; a redundant scheduling platform, for determining the operating state of the first main gateway controller according to the first heartbeat signal; determining the operating state of the first standby gateway controller according to the second heartbeat signal; and performing redundant scheduling on the gateway controllers in the hot standby redundant group according to the operating state of the first main gateway controller and the operating state of the first standby gateway controller; and determining the operating state of the second main gateway controller according to the third heartbeat signal, and performing redundant scheduling on the gateway controllers in the cold standby redundant group according to the operating state of the second main gateway controller and the historical activity data of the second standby gateway controller.
[0006] In one embodiment of the present application, the redundant scheduling platform further includes: determining the operating state of the hot standby redundant group according to the operating state of the first main gateway controller and the operating state of the first standby gateway controller; wherein, when the operating state of at least one of the first main gateway controller and the first standby gateway controller is operating normally, the operating state of the hot standby redundant group is determined to be operating normally; when the operating state of the first main gateway controller is operating abnormally and the operating state of the first standby gateway controller is operating abnormally, the operating state of the hot standby redundant group is determined to be operating abnormally; and, according to the operating state of the second main gateway controller, determining the cold standby The operating status of the redundant group; wherein, when the operating status of the second main gateway controller is normal operation, the operating status of the cold standby redundant group is determined to be normal operation; when the operating status of the second main gateway controller is abnormal operation, the operating status of the cold standby redundant group is determined to be abnormal operation; and, broadcasting the operating status of the first main gateway controller, the operating status of the first standby gateway controller, the operating status of the second main gateway controller, the operating status of the hot standby redundant group, the operating status of the cold standby redundant group, the redundant scheduling results of the gateway controllers in the hot standby redundant group or the redundant scheduling results of the gateway controllers in the cold standby redundant group to the gateway controller in the startup state.
[0007] In one embodiment of the present application, the redundant scheduling system also includes: an Internet of Things platform, which is used to respond to the request of the first main gateway controller to send the first heartbeat signal and store the first heartbeat signal; and, respond to the request of the second main gateway controller to send the third heartbeat signal and store the third heartbeat signal; and, store the operating status of the hot standby redundant group, and when the operating status of the hot standby redundant group is an abnormal operation, record the reason for the abnormal operation of the hot standby redundant group; and, store the operating status of the cold standby redundant group, and when the operating status of the cold standby redundant group is an abnormal operation, record the reason for the abnormal operation of the cold standby redundant group; and, record the redundant scheduling results of the gateway controllers in the hot standby redundant group, or, record the redundant scheduling results of the gateway controllers in the cold standby redundant group.
[0008] According to one aspect of an embodiment of the present application, a redundant scheduling method is provided, including: obtaining a heartbeat signal of a first main gateway controller and a heartbeat signal of a first standby gateway controller; the first main gateway controller and the first standby gateway controller are both in a startup state; using the heartbeat signal of the first main gateway controller as a first heartbeat signal; determining the operating state of the first main gateway controller according to the first heartbeat signal; using the heartbeat signal of the first standby gateway controller as a second heartbeat signal; determining the operating state of the first standby gateway controller according to the second heartbeat signal; and performing redundant scheduling of gateway controllers in a hot standby redundant group according to the operating state of the first main gateway controller and the operating state of the first standby gateway controller.
[0009] In one embodiment of the present application, the process of determining the operating status of the first master gateway controller according to the first heartbeat signal includes: if the first heartbeat signal includes the latest heartbeat signal and the previous heartbeat signal, then calculating the time interval between the latest heartbeat signal and the previous heartbeat signal, recorded as the first time interval, and calculating the time interval between the current moment and the timestamp of the latest heartbeat signal, recorded as the second time interval; if the first time interval exceeds a preset interval threshold or the second time interval exceeds the preset time interval, then determining that the operating status of the first master gateway controller is abnormal operation; if the first time interval does not exceed the preset interval threshold and the second time interval does not exceed the preset time interval, then determining that the operating status of the first master gateway controller is normal operation.
[0010] In one embodiment of the present application, according to the operating status of the first main gateway controller and the operating status of the first standby gateway controller, the process of redundantly scheduling the gateway controllers in the hot standby redundant group includes: if the current operating status of the first main gateway controller is abnormal operation, the active gateway is switched from the first main gateway controller to the first standby gateway controller that is operating normally; wherein, when there are multiple first standby gateway controllers that are operating normally, the latest heartbeat timestamp of each first standby gateway controller that is operating normally is obtained, the time interval between the time point corresponding to each latest heartbeat timestamp and the current moment is calculated, and the first standby gateway controller with the smallest time interval is used as the active gateway; if the current operating status of the first main gateway controller is normal operation, the first main gateway controller continues to be used as the active gateway.
[0011] In one embodiment of the present application, the method also includes: obtaining the heartbeat signal of the second main gateway controller and the historical activity data of the second standby gateway controller; the second main gateway controller is in a startup state; the second standby gateway controller is in an unstarted state; using the heartbeat signal of the second main gateway controller as a third heartbeat signal; determining the operating status of the second main gateway controller according to the third heartbeat signal; and performing redundant scheduling of the gateway controllers in the cold standby redundancy group according to the operating status of the second main gateway controller and the historical activity data of the second standby gateway controller.
[0012] In one embodiment of the present application, the process of redundantly scheduling the gateway controllers in the cold standby redundancy group according to the operating status of the second main gateway controller and the historical activity data of the second standby gateway controller includes: if the operating status of the second main gateway controller is abnormal operation, determining the startup duration and the stop activity time point of the second standby gateway controller from the historical activity data; determining the selection weight of the second standby gateway controller according to the startup duration and the stop activity time point; and using the second standby gateway controller with the largest selection weight as the target gateway controller; starting the target gateway controller, and switching the active gateway from the second main gateway controller to the target gateway controller; if the operating status of the second main gateway controller is normal operation, continuing to use the second main gateway controller as the active gateway.
[0013] In one embodiment of the present application, the process of determining the selection weight of the second backup gateway controller according to the startup duration and the activity stop time point includes: determining a duration reference value according to the startup duration; the duration reference value is negatively correlated with the startup duration; calculating the time interval between the current moment and the activity stop time point, recorded as the third time interval, and determining a time reference value according to the third time interval; the time reference value is negatively correlated with the third time interval; determining the selection weight based on the duration reference value and the preset duration weight, the time reference value and the preset time weight.
[0014] According to one aspect of an embodiment of the present application, an electronic device is provided, comprising: one or more processors; a storage device for storing one or more programs, wherein when the one or more programs are executed by the one or more processors, the electronic device implements the redundant scheduling method as described above.
[0015] According to one aspect of an embodiment of the present application, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor of a computer, the computer executes the redundant scheduling method described above.
[0016] Beneficial effects of the present invention: The present invention sets a hot standby redundant group, a cold standby redundant group and a redundant scheduling platform. The hot standby redundant group includes a first main gateway controller and a first standby gateway controller in a startup state. The first main gateway controller is used to send a heartbeat signal to a redundant scheduling center, which is recorded as a first heartbeat signal; and the first standby gateway controller is used to send a heartbeat signal to the redundant scheduling center, which is recorded as a second heartbeat signal. The cold standby redundant group includes a second main gateway controller in a startup state and a second standby gateway controller that is not in a startup state. The second main gateway controller is used to send a heartbeat signal to the redundant scheduling center, which is recorded as a third heartbeat signal. The redundant scheduling platform is used to determine the operating status of the first main gateway controller according to the first heartbeat signal. state; determining the operating state of the first standby gateway controller according to the second heartbeat signal, and performing redundant scheduling on the gateway controllers in the hot standby redundant group according to the operating state of the first main gateway controller and the operating state of the first standby gateway controller, and determining the operating state of the second main gateway controller according to the third heartbeat signal; and performing redundant scheduling on the gateway controllers in the cold standby redundant group according to the operating state of the second main gateway controller and the historical activity data of the second standby gateway controller. The above process is integrated into the same system through the hot standby redundant group, the cold standby redundant group and the redundant scheduling platform. The user can select the hot standby mode (hot standby redundant group) or the cold standby mode (cold standby redundant group) according to the use requirements, which is convenient for the user to choose and improves the flexibility of choice.
[0017] It should be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present application. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] The drawings herein are incorporated into the specification and constitute a part of the specification, showing embodiments consistent with the present application, and together with the specification, are used to explain the principles of the present application. Obviously, the drawings described below are only some embodiments of the present application, and for those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative work. In the drawings:
[0019] Figure 1 is a block diagram of a redundant scheduling system shown in an exemplary embodiment of the present application;
[0020] Figure 2 is a structural schematic diagram of a redundant scheduling system shown in an exemplary embodiment of the present application;
[0021] Figure 3 is a schematic diagram of an exemplary system architecture shown in an exemplary embodiment of the present application;
[0022] Figure 4 is a flowchart of a redundant scheduling method shown in an exemplary embodiment of the present application;
[0023] Figure 5 is a flowchart of interaction between a redundant scheduling platform and an edge gateway controller shown in an exemplary embodiment of the present application;
[0024] Figure 6 is a flowchart of redundant scheduling of gateway controllers in a redundant group shown in an exemplary embodiment of the present application;
[0025] Figure 7 A schematic diagram of the structure of a computer system suitable for implementing a computer-readable storage medium of an embodiment of the present application is shown. DETAILED DESCRIPTION
[0026] Here, exemplary embodiments will be described in detail, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The implementations described in the following exemplary embodiments do not represent all implementations consistent with the present application. Instead, they are only examples of devices and methods consistent with some aspects of the present application as detailed in the attached claims.
[0027] The block diagrams shown in the accompanying drawings are merely functional entities and do not necessarily correspond to physically independent entities. That is, these functional entities may be implemented in software form, or in one or more hardware modules or integrated circuits, or in different networks and / or processor devices and / or microcontroller devices.
[0028] The flowcharts shown in the accompanying drawings are only exemplary and do not necessarily include all the contents and operations / steps, nor must they be executed in the order described. For example, some operations / steps can be decomposed, and some operations / steps can be combined or partially combined, so the actual execution order may change according to actual conditions.
[0029] The term "multiple" as used in this application refers to two or more than two. "And / or" describes the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone. The character " / " generally indicates that the related objects are in an "or" relationship.
[0030] The technical solution of the embodiment of the present application involves analog-to-digital conversion and other related technologies, which are specifically described by the following embodiments:
[0031] The hot standby redundant group supports single-active mode and multi-active mode. When the hot standby redundant group is in single-active mode, only the active gateway is allowed to be in the startup state; when the hot standby redundant group is in multi-active mode, both the active gateway and the standby gateway controller are in the startup state; the cold standby redundant group only supports single-active mode, that is, only the active gateway is allowed to be in the startup state.
[0032] The active gateway is used to realize network protocol conversion and data transmission between network devices (for example, acquisition devices or control devices) and redundant scheduling platforms; it is also used to realize network protocol conversion and data transmission between network devices (for example, acquisition devices or control devices) and Internet of Things platforms.
[0033] Figure 1 FIG. 1 is a block diagram of a redundant scheduling system shown in an exemplary embodiment of the present application. Figure 1 As shown, the exemplary redundant scheduling system includes:
[0034] The hot standby redundant group 101 includes a first main gateway controller and a first standby gateway controller in a startup state. The first main gateway controller is used to send a heartbeat signal to the redundant scheduling center, recorded as a first heartbeat signal; and the first standby gateway controller is used to send a heartbeat signal to the redundant scheduling center, recorded as a second heartbeat signal.
[0035] The cold standby redundancy group 102 includes a second main gateway controller in a startup state and a second standby gateway controller that is not in a startup state. The second main gateway controller is used to send a heartbeat signal to the redundant scheduling center, which is recorded as a third heartbeat signal.
[0036] The redundant scheduling platform 103 is used to determine the operating status of the first main gateway controller according to the first heartbeat signal; determine the operating status of the first standby gateway controller according to the second heartbeat signal; and perform redundant scheduling of the gateway controllers in the hot standby redundant group according to the operating status of the first main gateway controller and the operating status of the first standby gateway controller; and determine the operating status of the second main gateway controller according to the third heartbeat signal, and perform redundant scheduling of the gateway controllers in the cold standby redundant group according to the operating status of the second main gateway controller and the historical activity data of the second standby gateway controller.
[0037] In one embodiment of the present application, the active gateway can be a main gateway controller or a standby gateway controller. When both the main gateway controller and the standby gateway controller are in the startup state and the operating state of the main gateway controller and the operating state of the standby gateway controller are normal, the main gateway controller is used as the active gateway.
[0038] In some embodiments of the present application, the heartbeat signal includes fields such as redundancy group ID (Identification), gateway ID, heartbeat timestamp, etc. The heartbeat timestamp is used to indicate the time when the gateway controller sends the heartbeat signal.
[0039] In some embodiments of the present application, by integrating a hot standby redundant group, a cold standby redundant group and a redundant scheduling platform into the same system, a user can select a hot standby mode (hot standby redundant group) or a cold standby mode (cold standby redundant group) according to usage requirements, thereby facilitating user selection and improving flexibility of selection.
[0040] In one embodiment of the present application, the redundant scheduling platform also includes: determining the operating state of the hot standby redundant group according to the operating state of the first main gateway controller and the operating state of the first standby gateway controller; wherein, when the operating state of at least one of the first main gateway controller and the first standby gateway controller is operating normally, the operating state of the hot standby redundant group is determined to be operating normally; when the operating state of the first main gateway controller is operating abnormally and the operating state of the first standby gateway controller is operating abnormally, the operating state of the hot standby redundant group is determined to be operating abnormally; and, according to the operating state of the second main gateway controller, determining the cold standby redundant group's operating status; wherein, when the operating status of the second main gateway controller is normal operation, the operating status of the cold standby redundant group is determined to be normal operation; when the operating status of the second main gateway controller is abnormal operation, the operating status of the cold standby redundant group is determined to be abnormal operation; and, broadcasting the operating status of the first main gateway controller, the operating status of the first standby gateway controller, the operating status of the second main gateway controller, the operating status of the hot standby redundant group, the operating status of the cold standby redundant group, the redundant scheduling results of the gateway controllers in the hot standby redundant group, or the redundant scheduling results of the gateway controllers in the cold standby redundant group to the gateway controllers in the startup state.
[0041] In one embodiment of the present application, the redundant scheduling platform broadcasts the operating status of the first main gateway controller, the operating status of the first standby gateway controller, the operating status of the second main gateway controller, the operating status of the hot standby redundant group, the operating status of the cold standby redundant group, the redundant scheduling results of the gateway controllers in the hot standby redundant group, or the redundant scheduling results of the gateway controllers in the cold standby redundant group to the gateway controller in the startup state, which is beneficial for the gateway controller in the startup state to timely update the operating status of the first standby gateway controller, the operating status of the second main gateway controller, the operating status of the hot standby redundant group, the operating status of the cold standby redundant group, the redundant scheduling results of the gateway controllers in the hot standby redundant group, or the redundant scheduling results of the gateway controllers in the cold standby redundant group.
[0042] In one embodiment of the present application, the redundant scheduling system also includes: an Internet of Things platform, which is used to respond to the request of the first main gateway controller to send a first heartbeat signal and store the first heartbeat signal; and, respond to the request of the second main gateway controller to send a third heartbeat signal and store the third heartbeat signal; and, store the operating status of the hot standby redundant group, and when the operating status of the hot standby redundant group is abnormal operation, record the reason for the abnormal operation of the hot standby redundant group; and, store the operating status of the cold standby redundant group, and when the operating status of the cold standby redundant group is abnormal operation, record the reason for the abnormal operation of the cold standby redundant group; and, record the redundant scheduling results of the gateway controllers in the hot standby redundant group, or, record the redundant scheduling results of the gateway controllers in the cold standby redundant group.
[0043] In one embodiment of the present application, the first heartbeat signal is recorded and analyzed through the Internet of Things platform, so as to facilitate timely discovery of the abnormality of the first main gateway controller according to the first heartbeat signal; the second heartbeat signal is recorded and analyzed through the Internet of Things platform, so as to facilitate timely discovery of the abnormality of the first standby gateway controller according to the second heartbeat signal; the third heartbeat signal is recorded and analyzed through the Internet of Things platform, so as to facilitate timely discovery of the abnormality of the second main gateway controller according to the third heartbeat signal; and by recording the reasons for the abnormal operation of the hot standby redundant group and the reasons for the abnormal operation of the cold standby redundant group, it is convenient to perform subsequent problem analysis and troubleshooting based on the recorded data.
[0044] Figure 2 is a schematic diagram of a redundant scheduling system shown in an exemplary embodiment of the present application. Figure 2 In the embodiment, the redundant scheduling system includes: end-layer devices, edge-layer devices and cloud-layer platforms, the cloud-layer platform includes an industrial Internet of Things platform, the edge-layer devices include a hot standby redundant group, a cold standby redundant group and a redundant scheduling center (redundant scheduling platform), the hot standby redundant group includes a main link gateway controller and a standby link gateway controller, the cold standby redundant group includes a main link gateway controller and a standby link gateway controller, the end-layer devices include a main programmable logic controller (PLC) device, a standby PLC device, a data acquisition device, a data transmission device, a distributed controller (DCS), etc.
[0045] In some embodiments of the present application, the main link gateway controller in the hot standby redundant group communicates with the main PLC device through the MODBUS TCP (Transmission Control Protocol) protocol, S7 protocol or CIP (Common Industrial Protocol) protocol, and the standby link gateway controller in the hot standby redundant group communicates with the main PLC device through the MODBUS TCP (Transmission Control Protocol) protocol, S7 protocol or CIP (Common Industrial Protocol) protocol. The hot standby redundant group uses a master link gateway controller to communicate with the standby PLC device according to the master link gateway controller protocol; the standby link gateway controller in the hot standby redundant group is used to send a heartbeat signal to the redundant scheduling center, and the redundant scheduling center is used to determine the operating status of the master link gateway controller in the hot standby redundant group according to the heartbeat signal of the master link gateway controller in the hot standby redundant group, determine the operating status of the standby link gateway controller in the hot standby redundant group according to the heartbeat signal of the standby link gateway controller in the hot standby redundant group, and perform redundant scheduling of the gateway controllers in the hot standby redundant group according to the operating status of the master link gateway controller in the hot standby redundant group and the operating status of the standby link gateway controller in the hot standby redundant group; the industrial Internet of Things platform is used to record the data of the active gateway (master link gateway controller or standby link gateway controller) in the hot standby redundant group, the operating status of the hot standby redundant group, the cause of the abnormal operation of the hot standby redundant group, and the redundant scheduling results of the gateway controllers in the hot standby redundant group.
[0046] In some embodiments of the present application, a distributed controller is used to manage and control data transmission equipment or data acquisition equipment, and communicate with a main link gateway controller in a cold standby redundant group through an OPC DA (OLE for Process Control Data Access) protocol or an OPC UA (Open Platform Communications Unified Architecture) protocol, or communicate with a standby link gateway controller in a cold standby redundant group through an OPC DA protocol or an OPC UA protocol; the main link gateway controller in the cold standby redundant group is used to send a heartbeat signal to a redundant scheduling center, and the redundant scheduling center is used to determine the operating status of the main link gateway controller in the cold standby redundant group according to the heartbeat signal of the main link gateway controller in the cold standby redundant group, and perform redundant scheduling of the gateway controllers in the cold standby redundant group according to the operating status of the main link gateway controller in the cold standby redundant group and the historical activity data of the standby link gateway controller in the cold standby redundant group; the industrial Internet of Things platform is used to record the data of the active gateway (main link gateway controller or standby link gateway controller) in the cold standby redundant group, the operating status of the cold standby redundant group, the cause of the abnormal operation of the cold standby redundant group, and the redundant scheduling results of the gateway controllers in the cold standby redundant group.
[0047] The following describes a method embodiment of the present application, which can be applied to the redundant scheduling system in the above embodiment of the present application. For details not disclosed in the method embodiment of the present application, please refer to the above embodiment of the redundant scheduling system of the present application.
[0048] Reference Figure 3 As shown, the system architecture may include a storage device 301 and a computer device 302. The computer device 302 may be at least one of a desktop graphics processing unit (GPU) computer, a GPU computing cluster, a neural network computer, etc. Relevant technicians may use the computer device 302 to determine the operating state of the first main gateway controller according to the first heartbeat signal by using the heartbeat signal of the first main gateway controller as the first heartbeat signal, and the heartbeat signal of the first standby gateway controller as the second heartbeat signal; determine the operating state of the first standby gateway controller according to the second heartbeat signal, and perform redundant scheduling on the gateway controllers in the hot standby redundant group according to the operating state of the first main gateway controller and the operating state of the first standby gateway controller. The storage device 301 is used to store the first heartbeat signal and the second heartbeat signal. In this embodiment, the storage device 301 uses a random access memory (RAM) or the like to store the first heartbeat signal and the second heartbeat signal, and provides them to the computer device 302 for processing.
[0049] Illustratively, after obtaining the first heartbeat signal and the second heartbeat signal of the storage device 301, the computer device 302 uses the heartbeat signal of the first main gateway controller as the first heartbeat signal, determines the operating status of the first main gateway controller according to the first heartbeat signal, and uses the heartbeat signal of the first standby gateway controller as the second heartbeat signal; determines the operating status of the first standby gateway controller according to the second heartbeat signal, and performs redundant scheduling of the gateway controllers in the hot standby redundant group according to the operating status of the first main gateway controller and the operating status of the first standby gateway controller. The above process can realize redundant scheduling and switching between the first main gateway controller and the first standby gateway controller, effectively avoiding service interruption caused by a single gateway failure, thereby ensuring that the acquisition link or the transmission link maintains stable operation in a complex and changeable network environment, ensuring the continuity and integrity of user data, and improving the overall satisfaction and trust of users; and when the first main gateway controller fails, quickly switch to the first standby gateway controller, reducing the need for manual intervention, greatly shortening the fault recovery time, reducing the system's operation and maintenance costs, and improving the system's overall fault tolerance and availability.
[0050] It should be noted that the redundant scheduling method provided in the embodiment of the present application is generally executed by the computer device 302 , and accordingly, the redundant scheduling system is generally set in the computer device 302 .
[0051] The implementation details of the technical solution of the embodiment of the present application are described in detail below:
[0052] Figure 4 is a flowchart of a redundant scheduling method shown in an exemplary embodiment of the present application. The redundant scheduling method can be executed by a computing processing device. The computing processing device can be Figure 3 The computer device 302 shown in FIG. Figure 4 As shown, the redundant scheduling method at least includes steps S410 to S440, which are described in detail as follows:
[0053] In step S410, the heartbeat signal of the first main gateway controller and the heartbeat signal of the first standby gateway controller are obtained. In one embodiment of the present application, the first main gateway controller and the first standby gateway controller are both in a startup state, and the basic parameters of the gateway controller are configured, and the basic parameters include the communication protocol of the gateway controller, the redundancy group ID to which it belongs, the priority as an active gateway, the sending interval of the heartbeat signal, etc.
[0054] In step S420, the heartbeat signal of the first master gateway controller is used as the first heartbeat signal; the operating state of the first master gateway controller is determined according to the first heartbeat signal. In one embodiment of the present application, the heartbeat signal includes fields such as a redundancy group ID, a gateway ID, and a heartbeat timestamp, and the heartbeat timestamp is used to characterize the time interval for the gateway controller to send the heartbeat signal. The process of determining the operating state of the first master gateway controller according to the first heartbeat signal is implemented by an operating state determination module.
[0055] In step S430, the heartbeat signal of the first standby gateway controller is used as the second heartbeat signal; the operating state of the first standby gateway controller is determined according to the second heartbeat signal. In one embodiment of the present application, the process of determining the operating state of the first standby gateway controller according to the second heartbeat signal includes: if the second heartbeat signal includes the latest second heartbeat signal and the previous second heartbeat signal, then the time interval between the latest second heartbeat signal and the previous second heartbeat signal is calculated, recorded as the fourth time interval, and the time interval between the current moment and the timestamp of the latest second heartbeat signal is calculated, recorded as the fifth time interval; if the fourth time interval exceeds the preset interval threshold or the fifth time interval exceeds the preset time interval, the operating state of the first standby gateway controller is determined to be abnormal operation; if the fourth time interval does not exceed the preset interval threshold and the fifth time interval does not exceed the preset time interval, the operating state of the first standby gateway controller is determined to be normal operation. The process of determining the operating state of the first standby gateway controller according to the second heartbeat signal is also implemented by the operating state determination module.
[0056] In step S440, redundant scheduling is performed on the gateway controllers in the hot standby redundant group according to the operating status of the first main gateway controller and the operating status of the first standby gateway controller. In one embodiment of the present application, the process of redundant scheduling of the gateway controllers in the hot standby redundant group according to the operating status of the first main gateway controller and the operating status of the first standby gateway controller includes: if the current operating status of the first main gateway controller is abnormal operation, the active gateway is switched from the first main gateway controller to the first standby gateway controller that is operating normally; wherein, when there are multiple first standby gateway controllers that are operating normally, the latest heartbeat timestamp of each first standby gateway controller that is operating normally is obtained, the time interval between the time point corresponding to each latest heartbeat timestamp and the current moment is calculated, and the first standby gateway controller with the smallest time interval is used as the active gateway; if the current operating status of the first main gateway controller is normal operation, the first main gateway controller continues to be used as the active gateway.
[0057] In some embodiments of the present application, based on the operating status of the first main gateway controller and the operating status of the first standby gateway controller, redundant scheduling is performed on the gateway controllers in the hot standby redundant group to implement redundant scheduling and switching between the first main gateway controller and the first standby gateway controller, effectively avoiding service interruption caused by a single gateway failure, thereby ensuring that the acquisition link or transmission link maintains stable operation in a complex and changeable network environment, ensuring the continuity and integrity of user data, and improving the overall user satisfaction and trust; and when the first main gateway controller fails, quickly switching to the first standby gateway controller, reducing the need for manual intervention, greatly shortening the fault recovery time, reducing the system's operation and maintenance costs, and improving the system's overall fault tolerance and availability.
[0058] In one embodiment of the present application, the process of determining the operating state of the first master gateway controller according to the first heartbeat signal includes:
[0059] If the first heartbeat signal includes the latest heartbeat signal and the previous heartbeat signal, the time interval between the latest heartbeat signal and the previous heartbeat signal is calculated, recorded as the first time interval, and the time interval between the current moment and the timestamp of the latest heartbeat signal is calculated, recorded as the second time interval. In one embodiment of the present application, the first time interval is the time difference between the time point represented by the heartbeat timestamp in the latest heartbeat signal and the time point represented by the heartbeat timestamp in the previous heartbeat signal. The second time interval is the time difference between the current moment and the time point represented by the heartbeat timestamp in the latest heartbeat signal.
[0060] If the first time interval exceeds the preset interval threshold or the second time interval exceeds the preset time interval, the operation state of the first master gateway controller is determined to be abnormal. The preset interval threshold can be set according to actual conditions, for example, the preset interval threshold is set to 3 times the heartbeat signal sending interval.
[0061] If the first time interval does not exceed the preset interval threshold and the second time interval does not exceed the preset time interval, the operating state of the first master gateway controller is determined to be normal. In one embodiment of the present application, the operating state of the first master gateway controller is judged by the first time interval and the second time interval, so as to timely determine the latest operating state of the first master gateway controller.
[0062] In one embodiment of the present application, according to the operating state of the first main gateway controller and the operating state of the first standby gateway controller, the process of performing redundancy scheduling on the gateway controllers in the hot standby redundancy group includes:
[0063] If the current operating state of the first main gateway controller is abnormal operation, the active gateway is switched from the first main gateway controller to the first standby gateway controller that is operating normally. In one embodiment of the present application, when there are multiple first standby gateway controllers that are operating normally, the latest heartbeat timestamp of each first standby gateway controller that is operating normally is obtained, and the time interval between the time point corresponding to each latest heartbeat timestamp and the current moment is calculated, and the first standby gateway controller with the smallest time interval is used as the active gateway. Each first standby gateway controller that is operating normally sends multiple heartbeat signals, and each first standby gateway controller that is operating normally has the latest heartbeat signal, and the heartbeat timestamp in the latest heartbeat signal is the latest heartbeat timestamp.
[0064] If the current operating state of the first main gateway controller is normal, the first main gateway controller continues to be used as the active gateway. In one embodiment of the present application, in the hot standby mode, when the first main gateway controller fails, the first standby gateway controller can be quickly enabled without manual intervention, which greatly shortens the fault recovery time and improves the overall fault tolerance and availability of the system.
[0065] In one embodiment of the present application, the redundant scheduling method further includes:
[0066] Obtain the heartbeat signal of the second main gateway controller and the historical activity data of the second standby gateway controller. In one embodiment of the present application, the second main gateway controller is in a startup state, and the second standby gateway controller is in an unstarted state, that is, the cold standby redundancy group only supports a single-active mode. The historical activity data includes the startup duration and the time point of inactivity of the second standby gateway controller. The startup duration is used to characterize the startup performance of the second standby gateway controller, and the time point of inactivity is used to characterize the latest time point of the normal operation of the second standby gateway controller.
[0067] The heartbeat signal of the second main gateway controller is used as the third heartbeat signal; the operating state of the second main gateway controller is determined according to the third heartbeat signal. In one embodiment of the present application, the process of determining the operating state of the second main gateway controller according to the third heartbeat signal includes: if the third heartbeat signal includes the latest third heartbeat signal and the previous third heartbeat signal, then the time interval between the latest third heartbeat signal and the previous third heartbeat signal is calculated, recorded as the sixth time interval, and the time interval between the current moment and the timestamp of the latest third heartbeat signal is calculated, recorded as the seventh time interval; if the sixth time interval exceeds the preset interval threshold or the seventh time interval exceeds the preset time interval, the operating state of the second main gateway controller is determined to be abnormal operation; if the sixth time interval does not exceed the preset interval threshold and the seventh time interval does not exceed the preset time interval, the operating state of the second main gateway controller is determined to be normal operation. The process of determining the operating state of the second main gateway controller according to the third heartbeat signal is also implemented by the operating state determination module.
[0068] According to the operating status of the second main gateway controller and the historical activity data of the second standby gateway controller, the gateway controllers in the cold standby redundant group are redundantly scheduled. In one embodiment of the present application, according to the operating status of the second main gateway controller and the historical activity data of the second standby gateway controller, the process of redundantly scheduling the gateway controllers in the cold standby redundant group includes: if the operating status of the second main gateway controller is abnormal operation, then the startup duration and the stop activity time point of the second standby gateway controller are determined from the historical activity data; according to the startup duration and the stop activity time point, the selection weight of the second standby gateway controller is determined; and the second standby gateway controller with the largest selection weight is used as the target gateway controller; the target gateway controller is started, and the active gateway is switched from the second main gateway controller to the target gateway controller; if the operating status of the second main gateway controller is normal operation, the second main gateway controller continues to be used as the active gateway. In the cold standby mode, when the second main gateway controller fails, the second standby gateway controller can be quickly enabled without manual intervention, which greatly shortens the fault recovery time and improves the overall fault tolerance and availability of the system.
[0069] In one embodiment of the present application, the process of determining the selection weight of the second standby gateway controller according to the startup duration and the inactivity stop time point includes:
[0070] In one embodiment of the present application, the duration reference value is negatively correlated with the startup duration, that is, the longer the startup duration, the smaller the duration reference value, and the shorter the startup duration, the larger the duration reference value, thereby highlighting the superiority of the startup performance of the gateway controller.
[0071] The time interval between the current moment and the time point of stopping the activity is calculated and recorded as the third time interval, and the time reference value is determined according to the third time interval. In one embodiment of the present application, the time reference value is negatively correlated with the third time interval, that is, the larger the third time interval is, the smaller the time reference value is, and the smaller the third time interval is, the larger the time reference value is, so as to highlight the gateway controller that is closest to the current moment as the active gateway, and the gateway controller has a smaller probability of abnormality.
[0072] Based on the duration reference value and the preset duration weight, the time reference value and the preset time weight, the selection weight is determined. In one embodiment of the present application, the sum of the preset duration weight and the preset time weight is a preset value, and the preset value can be 1 or other values. The calculation process of the selection weight includes: calculating the product of the duration reference value and the preset duration weight, calculating the product of the time reference value and the preset time weight, adding the product of the duration reference value and the preset duration weight to the product of the time reference value and the preset time weight to obtain the selection weight. The second standby gateway controller with the largest selection weight has a smaller startup time and a smaller probability of abnormality. Therefore, when the second main gateway controller fails, the active gateway is switched from the second main gateway controller to the second standby gateway controller with the largest selection weight, thereby improving the switching rate and switching success rate between the second main gateway controller and the target gateway controller, greatly shortening the fault recovery time, and improving the automation and intelligence of the system.
[0073] Figure 5 is an interactive flow chart between a redundant scheduling platform and an edge gateway controller shown in an exemplary embodiment of the present application, such as Figure 5 As shown in the figure, the interaction process between the redundant scheduling platform and the edge gateway controller includes: (1) the gateway controller in the startup state sends a heartbeat signal to the redundant scheduling center; (2) the redundant scheduling center responds to the heartbeat signal of the gateway controller in the startup state; (3) it is determined whether the operation status of the redundant group is abnormal; (4) if the operation status of the redundant group is abnormal, the gateway controller is switched or the gateway controller is started first and then switched; (5) it is determined whether the gateway control is switched successfully; (6) if the gateway controller is switched successfully, the switching result of the gateway controller, the current active gateway, the operation status of the redundant group, etc. are broadcast to the gateway controller in the startup state; (7) the redundant scheduling center sends a message to the network controller in the startup state. The gateway controller sends a heartbeat signal reception success and redundant scheduling results, and the gateway controller in the startup state determines whether the active gateway is itself based on the redundant scheduling results; (8) If the gateway controller fails to switch successfully, the redundant scheduling center sends a heartbeat signal reception success and redundant scheduling results to the gateway controller in the startup state, and the gateway controller in the startup state determines whether the active gateway is itself based on the redundant scheduling results; (9) If the operating status of the redundant group is normal, the redundant scheduling center sends a heartbeat signal reception success and redundant scheduling results to the gateway controller in the startup state, and the gateway controller in the startup state determines whether the active gateway is itself based on the redundant scheduling results; (10) Respond to the redundant scheduling results.
[0074] In some embodiments of the present application, the gateway controller in the startup state includes the main link gateway controller in the hot standby redundant group, the backup link gateway controller in the hot standby redundant group, and the main link gateway controller in the cold standby redundant group. The process of judging whether the operation state of the redundant group is abnormal according to the heartbeat signal of the gateway controller in the startup state includes: judging whether the operation state of the hot standby redundant group is abnormal according to the heartbeat signal of the main link gateway controller in the hot standby redundant group and the heartbeat signal of the backup link gateway controller in the hot standby redundant group; judging whether the operation state of the cold standby redundant group is abnormal according to the heartbeat signal of the main link gateway controller in the cold standby redundant group. If the operation state of the hot standby redundant group is abnormal, switch the gateway controller; if the operation state of the cold standby redundant group is abnormal, start the gateway controller first and then switch the gateway controller.
[0075] In some embodiments of the present application, if the response of a gateway controller in a startup state times out, it can be tested by plugging and unplugging the network cable of the gateway controller in a startup state. If there is still no successful response after plugging and unplugging for a preset number of consecutive times, it is necessary to reselect an active gateway; session disconnection detection can also be performed by closing the process.
[0076] In some embodiments of the present application, after each gateway controller is started, it is not an active gateway and must be notified by the redundant scheduling center to be upgraded to an active gateway.
[0077] Figure 6 is a flowchart of redundant scheduling of gateway controllers in a redundant group shown in an exemplary embodiment of the present application. Figure 6 In the process of redundant scheduling of gateway controllers in a redundant group, the process includes: (1) performing regular detection on the operating status of the gateway controller in the redundant group that is in the startup state; (2) determining the operating status of the redundant group according to the operating status of the gateway controller in the startup state; (3) judging whether the operating status of the cold standby redundant group or the hot standby redundant group is normal; (4) if the operating status of the cold standby redundant group or the hot standby redundant group is normal, the redundant scheduling process ends; (5) if the cold standby redundant group operates abnormally, it is necessary to ensure that at least one gateway controller operates normally and is an active gateway, and shut down other gateway controllers; (6) if the hot standby redundant group operates abnormally, it is necessary to ensure that at least one gateway controller operates normally, and control other gateway controllers to be turned on or off according to the single-active mode, and control other gateway controllers to be turned on or off according to the multi-active mode; (7) broadcasting the switching result of the gateway controller, the current active gateway, the operating status of the redundant group, etc. to the gateway controller in the startup state in the redundant group.
[0078] In some embodiments of the present application, the redundancy scheduling center should set a scheduled task to regularly check the operating status of the redundancy group. If an abnormal operation of the redundancy group is detected, recovery measures should be taken immediately, such as starting a standby gateway device, switching an active gateway, or re-evaluating the operating status of the current active gateway after switching the active gateway.
[0079] In some embodiments of the present application, when the redundancy group operates normally and there is an active gateway, the industrial Internet of Things platform receives data from the active gateway and processes and stores the data. After discovering that the active gateway is operating abnormally or fails, the industrial Internet of Things platform can quickly switch to a new active gateway to ensure that data collection is not interrupted, and promptly record all state changes after switching the active gateway for subsequent analysis.
[0080] This application significantly improves the high availability, flexibility and maintainability of the system, thereby achieving the high efficiency and accuracy of the data acquisition or transmission system. The data acquisition or transmission system can effectively cope with the impact of equipment failures and network interruptions, ensuring the reliability and stability of data acquisition or transmission.
[0081] It should be noted that the redundant scheduling method provided in the above embodiment and the redundant scheduling system provided in the above embodiment belong to the same concept, wherein the specific manner in which each module and unit performs the operation has been described in detail in the method embodiment, and will not be repeated here. In practical applications, the redundant scheduling method provided in the above embodiment can allocate the above functions to different functional modules as needed, that is, divide the internal structure of the device into different functional modules to complete all or part of the functions described above, and this is not limited here.
[0082] An embodiment of the present application also provides an electronic device, comprising: one or more processors; a storage device for storing one or more programs, and when the one or more programs are executed by one or more processors, the electronic device implements the redundant scheduling method provided in the above-mentioned embodiments.
[0083] Figure 7 The structure diagram of the computer system of the computer readable storage medium suitable for implementing the embodiment of the present application is shown. It should be noted that: Figure 7 The computer system 700 of the computer-readable storage medium shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.
[0084] like Figure 7As shown, the computer system 700 includes a central processing unit (CPU) 701, which can perform various appropriate actions and processes according to the program stored in the read-only memory (ROM) 702 or the program loaded from the storage part 708 to the random access memory (RAM) 703, such as executing the method in the above embodiment. In the RAM 703, various programs and data required for system operation are also stored. The CPU 701, the ROM 702 and the RAM 703 are connected to each other through the bus 704. The input / output (I / O) interface 705 is also connected to the bus 704.
[0085] The following components are connected to the I / O interface 705: an input section 706 including a keyboard, a mouse, etc.; an output section 707 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage section 708 including a hard disk, etc.; and a communication section 709 including a network interface card such as a LAN (Local Area Network) card, a modem, etc. The communication section 709 performs communication processing via a network such as the Internet. A drive 710 is also connected to the I / O interface 705 as needed. A removable medium 711, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 710 as needed so that a computer program read therefrom is installed into the storage section 708 as needed.
[0086] In particular, according to an embodiment of the present application, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present application includes a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a computer program for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network through a communication section 709, and / or installed from a removable medium 711. When the computer program is executed by a central processing unit (CPU) 701, various functions defined in the system of the present application are executed.
[0087] It should be noted that the computer-readable medium shown in the embodiment of the present application can be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium can be, for example, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media can include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM), a flash memory, an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present application, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, wherein a computer-readable computer program is carried. This propagated data signal can take a variety of forms, including but not limited to an electromagnetic signal, an optical signal, or any suitable combination of the above. A computer-readable signal medium may also be any computer-readable medium other than a computer-readable storage medium, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. A computer program contained on a computer-readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wired, etc., or any suitable combination of the above.
[0088] The flowchart and block diagram in the accompanying drawings illustrate the possible architecture, functions and operations of the system, method and computer program product according to various embodiments of the present application. Wherein, each box in the flowchart or block diagram can represent a module, a program segment, or a part of the code, and the above-mentioned module, program segment, or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram or flowchart, and the combination of boxes in the block diagram or flowchart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0089] The units involved in the embodiments described in this application may be implemented by software or hardware, and the units described may also be set in a processor. The names of these units do not, in some cases, constitute limitations on the units themselves.
[0090] Another aspect of the present application provides a computer-readable storage medium having computer-readable instructions stored thereon, and when the computer-readable instructions are executed by a processor of a computer, the computer is caused to execute the redundant scheduling method provided in each of the above embodiments. The computer-readable storage medium may include the electronic device described in the above embodiments, or may exist alone without assembling the electronic device described in the above embodiments into the computer-readable storage medium.
[0091] It should be noted that, although several modules or units of the equipment for action execution are mentioned in the above detailed description, this division is not mandatory. In fact, according to the embodiments of the present application, the features and functions of two or more modules or units described above can be embodied in one module or unit. On the contrary, the features and functions of one module or unit described above can be further divided into being embodied by multiple modules or units.
[0092] Through the description of the above implementation methods, it is easy for those skilled in the art to understand that the example implementation methods described here can be implemented by software or by combining software with necessary hardware. Therefore, the technical solution according to the implementation methods of the present application can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.) or on a network, and includes several instructions to enable a computing device (which can be a personal computer, a server, a touch terminal, or a network device, etc.) to execute the method according to the implementation methods of the present application.
[0093] Those skilled in the art will readily appreciate other embodiments of the present application after considering the specification and practicing the embodiments disclosed herein. The present application is intended to cover any variations, uses or adaptations of the present application, which follow the general principles of the present application and include common knowledge or customary technical means in the art that are not disclosed in the present application.
[0094] It should be understood that the above content is only a preferred exemplary embodiment of the present application and is not intended to limit the implementation scheme of the present application. Ordinary technicians in this field can easily make corresponding changes or modifications based on the main concept and spirit of the present application. Therefore, the scope of protection of the present application should be based on the scope of protection required by the claims.
Claims
1. A redundant scheduling system, characterized in that: include: A hot standby redundant group, comprising a first main gateway controller and a first standby gateway controller in a startup state, wherein the first main gateway controller is used to send a heartbeat signal to a redundant scheduling center, recorded as a first heartbeat signal; and the first standby gateway controller is used to send a heartbeat signal to the redundant scheduling center, recorded as a second heartbeat signal; A cold standby redundancy group, comprising a second main gateway controller in a startup state and a second standby gateway controller that is not in a startup state, wherein the second main gateway controller is used to send a heartbeat signal to the redundant scheduling center, which is recorded as a third heartbeat signal; A redundant scheduling platform is used to determine the operating status of the first main gateway controller according to the first heartbeat signal; determine the operating status of the first standby gateway controller according to the second heartbeat signal; and perform redundant scheduling of the gateway controllers in the hot standby redundant group according to the operating status of the first main gateway controller and the operating status of the first standby gateway controller; and determine the operating status of the second main gateway controller according to the third heartbeat signal, and perform redundant scheduling of the gateway controllers in the cold standby redundant group according to the operating status of the second main gateway controller and the historical activity data of the second standby gateway controller.
2. The redundant scheduling system according to claim 1, characterized in that: The redundant scheduling platform also includes: determining the operating state of the hot standby redundant group according to the operating state of the first main gateway controller and the operating state of the first standby gateway controller; wherein, when the operating state of at least one of the first main gateway controller and the first standby gateway controller is operating normally, the operating state of the hot standby redundant group is determined to be operating normally; when the operating state of the first main gateway controller is operating abnormally and the operating state of the first standby gateway controller is operating abnormally, the operating state of the hot standby redundant group is determined to be operating abnormally; And, according to the operating state of the second main gateway controller, determining the operating state of the cold standby redundant group; wherein, when the operating state of the second main gateway controller is normal operation, the operating state of the cold standby redundant group is determined to be normal operation; when the operating state of the second main gateway controller is abnormal operation, the operating state of the cold standby redundant group is determined to be abnormal operation; And, broadcasting the operating status of the first main gateway controller, the operating status of the first standby gateway controller, the operating status of the second main gateway controller, the operating status of the hot standby redundant group, the operating status of the cold standby redundant group, the redundant scheduling results of the gateway controllers in the hot standby redundant group, or the redundant scheduling results of the gateway controllers in the cold standby redundant group to the gateway controller in the startup state.
3. The redundant scheduling system according to claim 2, characterized in that: The redundant scheduling system also includes: An Internet of Things platform, for responding to the request of the first main gateway controller to send the first heartbeat signal and storing the first heartbeat signal; and, responding to the request of the second main gateway controller to send the third heartbeat signal and storing the third heartbeat signal; and, storing the operating status of the hot standby redundant group, and when the operating status of the hot standby redundant group is abnormal operation, recording the reason for the abnormal operation of the hot standby redundant group; and, storing the operating status of the cold standby redundant group, and when the operating status of the cold standby redundant group is abnormal operation, recording the reason for the abnormal operation of the cold standby redundant group; and, recording the redundant scheduling results of the gateway controllers in the hot standby redundant group, or, recording the redundant scheduling results of the gateway controllers in the cold standby redundant group.
4. A redundant scheduling method, characterized in that: include: Obtaining the heartbeat signal of the first master gateway controller and the heartbeat signal of the first standby gateway controller; The first main gateway controller and the first standby gateway controller are both in a startup state; Using the heartbeat signal of the first master gateway controller as the first heartbeat signal; Determining the operating state of the first master gateway controller according to the first heartbeat signal; Using the heartbeat signal of the first standby gateway controller as the second heartbeat signal; Determining the operating state of the first standby gateway controller according to the second heartbeat signal; Redundancy scheduling is performed on the gateway controllers in the hot standby redundancy group according to the operating status of the first main gateway controller and the operating status of the first standby gateway controller.
5. The redundant scheduling method according to claim 4, characterized in that: The process of determining the operating state of the first master gateway controller according to the first heartbeat signal includes: If the first heartbeat signal includes the latest heartbeat signal and the previous heartbeat signal, then the time interval between the latest heartbeat signal and the previous heartbeat signal is calculated, recorded as the first time interval, and the time interval between the current time and the timestamp of the latest heartbeat signal is calculated, recorded as the second time interval; If the first time interval exceeds a preset interval threshold or the second time interval exceeds the preset time interval, determining that the operation state of the first master gateway controller is abnormal operation; If the first time interval does not exceed the preset interval threshold and the second time interval does not exceed the preset time interval, it is determined that the operating status of the first master gateway controller is normal.
6. The redundant scheduling method according to claim 4, characterized in that: The process of performing redundancy scheduling on the gateway controllers in the hot standby redundancy group according to the operating status of the first main gateway controller and the operating status of the first standby gateway controller includes: If the current operating state of the first main gateway controller is abnormal operation, the active gateway is switched from the first main gateway controller to the first standby gateway controller that is operating normally; wherein, when there are multiple first standby gateway controllers that are operating normally, the latest heartbeat timestamp of each first standby gateway controller that is operating normally is obtained, and the time interval between the time point corresponding to each latest heartbeat timestamp and the current time is calculated, and the first standby gateway controller with the smallest time interval is used as the active gateway; If the current operating status of the first master gateway controller is normal, the first master gateway controller continues to be used as the active gateway.
7. The redundant scheduling method according to any one of claims 4 to 6, characterized in that: The method further comprises: Acquire the heartbeat signal of the second main gateway controller and the historical activity data of the second standby gateway controller; the second main gateway controller is in the startup state; the second standby gateway controller is in the non-startup state; Using the heartbeat signal of the second master gateway controller as the third heartbeat signal; and determining the operating state of the second master gateway controller according to the third heartbeat signal; Redundancy scheduling is performed on the gateway controllers in the cold standby redundancy group according to the running status of the second main gateway controller and the historical activity data of the second standby gateway controller.
8. The redundant scheduling method according to claim 7, characterized in that: The process of performing redundancy scheduling on the gateway controllers in the cold standby redundancy group according to the running state of the second main gateway controller and the historical activity data of the second standby gateway controller includes: If the operation status of the second main gateway controller is abnormal operation, determine the startup duration and the inactivity time point of the second standby gateway controller from the historical activity data; determine the selection weight of the second standby gateway controller according to the startup duration and the inactivity time point; and use the second standby gateway controller with the largest selection weight as the target gateway controller; start the target gateway controller, and switch the active gateway from the second main gateway controller to the target gateway controller; If the operating status of the second main gateway controller is normal, the second main gateway controller continues to be used as the active gateway.
9. The redundant scheduling method according to claim 8, characterized in that: The process of determining the selection weight of the second standby gateway controller according to the startup duration and the inactivity stop time point includes: Determine a duration reference value according to the startup duration; the duration reference value is negatively correlated with the startup duration; Calculate the time interval between the current moment and the activity stopping time point, record it as a third time interval, and determine a time reference value according to the third time interval; the time reference value is negatively correlated with the third time interval; The selection weight is determined based on the duration reference value and the preset duration weight, the time reference value and the preset time weight.
10. An electronic device, characterized in that: include: one or more processors; A storage device for storing one or more programs, when the one or more programs are executed by the one or more processors, enables the electronic device to implement the redundant scheduling method as described in any one of claims 4 to 9.
Citation Information
Patent Citations
Cold backup and hot backup combined double-host command and control system
CN104199353A
Dual-redundancy unmanned aerial vehicle brake controller and cold standby control method
CN109212958A
Switching control method, system and apparatus
CN111965968A
Cross backup high-performance satellite-borne data processing system control method
CN117724908A
Dual-computer redundancy communication method and system
CN118331026A