Method, device and system for constructing network topology structure
By constructing an initial network topology diagram and automatically deploying physical connection relationships, the problems of low test efficiency and high error rate caused by manual operations in the existing technology are solved, and efficient and accurate network topology deployment is achieved.
Patent Information
- Application Number
- CN202211103091.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-09-09
- Publication Date
- 2024-08-30
- Estimated Expiration
- 2042-09-09
AI Technical Summary
In the existing technology, the construction and deployment of network topology relies on manual operations, resulting in complex topology levels, widely varying switches, and changeable test scenarios. It is error-prone and lacks visibility, resulting in low efficiency and high error rate in product performance testing. .
By obtaining the account device resource nodes and their corresponding device resource information and public network element nodes, the initial network topology structure diagram is constructed, and the target instructions are determined according to the diagram to automatically deploy the physical connection relationships to realize the automatic construction of the target network topology structure.
It improves the deployment efficiency of device connection relationships in the network topology, improves the efficiency and accuracy of product performance testing, and reduces manual errors.
Smart Images

Figure CN115484169B
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of product performance testing, and in particular to the technical field of test networking construction and deployment, and specifically to a method, device and system for constructing a network topology structure. Background Art
[0002] When testers of network security product companies conduct product function tests, they need to manually network the test equipment, such as network security products and personal computers (PCs), that is, to build a network topology for device testing and perform network deployment. The networking process requires identifying the target device, finding the switch connection relationship of the target device, and issuing instructions to the switch based on the networking requirements. This process relies on manual operation, which is prone to errors in situations with complex topology levels, a wide variety of switches, and changing test scenarios. It also lacks visibility and cannot clearly see the equipment and networking required for this test.
[0003] To address the above-mentioned problems, no effective solution has been proposed yet. Summary of the invention
[0004] The embodiments of the present invention provide a method, device and system for constructing a network topology structure, so as to at least solve the technical problem in the related art of manually deploying device connection relationships in a network topology structure, resulting in low efficiency and high error rate in product performance testing.
[0005] According to one aspect of an embodiment of the present invention, a method for constructing a network topology structure is provided, including: obtaining an account device resource node, device resource information corresponding to the account device resource node, and a public network element node; constructing an initial network topology structure diagram based on the account device resource node, the device resource information, and the public network element node; determining a target instruction according to the networking connection relationship in the initial network topology structure diagram; and deploying the physical connection relationship to the initial network topology structure diagram according to the target instruction to obtain a target network topology structure diagram.
[0006] Optionally, the above-mentioned device resource information includes at least: device name, undeployed device interface and device type, the above-mentioned public network element node includes at least: communication node and network identification node, and the above-mentioned initial network topology structure diagram is constructed based on the above-mentioned account device resource node, the above-mentioned device resource information and the above-mentioned public network element node, including: drawing the node type of the above-mentioned account device resource node according to the above-mentioned device name; drawing the node image of the above-mentioned account device resource node according to the above-mentioned device type; drawing the connection port of the above-mentioned account device resource node according to the above-mentioned undeployed device interface; drawing the node image of the above-mentioned communication node; drawing the node image of the above-mentioned network identification node, and the connection port of the above-mentioned network identification node.
[0007] Optionally, the above-mentioned construction of the initial network topology structure diagram based on the above-mentioned account device resource nodes, the above-mentioned device resource information and the above-mentioned public network element nodes also includes: drawing a connection line between the above-mentioned account device resource nodes and the above-mentioned communication nodes; drawing a connection line between the above-mentioned account device resource nodes that need to be connected to the external network and the above-mentioned network identification nodes.
[0008] Optionally, the above-mentioned determining the target instruction according to the networking connection relationship in the above-mentioned initial network topology structure diagram includes: obtaining the networking connection relationship in the above-mentioned initial network topology structure diagram; determining the target device and the switch corresponding to the above-mentioned target device according to the above-mentioned networking connection relationship; determining the model information of the above-mentioned switch; and determining the above-mentioned target instruction according to the above-mentioned model information.
[0009] Optionally, the method further includes: displaying the target network topology diagram in a target display device, wherein the connection lines in which the physical connection relationship in the target network topology diagram fails to be deployed are displayed by a first color mark, and the connection lines in which the physical connection relationship in the target network topology diagram is successfully deployed are displayed by a second color mark; the target display device also displays network identification information corresponding to the network identification node, and the network identification information is used to perform network configuration on the account device resource nodes that need to connect to an external network.
[0010] Optionally, the method further includes: in response to a release operation on the networking connection relationship in the target network topology diagram, displaying connection lines in the target network topology diagram with a third color.
[0011] According to another aspect of an embodiment of the present invention, a system for constructing a network topology structure is also provided, including: a resource display module, used to obtain account device resource nodes, device resource information corresponding to the above account device resource nodes, and public network element nodes; a topology drawing module, connected to the above resource display module, used to construct an initial network topology structure diagram based on the above account device resource nodes, the above device resource information and the above public network element nodes; a topology deployment module, connected to the above topology drawing module, used to determine target instructions according to the networking connection relationship in the above initial network topology structure diagram; deploy the physical connection relationship to the above initial network topology structure diagram according to the above target instructions to obtain a target network topology structure diagram.
[0012] According to another aspect of an embodiment of the present invention, a device for constructing a network topology structure is also provided, including: an acquisition unit, used to acquire account device resource nodes, device resource information corresponding to the above-mentioned account device resource nodes, and public network element nodes; a construction unit, used to construct an initial network topology structure diagram based on the above-mentioned account device resource nodes, the above-mentioned device resource information and the above-mentioned public network element nodes; a determination unit, used to determine a target instruction according to the networking connection relationship in the above-mentioned initial network topology structure diagram; a deployment unit, used to deploy the physical connection relationship to the above-mentioned initial network topology structure diagram according to the above-mentioned target instruction, and obtain a target network topology structure diagram.
[0013] According to another aspect of an embodiment of the present invention, a non-volatile storage medium is provided. The non-volatile storage medium stores a plurality of instructions. The instructions are suitable for being loaded by a processor and executing any one of the above-mentioned methods for constructing a network topology structure.
[0014] According to another aspect of an embodiment of the present invention, there is also provided an electronic device, comprising one or more processors and a memory, wherein the memory is used to store one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement any one of the above-mentioned methods for constructing a network topology structure.
[0015] In an embodiment of the present invention, a network topology structure is constructed by obtaining account device resource nodes, device resource information corresponding to the above account device resource nodes, and public network element nodes; an initial network topology structure diagram is constructed based on the above account device resource nodes, the above device resource information and the above public network element nodes; a target instruction is determined according to the networking connection relationship in the above initial network topology structure diagram; and a physical connection relationship is deployed to the above initial network topology structure diagram according to the above target instruction to obtain a target network topology structure diagram, thereby achieving the purpose of automating the deployment of device connection relationships in the network topology structure and realizing efficient deployment, thereby achieving the technical effect of improving the deployment efficiency of device connection relationships in the network topology structure, and then improving the product performance test efficiency and test accuracy, thereby solving the technical problem of low product performance test efficiency and high error rate in the related art of manually deploying device connection relationships in the network topology structure. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] The drawings described herein are used to provide a further understanding of the present invention and constitute a part of this application. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the drawings:
[0017] Figure 1 is a flow chart of a method for constructing a network topology structure according to an embodiment of the present invention;
[0018] Figure 2 is a structural schematic diagram of a system for constructing a network topology structure according to an embodiment of the present invention;
[0019] Figure 3 is a schematic diagram of a system for constructing an optional network topology structure according to an embodiment of the present invention;
[0020] Figure 4 is a schematic diagram of the structure of a device for constructing a network topology structure according to an embodiment of the present invention;
[0021] Figure 5 It is a schematic diagram of the structure of an electronic device according to an embodiment of the present invention. DETAILED DESCRIPTION
[0022] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.
[0023] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0024] When testers of network security product companies conduct product function tests, they need to manually network the test equipment, such as network security products and personal computers (PCs), that is, to build a network topology for device testing and perform network deployment. The networking process requires identifying the target device, finding the switch connection relationship of the target device, and issuing instructions to the switch based on the networking requirements. This process relies on manual operation, which is prone to errors in situations with complex topology levels, a wide variety of switches, and changing test scenarios. It also lacks visibility and cannot clearly see the equipment and networking required for this test.
[0025] A network topology display system is disclosed in the related technology, which includes: a node menu module and a topology drawing module; the node menu module is configured to customize the nodes and pictures in the configuration menu according to the node type; the topology drawing module is configured to obtain the topology nodes, physical security domains and logical domains dragged from the node menu module, the physical security domain is configured with security domain information, and the logical domain is configured with organizational information; each topology node displays the corresponding asset list, and the asset list is saved in the corresponding node after being selected, and the node automatically displays the online status of the current asset and the number of alarms. The network topology display system is implemented through Cytoscape, which includes the following processes: nodes and pictures in the configuration menu are customized according to the node type in the node menu; in the topology drawing canvas, the map nodes, physical security domains and logical domains are obtained by dragging from the node menu module. The physical security domain is configured with security domain information, and the logical domain is configured with organizational information; each topology node displays the corresponding asset list, and the asset list is saved in the corresponding node after being selected. The node automatically displays the online status of the current asset and the number of alarms; any two nodes in the topology drawing canvas can be connected according to the connection instructions and the connection direction can be set.
[0026] It can be seen that the relevant technology can only draw and display the topology based on the actual network configuration of the devices and the established connection relationship between them. It is a static network display, not a dynamic drawing, and it is impossible to achieve dynamic network deployment.
[0027] Example 1
[0028] Based on the above problems, an embodiment of the present invention provides a method embodiment for constructing a network topology structure. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although the logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.
[0029] Figure 1 is a flow chart of a method for constructing a network topology structure according to an embodiment of the present invention. Figure 1 As shown, the method comprises the following steps:
[0030] Step S102, obtaining an account device resource node, device resource information corresponding to the account device resource node, and a public network element node;
[0031] Step S104, constructing an initial network topology diagram based on the account device resource node, the device resource information and the public network element node;
[0032] Step S106, determining the target instruction according to the network connection relationship in the above-mentioned initial network topology diagram;
[0033] Step S108, deploying the physical connection relationship to the initial network topology diagram according to the target instruction to obtain a target network topology diagram.
[0034] Optionally, the above-mentioned device resource information includes at least: device name, undeployed device interface and device type; the above-mentioned public network element node includes at least: a communication node and a network identification node, wherein the above-mentioned communication node tsp can be a virtual local area network communication node (i.e., traffic vlan node), and the above-mentioned network identification node is an Internet access identification cloud.
[0035] Optionally, draw the node type of the account device resource node according to the device name; draw the node image of the account device resource node according to the device type; draw the connection port of the account device resource node according to the undeployed device interface; draw the node image of the communication node; draw the node image of the network identification node and the connection port of the network identification node, and finally construct the initial network topology structure diagram.
[0036] Optionally, an initial network topology diagram may be constructed using a diagram editing engine based on, but not limited to, the account device resource node, the device resource information, and the public network element node.
[0037] Optionally, after obtaining the above-mentioned initial network topology structure diagram, a target instruction corresponding to the network connection relationship is automatically generated according to the networking connection relationship in the above-mentioned initial network topology structure diagram, and the physical connection relationship is automatically deployed to the above-mentioned initial network topology structure diagram according to the above-mentioned target instruction to obtain the target network topology structure diagram. The whole process is implemented in an automated manner without the need for human intervention, thereby achieving the effect of improving the deployment efficiency of the device connection relationship in the network topology structure, which in turn helps to improve the product performance testing efficiency and testing accuracy.
[0038] In an embodiment of the present invention, a network topology structure is constructed by obtaining account device resource nodes, device resource information corresponding to the above account device resource nodes, and public network element nodes; an initial network topology structure diagram is constructed based on the above account device resource nodes, the above device resource information and the above public network element nodes; a target instruction is determined according to the networking connection relationship in the above initial network topology structure diagram; and a physical connection relationship is deployed to the above initial network topology structure diagram according to the above target instruction to obtain a target network topology structure diagram, thereby achieving the purpose of automating the deployment of device connection relationships in the network topology structure and realizing efficient deployment, thereby achieving the technical effect of improving the deployment efficiency of device connection relationships in the network topology structure, and then improving the product performance test efficiency and test accuracy, thereby solving the technical problem of low product performance test efficiency and high error rate in the related art of manually deploying device connection relationships in the network topology structure.
[0039] In an optional embodiment, the device resource information includes at least: a device name, an undeployed device interface, and a device type; the public network element node includes at least: a communication node and a network identification node; and the initial network topology diagram is constructed based on the account device resource node, the device resource information, and the public network element node, including:
[0040] Draw the node type of the above account device resource node according to the above device name;
[0041] Draw a node image of the above account device resource node according to the above device type;
[0042] Draw the connection port of the account device resource node according to the undeployed device interface;
[0043] Draw a node picture of the above communication node;
[0044] Draw a node picture of the network identification node and a connection port of the network identification node.
[0045] Optionally, the initial network topology diagram can be constructed using a graph editing engine antv X6 based on, but not limited to, the account device resource nodes, the device resource information, and the public network element nodes. It should be noted that the graph editing engine antv X6 provides a series of out-of-the-box interactive components and easy-to-use node customization capabilities, which facilitates us to quickly build flowcharts, DAG diagrams, ER diagrams and other graph applications. It is based on the MVC architecture, and users can focus more on data logic and business logic, and can monitor any events occurring in the diagram. Points and lines are the two core elements of the topological network. By changing the styles of points and lines and assigning various information according to needs, the data can be visualized. The use of this graph editing engine can effectively improve the efficiency of building the initial network topology diagram.
[0046] Optionally, the above-mentioned account device resource node corresponds to the device resource information of the target account, which may specifically include hardware device resources and software device resources, wherein the above-mentioned hardware device resources are used to provide operations such as clearing serial ports and restoring factory settings; the above-mentioned virtual device resources are used to provide operations such as remote control, clearing serial ports, device power-on, device power-off and device restart.
[0047] Optionally, nodes (such as account device resource nodes, communication nodes, and network identification nodes) used to construct the initial network topology structure diagram are placed in the target area by dragging and dropping, and the construction of the initial network topology structure diagram is started in the area. If the currently dragged node is an account device resource node, the device resource information corresponding to the account device resource node is obtained, such as the device name, the undeployed device interface, and the device type, and the node type of the account device resource node is drawn according to the above device name, the node image of the account device resource node is drawn according to the above device type, and the connection port of the account device resource node is drawn according to the above undeployed device interface.
[0048] In an optional embodiment, the constructing of the initial network topology diagram based on the account device resource node, the device resource information and the public network element node further includes:
[0049] Draw a connection line between the account device resource node and the communication node;
[0050] Draw a connection line between the account device resource node that needs to be connected to the external network and the network identification node.
[0051] Optionally, nodes used to construct the initial network topology diagram (such as account device resource nodes, communication nodes, and network identification nodes) are placed in the target area by dragging and dropping, and the construction of the initial network topology diagram is started in this area. If the currently dragged node is a public network element node, the node images and connection ports corresponding to different nodes are drawn according to the network element type. The above network element types include at least communication nodes and network identification nodes. It should be noted that the same communication node can be connected to multiple account device resource nodes and network identification nodes. There is no need to draw the connection port of the communication node, and the network identification node has only one connection port.
[0052] Optionally, when drawing the initial network topology diagram, all account device resource nodes and network identification node cloud must be connected to the communication node tsp. The node connection port (i.e., account device resource node or network identification node cloud) connected to the same communication node tsp indicates that they belong to the same virtual local area network communication node traffic vlan node. For the above account device resource nodes that need to connect to the external network, the corresponding network identification node is connected to the communication node tsp to which the account device resource node is connected.
[0053] In an optional embodiment, the determining of the target instruction according to the network connection relationship in the initial network topology structure diagram includes:
[0054] Obtaining the network connection relationship in the above initial network topology diagram;
[0055] Determine the target device and the switch corresponding to the target device according to the above networking connection relationship;
[0056] Determine the model information of the above switch;
[0057] The target instruction is determined according to the model information.
[0058] Optionally, according to the networking information in the above initial network topology diagram, the device connection relationship (i.e., the networking connection relationship) is searched, the target device and the switch corresponding to the above target device are determined according to the above networking connection relationship, the model information of the switch corresponding to the above target device is obtained, and the target instruction is determined according to the above model information. The physical connection relationship is deployed to the initial network topology diagram by issuing the above target instruction, and the physical deployment is automatically completed.
[0059] In an optional embodiment, the above method further includes:
[0060] Displaying the target network topology structure diagram on the target display device, wherein the connection lines in the target network topology structure diagram where the physical connection relationship fails to be deployed are displayed by a first color mark, and the connection lines in the target network topology structure diagram where the physical connection relationship is successfully deployed are displayed by a second color mark;
[0061] The target display device also displays the network identification information corresponding to the network identification node, and the network identification information is used to perform network configuration on the account device resource node that needs to be connected to the external network.
[0062] Optionally, the target display device may be, but is not limited to, a foreground canvas (i.e., a topology drawing canvas), and the first color identifier and the second color identifier respectively represent different colors. For example, the first color identifier may be red, indicating that a physical connection relationship deployment fails through a red connection line; the first color identifier may be green, indicating that a physical connection relationship deployment succeeds through a red connection line.
[0063] Optionally, after the physical connection relationship is deployed to the initial network topology diagram and the target network topology diagram is obtained, the deployment result (i.e., the above-mentioned target network topology diagram) is fed back to the topology drawing canvas, and a red connection line indicates that the physical connection relationship deployment fails, and a red connection line indicates that the physical connection relationship deployment is successful.
[0064] Optionally, the network identification information may include, but is not limited to, a domain name server DNS Serve, an IP address / subnet mask (IP / mask), and a gateway Gateway, etc., and is used to perform network configuration on the account device resource node that needs to connect to an external network.
[0065] Optionally, the switch operation is performed according to the above-mentioned target network topology diagram that has been deployed. If a fault occurs during the operation of the switch, the fault feedback can be made via email, and the log record corresponding to the fault information can be viewed through the display page provided by the system.
[0066] In an optional embodiment, the above method further includes:
[0067] In response to a release operation on the networking connection relationship in the target network topology diagram, connection lines in the target network topology diagram are displayed in a third color.
[0068] Optionally, according to the deployed target network topology diagram, actual switch, open source virtual switch ovs and other operations are performed. In response to the release operation of the above networking connection relationship in the above target network topology diagram, the connection lines in the above target network topology diagram are displayed with a third color mark, for example, the connection lines in the canvas will turn gray.
[0069] Optionally, before executing the above-mentioned operation of deploying the physical connection relationship to the above-mentioned initial network topology structure diagram according to the above-mentioned target instruction to obtain the target network topology structure diagram, the above-mentioned target display interface (ie, the topology drawing canvas) is cleared and all elements on the canvas are deleted.
[0070] Through the above steps, a system with on-demand dynamic networking drawing and one-click topology deployment can be realized. Users only need to drag the target device, draw the interface connection relationship, and click one-click deployment to automatically realize the device switch connection relationship search, command issuance, and topology deployment result presentation functions. This greatly improves the efficiency of testers in building the test environment and realizes dynamic topology formation and disassembly.
[0071] Example 2
[0072] According to an embodiment of the present invention, a system embodiment for implementing the method for constructing the above network topology structure is also provided. Figure 2 is a schematic diagram of a system for constructing a network topology structure according to an embodiment of the present invention. Figure 2 As shown, the above network topology construction system includes: a resource display module 200, a topology drawing module 202 and a topology deployment module 204, wherein:
[0073] The resource display module 200 is used to obtain the account device resource node, the device resource information corresponding to the account device resource node, and the public network element node;
[0074] The topology drawing module 202 is connected to the resource display module and is used to construct an initial network topology diagram based on the account device resource nodes, the device resource information and the public network element nodes;
[0075] The above-mentioned topology deployment module 204 is connected to the above-mentioned topology drawing module, and is used to determine the target instruction according to the networking connection relationship in the above-mentioned initial network topology structure diagram; according to the above-mentioned target instruction, the physical connection relationship is deployed to the above-mentioned initial network topology structure diagram to obtain the target network topology structure diagram.
[0076] In an embodiment of the present invention, the resource display module 200 is provided to obtain the account device resource node, the device resource information corresponding to the account device resource node, and the public network element node; the topology drawing module 202 is connected to the resource display module to construct an initial network topology structure diagram based on the account device resource node, the device resource information and the public network element node; the topology deployment module 204 is connected to the topology drawing module to determine the target instruction according to the networking connection relationship in the initial network topology structure diagram; the physical connection relationship is deployed to the initial network topology structure diagram according to the target instruction to obtain the target network topology structure diagram, thereby achieving the purpose of automating the deployment of the device connection relationship in the network topology structure and realizing efficient deployment, thereby achieving the technical effect of improving the deployment efficiency of the device connection relationship in the network topology structure, and then improving the product performance test efficiency and test accuracy, thereby solving the technical problem of low product performance test efficiency and high error rate in the related technology of manually deploying the device connection relationship in the network topology structure.
[0077] As an optional embodiment, Figure 3 is a schematic diagram of a system for constructing an optional network topology structure according to an embodiment of the present invention. Figure 3 As shown, the system includes: a resource display module, a topology drawing module and a topology deployment module.
[0078] The above resource display module can be divided into a public network element part and a my resource part. The public network element part corresponds to the public network element node, which includes a communication node tsp and a network identification node cloud. Tsp represents a virtual local area network communication node (i.e., traffic vlan node), and cloud is an Internet access identifier. My resource part corresponds to the account device resource node, which is used to display the device resource information of all target accounts under the target account, which may specifically include hardware device resources and software device resources. The above hardware device resources are used to provide operations such as clearing serial ports and restoring factory settings; the above virtual device resources are used to provide operations such as remote control, clearing serial ports, powering on the device, powering off the device, and restarting the device.
[0079] For the above-mentioned topology drawing module, the module can be implemented by, but not limited to, the utility diagram editing engine antv X6. The nodes (such as account device resource nodes, communication nodes, and network identification nodes) used to construct the initial network topology structure diagram are placed in the target area by dragging and dropping, and the construction of the initial network topology structure diagram is started in the area. If the currently dragged node is an account device resource node, the device resource information corresponding to the account device resource node is obtained, such as the device name, the undeployed device interface, and the device type, and the node type of the above-mentioned account device resource node is drawn according to the above-mentioned device name, the node image of the above-mentioned account device resource node is drawn according to the above-mentioned device type, and the connection port of the above-mentioned account device resource node is drawn according to the above-mentioned undeployed device interface. If the currently dragged node is a public network element node, the node image and connection port corresponding to different nodes are drawn according to the network element type, and the above-mentioned network element type includes at least a communication node and a network identification node. It should be noted that the same communication node can be connected to multiple account device resource nodes and network identification nodes, and the connection port of the communication node does not need to be drawn, and the network identification node has only one connection port.
[0080] It should be noted that when drawing the initial network topology diagram, all account device resource nodes and network identification node cloud must be connected to the communication node tsp. The node connection port (i.e. account device resource node or network identification node cloud) connected to the same communication node tsp indicates that they belong to the same virtual local area network communication node trafficvlan node. For the above account device resource nodes that need to connect to the external network, the corresponding network identification node is connected to the communication node tsp to which the account device resource node is connected.
[0081] The above topology deployment module can provide topology deployment, topology release, and topology deletion functions, among which:
[0082] For the above topology deployment function, according to the networking information in the above initial network topology diagram, the device connection relationship (i.e., the networking connection relationship) is searched, the target device and the switch corresponding to the above target device are determined according to the above networking connection relationship, the model information of the switch corresponding to the above target device is obtained, and the target instruction is determined according to the above model information. The physical connection relationship is deployed to the initial network topology diagram by issuing the above target instruction, and the physical deployment is automatically completed. After the deployment is completed, the deployment result (i.e., the above target network topology diagram) is fed back to the topology drawing canvas, and the red connection line indicates that the physical connection relationship deployment fails, and the red connection line indicates that the physical connection relationship deployment is successful. The domain name server DNS Serve, IP address / subnet mask (IP / mask) and gateway Gateway will be displayed next to the network identification node, which are used to perform network configuration for the above account device resource nodes that need to connect to the external network. According to the above target network topology diagram that has been deployed, the switch operation is performed. If a fault occurs during the operation of the switch, the fault feedback can be made by email, and the log record corresponding to the fault information can be viewed through the display page provided by the system.
[0083] For the above topology release function, according to the above target network topology diagram that has been deployed, the actual switch, Kaiyuan virtual switch ovs and other operations are performed. In response to the release operation of the above networking connection relationship in the above target network topology diagram, the connection lines in the above target network topology diagram are displayed with a third color mark, for example, the connection lines in the canvas will turn gray.
[0084] For the above-mentioned topology deletion function, before executing the above-mentioned operation of deploying the physical connection relationship to the above-mentioned initial network topology structure diagram according to the above-mentioned target instructions to obtain the target network topology structure diagram, the above-mentioned target display interface (ie, the topology drawing canvas) is cleared and all elements on the canvas are deleted.
[0085] It should be noted that in this application Figures 2 to 3 The specific structure of the network topology construction system shown in the figure is only for reference. In specific applications, the network topology construction system in this application can be compared to Figures 2 to 3 The resource display module, topology drawing module and topology deployment module shown have more or less structures.
[0086] It should be noted that any optional or preferred method for constructing a network topology structure in the above embodiments can be executed or implemented in the network topology structure construction system provided in this embodiment.
[0087] In addition, it is still necessary to explain that the optional or preferred implementation of this embodiment can refer to the relevant description in the embodiment, which will not be repeated here.
[0088] Example 3
[0089] In this embodiment, a device for constructing a network topology structure is also provided, and the device is used to implement the above-mentioned embodiments and preferred implementation modes, and the descriptions that have been made will not be repeated. As used below, the terms "unit" and "device" can implement a combination of software and / or hardware of a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and conceivable.
[0090] According to an embodiment of the present invention, there is also provided an apparatus embodiment for implementing the method for constructing the above network topology structure. Figure 4 is a schematic diagram of a structure of a device for constructing a network topology structure according to an embodiment of the present invention. Figure 4 As shown, the above-mentioned network topology construction device includes: an acquisition unit 400, a construction unit 402, a determination unit 404 and a deployment unit 406, wherein:
[0091] The acquisition unit 400 is used to acquire the account device resource node, the device resource information corresponding to the account device resource node, and the public network element node;
[0092] The construction unit 402 is connected to the acquisition unit 400 and is used to construct an initial network topology diagram based on the account device resource node, the device resource information and the public network element node;
[0093] The determination unit 404 is connected to the construction unit 402 and is used to determine the target instruction according to the network connection relationship in the initial network topology diagram;
[0094] The deployment unit 406 is connected to the determination unit 404 and is used to deploy the physical connection relationship to the initial network topology structure diagram according to the target instruction to obtain a target network topology structure diagram.
[0095] In the embodiment of the present invention, the acquisition unit 400 is provided to acquire the account device resource node, the device resource information corresponding to the account device resource node, and the public network element node; the construction unit 402 is connected to the acquisition unit 400 to construct an initial network topology structure diagram based on the account device resource node, the device resource information and the public network element node; the determination unit 404 is connected to the construction unit 402 to determine the target instruction according to the networking connection relationship in the initial network topology structure diagram; the deployment unit 406 is connected to the determination unit 404 to deploy the physical connection relationship to the initial network topology structure diagram according to the target instruction to obtain the target network topology structure diagram, thereby achieving the purpose of automating the deployment of the device connection relationship in the network topology structure and realizing efficient deployment, thereby achieving the technical effect of improving the deployment efficiency of the device connection relationship in the network topology structure, and then improving the product performance test efficiency and test accuracy, thereby solving the technical problem of low product performance test efficiency and high error rate in the related art of manually deploying the device connection relationship in the network topology structure.
[0096] Optionally, the above-mentioned device resource information includes at least: a device name, an undeployed device interface and a device type; the above-mentioned public network element node includes at least: a communication node and a network identification node; the above-mentioned construction unit includes: a first drawing subunit, used to draw the node type of the above-mentioned account device resource node according to the above-mentioned device name; a second drawing subunit, used to draw the node image of the above-mentioned account device resource node according to the above-mentioned device type; a third drawing subunit, used to draw the connection port of the above-mentioned account device resource node according to the above-mentioned undeployed device interface; a fourth drawing subunit, used to draw the node image of the above-mentioned communication node; a fifth drawing subunit, used to draw the node image of the above-mentioned network identification node, and the connection port of the above-mentioned network identification node.
[0097] Optionally, the above-mentioned initial network topology structure diagram is constructed based on the above-mentioned account device resource node, the above-mentioned device resource information and the above-mentioned public network element node, and also includes: a sixth drawing subunit, used to draw a connection line between the above-mentioned account device resource node and the above-mentioned communication node; and a seventh drawing subunit, used to draw a connection line between the above-mentioned account device resource node that needs to be connected to an external network and the above-mentioned network identification node.
[0098] Optionally, the above-mentioned construction unit also includes: a first acquisition sub-unit, used to acquire the networking connection relationship in the above-mentioned network topology diagram; a first determination sub-unit, used to determine the target device and the switch corresponding to the above-mentioned target device according to the above-mentioned networking connection relationship; a second determination sub-unit, used to determine the model information of the above-mentioned switch; and a third determination sub-unit, used to determine the above-mentioned target instruction according to the above-mentioned model information.
[0099] Optionally, the above-mentioned device also includes: a first display sub-unit, used to display the above-mentioned target network topology diagram in the target display device, wherein the connection line in the above-mentioned target network topology diagram where the above-mentioned physical connection relationship deployment fails is displayed by a first color mark, and the connection line in the above-mentioned target network topology diagram where the above-mentioned physical connection relationship deployment succeeds is displayed by a second color mark; a second display sub-unit, used for the above-mentioned target display device to also display the network identification information corresponding to the above-mentioned network identification node, and the above-mentioned network identification information is used to perform network configuration on the above-mentioned account device resource node that needs to connect to an external network.
[0100] Optionally, the above-mentioned device also includes: a third display subunit, which is used to respond to the release operation of the above-mentioned networking connection relationship in the above-mentioned target network topology diagram, and display the connection lines in the above-mentioned target network topology diagram with a third color mark.
[0101] It should be noted that the above modules can be implemented by software or hardware. For example, for the latter, it can be implemented in the following ways: the above modules can be located in the same processor; or the above modules can be located in different processors in any combination.
[0102] It should be noted that the acquisition unit 400, the construction unit 402, the determination unit 404 and the deployment unit 406 correspond to steps S102 to S108 in the embodiment, and the examples and application scenarios implemented by the modules and the corresponding steps are the same, but are not limited to the contents disclosed in the embodiment. It should be noted that the modules as part of the device can be run in a computer terminal.
[0103] It should be noted that the optional or preferred implementation of this embodiment can refer to the relevant description in the embodiment, which will not be repeated here.
[0104] The above-mentioned network topology construction device may also include a processor and a memory. The above-mentioned acquisition unit 400, construction unit 402, determination unit 404 and deployment unit 406 are all stored in the memory as program units, and the processor executes the above-mentioned program units stored in the memory to realize corresponding functions.
[0105] The processor includes a kernel, which retrieves the corresponding program unit from the memory. The kernel may be one or more. The memory may include non-permanent memory in a computer-readable medium, random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. The memory includes at least one memory chip.
[0106] According to an embodiment of the present application, an embodiment of a non-volatile storage medium is also provided. Optionally, in this embodiment, the non-volatile storage medium includes a stored program, wherein when the program is executed, the device where the non-volatile storage medium is located is controlled to execute any of the above-mentioned methods for constructing a network topology structure.
[0107] Optionally, in this embodiment, the non-volatile storage medium may be located in any computer terminal in a computer terminal group in a computer network, or in any mobile terminal in a mobile terminal group, and the non-volatile storage medium includes a stored program.
[0108] Optionally, when the program is running, the device where the non-volatile storage medium is located is controlled to perform the following functions: obtain account device resource nodes, device resource information corresponding to the above account device resource nodes, and public network element nodes; construct an initial network topology structure diagram based on the above account device resource nodes, the above device resource information and the above public network element nodes; determine the target instruction according to the networking connection relationship in the above initial network topology structure diagram; deploy the physical connection relationship to the above initial network topology structure diagram according to the above target instruction to obtain the target network topology structure diagram.
[0109] According to an embodiment of the present application, an embodiment of a processor is also provided. Optionally, in this embodiment, the processor is used to run a program, wherein when the program is run, any of the methods for constructing a network topology structure is executed.
[0110] like Figure 5 As shown, an embodiment of the present invention provides an electronic device, which includes a processor, a memory, and a program stored in the memory and executable on the processor. When the processor executes the program, the following steps are implemented: obtaining an account device resource node, device resource information corresponding to the above-mentioned account device resource node, and a public network element node; constructing an initial network topology structure diagram based on the above-mentioned account device resource node, the above-mentioned device resource information, and the above-mentioned public network element node; determining a target instruction according to the networking connection relationship in the above-mentioned initial network topology structure diagram; and deploying the physical connection relationship to the above-mentioned initial network topology structure diagram according to the above-mentioned target instruction to obtain a target network topology structure diagram.
[0111] The present application also provides a computer program product, which, when executed on a data processing device, is suitable for executing an initialization program having the following method steps: obtaining an account device resource node, device resource information corresponding to the above-mentioned account device resource node, and a public network element node; constructing an initial network topology structure diagram based on the above-mentioned account device resource node, the above-mentioned device resource information and the above-mentioned public network element node; determining a target instruction according to the networking connection relationship in the above-mentioned initial network topology structure diagram; and deploying the physical connection relationship to the above-mentioned initial network topology structure diagram according to the above-mentioned target instruction to obtain a target network topology structure diagram.
[0112] Optionally, the computer program product is also suitable for executing a program that initializes the following method steps: device name, undeployed device interface and device type, the public network element node at least includes: a communication node and a network identification node, and the initial network topology structure diagram is constructed based on the account device resource node, the device resource information and the public network element node, including: drawing the node type of the account device resource node according to the device name; drawing the node image of the account device resource node according to the device type; drawing the connection port of the account device resource node according to the undeployed device interface; drawing the node image of the communication node; drawing the node image of the network identification node, and the connection port of the network identification node.
[0113] Optionally, the computer program product is further suitable for executing a program that initializes the following method steps: drawing a connection line between the account device resource node and the communication node; drawing a connection line between the account device resource node that needs to be connected to an external network and the network identification node.
[0114] Optionally, the above-mentioned computer program product is also suitable for executing an initialization program having the following method steps: obtaining the networking connection relationship in the above-mentioned initial network topology structure diagram; determining the target device and the switch corresponding to the above-mentioned target device based on the above-mentioned networking connection relationship; determining the model information of the above-mentioned switch; and determining the above-mentioned target instruction based on the above-mentioned model information.
[0115] Optionally, the above-mentioned computer program product is also suitable for executing an initialized program having the following method steps: displaying the above-mentioned target network topology structure diagram in the target display device, wherein the connection lines in the above-mentioned target network topology structure diagram where the above-mentioned physical connection relationship deployment fails are displayed by a first color mark, and the connection lines in the above-mentioned target network topology structure diagram where the above-mentioned physical connection relationship deployment succeeds are displayed by a second color mark; the above-mentioned target display device also displays the network identification information corresponding to the above-mentioned network identification node, and the above-mentioned network identification information is used to perform network configuration on the above-mentioned account device resource nodes that need to connect to an external network.
[0116] Optionally, the above-mentioned computer program product is also suitable for executing a program initialized with the following method steps: in response to a release operation acting on the above-mentioned networking connection relationship in the above-mentioned target network topology diagram, displaying the connection lines in the above-mentioned target network topology diagram with a third color mark.
[0117] The serial numbers of the above embodiments of the present invention are only for description and do not represent the advantages or disadvantages of the embodiments.
[0118] In the above embodiments of the present invention, the description of each embodiment has its own emphasis. For parts that are not described in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0119] In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. Among them, the device embodiments described above are only schematic. For example, the division of the above-mentioned units can be a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of units or modules, which can be electrical or other forms.
[0120] The units described above as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple units. Some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.
[0121] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0122] If the above-mentioned integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable non-volatile storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a non-volatile storage medium, including a number of instructions for a computer device (which can be a personal computer, server or network device, etc.) to perform all or part of the steps of the above-mentioned methods of each embodiment of the present invention. The aforementioned non-volatile storage medium includes: U disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), mobile hard disk, magnetic disk or optical disk and other media that can store program codes.
[0123] The above are only preferred embodiments of the present invention. It should be pointed out that, for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.
Claims
1. A method for constructing a network topology structure, characterized in that: include: Acquire an account device resource node, device resource information corresponding to the account device resource node, and a public network element node, wherein the device resource information includes at least: a device name, an undeployed device interface, and a device type, and the public network element node includes at least: a communication node and a network identification node; Constructing an initial network topology diagram based on the account device resource node, the device resource information and the public network element node; Determining a target instruction according to the network connection relationship in the initial network topology diagram; Deploying the physical connection relationship to the initial network topology structure diagram according to the target instruction to obtain a target network topology structure diagram, wherein the target network topology structure is a network topology structure used for device testing; The step of determining the target instruction according to the network connection relationship in the initial network topology diagram includes: Acquire the network connection relationship in the initial network topology diagram; determine the target device and the switch corresponding to the target device according to the network connection relationship; determine the model information of the switch; determine the target instruction according to the model information; Among them, the constructing of the initial network topology structure diagram based on the account device resource node, the device resource information and the public network element node includes: drawing the node type of the account device resource node according to the device name; drawing the node image of the account device resource node according to the device type; drawing the connection port of the account device resource node according to the undeployed device interface; drawing the node image of the communication node; drawing the node image of the network identification node, and the connection port of the network identification node.
2. The method according to claim 1, characterized in that The constructing an initial network topology diagram based on the account device resource node, the device resource information and the public network element node also includes: Draw a connection line between the account device resource node and the communication node; Draw a connection line between the account device resource node that needs to be connected to the external network and the network identification node.
3. The method according to claim 2, characterized in that The method further comprises: Displaying the target network topology structure diagram on a target display device, wherein the connection lines in the target network topology structure diagram where the physical connection relationship deployment fails are displayed by a first color mark, and the connection lines in the target network topology structure diagram where the physical connection relationship deployment succeeds are displayed by a second color mark; The target display device also displays network identification information corresponding to the network identification node, and the network identification information is used to perform network configuration on the account device resource node that needs to be connected to an external network.
4. The method according to claim 3, characterized in that The method further comprises: In response to a release operation on the networking connection relationship in the target network topology structure diagram, connection lines in the target network topology structure diagram are displayed in a third color.
5. A system for constructing a network topology structure, characterized in that: include: A resource display module, used to obtain an account device resource node, device resource information corresponding to the account device resource node, and a public network element node, wherein the device resource information at least includes: a device name, an undeployed device interface, and a device type, and the public network element node at least includes: a communication node and a network identification node; A topology drawing module, connected to the resource display module, for constructing an initial network topology diagram based on the account device resource nodes, the device resource information and the public network element nodes; A topology deployment module is connected to the topology drawing module and is used to determine a target instruction according to the networking connection relationship in the initial network topology structure diagram; deploy the physical connection relationship to the initial network topology structure diagram according to the target instruction to obtain a target network topology structure diagram, wherein the target network topology is a network topology structure used for device testing; The topology deployment module is also used to: obtain the network connection relationship in the initial network topology structure diagram; determine the target device and the switch corresponding to the target device according to the network connection relationship; determine the model information of the switch; and determine the target instruction according to the model information; Among them, the topology drawing module is also used to: draw the node type of the account device resource node according to the device name; draw the node image of the account device resource node according to the device type; draw the connection port of the account device resource node according to the undeployed device interface; draw the node image of the communication node; draw the node image of the network identification node, and the connection port of the network identification node.
6. A device for constructing a network topology structure, characterized in that: include: An acquisition unit, configured to acquire an account device resource node, device resource information corresponding to the account device resource node, and a public network element node, wherein the device resource information at least includes: a device name, an undeployed device interface, and a device type, and the public network element node at least includes: a communication node and a network identification node; A construction unit, configured to construct an initial network topology diagram based on the account device resource node, the device resource information, and the public network element node; A determination unit, configured to determine a target instruction according to a network connection relationship in the initial network topology diagram; A deployment unit, configured to deploy the physical connection relationship to the initial network topology structure diagram according to the target instruction, to obtain a target network topology structure diagram, wherein the target network topology structure is a network topology structure used for device testing; The determining unit is further used to: obtain the network connection relationship in the initial network topology diagram; determine the target device and the switch corresponding to the target device according to the network connection relationship; determine the model information of the switch; and determine the target instruction according to the model information; The construction unit is further used to: draw the node type of the account device resource node according to the device name; draw the node image of the account device resource node according to the device type; draw the connection port of the account device resource node according to the undeployed device interface; draw the node image of the communication node; draw the node image of the network identification node, and the connection port of the network identification node.
7. A non-volatile storage medium, characterized in that: The non-volatile storage medium stores a plurality of instructions, and the instructions are suitable for being loaded by a processor and executing the method for constructing a network topology structure as described in any one of claims 1 to 4.
8. An electronic device, characterized in that: It includes one or more processors and a memory, wherein the memory is used to store one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement the method for constructing a network topology structure as described in any one of claims 1 to 4.
Citation Information
Patent Citations
Construction method and device of network topology structure, storage medium and terminal
CN110493058A
Dynamic network topology management system and method
CN111741382A
Network topology construction method, apparatus and device, and storage medium
CN111934922A
Method for constructing virtual-real decoupling simulation network
CN112311606A
Resource virtual-real mapping method for virtual network construction in multi-hop network
CN112953761A
