Device connection methods, apparatus, computer equipment, readable storage media and program products

CN119484297BActive Publication Date: 2026-08-14CHINA TELECOM CLOUD TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-12-03
Publication Date
2026-08-14

AI Technical Summary

Technical Problem

[0004]然而,上述连线设计方式中,需要付出大量的人工成本,导致设备连线的效率较低

Benefits of technology

[0034]上述设备连线方法、装置、计算机设备、计算机可读存储介质和计算机程序产品,可以获取设备拓扑图和所述设备拓扑图对应的设备清单信息; 根据所述设备拓扑图,确定所述拓扑图包含的至少一个设备连接信息;所述设备连接信息至少包含源端设备和对端设备;基于预先构建的设备连线规则模型、所述设备连接信息和所述设备清单信息,确定目标连线规则;基于所述目标连线规则,生成所述设备连接信息对应的端口连线表;所述端口连线表至少包含所述源端设备和所述对端设备之间的端口连接信息。采用本方案,可以预先构建设备连线规则模型,并根据拓扑图中的设备连接信息,匹配适用的目标连线规则,进而基于所述目标连线规则,自动生成所述设备连接信息对应的端口连线表,无需人工生产端口连接信息,提升了设备连线的效率。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119484297B_ABST
    Figure CN119484297B_ABST
Patent Text Reader

Abstract

This application relates to a device connection method, apparatus, computer device, readable storage medium, and program product. The method includes: acquiring a device topology diagram and corresponding device list information; determining at least one device connection information contained in the topology diagram based on the device topology diagram; the device connection information at least includes a source device and a peer device; determining a target connection rule based on a pre-built device connection rule model, the device connection information, and the device list information; and generating a port connection table corresponding to the device connection information based on the target connection rule; the port connection table at least includes port connection information between the source device and the peer device. This method can improve the efficiency of device connection.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of cloud computing technology, and in particular to a device connection method, apparatus, computer equipment, readable storage medium, and program product. Background Technology

[0002] With the development of internet technology, cloud computing networks are growing rapidly, and data centers are expanding in scale, requiring the management of an increasing number of physical devices (such as network devices like switches and servers). These physical devices are often interconnected by numerous cables; only when each cable is correctly connected can the entire network function properly.

[0003] In related technologies, technicians need to read a large number of specification documents provided by the R&D department and fully understand the connection logic of different products and different scenarios. Then, based on the physical device connection requirements in the current data center, they need to design the port connection table between various physical devices.

[0004] However, the above wiring design requires a lot of labor costs, resulting in low efficiency of equipment wiring. Summary of the Invention

[0005] Therefore, it is necessary to provide a device connection method, apparatus, computer device, computer-readable storage medium, and computer program product that can improve the efficiency of device connection in order to address the above-mentioned technical problems.

[0006] In a first aspect, this application provides a device connection method, the method comprising:

[0007] Obtain the device topology diagram and the device list information corresponding to the device topology diagram;

[0008] Based on the device topology diagram, determine at least one device connection information contained in the topology diagram; the device connection information includes at least a source device and a peer device;

[0009] Based on the pre-built device connection rule model, the device connection information, and the device list information, the target connection rule is determined;

[0010] Based on the target connection rules, a port connection table corresponding to the device connection information is generated; the port connection table contains at least the port connection information between the source device and the peer device.

[0011] In one embodiment, the device list information includes parameter information for each device in the device topology diagram; the device connection information also includes connection configuration information;

[0012] The determination of target connection rules based on the pre-built device connection rule model, the device connection information, and the device list information includes:

[0013] For each device connection information, the parameter information of the source device and the parameter information of the peer device contained in the device connection information are obtained from the device list information;

[0014] In a pre-stored device connection rule model, a target connection rule is determined that matches the parameter information of the source device, the parameter information of the peer device, and the connection configuration information.

[0015] In one embodiment, generating the port connection table corresponding to the device connection information based on the target connection rule includes:

[0016] Based on the target connection rules, port access processing is performed on the source device and the peer device, and a port connection table is generated based on the accessed ports of the source device and the peer device.

[0017] In one embodiment, the method further includes:

[0018] If the target connection rule is not determined in the pre-stored device connection rule model, a prompt message is output. The prompt message is used to prompt the configuration of port connection information between the source device and the peer device.

[0019] In response to a port configuration command, the port connection information between the source device and the peer device is obtained, and a port connection table is generated.

[0020] In one embodiment, determining at least one device connection information contained in the device topology map based on the device topology map includes:

[0021] The device topology diagram is parsed in a preset order to obtain the device pairs connected by each device connection line in the device topology diagram;

[0022] Identify the source and peer devices in the device pair, and recognize the connection configuration information between the source and peer devices from the device topology diagram.

[0023] In one embodiment, the method further includes:

[0024] Obtain the wiring specification design documents;

[0025] The text processing model identifies the device configuration information of each device contained in the wiring specification design document, and generates a device wiring rule model based on the device configuration information.

[0026] Secondly, this application provides a device connection apparatus, the apparatus comprising:

[0027] The first acquisition module is used to acquire a device topology diagram and the device list information corresponding to the device topology diagram;

[0028] The first determining module is configured to determine, based on the device topology diagram, at least one device connection information contained in the topology diagram; the device connection information includes at least a source device and a peer device;

[0029] The second determining module is used to determine the target connection rule based on the pre-built device connection rule model, the device connection information and the device list information;

[0030] The first generation module is used to generate a port connection table corresponding to the device connection information based on the target connection rules; the port connection table includes at least the port connection information between the source device and the peer device.

[0031] Thirdly, this application provides a computer device including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps of the method described in any one of the first aspects.

[0032] Fourthly, this application provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the method described in any one of the first aspects.

[0033] Fifthly, this application provides a computer program product, including a computer program that, when executed by a processor, implements the steps of the method described in any one of the first aspects.

[0034] The aforementioned device connection method, apparatus, computer equipment, computer-readable storage medium, and computer program product can acquire a device topology diagram and the device list information corresponding to the device topology diagram; determine at least one device connection information contained in the topology diagram based on the device topology diagram; the device connection information includes at least a source device and a peer device; determine a target connection rule based on a pre-built device connection rule model, the device connection information, and the device list information; and generate a port connection table corresponding to the device connection information based on the target connection rule; the port connection table includes at least the port connection information between the source device and the peer device. Using this solution, a device connection rule model can be pre-built, and applicable target connection rules can be matched according to the device connection information in the topology diagram. Then, based on the target connection rule, a port connection table corresponding to the device connection information can be automatically generated, eliminating the need for manual generation of port connection information and improving the efficiency of device connection. Attached Figure Description

[0035] To more clearly illustrate the technical solutions in the embodiments of this application or related technologies, the drawings used in the description of the embodiments of this application or related technologies will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.

[0036] Figure 1 This is a flowchart illustrating a device connection method in one embodiment;

[0037] Figure 2 This is a schematic diagram of the switch-to-switch connection rules in one embodiment;

[0038] Figure 3 This is a schematic diagram of the switch-server connection rules in one embodiment;

[0039] Figure 4 This is a flowchart illustrating a device connection method in one embodiment;

[0040] Figure 5 This is a flowchart illustrating an example of a device connection method in one embodiment;

[0041] Figure 6 This is a structural block diagram of the device wiring device in one embodiment;

[0042] Figure 7 This is an internal structural diagram of a computer device in one embodiment. Detailed Implementation

[0043] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.

[0044] This application provides a device connection method. This embodiment illustrates the method applied to a terminal, but it is understood that the method can also be applied to a server, or a system including both a terminal and a server, and is implemented through interaction between the terminal and the server. It is understood that this method can be applied to any terminal with data processing capabilities, and this application is not limited thereto.

[0045] With the development of internet technology, cloud computing networks are growing rapidly, and data centers are expanding in scale, requiring the management of an increasing number of physical devices (such as network devices like switches and servers). Numerous connections exist between these physical devices; only when each connection is correctly established can the entire network function properly. Cloud computing networks are a network connection method that transforms resource pools into virtual resources and connects user devices in all locations to these virtual resources. The physical devices in a data center mainly include network devices and servers. Network devices refer to the hardware components used for connection and network communication, including but not limited to switches, routers, firewalls, bridges, hubs, gateways, VPN (Virtual Private Network) servers, etc. A switch is a type of network hardware device used for forwarding electrical signals, providing an electrical signal path for any two network nodes connected to the switch. Servers primarily provide various services to other devices (such as personal computers, smartphones, ATMs) within the network environment. Physical device connections refer to the use of twisted-pair cables or fiber optic cables to link physical devices in the network, enabling resource sharing and information exchange between them.

[0046] In this embodiment, a device connection rule model can be constructed based on traditional connection specification documents. According to the device connection information in the topology diagram, the applicable target connection rule is matched, and then the port connection table corresponding to the device connection information is automatically generated based on the target connection rule. There is no need to manually generate port connection information, which improves the efficiency of device connection.

[0047] The device connection method provided in this application will be described in detail below with reference to specific implementation methods. For example... Figure 1 As shown, the method includes the following steps:

[0048] Step 102: Obtain the device topology diagram and the device list information corresponding to the device topology diagram.

[0049] In this embodiment, the terminal can obtain a device topology diagram requiring device continuity and a corresponding device list information. Specifically, the terminal can obtain a network planning and design document, which includes a device topology diagram and device list information. In the device topology diagram, nodes represent physical devices, and connecting lines represent connections between physical devices. The device topology diagram also includes connection configuration information between physical devices. This connection configuration information may include connection parameters between two physical devices, which will be explained in detail later. The device list information may include parameter information of the physical devices, such as the number of boards, board type, and available port range.

[0050] Step 104: Based on the device topology diagram, determine at least one device connection information contained in the topology diagram.

[0051] The device connection information includes at least the source device and the peer device.

[0052] In this embodiment, the terminal can break down the connections between physical devices in the device topology diagram to obtain at least one device connection information contained in the topology diagram. Each device connection information contains information about a device pair. The device pair includes a source device and a peer device.

[0053] Step 106: Determine the target connection rule based on the pre-built device connection rule model, device connection information, and device list information.

[0054] In this embodiment, the terminal may store a pre-built device connection rule model. The device connection rule model may contain multiple device connection rules, each indicating the port connection requirements of a device pair. For each device connection information, the terminal may determine a target connection rule based on the pre-built device connection rule model, the device connection information, and the device list information. The target connection rule is the connection rule that matches the device connection information. Different connection rules apply to connections between different types of physical devices. Specifically, the types of connection rules include switch-to-switch connection rules and switch-to-server connection rules. Figure 2 This is a schematic diagram of the switch-to-switch connection rules provided in the embodiments of this application. It may include the device role, manufacturer model, board type, start port, end port, cross-frame / cross-device priority, number of board groups, usage order, and port type of the source and peer devices, and may also include the virtualization method of the link (i.e., virtualization type). Figure 3 This is a schematic diagram of the switch-server connection rules provided in an embodiment of this application. It may include the source device's device role, manufacturer model, card type, start port, end port, cross-frame / cross-device priority, number of card groups, usage order, and port type; and the peer device's device role, manufacturer model, local / cross-NIC priority, and bond number. The terminal can determine the type of connection rule matching it based on the types of the source and peer devices in the device connection information, and then determine the target connection rule from the connection rules of that type included in the device connection rule model.

[0055] In one example, a device connection rule can contain multiple fields, specifically information about the source device and information about the peer device. The source device's information may include at least one or more of the following: device role, board type, starting port, ending port, cross-frame / cross-device priority, number of board groups, usage order, and port type. The peer device's information, in addition to the above fields, may also include the connection virtualization method. Table 1 shows an example of a connection rule provided in this application embodiment.

[0056]

[0057] Step 108: Based on the target connection rules, generate a port connection table corresponding to the device connection information.

[0058] The port connection table contains at least the port connection information between the source device and the peer device.

[0059] In this embodiment, the terminal can determine the port usage of the source and peer devices in the device connection information according to the target connection rules, determine the port connection status of the source and peer devices based on the port usage, and then generate a port connection table. The port connection information for multiple devices can be stored in one port connection table or in different port connection information tables; this embodiment does not impose any limitation on this.

[0060] In this solution, a device connection rule model can be built based on traditional connection specification documents. According to the device connection information in the topology diagram, the applicable target connection rules are matched. Then, based on the target connection rules, the port connection table corresponding to the device connection information is automatically generated, eliminating the need for manual generation of port connection information and improving the efficiency of device connection.

[0061] Optionally, the device list information includes parameter information for each device in the device topology diagram; the device connection information also includes connection configuration information. The connection configuration information may include at least one of the following: the connection virtualization method and the connection speed. For example... Figure 4 As shown, in the pre-built device connection rule model, target connection rules that match device connection information and device list information are determined, including:

[0062] Step 402: For each device connection information, obtain the parameter information of the source device and the parameter information of the peer device contained in the device connection information from the device list information.

[0063] In this embodiment, for each device connection information, the terminal can obtain the parameter information of the source device and the parameter information of the peer device contained in the device list information. The parameter information may include manufacturer model, number of boards, board type, and available port range, etc.

[0064] In one example, the source device is a core switch and the peer device is a large customer access switch. The parameters of the core switch can be obtained as follows: the board configuration is 2 x 48-port 10GE boards and 2 x 18-port 100GE boards, and all available ports are fully configured. The parameters of the large customer access switch are as follows: the large customer access switch is a box switch, with 1-48 ports configured as 10GE optical ports and 49-54 ports as 40GE optical ports.

[0065] Step 404: In the pre-stored device connection rule model, determine the target connection rule that matches the parameter information of the source device, the parameter information of the peer device, and the connection configuration information.

[0066] In this embodiment, the terminal can query the device connection rule model to find target connection rules that match the parameter information of the source device, the parameter information of the peer device, and the connection configuration information. Specifically, a connection rule containing the parameter information of the source device, the parameter information of the peer device, and the connection configuration information can be identified as the target connection rule. In one example, the target connection rule can be determined based on the source device role, manufacturer model, board type, peer device role, manufacturer model, board type, and the virtualization method of the connection between the two ends. Table 2 shows an example of target connection rules provided in this embodiment.

[0067]

[0068] Optionally, the device connection rule model can also be obtained by training a machine learning model using sample data. The terminal can input the parameter information of the source device, the parameter information of the peer device, and the connection configuration information into the pre-trained device connection rule model to obtain the target connection rules.

[0069] This solution can match applicable target connection rules based on multi-dimensional information such as the parameter information of the source device, the parameter information of the peer device, and the connection configuration information. This can improve the accuracy and efficiency of determining connection rules, thereby improving the efficiency and accuracy of device connection.

[0070] Optionally, based on the target connection rules, a port connection table corresponding to the device connection information is generated, including: based on the target connection rules, port access processing is performed on the source device and the peer device, and a port connection table is generated based on the accessed ports of the source device and the peer device.

[0071] In this embodiment, the terminal can determine the available ports of the source device and the peer device based on the target connection rules. Then, based on the port usage order in the target connection rules, it performs port acquisition processing on the available ports of the source device and the peer device, and generates a port connection table based on the acquired ports of the source and peer devices. In one example, port acquisition is performed on the source and peer devices. The first port acquired by the source device is connected to the first port acquired by the peer device, the second port acquired by the source device is connected to the second port acquired by the peer device, and so on, generating a port connection table. For example, based on the target connection rules in Table 2, the partial port connection table of the large customer access switch to the core switch is as follows:

[0072]

[0073] Optionally, the method further includes: if the target connection rule is not determined in the pre-stored device connection rule model, outputting a prompt message, which is used to prompt the configuration of port connection information between the source device and the peer device; in response to the port configuration command, obtaining the port connection information between the source device and the peer device, and generating a port connection table.

[0074] In this embodiment, if the terminal cannot determine the target connection rule in the pre-built device connection rule model or the pre-stored device connection rule model, it can display a prompt message through the display component. This prompt message is used to prompt the user to configure the port connection information between the source device and the peer device, and may include parameter information of the source device, parameter information of the peer device, and connection configuration information. The user can configure the port connection information on the terminal based on the prompt message. The terminal responds to the user's input port configuration command, obtains the port connection information between the source device and the peer device, and generates a port connection table.

[0075] This solution prompts users to configure port continuity information even when the target connection rules are not determined. It also provides users with device parameter information and connection configuration information, thus providing a basis for users to configure port connection information and effectively improving port configuration efficiency.

[0076] Optionally, based on the device topology diagram, determine at least one device connection information contained in the topology diagram, including: parsing the device topology diagram in a preset order to obtain the device pairs connected by each device connection line contained in the device topology diagram; determining the source device and the peer device in the device pair, and identifying the connection configuration information between the source device and the peer device from the device topology diagram.

[0077] In this embodiment, the terminal can parse the device topology diagram according to a preset order. For example, it can traverse the device topology diagram sequentially from top to bottom, determine each device connection included in the topology diagram, and identify the devices connected to each device to obtain device pairs. Then, it can determine the device roles of the two devices in the device pair, namely the source device and the peer device, and identify the connection configuration information between the source device and the peer device from the device topology diagram. For example, based on the topology diagram in the specification design document, the connections between different device roles are split, and each connection is split into: source device role, peer device role, etc. Simultaneously, the connection rate and connection virtualization method between the two devices are obtained. For example, the core switch connects to the large customer access switch via a 40GE multimode fiber optic cable, in a down relationship.

[0078] This solution can intelligently parse the device topology diagram to obtain the source and peer devices, as well as connection configuration information, in order to determine the connection rules to be used. Based on this, after establishing a device connection rule model, it can automatically analyze and adapt the connection rules and generate a port connection table for any project's device topology diagram, adapting to different scenarios and network topologies and improving device connection efficiency.

[0079] Optionally, the method further includes: obtaining a wiring specification design document; identifying the device configuration information of each device contained in the wiring specification design document through a text processing model, and generating a device wiring rule model based on the device configuration information.

[0080] In this embodiment, the terminal can obtain a wiring specification design document, identify the device configuration information of each device contained in the wiring specification design document using a text processing model, and generate a device wiring rule model based on the device configuration information. The text processing model can be an artificial intelligence model with text parsing and understanding capabilities, which can be trained using sample data.

[0081] Specifically, by parsing the connection specification design document using a text processing model, at least one or more of the following can be obtained: 1. The devices involved in the connection specification design document, and within these devices, the roles and manufacturers / models of the source and peer devices. Different device roles and manufacturers / models have different connection specifications; therefore, it is necessary to first determine the roles and manufacturers / models of the source and peer devices for more accurate subsequent abstract design of the connection rules. 2. The device board type (for network devices) and bond (for servers); for network devices, specify the board type to which this rule applies, such as: 48-port 10GE or 18-port 100GE, for more accurate definition of the port range later. For servers, specify the bond port to which this rule applies. 3. The start and end ports; for both source and peer devices, determine the start and end ports to which this rule applies, i.e., the ports within this range on the local end connect to ports within this range on the peer end. 4. Port usage rules (including cross-board / cross-device priority, number of board groups, usage order, etc.). In the above content, the connection port range of the source and the other end has been clearly defined. Based on this, the port usage rules need to be further clarified. It is usually specified from the following three dimensions: (1) Cross-board / cross-device priority. In actual situations, there are usually multiple boards on one device; two devices stacked / M-lag used; multiple devices grouped for use, etc. In the rules, it is necessary to clarify whether to prioritize cross-board ports of this device or cross-device ports when using ports; (2) Number of board groups: used to specify the number of boards used at the same time when using ports, such as: using 2 boards of ports in this range at the same time, or using 4 boards of ports in this range at the same time; (3) Usage order: divided into forward order and reverse order, used to specify the usage order of the above port range. 5. Port type. Among them, the switch port type is divided into normal, MGT, Console, and the server port type is divided into normal, IPMI, etc. 6. Virtualization methods; among which, virtualization methods are divided into two types: device virtualization and link virtualization. Each type is further divided into two types: detection line and data line. Therefore, this method is divided into the following five cases: stack detection, stack data line, M-lag detection line, M-lag data line, and none.

[0082] The terminal uses a text processing model to abstract relevant data from the connection specification design file according to the above data dimensions, obtains device configuration information, constructs connection rules based on the abstracted device configuration information, and then constructs a device connection rule model based on each consecutive rule.

[0083] In this solution, the content of complex wiring specification documents is extracted into several wiring rules through a text processing model, thereby constructing a device wiring rule model. This eliminates the need for technicians to read and understand complex specification documents, saving labor costs and improving device wiring efficiency.

[0084] like Figure 5 As shown in the figure, this application provides an example of a device connection method, including the following steps:

[0085] Step 501: Obtain the wiring specification design document.

[0086] Step 502: Using a text processing model, identify the device configuration information of each device contained in the wiring specification design document, and generate a device wiring rule model based on the device configuration information.

[0087] The device connection rule model includes switch-to-switch connection rules and switch-to-server connection rules.

[0088] Step 503: Obtain the device topology diagram and the device list information corresponding to the device topology diagram.

[0089] Step 504: parse the device topology diagram according to a preset order, obtain the device pairs connected by each device connection line in the device topology diagram, and determine the device connection information of the device pairs.

[0090] The device connection information includes at least the source device and the peer device, as well as connection configuration information.

[0091] Step 505: Obtain the parameter information of the source device and the parameter information of the peer device from the device list information.

[0092] Step 506: In the pre-stored device connection rule model, determine the target connection rule that matches the parameter information of the source device, the parameter information of the peer device, and the connection configuration information.

[0093] Step 507: Based on the target connection rules, perform port access processing on the source device and the peer device, and generate a port connection table based on the accessed ports of the source device and the peer device.

[0094] The port connection table contains at least the port connection information between the source device and the peer device.

[0095] It should be understood that although the steps in the flowcharts of the above embodiments are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the above embodiments may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages of other steps.

[0096] Based on the same inventive concept, this application also provides a device connection apparatus for implementing the device connection method described above. The solution provided by this apparatus is similar to the implementation scheme described in the above method; therefore, the specific limitations in one or more device connection apparatus embodiments provided below can be found in the limitations of the device connection method described above, and will not be repeated here.

[0097] In one exemplary embodiment, such as Figure 6 As shown, a device connection apparatus is provided, including: a first acquisition module 610, a first determination module 620, and a first generation module 630, wherein:

[0098] The first acquisition module 610 is used to acquire the device topology diagram and the device list information corresponding to the device topology diagram;

[0099] The first determining module 620 is used to determine, based on the device topology diagram, at least one device connection information contained in the topology diagram; the device connection information includes at least a source device and a peer device;

[0100] The second determination module is used to determine the target connection rule based on the pre-built device connection rule model, device connection information and device list information;

[0101] The first generation module 630 is used to generate a port connection table corresponding to the device connection information based on the target connection rules; the port connection table contains at least the port connection information between the source device and the peer device.

[0102] In one embodiment, the device list information includes parameter information for each device in the device topology diagram; the device connection information also includes connection configuration information.

[0103] The second determining module is specifically used for:

[0104] For each device connection information, retrieve the parameter information of the source device and the parameter information of the peer device from the device list information;

[0105] In the pre-stored device connection rule model, determine the target connection rule that matches the parameter information of the source device, the parameter information of the peer device, and the connection configuration information.

[0106] In one embodiment, the first generation module 630 is specifically used for:

[0107] Based on the target connection rules, port access processing is performed on the source and peer devices, and a port connection table is generated based on the accessed ports of the source and peer devices.

[0108] In one embodiment, the device further includes:

[0109] The output module is used to output a prompt message if the target connection rule is not determined in the pre-stored device connection rule model. The prompt message is used to prompt the configuration of port connection information between the source device and the peer device.

[0110] The second generation module is used to respond to port configuration commands, obtain port connection information between the source device and the peer device, and generate a port connection table.

[0111] In one embodiment, the first determining module 620 is specifically used for:

[0112] The device topology diagram is parsed according to a preset order to obtain the device pairs connected by each device connection line in the device topology diagram;

[0113] Identify the source and peer devices in the device pair, and recognize the connection configuration information between the source and peer devices from the device topology diagram.

[0114] In one embodiment, the device further includes:

[0115] The second acquisition module is used to acquire the wiring specification design file;

[0116] The third generation module is used to identify the device configuration information of each device contained in the wiring specification design document through a text processing model, and generate a device wiring rule model based on the device configuration information.

[0117] Each module in the aforementioned device connection device can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in the processor of the computer device in hardware form or independent of it, or stored in the memory of the computer device in software form, so that the processor can call and execute the operations corresponding to each module.

[0118] In one exemplary embodiment, a computer device is provided, which may be a terminal, and its internal structure diagram may be as follows: Figure 7 As shown, the computer device includes a processor, memory, input / output interfaces, a communication interface, a display unit, and an input device. The processor, memory, and input / output interfaces are connected via a system bus, and the communication interface, display unit, and input device are also connected to the system bus via the input / output interfaces. The processor provides computing and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The input / output interfaces are used for exchanging information between the processor and external devices. The communication interface is used for wired or wireless communication with external terminals; wireless communication can be achieved through Wi-Fi, mobile cellular networks, Near Field Communication (NFC), or other technologies. When the computer program is executed by the processor, it implements a device connection method. The display unit is used to form a visually visible image and can be a display screen, a projection device, or a virtual reality imaging device. The display screen can be an LCD screen or an e-ink screen. The input device of the computer device can be a touch layer covering the display screen, or buttons, trackballs, or touchpads set on the casing of the computer device, or external keyboards, touchpads, or mice, etc.

[0119] Those skilled in the art will understand that Figure 7 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.

[0120] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon, which, when executed by a processor, implements the steps of the device connection method described above.

[0121] In one embodiment, a computer program product is provided, including a computer program that, when executed by a processor, implements the steps of the device connection method described above.

[0122] It should be noted that the user information (including but not limited to user device identifiers, user personal information, etc.) and data (including but not limited to data used for analysis, data stored, data displayed, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of the relevant data must comply with relevant regulations.

[0123] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile memory and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM). The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, artificial intelligence (AI) processors, etc., and are not limited to these.

[0124] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this application.

[0125] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.

Claims

1. A device wiring method, characterized in that, The method includes: Obtain a device topology diagram and a device list information corresponding to the device topology diagram, wherein the device list information includes parameter information of each device in the device topology diagram; Based on the device topology diagram, at least one device connection information contained in the topology diagram is determined; the device connection information includes source device, peer device, and connection configuration information; For each device connection information, the parameter information of the source device and the parameter information of the peer device contained in the device connection information are obtained from the device list information; in the pre-stored device connection rule model, the connection rule containing the parameter information of the source device, the parameter information of the peer device, and the connection configuration information is determined as the target connection rule; Based on the target connection rules, a port connection table corresponding to the device connection information is generated; the port connection table contains at least the port connection information between the source device and the peer device, and the port connection table is used for physical device connection, which refers to linking the source device and the peer device in the network using twisted pair or optical fiber.

2. The method according to claim 1, characterized in that, The step of generating a port connection table corresponding to the device connection information based on the target connection rules includes: Based on the target connection rules, port access processing is performed on the source device and the peer device, and a port connection table is generated based on the accessed ports of the source device and the peer device.

3. The method according to claim 1, characterized in that, The method further includes: If the target connection rule is not determined in the pre-stored device connection rule model, a prompt message is output. The prompt message is used to prompt the configuration of port connection information between the source device and the peer device. In response to a port configuration command, the port connection information between the source device and the peer device is obtained, and a port connection table is generated.

4. The method according to claim 1, characterized in that, The step of determining at least one device connection information contained in the device topology map based on the device topology map includes: The device topology diagram is parsed in a preset order to obtain the device pairs connected by each device connection line in the device topology diagram; Identify the source and peer devices in the device pair, and recognize the connection configuration information between the source and peer devices from the device topology diagram.

5. The method according to claim 1, characterized in that, The method further includes: Obtain the wiring specification design documents; The text processing model identifies the device configuration information of each device contained in the wiring specification design document, and generates a device wiring rule model based on the device configuration information.

6. A device wiring apparatus, characterized in that, The device includes: The first acquisition module is used to acquire a device topology diagram and a device list information corresponding to the device topology diagram, wherein the device list information includes parameter information of each device in the device topology diagram. The first determining module is configured to determine, based on the device topology diagram, at least one device connection information contained in the topology diagram; the device connection information includes a source device, a peer device, and connection configuration information; The second determining module is used to obtain, for each device connection information, the parameter information of the source device and the parameter information of the peer device contained in the device connection information from the device list information; and determine the connection rule containing the parameter information of the source device, the parameter information of the peer device and the connection configuration information in the pre-stored device connection rule model as the target connection rule. The first generation module is used to generate a port connection table corresponding to the device connection information based on the target connection rules; the port connection table contains at least the port connection information between the source device and the peer device, and the port connection table is used to perform physical device connection, which refers to linking the source device and the peer device in the network using twisted pair or optical fiber.

7. The apparatus according to claim 6, characterized in that, The first generation module is specifically used for: Based on the target connection rules, port access processing is performed on the source device and the peer device, and a port connection table is generated based on the accessed ports of the source device and the peer device.

8. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 5.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 5.

10. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 5.

Citation Information

Patent Citations

  • Method and device for configuring network

    CN115277428A

  • Network path detection method and device, equipment and storage medium

    CN116248479A