CN113630291A - Method, device and equipment for testing processing capability of network control plane and readable medium - Google Patents

Method, device and equipment for testing processing capability of network control plane and readable medium Download PDF

Info

Publication number
CN113630291A
CN113630291A CN202110865556.7A CN202110865556A CN113630291A CN 113630291 A CN113630291 A CN 113630291A CN 202110865556 A CN202110865556 A CN 202110865556A CN 113630291 A CN113630291 A CN 113630291A
Authority
CN
China
Prior art keywords
port
network
time
ports
interface
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202110865556.7A
Other languages
Chinese (zh)
Inventor
周恒�
秦海中
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhengzhou Inspur Data Technology Co Ltd
Original Assignee
Jinan Inspur Data Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Jinan Inspur Data Technology Co Ltd filed Critical Jinan Inspur Data Technology Co Ltd
Priority to CN202110865556.7A priority Critical patent/CN113630291A/en
Publication of CN113630291A publication Critical patent/CN113630291A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/50Testing arrangements
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/0803Configuration setting

Abstract

The invention provides a method, a device, equipment and a readable medium for testing the processing capability of a network control plane, wherein the method comprises the following steps: concurrently creating ports with threshold quantity, and recording the starting time and the ending time of creating the ports; responding to the completion of port creation, simulating each port UP, checking the state of the port and recording the starting time and the ending time of the port UP; in response to the completion of the port UP, deleting the created port and recording the completion time of deleting the port; and evaluating the processing capacity of the network control plane according to the recorded starting time and ending time of creating the port, the starting time and ending time of the port UP and the completion time of deleting the port. By using the scheme of the invention, the concurrent processing capability of the openstack network control plane can be tested in a real full flow, a large amount of concurrency can be tested in a small computing cluster, and the loss caused by problems in real large-scale testing can be effectively reduced.

Description

Method, device and equipment for testing processing capability of network control plane and readable medium
Technical Field
The field relates to the field of computers, and more particularly to a method, apparatus, device and readable medium for testing network control plane processing capability.
Background
There are many tools for testing the control surface of the openstack cloud platform. There are also many schemes, such as calling the interface of the batch creation virtual machine, creating the virtual machine indirectly calling the network related interface, and equal to indirectly testing the performance of the network control plane. The problem of this scheme is that the first scale is difficult to be increased, the number of virtual machines that can be created is related to the number of computing nodes, and the number of computing nodes is small and the number of computing nodes that can be created in batches is small. Furthermore, it is desirable to test large-scale concurrent test cluster processing capacity with fewer clusters as much as possible. Another problem is that the process of creating the virtual machine is long and slow, and when the network related interface is called, the call is already performed in a dispersed time, and the call is not a network control plane interface which is called concurrently. The measured value is not accurate at this time.
Disclosure of Invention
In view of this, embodiments of the present invention provide a method, an apparatus, a device, and a readable medium for testing a processing capability of a network control plane, where by using the technical solution of the present invention, a concurrent processing capability of an openstack network control plane can be tested in a real full flow, a large amount of concurrency can be tested in a small computing cluster, and loss caused by problems occurring in a real large-scale test can be effectively reduced.
In view of the above, an aspect of the embodiments of the present invention provides a method for testing processing capability of a network control plane, including the following steps:
concurrently creating ports with threshold quantity, and recording the starting time and the ending time of creating the ports;
responding to the completion of port creation, simulating each port UP, checking the state of the port and recording the starting time and the ending time of the port UP;
in response to the completion of the port UP, deleting the created port and recording the completion time of deleting the port;
and evaluating the processing capacity of the network control plane according to the recorded starting time and ending time of creating the port, the starting time and ending time of the port UP and the completion time of deleting the port.
According to an embodiment of the present invention, concurrently creating a threshold number of ports and recording a start time and an end time of creating the ports comprises:
setting a network name, a subnet name and a port name, and judging whether a network exists according to the network name;
responding to the absence of the network, calling a POST/v2.0/networks interface to create the network;
judging whether the subnet exists according to the subnet name and the ID of the created network;
responding to the absence of the subnet, calling a POST/v2.0/subnet interface to create the subnet;
judging whether a port exists according to the ID and the port name of the created network;
responding to the absence of the port, calling a POST/v2.0/ports interface to create the port, putting a task of creating the port into a protocol pool for carrying out and setting a self-defined equipment owner;
the start time of port creation and the completion time of port creation are recorded.
According to one embodiment of the invention, judging whether the network exists according to the network name comprises calling a GET/v2.0/networks interface to judge whether the network exists;
judging whether the subnet exists according to the subnet name and the ID of the created network, wherein the step of calling GET/v2.0/subnet interface to judge whether the subnet exists;
judging whether the port exists according to the ID and the port name of the created network comprises calling a GET/v2.0/ports interface to judge whether the port exists.
According to one embodiment of the invention, simulating each port UP in response to port creation completion comprises:
circularly binding the created port to a computing node of a host by calling PUT/v 2.0/ports;
calling an ovsdb client of the computing node, creating an ovs internal type interface, and setting external _ ids information of the interface;
creating a network name space according to the port name through remote system call;
adding the created ovs internal type interface into a network name space;
the port is UP using an ip link command.
According to one embodiment of the invention, the ovsdb client of the computing node is called, an ovs internal type interface is created, and the setting of external _ ids information of the interface comprises the following steps:
setting external _ IDs. iface-ID as ID of port;
if-status is set to active;
external _ ids. attached-MAC is set to the MAC address of the port.
According to one embodiment of the invention, verifying the state of the port comprises:
periodically inquiring the network ID and the port state of the equipment owner, which are transmitted into a database;
responding to the first inquiry of the port UP of the device owner and the port under the network ID, and recording the time of the port UP;
responding to the completion of the creation of all the ports, and periodically inquiring the network ID transmitted in the database and the port state which is under the equipment owner and is in the down state;
responding to the first inquiry that one port is not included, judging one UP port, and recording the UP time of the port;
in response to all ports having been UP or a timeout being reached, the check port state ends.
According to an embodiment of the present invention, deleting a created port and recording a completion time of deleting the port in response to the port UP completion includes:
calling a GET/v2.0/ports interface to inquire port information according to the network ID and the port name;
responding to the query of the computing node of which the port is bound with the host, and calling the ovsdb client of the bound computing node to delete ovs the interface according to the port name;
the network namespace is deleted at the binding compute node and the DELETE/v2.0/ports/{ port _ id } interface is invoked, deleting the port.
In another aspect of the embodiments of the present invention, there is also provided an apparatus for testing processing capability of a network control plane, where the apparatus includes:
the creating module is configured to concurrently create a threshold number of ports and record the starting time and the ending time of creating the ports;
the checking module is configured to simulate each port UP in response to the completion of port creation, check the state of the port and record the starting time and the ending time of the port UP;
the deleting module is configured to respond to the completion of the port UP, delete the created port and record the completion time of deleting the port;
and the evaluation module is configured to evaluate the processing capacity of the network control plane according to the recorded start time and end time of creating the port, the start time and end time of the port UP and the completion time of deleting the port.
In another aspect of an embodiment of the present invention, there is also provided a computer apparatus including:
at least one processor; and
a memory storing computer instructions executable on the processor, the instructions when executed by the processor implementing the steps of any of the methods described above.
In another aspect of the embodiments of the present invention, there is also provided a computer-readable storage medium storing a computer program, which when executed by a processor implements the steps of any one of the above-mentioned methods.
The invention has the following beneficial technical effects: according to the method for testing the processing capability of the network control plane, the ports with the threshold number are created concurrently, and the starting time and the ending time of creating the ports are recorded; responding to the completion of port creation, simulating each port UP, checking the state of the port and recording the starting time and the ending time of the port UP; in response to the completion of the port UP, deleting the created port and recording the completion time of deleting the port; according to the technical scheme of evaluating the processing capacity of the network control plane according to the recorded starting time and ending time of creating the port, the starting time and ending time of the port UP and the finishing time of deleting the port, the concurrent processing capacity of the openstack network control plane can be truly tested in a full flow, a large amount of concurrent can be tested in a small computing cluster, and loss caused by problems in real large-scale testing can be effectively reduced.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art that other embodiments can be obtained by using the drawings without creative efforts.
Fig. 1 is a schematic flow diagram of a method of testing the processing capability of the network control plane according to one embodiment of the invention;
fig. 2 is a schematic diagram of an apparatus for testing the processing capability of the control plane of a network according to an embodiment of the present invention;
FIG. 3 is a schematic diagram of a computer device according to one embodiment of the present invention;
fig. 4 is a schematic diagram of a computer-readable storage medium according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the following embodiments of the present invention are described in further detail with reference to the accompanying drawings.
In view of the above object, a first aspect of the embodiments of the present invention proposes an embodiment of a method for testing the processing capability of a network control plane. Fig. 1 shows a schematic flow diagram of the method.
As shown in fig. 1, the method may include the steps of:
s1 concurrently creates a threshold number of ports and records the start time and end time of creating the ports.
When the resources are created, the names are predefined, for example, before a port is created, a network and a subnet need to be created, the network and the subnet are created by using fixed names, when the port is created, a name is also created by adding a subscript according to a prefix, a GET/v2.0/networks interface is called to judge whether the network exists or not according to the predefined network name, if the network does not exist, a POST/v2.0/networks interface is called to create the network, if the network exists, the network information is directly used, then a GET/v2.0/networks interface is called to judge whether the subnet exists or not according to the subnet name and the network ID, if the subnet does not exist, the POST/v2.0/networks interface is called to create the subnet, if the subnet information exists, then a port creating flow is submitted to a protocol pool, the protocol pool is executed concurrently, and if the port exists, a GET/v2.0/s interface is called according to the network ID and the port name, if the port is not established, the POST/v2.0/ports interface is called to establish the port, and a user-defined device _ owner (such as a computer: ns-ovs) is required to be set during establishment, so that the subsequent port state confirmation can be conveniently carried out, and the port establishment starting time and the port establishment finishing time are recorded.
S2 simulates each port UP in response to completion of port creation, and verifies the status of the port and records the start time and end time of the port UP.
Selecting each computing node according to the created port, where the selection algorithm may be sequentially selected from a computing node list or other algorithms, but it is to be ensured that the node selected each time is not changed, and a principle that the execution can be repeated is not damaged, for example, if 3 computing nodes are selected for 100 ports, a first computing node is selected for a first port, a second computing node is selected for a second port, a third computing node is selected for a third port, a first computing node is selected for a fourth port, and so on. And then calling a host computer set with PUT/v2.0/ports for binding, binding the ports to the selected computing nodes, and recording the binding completion time. And then calling the ovsdb client of the selected computing node, creating an ovs internal type interface, simultaneously setting the external _ IDs of the interface, setting the external _ IDs. iface-ID as the ID of the port, setting the external _ IDs. iface-status as the active, and setting the external _ IDs. attected-mac as the mac address of the port. Setting external _ ids is necessary, otherwise, the flow of neutron cannot identify that the external _ ids is a port of neutron, and the UP process is carried out, and the setting completion time is recorded after the setting is completed. Then creating a network name space according to the port number name through remote system call, adding ovs interface into the network name space, and then using ip link command to enable the interface state to be UP. The optional steps are to execute the dhclient command, record the start time, and the successful execution time through remote system call, and if the processing capability of the control plane dhcp-server is tested, the step can be executed. The port check adopts a mode of directly querying the database instead of calling a neutron-server interface. The query database is faster, the processing speed can be reflected better, meanwhile, stress is not caused to neutron-server, the processing capacity of the created port can be tested at the limit, in order to improve the efficiency and reduce the interaction with the database, the port state is divided into two stages, namely a first stage: since the port state check is started after the creation of the port is submitted, and a process is required for creating the port, when the port is acquired, the acquired number is smaller than the created number, which is defined as a first stage, and the first stage comprises the following steps: and (3) periodically querying the network ID and device _ owner which are transmitted by the database, wherein the device _ owner is a computer, and ns-ovs (set when the port is created), and recording the time of the port UP if the port is the port UP queried for the first time according to the returned port state. And a second stage: all ports are created and we define the second phase. When the number of the query return ports is consistent with the created number in the first stage, entering a second stage, and processing the second stage: the periodic query database is used for inputting a network ID, device _ owner, ns-ovs and status, and if a certain port is not included in the queried port for the first time, the port is considered to be UP, and the port UP time is recorded. All ports are UP or reach the overtime, and the port state checking process is considered to be finished.
S3 deletes the created port and records the completion time of deleting the port in response to the port UP completion.
Invoking a GET/v2.0/ports interface, querying a port according to a network ID and a port name, ending the process if the query is not successful, otherwise, judging whether the port is bound with a host, if the port is not bound, directly invoking a DELETE/v2.0/ports/{ port _ ID } interface, deleting the port, if the port is bound, invoking an ovsdb client of a binding calculation node, deleting ovs the interface according to the name, executing a command of deleting a network namespace through remotely invoking a calculation node bound, and then invoking DELETE/v2.0/ports/{ port _ ID } interface to DELETE the port.
S4 evaluates the processing capability of the network control plane based on the recorded start time and end time of creating a port, start time and end time of port UP, and completion time of deleting a port.
The total time of creating ports can be obtained according to the recorded start time and end time of creating ports, for example, the number of creating ports is 1000, and the total time is 5 minutes, so that the creating capacity is 1000 created for 5 minutes. The time of other records can be calculated according to the requirement to obtain the processing capacity.
By the technical scheme, the concurrent processing capacity of the openstack network control plane can be tested in a real full flow, a large amount of concurrency can be tested in a small computing cluster, and loss caused by problems in real large-scale testing can be effectively reduced.
In a preferred embodiment of the present invention, concurrently creating a threshold number of ports and recording a start time and an end time of creating the ports comprises:
setting a network name, a subnet name and a port name, and judging whether a network exists according to the network name;
responding to the absence of the network, calling a POST/v2.0/networks interface to create the network;
judging whether the subnet exists according to the subnet name and the ID of the created network;
responding to the absence of the subnet, calling a POST/v2.0/subnet interface to create the subnet;
judging whether a port exists according to the ID and the port name of the created network;
responding to the absence of the port, calling a POST/v2.0/ports interface to create the port, putting a task of creating the port into a protocol pool for carrying out and setting a self-defined equipment owner;
the start time of port creation and the completion time of port creation are recorded.
In a preferred embodiment of the present invention, judging whether a network exists according to a network name includes calling a GET/v2.0/networks interface to judge whether the network exists;
judging whether the subnet exists according to the subnet name and the ID of the created network, wherein the step of calling GET/v2.0/subnet interface to judge whether the subnet exists;
judging whether the port exists according to the ID and the port name of the created network comprises calling a GET/v2.0/ports interface to judge whether the port exists.
In a preferred embodiment of the present invention, simulating each port UP in response to completion of port creation comprises:
circularly binding the created port to a computing node of a host by calling PUT/v 2.0/ports;
calling an ovsdb client of the computing node, creating an ovs internal type interface, and setting external _ ids information of the interface;
creating a network name space according to the port name through remote system call;
adding the created ovs internal type interface into a network name space;
the port is UP using an ip link command.
In a preferred embodiment of the present invention, invoking the ovsdb client of the compute node, creating an ovs internal type interface, and setting external _ ids information of the interface includes:
setting external _ IDs. iface-ID as ID of port;
if-status is set to active;
external _ ids. attached-MAC is set to the MAC address of the port.
In a preferred embodiment of the present invention, verifying the state of the port comprises:
periodically inquiring the network ID and the port state of the equipment owner, which are transmitted into a database;
responding to the first inquiry of the port UP of the device owner and the port under the network ID, and recording the time of the port UP;
responding to the completion of the creation of all the ports, and periodically inquiring the network ID transmitted in the database and the port state which is under the equipment owner and is in the down state;
responding to the first inquiry that one port is not included, judging one UP port, and recording the UP time of the port;
in response to all ports having been UP or a timeout being reached, the check port state ends.
In a preferred embodiment of the present invention, deleting the created port and recording the completion time of deleting the port in response to the port UP being completed comprises:
calling a GET/v2.0/ports interface to inquire port information according to the network ID and the port name;
responding to the query of the computing node of which the port is bound with the host, and calling the ovsdb client of the bound computing node to delete ovs the interface according to the port name;
the network namespace is deleted at the binding compute node and the DELETE/v2.0/ports/{ port _ id } interface is invoked, deleting the port.
The technical scheme of the invention can avoid creating a virtual machine, achieve the real full-flow concurrent processing capability of testing the openstack network control plane, and test a large amount of concurrency in a small computing cluster. For large-scale clusters on business, codes can be verified, testing is carried out in advance, and problems are exposed in advance. The loss caused by problems after the actual large scale is reduced effectively. Meanwhile, accurate data of the test can provide reference for large-scale test deployment parameters.
It should be noted that, as will be understood by those skilled in the art, all or part of the processes in the methods of the above embodiments may be implemented by instructing relevant hardware through a computer program, and the above programs may be stored in a computer-readable storage medium, and when executed, the programs may include the processes of the embodiments of the methods as described above. The storage medium may be a magnetic disk, an optical disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), or the like. The embodiments of the computer program may achieve the same or similar effects as any of the above-described method embodiments.
Furthermore, the method disclosed according to an embodiment of the present invention may also be implemented as a computer program executed by a CPU, and the computer program may be stored in a computer-readable storage medium. The computer program, when executed by the CPU, performs the above-described functions defined in the method disclosed in the embodiments of the present invention.
In view of the above object, according to a second aspect of the embodiments of the present invention, there is provided an apparatus for testing processing capability of a control plane of a network, as shown in fig. 2, the apparatus 200 includes:
the creating module is configured to concurrently create a threshold number of ports and record the starting time and the ending time of creating the ports;
the checking module is configured to simulate each port UP in response to the completion of port creation, check the state of the port and record the starting time and the ending time of the port UP;
the deleting module is configured to respond to the completion of the port UP, delete the created port and record the completion time of deleting the port;
and the evaluation module is configured to evaluate the processing capacity of the network control plane according to the recorded start time and end time of creating the port, the start time and end time of the port UP and the completion time of deleting the port.
In view of the above object, a third aspect of the embodiments of the present invention provides a computer device. Fig. 3 is a schematic diagram of an embodiment of a computer device provided by the present invention. As shown in fig. 3, an embodiment of the present invention includes the following means: at least one processor S21; and a memory S22, the memory S22 storing computer instructions S23 executable on the processor, the instructions when executed by the processor implementing the method of:
concurrently creating ports with threshold quantity, and recording the starting time and the ending time of creating the ports;
responding to the completion of port creation, simulating each port UP, checking the state of the port and recording the starting time and the ending time of the port UP;
in response to the completion of the port UP, deleting the created port and recording the completion time of deleting the port;
and evaluating the processing capacity of the network control plane according to the recorded starting time and ending time of creating the port, the starting time and ending time of the port UP and the completion time of deleting the port.
In a preferred embodiment of the present invention, concurrently creating a threshold number of ports and recording a start time and an end time of creating the ports comprises:
setting a network name, a subnet name and a port name, and judging whether a network exists according to the network name;
responding to the absence of the network, calling a POST/v2.0/networks interface to create the network;
judging whether the subnet exists according to the subnet name and the ID of the created network;
responding to the absence of the subnet, calling a POST/v2.0/subnet interface to create the subnet;
judging whether a port exists according to the ID and the port name of the created network;
responding to the absence of the port, calling a POST/v2.0/ports interface to create the port, putting a task of creating the port into a protocol pool for carrying out and setting a self-defined equipment owner;
the start time of port creation and the completion time of port creation are recorded.
In a preferred embodiment of the present invention, judging whether a network exists according to a network name includes calling a GET/v2.0/networks interface to judge whether the network exists;
judging whether the subnet exists according to the subnet name and the ID of the created network, wherein the step of calling GET/v2.0/subnet interface to judge whether the subnet exists;
judging whether the port exists according to the ID and the port name of the created network comprises calling a GET/v2.0/ports interface to judge whether the port exists.
In a preferred embodiment of the present invention, simulating each port UP in response to completion of port creation comprises:
circularly binding the created port to a computing node of a host by calling PUT/v 2.0/ports;
calling an ovsdb client of the computing node, creating an ovs internal type interface, and setting external _ ids information of the interface;
creating a network name space according to the port name through remote system call;
adding the created ovs internal type interface into a network name space;
the port is UP using an ip link command.
In a preferred embodiment of the present invention, invoking the ovsdb client of the compute node, creating an ovs internal type interface, and setting external _ ids information of the interface includes:
setting external _ IDs. iface-ID as ID of port;
if-status is set to active;
external _ ids. attached-MAC is set to the MAC address of the port.
In a preferred embodiment of the present invention, verifying the state of the port comprises:
periodically inquiring the network ID and the port state of the equipment owner, which are transmitted into a database;
responding to the first inquiry of the port UP of the device owner and the port under the network ID, and recording the time of the port UP;
responding to the completion of the creation of all the ports, and periodically inquiring the network ID transmitted in the database and the port state which is under the equipment owner and is in the down state;
responding to the first inquiry that one port is not included, judging one UP port, and recording the UP time of the port;
in response to all ports having been UP or a timeout being reached, the check port state ends.
In a preferred embodiment of the present invention, deleting the created port and recording the completion time of deleting the port in response to the port UP being completed comprises:
calling a GET/v2.0/ports interface to inquire port information according to the network ID and the port name;
responding to the query of the computing node of which the port is bound with the host, and calling the ovsdb client of the bound computing node to delete ovs the interface according to the port name;
the network namespace is deleted at the binding compute node and the DELETE/v2.0/ports/{ port _ id } interface is invoked, deleting the port.
In view of the above object, a fourth aspect of the embodiments of the present invention proposes a computer-readable storage medium. FIG. 4 is a schematic diagram illustrating an embodiment of a computer-readable storage medium provided by the present invention. As shown in fig. 4, the computer readable storage medium S31 stores a computer program S32 that when executed by a processor performs the method of:
concurrently creating ports with threshold quantity, and recording the starting time and the ending time of creating the ports;
responding to the completion of port creation, simulating each port UP, checking the state of the port and recording the starting time and the ending time of the port UP;
in response to the completion of the port UP, deleting the created port and recording the completion time of deleting the port;
and evaluating the processing capacity of the network control plane according to the recorded starting time and ending time of creating the port, the starting time and ending time of the port UP and the completion time of deleting the port.
In a preferred embodiment of the present invention, concurrently creating a threshold number of ports and recording a start time and an end time of creating the ports comprises:
setting a network name, a subnet name and a port name, and judging whether a network exists according to the network name;
responding to the absence of the network, calling a POST/v2.0/networks interface to create the network;
judging whether the subnet exists according to the subnet name and the ID of the created network;
responding to the absence of the subnet, calling a POST/v2.0/subnet interface to create the subnet;
judging whether a port exists according to the ID and the port name of the created network;
responding to the absence of the port, calling a POST/v2.0/ports interface to create the port, putting a task of creating the port into a protocol pool for carrying out and setting a self-defined equipment owner;
the start time of port creation and the completion time of port creation are recorded.
In a preferred embodiment of the present invention, judging whether a network exists according to a network name includes calling a GET/v2.0/networks interface to judge whether the network exists;
judging whether the subnet exists according to the subnet name and the ID of the created network, wherein the step of calling GET/v2.0/subnet interface to judge whether the subnet exists;
judging whether the port exists according to the ID and the port name of the created network comprises calling a GET/v2.0/ports interface to judge whether the port exists.
In a preferred embodiment of the present invention, simulating each port UP in response to completion of port creation comprises:
circularly binding the created port to a computing node of a host by calling PUT/v 2.0/ports;
calling an ovsdb client of the computing node, creating an ovs internal type interface, and setting external _ ids information of the interface;
creating a network name space according to the port name through remote system call;
adding the created ovs internal type interface into a network name space;
the port is UP using an ip link command.
In a preferred embodiment of the present invention, invoking the ovsdb client of the compute node, creating an ovs internal type interface, and setting external _ ids information of the interface includes:
setting external _ IDs. iface-ID as ID of port;
if-status is set to active;
external _ ids. attached-MAC is set to the MAC address of the port.
In a preferred embodiment of the present invention, verifying the state of the port comprises:
periodically inquiring the network ID and the port state of the equipment owner, which are transmitted into a database;
responding to the first inquiry of the port UP of the device owner and the port under the network ID, and recording the time of the port UP;
responding to the completion of the creation of all the ports, and periodically inquiring the network ID transmitted in the database and the port state which is under the equipment owner and is in the down state;
responding to the first inquiry that one port is not included, judging one UP port, and recording the UP time of the port;
in response to all ports having been UP or a timeout being reached, the check port state ends.
In a preferred embodiment of the present invention, deleting the created port and recording the completion time of deleting the port in response to the port UP being completed comprises:
calling a GET/v2.0/ports interface to inquire port information according to the network ID and the port name;
responding to the query of the computing node of which the port is bound with the host, and calling the ovsdb client of the bound computing node to delete ovs the interface according to the port name;
the network namespace is deleted at the binding compute node and the DELETE/v2.0/ports/{ port _ id } interface is invoked, deleting the port.
Furthermore, the methods disclosed according to embodiments of the present invention may also be implemented as a computer program executed by a processor, which may be stored in a computer-readable storage medium. Which when executed by a processor performs the above-described functions defined in the methods disclosed in embodiments of the invention.
Further, the above method steps and system elements may also be implemented using a controller and a computer readable storage medium for storing a computer program for causing the controller to implement the functions of the above steps or elements.
Those of skill would further appreciate that the various illustrative logical blocks, modules, circuits, and algorithm steps described in connection with the disclosure herein may be implemented as electronic hardware, computer software, or combinations of both. To clearly illustrate this interchangeability of hardware and software, various illustrative components, blocks, modules, circuits, and steps have been described above generally in terms of their functionality. Whether such functionality is implemented as software or hardware depends upon the particular application and design constraints imposed on the overall system. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the disclosed embodiments of the present invention.
In one or more exemplary designs, the functions may be implemented in hardware, software, firmware, or any combination thereof. If implemented in software, the functions may be stored on or transmitted over as one or more instructions or code on a computer-readable medium. Computer-readable media includes both computer storage media and communication media including any medium that facilitates transfer of a computer program from one place to another. A storage media may be any available media that can be accessed by a general purpose or special purpose computer. By way of example, and not limitation, such computer-readable media can comprise RAM, ROM, EEPROM, CD-ROM or other optical disk storage, magnetic disk storage or other magnetic storage devices, or any other medium that can be used to carry or store desired program code in the form of instructions or data structures and that can be accessed by a general-purpose or special-purpose computer, or a general-purpose or special-purpose processor. Also, any connection is properly termed a computer-readable medium. For example, if the software is transmitted from a website, server, or other remote source using a coaxial cable, fiber optic cable, twisted pair, Digital Subscriber Line (DSL), or wireless technologies such as infrared, radio, and microwave, then the coaxial cable, fiber optic cable, twisted pair, DSL, or wireless technologies such as infrared, radio, and microwave are included in the definition of medium. Disk and disc, as used herein, includes Compact Disc (CD), laser disc, optical disc, Digital Versatile Disc (DVD), floppy disk, blu-ray disc where disks usually reproduce data magnetically, while discs reproduce data optically with lasers. Combinations of the above should also be included within the scope of computer-readable media.
The foregoing is an exemplary embodiment of the present disclosure, but it should be noted that various changes and modifications could be made herein without departing from the scope of the present disclosure as defined by the appended claims. The functions, steps and/or actions of the method claims in accordance with the disclosed embodiments described herein need not be performed in any particular order. Furthermore, although elements of the disclosed embodiments of the invention may be described or claimed in the singular, the plural is contemplated unless limitation to the singular is explicitly stated.
It should be understood that, as used herein, the singular forms "a", "an" and "the" are intended to include the plural forms as well, unless the context clearly supports the exception. It should also be understood that "and/or" as used herein is meant to include any and all possible combinations of one or more of the associated listed items.
The numbers of the embodiments disclosed in the embodiments of the present invention are merely for description, and do not represent the merits of the embodiments.
It will be understood by those skilled in the art that all or part of the steps for implementing the above embodiments may be implemented by hardware, or may be implemented by a program instructing relevant hardware, and the program may be stored in a computer-readable storage medium, and the above-mentioned storage medium may be a read-only memory, a magnetic disk or an optical disk, etc.
Those of ordinary skill in the art will understand that: the discussion of any embodiment above is meant to be exemplary only, and is not intended to intimate that the scope of the disclosure, including the claims, of embodiments of the invention is limited to these examples; within the idea of an embodiment of the invention, also technical features in the above embodiment or in different embodiments may be combined and there are many other variations of the different aspects of the embodiments of the invention as described above, which are not provided in detail for the sake of brevity. Therefore, any omissions, modifications, substitutions, improvements, and the like that may be made without departing from the spirit and principles of the embodiments of the present invention are intended to be included within the scope of the embodiments of the present invention.

Claims (10)

1. A method for testing the processing capability of a network control plane is characterized by comprising the following steps:
concurrently creating ports with threshold quantity, and recording the starting time and the ending time of creating the ports;
responding to the completion of port creation, simulating each port UP, checking the state of the port and recording the starting time and the ending time of the port UP;
in response to the completion of the port UP, deleting the created port and recording the completion time of deleting the port;
and evaluating the processing capacity of the network control plane according to the recorded starting time and ending time of creating the port, the starting time and ending time of the port UP and the completion time of deleting the port.
2. The method of claim 1, wherein concurrently creating a threshold number of ports and recording a start time and an end time for creating ports comprises:
setting a network name, a subnet name and a port name, and judging whether a network exists according to the network name;
responding to the absence of the network, calling a POST/v2.0/networks interface to create the network;
judging whether the subnet exists according to the subnet name and the ID of the created network;
responding to the absence of the subnet, calling a POST/v2.0/subnet interface to create the subnet;
judging whether a port exists according to the ID and the port name of the created network;
responding to the absence of the port, calling a POST/v2.0/ports interface to create the port, putting a task of creating the port into a protocol pool for carrying out and setting a self-defined equipment owner;
the start time of port creation and the completion time of port creation are recorded.
3. The method of claim 2, wherein determining whether a network exists according to the network name comprises: calling a GET/v2.0/networks interface to judge whether a network exists;
judging whether the subnet exists according to the subnet name and the ID of the created network comprises the following steps: calling a GET/v2.0/subnet interface to judge whether the subnet exists or not;
judging whether a port exists according to the ID and the port name of the created network comprises the following steps: and calling a GET/v2.0/ports interface to judge whether the port exists.
4. The method of claim 1, wherein simulating each port UP in response to port creation completion comprises:
circularly binding the created port to a computing node of a host by calling PUT/v 2.0/ports;
calling an ovsdb client of the computing node, creating an ovs internal type interface, and setting external _ ids information of the interface;
creating a network name space according to the port name through remote system call;
adding the created ovs internal type interface into a network name space;
the port is UP using an ip link command.
5. The method of claim 4, wherein invoking the ovsdb client of the compute node, creating an ovs internal type interface, and setting external _ ids information of the interface comprises:
setting external _ IDs. iface-ID as ID of port;
if-status is set to active;
external _ ids. attached-MAC is set to the MAC address of the port.
6. The method of claim 1, wherein verifying the state of a port comprises:
periodically inquiring the network ID and the port state of the equipment owner, which are transmitted into a database;
responding to the first inquiry of the port UP of the device owner and the port under the network ID, and recording the time of the port UP;
responding to the completion of the creation of all the ports, and periodically inquiring the network ID transmitted in the database and the port state which is under the equipment owner and is in the down state;
responding to the first inquiry that one port is not included, judging the UP of the one port, and recording the UP time of the port;
in response to all ports having been UP or a timeout being reached, the check port state ends.
7. The method of claim 1, wherein deleting the created port and recording the completion time of deleting the port in response to the port UP being completed comprises:
calling a GET/v2.0/ports interface to inquire port information according to the network ID and the port name;
responding to the query of the computing node of which the port is bound with the host, and calling the ovsdb client of the bound computing node to delete ovs the interface according to the port name;
the network namespace is deleted at the binding compute node and the DELETE/v2.0/ports/{ port _ id } interface is invoked, deleting the port.
8. An apparatus for testing processing capability of a network control plane, the apparatus comprising:
a creation module configured to concurrently create a threshold number of ports and record a start time and an end time of creating the ports;
the checking module is configured to simulate each port UP in response to the completion of port creation, check the state of the port and record the starting time and the ending time of the port UP;
the deleting module is configured to respond to the completion of the port UP, delete the created port and record the completion time of deleting the port;
an evaluation module configured to evaluate a processing capability of the network control plane according to the recorded start time and end time of creating the port, start time and end time of the port UP, and completion time of deleting the port.
9. A computer device, comprising:
at least one processor; and
a memory storing computer instructions executable on the processor, the instructions when executed by the processor implementing the steps of the method of any one of claims 1 to 7.
10. A computer-readable storage medium, in which a computer program is stored which, when being executed by a processor, carries out the steps of the method according to any one of claims 1 to 7.
CN202110865556.7A 2021-07-29 2021-07-29 Method, device and equipment for testing processing capability of network control plane and readable medium Pending CN113630291A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110865556.7A CN113630291A (en) 2021-07-29 2021-07-29 Method, device and equipment for testing processing capability of network control plane and readable medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110865556.7A CN113630291A (en) 2021-07-29 2021-07-29 Method, device and equipment for testing processing capability of network control plane and readable medium

Publications (1)

Publication Number Publication Date
CN113630291A true CN113630291A (en) 2021-11-09

Family

ID=78381923

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110865556.7A Pending CN113630291A (en) 2021-07-29 2021-07-29 Method, device and equipment for testing processing capability of network control plane and readable medium

Country Status (1)

Country Link
CN (1) CN113630291A (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20070174815A1 (en) * 2006-01-04 2007-07-26 Microsoft Corporation Decentralized system services
US20120307623A1 (en) * 2011-06-02 2012-12-06 Avaya Inc. Method and Apparatus Providing Selective Flow Redistribution Across Multi Link Trunk/Link Aggregation Group (MLT/LAG) After Port Member Failure and Recovery
CN104468316A (en) * 2014-12-19 2015-03-25 国家电网公司 Method and device for rapidly detecting virtual local area network configuration of intelligent substation
CN112217690A (en) * 2020-09-18 2021-01-12 苏州浪潮智能科技有限公司 Concurrent testing method and system for local area network availability between computing nodes

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20070174815A1 (en) * 2006-01-04 2007-07-26 Microsoft Corporation Decentralized system services
US20120307623A1 (en) * 2011-06-02 2012-12-06 Avaya Inc. Method and Apparatus Providing Selective Flow Redistribution Across Multi Link Trunk/Link Aggregation Group (MLT/LAG) After Port Member Failure and Recovery
CN104468316A (en) * 2014-12-19 2015-03-25 国家电网公司 Method and device for rapidly detecting virtual local area network configuration of intelligent substation
CN112217690A (en) * 2020-09-18 2021-01-12 苏州浪潮智能科技有限公司 Concurrent testing method and system for local area network availability between computing nodes

Similar Documents

Publication Publication Date Title
US8150948B2 (en) Complex software deployment
EP3975482B1 (en) Quantitative network testing framework for 5g and subsequent generation networks
CN112131099B (en) Version upgrading test method and device
WO2020024408A1 (en) Test device, test method and storage medium
CN108845949A (en) A kind of performance test methods and platform
CN107239392A (en) A kind of method of testing, device and terminal
CN112260885B (en) Industrial control protocol automatic test method, system, device and readable storage medium
CN109857391A (en) Processing method and processing device, storage medium and the electronic device of data
CN116204438A (en) Test case generation method, automatic test method and related device
CN111221721B (en) Automatic recording and executing method and device for unit test cases
CN108306780B (en) Cloud environment-based virtual machine communication quality self-optimization system and method
CN114138181A (en) Method, device, equipment and readable medium for placing, grouping and selecting owners in binding pool
CN112988600A (en) Service scene testing method and device, electronic equipment and storage medium
CN113630291A (en) Method, device and equipment for testing processing capability of network control plane and readable medium
CN113688025A (en) Interface test method, device, equipment and storage medium
CN111225075A (en) Configuration method and device for Internet of things directional access service
CN112738157A (en) File uploading method, system and equipment
US20200226082A1 (en) Input/output control code filter
CN112463608B (en) Test method and system based on distributed storage
CN114826994B (en) User environment playback method, system, electronic device and readable storage medium
CN113722133B (en) Memory leakage detection method, device and equipment
CN114189512B (en) Baseline code downloading method, device, terminal equipment and storage medium
CN112463528B (en) In-band and out-band data interaction method, device, equipment and readable medium
WO2016177072A1 (en) Network topology display method and device, and network management system
CN112748882B (en) Communication method, device, equipment and readable medium of host and storage equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
TA01 Transfer of patent application right

Effective date of registration: 20240426

Address after: Room 1801, Floor 18, Jiyun Investment Building, No. 278, Xinyi Road, Zhengdong New District, Zhengzhou City, Henan Province, 450000

Applicant after: Zhengzhou Inspur Data Technology Co.,Ltd.

Country or region after: China

Address before: Room s311, building S05, Inspur Science Park, No. 1036, Inspur Road, Jinan area, China (Shandong) pilot Free Trade Zone, Jinan City, Shandong Province

Applicant before: Ji'nan tide data Technology Co.,Ltd.

Country or region before: China