Tunnel comprehensive management and control platform construction method and system
By constructing node-device and device-protocol mapping tables and combining them with a tunnel network knowledge graph, the problems of device management interruption and protocol incompatibility under tunnel node failure were solved. This enabled automated and efficient device migration, ensuring the communication reliability and device management continuity of the tunnel network.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-12
- Publication Date
- 2026-03-24
AI Technical Summary
Traditional methods lack structured modeling of the relationships between tunnel nodes, devices, and protocols, leading to interruptions in device management, reduced communication reliability, low device migration efficiency, and communication failures caused by protocol conflicts at faulty nodes.
A node-device mapping table and a device-protocol mapping table are constructed to form a tunnel network knowledge graph. The mapping table is used to quickly locate the device to be taken over. The optimal takeover node is intelligently selected based on protocol matching metric calculation, realizing the automation and accuracy of device migration. Protocol incompatibility issues are resolved through a protocol conversion mechanism.
It significantly improves fault response speed, increases equipment migration efficiency, reduces adaptation complexity, ensures communication reliability and equipment management continuity in tunnel networks, and adapts to the needs of expanding tunnel network scale and diversifying equipment protocols.
Smart Images

Figure CN121309368B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of tunnel comprehensive management and control, and more particularly to a tunnel comprehensive management and control platform construction method and system. BACKGROUND
[0002] In the field of tunnel comprehensive management and control, tunnel node failure will cause the tunnel equipment under its jurisdiction to lose management, and the protocols supported by the tunnel equipment are diverse, and the protocols supported by different tunnel nodes are different, so that the equipment to be taken over under the failed node may not be normally taken over due to protocol incompatibility, resulting in interruption of equipment management, decline of communication reliability, and difficulty in meeting the high real-time requirements of the tunnel monitoring system.
[0003] The traditional method lacks structured modeling of the association relationship between tunnel nodes, equipment and protocols, and it is difficult to quickly locate the equipment to be taken over and evaluate its protocol compatibility with the normal node when a fault occurs, resulting in low efficiency of equipment migration, complex adaptation process, and even communication failure due to protocol conflicts. With the expansion of the tunnel network scale and the diversification of equipment protocols, efficient handling of equipment migration and protocol compatibility problems during node failure has become a key to ensuring the safe and stable operation of tunnels.
[0004] In view of this, the present application proposes a tunnel comprehensive management and control platform construction method and system to solve the above problems. SUMMARY
[0005] In order to overcome the problem that the traditional method lacks structured modeling of the association relationship between tunnel nodes, equipment and protocols, and it is difficult to quickly locate the equipment to be taken over and evaluate its protocol compatibility with the normal node when a fault occurs, resulting in low efficiency of equipment migration, complex adaptation process, and even communication failure due to protocol conflicts, the present application provides the following technical solution: a tunnel comprehensive management and control platform construction method, comprising:
[0006] Based on the collected tunnel node information, tunnel equipment information and protocol information, a node-equipment mapping table and a device-protocol mapping table are constructed, and a tunnel network knowledge graph is constructed using the two mapping tables;
[0007] When a failed tunnel node occurs, the tunnel equipment under the failed tunnel node is obtained and marked as equipment to be taken over, and the protocols supported by the normal tunnel node are obtained and marked as matchable protocols;
[0008] The equipment to be taken over is matched with the matchable protocols, the normal tunnel node with the highest protocol matching degree with the equipment to be taken over is found and marked as the takeover tunnel node, and a mapping table of the equipment to be taken over and the takeover node is constructed;
[0009] The to-be-taken-over device incompatible with the matchable protocol is identified based on the to-be-taken-over device-tunnel node mapping table, marked as an incompatible device, a tunnel node supporting the protocol of the incompatible device is found, and the to-be-taken-over device-tunnel node mapping table is updated, and migration of the to-be-taken-over device to the tunnel node is completed according to the to-be-taken-over device-tunnel node mapping table.
[0010] Further, if the incompatible device cannot find a tunnel node supporting the protocol thereof, a protocol conversion instruction is triggered, a normal tunnel node is selected and marked as a convertible node; the device to which the convertible node belongs is migrated to another normal tunnel node; the protocol corresponding to the incompatible device is installed in the convertible node according to the protocol conversion instruction, the incompatible device is migrated to the convertible node, and the to-be-taken-over device-tunnel node mapping table is updated.
[0011] Further, the method for finding a tunnel node supporting the protocol of the incompatible device comprises:
[0012] The protocol ID of the incompatible device is extracted from the device-protocol mapping table to construct an incompatible device-protocol set;
[0013] The support protocol set is generated by merging and deduplicating through the association query of the node-device mapping table and the device-protocol mapping table;
[0014] The match degree score is calculated based on the intersection of the incompatible device-protocol set and the support protocol set to construct an incompatible device-node match degree set;
[0015] The optimal candidate tunnel node for each incompatible device is screened out according to the match degree score in the incompatible device-node match degree set to construct a tunnel device-candidate tunnel node mapping temporary table;
[0016] The tunnel device-candidate tunnel node mapping temporary table is merged into the device-tunnel node mapping table;
[0017] The tunnel device migration is performed according to the device-tunnel node mapping table.
[0018] Further, the method for constructing the to-be-taken-over device-tunnel node mapping table comprises:
[0019] The protocol match degree is obtained by calculating the ratio of the number of intersections of each to-be-taken-over device and the matchable protocol to the total number of protocols to construct a protocol match degree set;
[0020] The optimal tunnel node for each tunnel device is found from the protocol match degree set according to the match degree to construct the to-be-taken-over device-tunnel node mapping table.
[0021] Further, when a fault tunnel node appears, tunnel devices under the fault tunnel node are obtained, marked as to-be-taken-over devices, and protocols supported by normal tunnel nodes are obtained, marked as matchable protocols, and the method comprises the following steps:
[0022] A fault tunnel node ID is screened out, and a fault tunnel node set is constructed;
[0023] According to the node-device mapping table and the fault tunnel node set, the device ID of the tunnel device under the fault tunnel node is obtained, and a to-be-taken-over device set is constructed;
[0024] A normal tunnel node ID is screened out, and a normal tunnel node set is constructed;
[0025] The protocol ID of the tunnel device under the jurisdiction of the normal tunnel node is obtained by using the node-device mapping table and the device-protocol mapping table, and the matchable protocols are obtained after all the protocol IDs are combined and de-duplicated.
[0026] Further, the method for constructing the node-device mapping table and the device-protocol mapping table comprises the following steps:
[0027] According to the tunnel node ID to which the tunnel device belongs, the ownership relationship between the tunnel node and the tunnel device is established in the node-device mapping table, the tunnel device ID is stored according to the tunnel node ID, and the node-device mapping table is constructed;
[0028] The protocol supported by the tunnel device is extracted, the association relationship between the tunnel device and the protocol is established in the device-protocol mapping table, and the device-protocol mapping table is constructed.
[0029] Further, the method for constructing the tunnel network knowledge graph comprises the following steps:
[0030] Three types of entities, tunnel nodes, tunnel devices and protocols, and two types of relationships, jurisdiction and support, are defined;
[0031] The node-device mapping table is traversed, tunnel node and tunnel device entities are created in the tunnel network knowledge graph, corresponding attributes are added, the jurisdiction relationship between the tunnel node and the tunnel device is established, and the node-device mapping table is constructed;
[0032] The device-protocol mapping table is traversed, the corresponding tunnel device entity is found, the protocol entity is created and the attribute is added, the support relationship between the tunnel device and the protocol is established, and the complete tunnel network knowledge graph is obtained.
[0033] Further, the tunnel node information comprises a tunnel node ID and a tunnel node state; the tunnel device information comprises a tunnel device ID, a tunnel node to which the tunnel device belongs, and a supported protocol; and the protocol information comprises a protocol ID, a name and a characteristic.
[0034] The tunnel comprehensive management and control platform construction system is used for realizing a tunnel comprehensive management and control platform construction method, and comprises the following steps:
[0035] The knowledge graph construction module is used for constructing a node-device mapping table and a device-protocol mapping table based on the collected tunnel node information, tunnel device information and protocol information, and constructing a tunnel network knowledge graph by using the two mapping tables.
[0036] The node information acquisition module is used for acquiring tunnel devices under a fault tunnel node when the fault tunnel node occurs, marking the tunnel devices as to-be-taken-over devices, and acquiring protocols supported by normal tunnel nodes, marking the protocols as matchable protocols.
[0037] The node adaptation module is used for matching the to-be-taken-over devices with the matchable protocols, finding a normal tunnel node with the highest protocol matching degree with the to-be-taken-over devices, marking the normal tunnel node as a takeover tunnel node, and constructing a to-be-taken-over device-takeover node mapping table.
[0038] The migration verification module is used for identifying to-be-taken-over devices that are incompatible with the matchable protocols based on the to-be-taken-over device-takeover node mapping table, marking the to-be-taken-over devices as incompatible devices, finding tunnel nodes supporting protocols of the incompatible devices, updating the to-be-taken-over device-takeover node mapping table, and completing migration of the to-be-taken-over devices to the takeover tunnel nodes according to the to-be-taken-over device-takeover node mapping table.
[0039] Compared with the prior art, the tunnel comprehensive management and control platform construction method and system have the following technical effects and advantages:
[0040] By constructing a node-device mapping table, a device-protocol mapping table and a tunnel network knowledge graph, a structured data model of the association relationship among tunnel nodes, devices and protocols is formed, the problem of fuzzy data association in traditional methods is solved, the set of devices to be taken over can be quickly located when a fault occurs through the mapping table, and a protocol library that can be matched is generated based on normal node protocol support information, which significantly improves the fault response speed. The scheme introduces a protocol matching quantification mechanism, intelligently filters the optimal takeover node through the intersection analysis of device protocols and node protocols, changes the inefficient mode of relying on manual evaluation or simple matching in traditional methods, realizes the automation and precision of device migration, and greatly improves the migration efficiency and reduces the adaptation complexity. For protocol incompatible devices, the node protocol support capability is dynamically expanded through network protocol support node retrieval and protocol conversion mechanism, communication failure caused by protocol conflict is avoided, and a closed-loop processing flow from fault detection, device matching to migration verification is formed. In the face of the expansion of the scale of the tunnel network and the diversification trend of device protocols, the structured modeling and intelligent adaptation strategy of the scheme have good scalability, can efficiently handle the device migration demand in complex network environment, ensure the continuity of device management and communication reliability when the tunnel node fails, provide a solid support for the high real-time data transmission requirements of the tunnel monitoring system, and fundamentally solve the technical bottlenecks of the traditional method in protocol compatibility evaluation and migration strategy formulation. BRIEF DESCRIPTION OF DRAWINGS
[0041] Figure 1 A system schematic diagram of the tunnel comprehensive management and control platform of embodiment 1 of the present application is shown in the figure.
[0042] Figure 2 A flow chart of the tunnel comprehensive management and control platform construction method of embodiment 3 of the present application is shown in the figure.
[0043] Figure 3 A flow chart of the protocol conversion method of embodiment 2 of the present application is shown in the figure.
[0044] Figure 4 A migration flow chart of incompatible devices of embodiment 1 of the present application is shown in the figure. DETAILED DESCRIPTION
[0045] The technical solutions in the embodiments of the present application will be described in detail, clearly and completely below with reference to the drawings in the embodiments of the present application. It should be particularly noted that the specific embodiments described below are only used to better illustrate and describe the technical solutions of the present application, and are intended to enable those skilled in the art to better understand and implement the present application, and should not be understood as limiting the protection scope of the present application. Those skilled in the art can modify, adjust or equivalently replace them according to the content disclosed in the present application without departing from the spirit and essence of the present application, and these should be regarded as the protection scope of the present application.
[0046] Embodiment 1
[0047] Referring to Figure 1 As shown in the figure, the embodiment discloses a tunnel comprehensive management and control platform construction system, which comprises a knowledge graph construction module, a node information acquisition module, a node adaptation module and a migration verification module. The modules are connected by wire and / or wireless connection to realize data transmission.
[0048] The knowledge graph construction module constructs a node-device mapping table and a device-protocol mapping table based on the collected tunnel node information, tunnel device information and protocol information, and constructs a tunnel network knowledge graph using the two mapping tables.
[0049] The tunnel node information includes tunnel node ID and tunnel node state; the tunnel device information includes tunnel device ID, belonging tunnel node and supported protocol; and the protocol information includes protocol ID, name and characteristics.
[0050] The collection method of the tunnel node information, the tunnel device information and the protocol information comprises:
[0051] The collection tool and the connection are initialized. When collecting for the first time, the system will acquire the access parameters of the tunnel node scanning tool, the tunnel device management system and the protocol database according to the preset configuration information. The initialization interface of the tunnel node scanning tool is called, and the scanning range is configured, including the tunnel network IP segment, the scanning frequency and the tunnel node state. In this embodiment, the scanning frequency is set to 1 time / s to avoid network congestion, and the control message protocol is used for detecting the protocol.
[0052] The tunnel node scanning tool is started, Ping detection is performed on all tunnel nodes in the tunnel network, and the IP addresses of the responding tunnel nodes are recorded. For each responding tunnel node, the tunnel node ID and the tunnel node state are acquired through the simple network management protocol or the API provided by the tunnel node itself, and the tunnel node state is used to determine whether the tunnel node is in a normal state or a fault state. The tunnel node information set is outputted, and the format is [{tunnel node ID: string type, tunnel node state: normal or fault}]. For example, [{tunnel node ID: TN001, tunnel node state: normal}, {tunnel node ID: TN002, tunnel node state: fault}].
[0053] The tunnel node ID is used to uniquely identify the network entity, and the tunnel node state is the core basis for subsequent fault detection. The output list provides basic data for constructing the tunnel node state library.
[0054] Connect the handle of the tunnel device management system, query the tunnel device registry, get the tunnel device ID and the tunnel node ID it belongs to, and match the tunnel node ID in the tunnel node information set to filter invalid associations, and the protocol list supported by the tunnel device, stored in the form of protocol ID array; Record error log for tunnel device records that do not match valid tunnel node IDs, and do not include valid data temporarily. Output the tunnel device information set, format [{tunnel device ID: string type, tunnel node ID: string type, supported protocol: [string type]}], for example, the list contains [{tunnel device ID: TD001, tunnel node ID: TN001, supported protocol: [TP001, TP002]}, {tunnel device ID: TD002, tunnel node ID: TN002, supported protocol: [TP003]}].
[0055] The tunnel node ID it belongs to reflects the ownership relationship between the tunnel device and the tunnel node, which is the core field of subsequent tunnel node-tunnel device mapping, and the supported protocol list is the key input for judging the compatibility of the tunnel device.
[0056] Execute the protocol database query statement, for example, SELECT protocol ID, protocol name, protocol characteristics FROM support protocol list; In this query statement, SELECT is used to specify the specific information to be extracted from the database, which specifies that the protocol ID, protocol name and protocol characteristics fields are to be obtained, and the protocol characteristics field stores structured information containing encapsulation format, version number and encryption algorithm, etc., and is presented in JSON format; And FROM is used to indicate the database table where these fields to be queried are located, which means that the data of the above fields comes from the table named support protocol list, and the FROM determines the source location of the data, so that the query can accurately find the corresponding data set to extract information. For each protocol ID, check in the tunnel device information set whether there is a tunnel device supporting the protocol, and if not supported by any tunnel device, mark it as unused. Output the tunnel device information set, format [{protocol ID: string type, protocol name: string type, protocol characteristics: object type}], for example, [{protocol ID: TP001, protocol name: Tunnel Protocol 1, protocol characteristics: {encapsulation format: IPsec, version number: 2.0, encryption algorithm: DES}}, {protocol ID: TP002, protocol name: Tunnel Protocol 2, protocol characteristics: {encapsulation format: GRE, version number: 1.0, encryption algorithm: AES-128}, status: unused}].
[0057] Protocol ID serves as a bridge between tunnel device-protocol mapping, and protocol characteristics are used for subsequent compatibility matching, such as version number comparison and algorithm adaptation.
[0058] Through the above steps, the system completes the collection of three types of basic data of tunnel nodes, tunnel devices and protocols. The initialization tool provides a channel for collection, tunnel node information defines the existence and state of network entities, tunnel device information establishes the ownership relationship between entities and protocol support capability, and protocol information supplements the description of the bottom layer communication rules. These standardized data structures provide a reliable input basis for subsequent construction of mapping table, tunnel network knowledge graph and fault handling logic, ensuring that the entire system can quickly locate tunnel devices, match protocols and execute migration strategies when tunnel nodes fail.
[0059] The method for constructing the node-device mapping table and the device-protocol mapping table comprises:
[0060] According to the tunnel node ID to which the tunnel device belongs, the ownership relationship between the tunnel node and the tunnel device is established in the node-device mapping table, the tunnel device ID is stored according to the tunnel node ID, and the node-device mapping table is constructed;
[0061] The protocols supported by the tunnel device are extracted, the association relationship between the tunnel device and the protocol is established in the device-protocol mapping table, and the device-protocol mapping table is constructed.
[0062] For example, by creating two empty dictionary structures as initial containers, one as a node-device mapping table and the other as a device-protocol mapping table, the key of the node-device mapping table is a tunnel node ID, and the value is a list of tunnel device IDs; the key of the device-protocol mapping table is a tunnel device ID, and the value is a list of protocol IDs; and the initialized node-device mapping table and device-protocol mapping table are output.
[0063] Each tunnel device in the tunnel device information is traversed, the tunnel device ID and the tunnel node ID to which it belongs are extracted, if the key of the tunnel node ID does not exist in the node-device mapping table, the key is created and the corresponding tunnel device ID is stored in the list; if it exists, the tunnel device ID is appended to the list corresponding to the key, and the filled node-device mapping table is output, the format of the node-device mapping table is {tunnel node ID: [tunnel device ID1, tunnel device ID2,...]}, for example, the input tunnel device is {tunnel device ID: TD001, tunnel node ID to which it belongs: TN001, supported protocol: [TP001]}, the node-device mapping table is updated to {TN001: [TD001]}, the next tunnel device is input as {tunnel device ID: TD002, tunnel node ID to which it belongs: TN001, supported protocol: [TP002]}, and the node-device mapping table is updated to {TN001: [TD001, TD002]}.
[0064] The tunnel node and the tunnel device are associated by the tunnel node ID of the tunnel device, so that each tunnel node corresponds to a set of tunnel devices under its jurisdiction, and an efficient query structure is provided for subsequent batch acquisition of tunnel devices under the failed tunnel node, for example, all associated tunnel devices can be quickly located by the tunnel node ID when the tunnel node fails.
[0065] Each tunnel device entry in the tunnel device information is traversed to extract the tunnel device ID and the list of supported protocols, and for each protocol ID in the list of supported protocols, the validity thereof is verified in the protocol information, which is to ensure that the protocol ID exists in the tunnel device information set and filter invalid protocol IDs; in the device-protocol mapping table, the valid protocol IDs are stored in the corresponding list with the tunnel device ID as the key, and the filled device-protocol mapping table is output, and the format of the device-protocol mapping table is {tunnel device ID: [protocol ID1, protocol ID2,...]}.
[0066] The association between the tunnel device and the protocol is established by the list of protocols supported by the tunnel device, and the communication protocol capability of each tunnel device is clear, which provides a direct query basis for subsequent protocol compatibility matching and conflict detection, for example, the table can be directly searched when judging whether the tunnel device protocol is supported by the takeover tunnel node.
[0067] The method for constructing the tunnel network knowledge graph by using the two mapping tables comprises:
[0068] Three types of entities, namely, tunnel nodes, tunnel devices and protocols, and two types of relationships, namely, jurisdiction and support, are defined;
[0069] The node-device mapping table is traversed, tunnel node and tunnel device entities are created in the tunnel network knowledge graph, corresponding attributes are added, and the jurisdiction relationship between the tunnel node and the tunnel device is established;
[0070] The device-protocol mapping table is traversed, the corresponding tunnel device entity is found, the protocol entity is created and the attributes are added, the support relationship between the tunnel device and the protocol is established, and the complete tunnel network knowledge graph is obtained.
[0071] For example, an empty tunnel network knowledge graph object is created, three types of entities and two types of relationships are defined; the three types of entities include tunnel nodes, tunnel devices and protocols; the two types of relationships include jurisdiction and support, wherein the jurisdiction represents the ownership relationship between the tunnel node and the tunnel device, and the support represents the capability relationship between the tunnel device and the protocol; and an initialized tunnel network knowledge graph framework is output.
[0072] The initialization of the graph structure is to standardize the addition rules of subsequent entities and relationships, to ensure that the tunnel network knowledge graph conforms to the preset logical model, and to facilitate subsequent reasoning operations.
[0073] Traverse the node-device mapping table, for each tunnel node ID, create a tunnel node entity in the tunnel network knowledge graph and add the tunnel node ID and state attributes; for each associated tunnel device ID, create a tunnel device entity and add the tunnel device ID and the tunnel node ID attribute, and then establish a jurisdiction relationship between the tunnel node entity and the tunnel device entity.
[0074] Traverse the device-protocol mapping table, for each tunnel device ID, find the corresponding tunnel device entity, for each protocol ID, create a protocol entity in the tunnel network knowledge graph and add the protocol ID, name and characteristics attributes; establish a support relationship between the tunnel device entity and the protocol entity, and output the complete tunnel network knowledge graph, which contains all entities and their attributes, and the relationship between entities.
[0075] The construction of the tunnel network knowledge graph converts the structured data in the mapping table into a graph structure, and intuitively presents the mapping network of the three through the jurisdiction and support relationship between the three entities of tunnel nodes, tunnel devices and protocols, supports complex queries and reasoning, and provides a logical reasoning basis for subsequent protocol conflict analysis in fault handling.
[0076] The node information acquisition module is configured to, when a fault tunnel node occurs, acquire tunnel devices under the fault tunnel node and mark them as to-be-taken-over devices, and acquire protocols supported by normal tunnel nodes and mark them as matchable protocols.
[0077] When a fault tunnel node occurs, the method for acquiring to-be-taken-over devices under the fault tunnel node, filtering out normal tunnel nodes, and acquiring matchable protocols includes the following steps.
[0078] Filter out the fault tunnel node ID and construct a fault tunnel node set.
[0079] According to the node-device mapping table and the fault tunnel node set, acquire the device ID of the tunnel device under the fault tunnel node, and construct a to-be-taken-over device set.
[0080] Filter out the normal tunnel node ID and construct a normal tunnel node set.
[0081] Using the node-device mapping table and the device-protocol mapping table, acquire the protocol ID of the tunnel device under the jurisdiction of the normal tunnel node, and obtain the matchable protocol after merging and deduplicating all protocol IDs.
[0082] The method for constructing the fault tunnel node set includes the following steps.
[0083] By traversing the tunnel node information set, the tunnel node IDs with fault status are filtered out to construct a fault tunnel node set, and the format of the fault tunnel node set is [TN002, TN005], for example. In a network containing multiple tunnel nodes, the fault tunnel node set obtained after filtering is [TN002, TN005], which indicates that nodes TN002 and TN005 are currently in a fault state.
[0084] The method for constructing the to-be-taken-over device set comprises:
[0085] For each tunnel node ID in the fault tunnel node set, find the corresponding tunnel device ID list in the node-device mapping table and merge it to obtain the to-be-taken-over device set, and the format of the to-be-taken-over device set is [TD003, TD004, TD007, TD008], for example. The device IDs under the jurisdiction of fault node TN002 are [TD003, TD004], and the device IDs under the jurisdiction of node TN005 are [TD007, TD008], so the merged to-be-taken-over device set is [TD003, TD004, TD007, TD008].
[0086] The method for constructing the normal tunnel node set comprises:
[0087] By traversing the tunnel node information set, the tunnel node IDs with normal status are filtered out to output a normal tunnel node set, and the format of the normal tunnel node set is [TN001, TN003, TN004], for example. The normal tunnel node set obtained is [TN001, TN003, TN004], indicating that these nodes are currently in a normal operating state and can undertake additional device management tasks.
[0088] The method for obtaining a matchable protocol comprises:
[0089] For each tunnel node ID in the normal tunnel node set, obtain the tunnel device ID list under its jurisdiction through the node-device mapping table, and then for each tunnel device ID, obtain the protocol ID list supported by it through the device-protocol mapping table, combine the protocol ID lists of all tunnel devices under the same tunnel node and remove duplicates to obtain a matchable protocol; the format of the matchable protocol is {tunnel node ID: [protocol ID1, protocol ID2,...]}, for example, the device TD001 under the jurisdiction of the normal node TN001 supports the protocol [TP001, TP002], and the device TD002 supports the protocol [TP002, TP003], so the protocol list corresponding to the node TN001 after merging and removing duplicates is [TP001, TP002, TP003], and the matchable protocol is presented as {TN001: [TP001, TP002, TP003], TN003: [TP002, TP004], TN004: [TP001, TP005]}.
[0090] Through the support relationship between the tunnel device and the protocol and the jurisdiction relationship between the tunnel node and the tunnel device, the matchable protocol is obtained layer by layer, which provides key data support for subsequent protocol matching and conflict detection.
[0091] The node adaptation module is used to match the to-be-taken-over device with the matchable protocol, find the normal tunnel node with the highest protocol matching degree with the to-be-taken-over device, mark it as a takeover tunnel node, and construct a to-be-taken-over device-takeover node mapping table.
[0092] The method for constructing the to-be-taken-over device-takeover node mapping table comprises:
[0093] The protocol matching degree set is constructed by calculating the ratio of the number of intersections between each to-be-taken-over device and the matchable protocol to the total number of protocols.
[0094] According to the matching degree, the optimal takeover tunnel node is found for each tunnel device from the protocol matching degree set, and the to-be-taken-over device-takeover node mapping table is constructed.
[0095] The method for constructing the protocol matching degree set comprises:
[0096] Through the device-protocol mapping table, the protocols supported by each tunnel device are extracted from the to-be-taken-over device set to form a protocol list of the to-be-taken-over device, for example, TD003 supports [TP002, TP003] and TD004 supports [TP002].
[0097] The node-device mapping table and the device-protocol mapping table are used to obtain the supported protocols of each normal tunnel node from the normal tunnel node set, and protocol support information of the normal tunnel node is obtained, for example, TN001 supports [TP001, TP002, TP003], and TN003 supports [TP002, TP004].
[0098] An empty mapping table is created, taking the device ID of the takeover device as the key, and the initial value is set to None, indicating that a suitable takeover tunnel node has not been found, and an initialized takeover device-takeover node mapping table is obtained, for example, {TD003: None, TD004: None,...}.
[0099] The protocol support information of the normal tunnel node is traversed, the intersection number of the supported protocols of the set of takeover devices and the supported protocols of each normal tunnel node is calculated, and then the intersection number is divided by the total number of supported protocols of the tunnel device to obtain the protocol matching degree, and a protocol matching degree set is constructed, for example, TD003 supports [TP002, TP003], TN001 supports [TP001, TP002, TP003], the intersection is [TP002, TP003], and the matching degree is 1; TN003 supports [TP002, TP004], the intersection is [TP002], and the matching degree is 0.5, forming the matching degree set {TN001: 1, TN003: 0.5, TN004: 0}.
[0100] The protocol matching degree reflects the degree of satisfaction of the protocol requirements of the takeover device on the normal tunnel node, and the higher the value, the better the matching degree.
[0101] The method for constructing the takeover device-takeover node mapping table comprises the following steps:
[0102] For each takeover device in the set of takeover devices, the normal tunnel node with the highest protocol matching degree is found from the protocol matching degree set, the mapping relationship between the device ID of the takeover device and the ID of the normal tunnel node is updated to the takeover device-takeover node mapping table, and an updated takeover device-takeover node mapping table is obtained, for example, the node with the highest matching degree for TD003 is TN001, and the score is 1, and the mapping table is updated to {TD003: TN001}; if the scores of multiple nodes are the same, for example, the scores of a device in TN001 and TN003 are both 0.8, the node with the lowest current load is selected preferentially.
[0103] The migration verification module identifies the to-be-taken-over device that cannot be compatible with the matched protocol based on the to-be-taken-over device-tunnel node mapping table, marks the to-be-taken-over device as an incompatible device, finds a tunnel node supporting the protocol of the incompatible device, updates the to-be-taken-over device-tunnel node mapping table, and completes migration of the to-be-taken-over device to the tunnel node according to the to-be-taken-over device-tunnel node mapping table.
[0104] The method for identifying the incompatible device comprises:
[0105] The to-be-taken-over device set is traversed to check whether the to-be-taken-over device has a corresponding tunnel node in the to-be-taken-over device-tunnel node mapping table, if not or the corresponding protocol matching degree is 0, the to-be-taken-over device is marked as an incompatible device, and a list of incompatible devices is obtained, for example, TD008 supports a special protocol TP006, and all normal nodes do not support it, the corresponding value of TD008 in the mapping table is None, and the matching degree is 0, so TD008 is marked as an incompatible device, and a list [TD008] is generated.
[0106] Referring to Figure 4 The method for finding a tunnel node supporting the protocol of the incompatible device and updating the to-be-taken-over device-tunnel node mapping table, and completing migration of the to-be-taken-over device to the tunnel node according to the to-be-taken-over device-tunnel node mapping table comprises:
[0107] The protocol ID of the incompatible device is extracted from the device-protocol mapping table to construct an incompatible device-protocol set;
[0108] The support protocol set is generated by merging and deduplicating through the association query of the node-device mapping table and the device-protocol mapping table;
[0109] The matching degree score is calculated based on the intersection of the incompatible device-protocol set and the support protocol set to construct an incompatible device-node matching degree set;
[0110] The optimal candidate tunnel node of each incompatible device is screened out from the matching degree score in the incompatible device-node matching degree set to construct a tunnel device-candidate tunnel node mapping temporary table;
[0111] The tunnel device-candidate tunnel node mapping temporary table is merged into the device-tunnel node mapping table;
[0112] The tunnel device migration is performed according to the device-tunnel node mapping table.
[0113] The method for constructing the incompatible device-protocol set comprises:
[0114] The protocol support set of the incompatible device is formed by traversing the incompatible device list, extracting all protocol IDs supported by each incompatible device from the device-protocol mapping table, and constructing the incompatible device-protocol set. The format of the incompatible device-protocol set is {tunnel device ID: [protocol ID1, protocol ID2,...]}, for example, the tunnel device TD009 supports [TP007, TP008], and the tunnel device TD010 supports [TP009], so the incompatible device-protocol set is {TD009: [TP007, TP008], TD010: [TP009]}.
[0115] The method for generating the support protocol set comprises:
[0116] The protocol support set of the normal tunnel node is obtained, for each normal tunnel node ID, the tunnel device ID list under jurisdiction is obtained through the node-device mapping table, then the protocol ID list supported by each tunnel device ID is obtained through the device-protocol mapping table, and then the protocol ID lists of all tunnel devices under the same tunnel node are combined and de-duplicated to obtain the support protocol set; the format of the support protocol set is {tunnel node ID: [protocol ID1, protocol ID2,...]}, which clearly shows the actual protocol range supported by each normal tunnel node, serving as a candidate pool for matching the tunnel device protocol, for example, the normal tunnel node TN006 governs the devices TD011 and TD012, TD011 supports [TP007, TP010], and TD012 supports [TP008, TP010], so the protocol support set of TN006 is [TP007, TP008, TP010], and the support protocol set is presented as {TN006: [TP007, TP008, TP010], TN007: [TP009, TP011]}.
[0117] The method for constructing the incompatible device-node matching degree set based on the intersection of the incompatible device-protocol set and the support protocol set comprises:
[0118] The protocol matching degree of the incompatible device and the normal tunnel node is calculated. For each incompatible device ID and its protocol support set, all normal tunnel node IDs are traversed, the intersection size of the protocol set of the incompatible device and the protocol set of the tunnel node, i.e. the number of commonly supported protocols, is calculated, and then the matching degree score is calculated. The matching degree score is obtained by dividing the number of commonly supported protocols by the size of the protocol set of the incompatible device. If the protocol set of the incompatible device is empty, the default matching degree is 0, and the incompatible device-node matching degree set is output. The format of the incompatible device-node matching degree set is {tunnel device ID:{tunnel node ID: matching degree score}}. For example, for the incompatible device TD009 and the tunnel node TN006, the protocol support set of the incompatible device TD009 is [TP007, TP008], the protocol support set of the tunnel node TN006 is [TP007, TP008, TP010], their intersection is [TP007, TP008], the intersection size is 2, and the protocol set size of the tunnel device TD009 is 2, so the matching degree score is 2 / 2=1. If the incompatible device TD010 and the tunnel node TN006 have no commonly supported protocol, the matching degree score is 0. Assuming that the tunnel node TN007 supports [TP009, TP011], the incompatible device-node matching degree set is {TD009:{TN006:1, TN007:0}, TD010:{TN006:0, TN007:1}}.
[0119] By quantifying the matching degree, the tunnel node that can support more incompatible devices can be preferentially selected, and the functional integrity of the migrated tunnel device is improved. The matching degree ranges from 0 to 1, 1 indicates complete matching, and 0 indicates no matching protocol.
[0120] According to the matching degree score in the incompatible device-node matching degree set, the optimal candidate takeover tunnel node of each incompatible device is screened out, and the method for constructing a tunnel device-candidate tunnel node mapping temporary table comprises the following steps:
[0121] Select the optimal matching tunnel node for each incompatible device. For each device ID of the incompatible device, filter the tunnel node IDs with a matching degree score greater than 0 and sort them from high to low. If there is a tunnel node with a score greater than 0, select the tunnel node with the highest matching degree as the candidate takeover tunnel node. If multiple tunnel nodes have the same score, select the tunnel node with the lowest current load. If the load information is not collected, randomly select one. Output the tunnel device-candidate tunnel node mapping temporary table in the format {tunnel device ID: optimal tunnel node ID}, which only includes incompatible devices. This ensures that each tunnel device finds the best compatible takeover tunnel node, avoiding migration failure due to protocol mismatch. For example, according to the above matching degree set, the incompatible device TD009 will select TN006 as the candidate takeover tunnel node, and the incompatible device TD010 will select TN007 as the candidate takeover tunnel node. The tunnel device-candidate tunnel node mapping temporary table is {TD009: TN006, TD010: TN007}.
[0122] Update the device-takeover node mapping table. The original device-takeover node mapping table records the matched tunnel device-tunnel node pairs, and the tunnel device-candidate tunnel node mapping temporary table records the newly matched incompatible tunnel device-tunnel node pairs. Merge the entries in the tunnel device-candidate tunnel node mapping temporary table into the original device-takeover node mapping table, overwrite or add the takeover tunnel node ID for the corresponding tunnel device ID. Output the updated device-takeover node mapping table, which integrates the takeover tunnel node information of all devices to be taken over, to uniformly manage the migration targets of all devices to be taken over, ensuring the integrity and consistency of subsequent migration operations.
[0123] The method for executing tunnel device migration according to the device-takeover node mapping table includes:
[0124] By iterating through each tunnel device ID and target tunnel node ID in the device-takeover node mapping table, the tunnel device management system executes the tunnel device migration operation, switches the jurisdiction of the tunnel device from the failed tunnel node to the target tunnel node, and outputs a migration status report, recording the migration results of each tunnel device, including success or failure and the corresponding reasons. The tunnel device migration is completed through a standardized operation process, and the status report is output for subsequent troubleshooting and system auditing. For example, if the tunnel device TD009 is migrated to TN006 successfully and the tunnel device TD010 fails to migrate to TN007 due to network failure, the migration status report records {TD009: {result: success, reason: none}, TD010: {result: failure, reason: network failure}}.
[0125] Through the above process, the system can dynamically find the optimal takeover tunnel node for incompatible devices, update the migration strategy and complete the actual migration, ensuring that the tunnel network can still maintain normal management and protocol compatibility of tunnel devices when the tunnel node fails, and minimizing the impact of failure.
[0126] Embodiment 2
[0127] The embodiment provides a tunnel integrated management and control platform construction system, and further comprises:
[0128] The protocol conversion module is configured to perform protocol conversion.
[0129] Referring to Figure 3 The method for performing protocol conversion comprises:
[0130] If the incompatible device cannot find a tunnel node supporting its protocol, a protocol conversion instruction is triggered, a normal tunnel node is selected and marked as a convertible node; the devices belonging to the convertible node are migrated to other normal tunnel nodes; the protocol corresponding to the incompatible device is installed on the convertible node according to the protocol conversion instruction, the incompatible device is migrated to the convertible node, and the mapping table of the device-to-be-taken-over-to-takeover node is updated.
[0131] The method for selecting a normal tunnel node comprises:
[0132] All normal tunnel nodes are traversed, the number of tunnel devices belonging to each node is obtained, and the normal tunnel node with the least number of tunnel devices is selected as the convertible node. During the selection process, it is necessary to synchronously verify whether the convertible node can install the target protocol corresponding to the incompatible device, that is, to check whether the hardware configuration and software environment of the convertible node meet the operation requirements of the target protocol, such as whether the convertible node has corresponding network interfaces, processing capacity and protocol drivers.
[0133] The method for migrating the devices belonging to the convertible node to other normal tunnel nodes comprises:
[0134] All tunnel devices currently governed by the convertible node and the protocol information corresponding thereto are obtained through the node-device mapping table;
[0135] The other normal tunnel nodes capable of receiving the devices are screened from the normal tunnel node set. The screening condition is that the target normal tunnel node supports the protocol corresponding to the tunnel device to which the convertible node belongs, and the number of devices that the target normal tunnel node can currently accommodate is not less than the number of the devices to be migrated. Specifically, for each tunnel device to be migrated, the protocol ID supported by the device is obtained through the device-protocol mapping table, and then a node supporting the protocol ID and currently having a number of devices that does not reach the maximum capacity of the node is found in the normal tunnel node set as a candidate target node. When there are multiple candidate target nodes, a node that is adjacent in geographical position to the convertible node or has a higher network connection bandwidth is preferentially selected to reduce data transmission delay.
[0136] The device ID of the device to be migrated is added to the node-device mapping table of the target node to establish the home relationship, the configuration parameters of the device to be migrated are updated to connect to the management address of the target node, a migration instruction is sent to the device to be migrated through a network communication protocol, and the device disconnects the connection with the original convertible node and re-enters the target node after receiving the instruction. During the migration process, the system monitors the connection state and data transmission of the device in real time, and automatically retries if the migration fails until all devices are migrated.
[0137] The method for installing the protocol corresponding to the incompatible device on the convertible node according to the protocol conversion instruction comprises:
[0138] The installation package of the target protocol is obtained from the protocol library of the system, the installation package is transmitted to the convertible node through a remote deployment tool, an installation program is executed and protocol parameters are configured to ensure that the protocol can normally run and be compatible with other modules of the system. After the installation is completed, the protocol information supported by the convertible node is updated through the device-protocol mapping table, and the target protocol is added to the protocol list of the node.
[0139] The method for migrating the incompatible device to the convertible node and updating the device-to-node mapping table to be taken over comprises:
[0140] The home node of the incompatible device is updated from the original faulty node to the convertible node through the device-to-node mapping table to be taken over, and then a node switching instruction is sent to the incompatible device. After receiving the instruction, the device disconnects the connection with the original faulty node or the temporary takeover node, reconnects to the convertible node, and communicates according to the protocol specification of the newly connected node. After the migration is completed, the system verifies the protocol compatibility between the incompatible device and the convertible node again to ensure that the device can normally receive and send data.
[0141] The normal tunnel node with the least number of tunnel devices is selected as the convertible node, which has multiple advantages. On the one hand, the small number of devices means a small amount of migration, which can effectively reduce the error probability caused by configuration errors, network interruptions and other problems in the migration process, and improve the stability of the migration operation. On the other hand, the node with a small number of devices usually has a relatively single protocol type corresponding to the devices thereof, which facilitates the quick finding of other normal tunnel nodes supporting the corresponding protocol and having accommodation capacity during migration, ensuring the efficiency of the migration process. In addition, only one protocol is used in each tunnel node in the embodiment, that is, each node governs tunnel devices supporting the same protocol, avoiding mutual interference between different protocols, ensuring the reliability of tunnel device communication, and meeting the requirements of the tunnel monitoring system for high real-time data transmission. By strictly following the above steps, those skilled in the art can accurately implement the protocol conversion and device migration process, ensure that the incompatible devices cannot find the native support node, and realize the normal takeover of the devices through resource scheduling and protocol adaptation, thereby maintaining the stable operation of the tunnel integrated management platform.
[0142] Embodiment 3
[0143] Referring to Figure 2 The embodiment provides a tunnel integrated management platform construction method, which comprises the following steps:
[0144] Based on the collected tunnel node information, tunnel device information and protocol information, a node-device mapping table and a device-protocol mapping table are constructed, and a tunnel network knowledge graph is constructed by using the two mapping tables;
[0145] When a fault tunnel node occurs, the tunnel devices under the fault tunnel node are obtained and marked as devices to be taken over, and the protocols supported by the normal tunnel nodes are obtained and marked as matchable protocols;
[0146] The devices to be taken over are matched with the matchable protocols, the normal tunnel node with the highest protocol matching degree with the devices to be taken over is found and marked as a takeover tunnel node, and a device-to-be-taken-over-to-node mapping table is constructed;
[0147] Based on the device-to-be-taken-over-to-node mapping table, the device to be taken over that is incompatible with the matchable protocol is identified and marked as an incompatible device, the tunnel node supporting the protocol of the incompatible device is found, and the device-to-be-taken-over-to-node mapping table is updated, and the migration of the device to be taken over to the takeover tunnel node is completed according to the device-to-be-taken-over-to-node mapping table.
[0148] The above merely describes specific embodiments of the present application, but the protection scope of the present application is not limited thereto, and any modification or substitution within the technical range disclosed by the present application can be easily thought of by those skilled in the art, and should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be subject to the protection scope of the claims.
[0149] Finally, the above merely describes preferred embodiments of the present application, and is not used to limit the present application, and any modification, equivalent substitution, improvement, etc. within the spirit and principles of the present application should be included in the protection scope of the present application.
Claims
1. A method for constructing a tunnel integrated management and control platform, characterized in that, include: Based on the collected tunnel node information, tunnel device information, and protocol information, a node-device mapping table and a device-protocol mapping table are constructed, and a tunnel network knowledge graph is constructed using the two mapping tables. When a faulty tunnel node occurs, the tunnel devices under the faulty tunnel node are retrieved and marked as devices to be taken over. At the same time, the protocols supported by the normal tunnel nodes are retrieved and marked as compatible protocols. The specific methods include: Filter out the faulty tunnel node IDs and construct a set of faulty tunnel nodes; based on the node-device mapping table and the set of faulty tunnel nodes, obtain the device IDs of the tunnel devices under the faulty tunnel nodes and construct a set of devices to be taken over; filter out the normal tunnel node IDs and construct a set of normal tunnel nodes; use the node-device mapping table and the device-protocol mapping table to obtain the protocol IDs of the tunnel devices managed by the normal tunnel nodes, and merge all protocol IDs to remove duplicates to obtain the matching protocols. The device to be taken over is matched with the available protocols. The normal tunnel node with the highest protocol matching degree with the device to be taken over is marked as the takeover tunnel node, and a mapping table of device to be taken over and takeover node is constructed. Based on the device-to-takeover node mapping table, devices incompatible with the matching protocol are identified and marked as incompatible devices. A tunnel node supporting the protocol is found for each incompatible device, and the device-to-takeover node mapping table is updated. The migration from the device to the takeover tunnel node is then completed according to this mapping table. Specific methods include: Extract the protocol IDs of incompatible devices from the device-protocol mapping table to construct an incompatible device-protocol set; generate a supported protocol set by merging and deduplicating the nodes-device mapping table and the device-protocol mapping table through an association query; calculate the matching score based on the intersection of the incompatible device-protocol set and the supported protocol set to construct an incompatible device-node matching score set; select the optimal candidate takeover tunnel node for each incompatible device based on the matching score in the incompatible device-node matching score set, and construct a temporary tunnel device-candidate tunnel node mapping table; merge the temporary tunnel device-candidate tunnel node mapping table into the device-takeover node mapping table; and perform tunnel device migration based on the device-takeover node mapping table.
2. The method for constructing a tunnel integrated management and control platform according to claim 1, characterized in that, If the incompatible device cannot find a tunnel node that supports its protocol, a protocol conversion command is triggered, a normal tunnel node is selected, and it is marked as a convertible node. Migrate the device belonging to the convertible node to another normal tunnel node; According to the protocol conversion instructions, install the protocol corresponding to the incompatible device on the convertible node, migrate the incompatible device to the convertible node, and update the device-to-takeover node mapping table.
3. The method for constructing a tunnel integrated management and control platform according to claim 1, characterized in that, The method for constructing the mapping table of devices to be taken over and takeover nodes includes: The protocol matching degree is obtained by calculating the ratio of the number of intersections between each device to be taken over and the number of matching protocols to the total number of protocols, and a protocol matching degree set is constructed. Based on the matching degree, the optimal takeover tunnel node is found for each tunnel device from the protocol matching degree set, and a mapping table of devices to be taken over and takeover nodes is constructed.
4. The method for constructing a tunnel integrated management and control platform according to claim 1, characterized in that, Methods for constructing node-device mapping tables and device-protocol mapping tables include: Based on the tunnel node ID to which the tunnel equipment belongs, establish the attribution relationship between the tunnel node and the tunnel equipment in the node-equipment mapping table, classify and store the tunnel equipment IDs according to the tunnel node IDs, and construct the node-equipment mapping table. Extract the protocols supported by the tunnel equipment, establish the association between the tunnel equipment and the protocols in the device-protocol mapping table, and construct the device-protocol mapping table.
5. The method for constructing a tunnel integrated management and control platform according to claim 1, characterized in that, Methods for constructing knowledge graphs for tunnel networks include: Define three types of entities: tunnel nodes, tunnel devices, and protocols, as well as two types of relationships: jurisdiction and support; Traverse the node-device mapping table, create tunnel node and tunnel device entities in the tunnel network knowledge graph, add corresponding attributes, and establish the jurisdiction relationship between tunnel nodes and tunnel devices; Traverse the device-protocol mapping table, find the corresponding tunnel device entity, create a protocol entity and add attributes, establish the support relationship between tunnel devices and protocols, and obtain a complete tunnel network knowledge graph.
6. The method for constructing a tunnel integrated management and control platform according to claim 1, characterized in that: The tunnel node information includes the tunnel node ID and tunnel node status; the tunnel device information includes the tunnel device ID, the tunnel node to which it belongs, and the supported protocols; the protocol information includes the protocol ID, name, and characteristics.
7. A tunnel integrated management and control platform construction system, used to implement the tunnel integrated management and control platform construction method according to any one of claims 1-6, characterized in that, include: The knowledge graph construction module constructs a node-device mapping table and a device-protocol mapping table based on the collected tunnel node information, tunnel device information, and protocol information, and uses the two mapping tables to construct a tunnel network knowledge graph; The node information acquisition module is used to acquire the tunnel devices under the faulty tunnel node when a faulty tunnel node occurs, mark them as devices to be taken over, and acquire the protocols supported by the normal tunnel nodes, mark them as compatible protocols. The node adaptation module is used to match the device to be taken over with the matching protocols, find the normal tunnel node with the highest protocol matching degree with the device to be taken over, mark it as the takeover tunnel node, and build a mapping table of device to be taken over and takeover node. The migration verification module identifies devices that are incompatible with the matching protocol based on the device-to-takeover node mapping table, marks them as incompatible devices, finds tunnel nodes that support their protocols for incompatible devices, updates the device-to-takeover node mapping table, and completes the migration of the device to the takeover tunnel node according to the device-to-takeover node mapping table.
Citation Information
Patent Citations
Tunnel protection method and device
CN102006218A
Tunnel electromechanical equipment edge control system and method compatible with multiple communication protocols
CN120335348A