Interactive intelligent network card test method and system, storage medium and computer equipment

By using software to simulate the testing environment and virtualization technology, a virtual network topology is constructed, which automatically identifies the network card type and supports real-time monitoring and dynamic adjustment. This solves the problems of high cost, complex wiring and compatibility in smart network card testing, and improves testing efficiency and flexibility.

CN121644406APending Publication Date: 2026-03-10NINGCHANG INFORMATION TECH (HANGZHOU) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-12-29
Publication Date
2026-03-10

AI Technical Summary

Technical Problem

Smart network interface card (NIC) testing suffers from high testing costs, complex wiring, and a high risk of errors. Traditional testing solutions are inefficient, difficult to flexibly adjust test parameters, and have high compatibility and maintenance complexity with NICs from different manufacturers.

Method used

By simulating the test environment with software and using virtualization technology to build a virtual network test topology, the system can automatically identify network card types and call the corresponding drivers. It supports real-time monitoring and intervention commands through a graphical interface to dynamically adjust test scenario parameters, enabling on-the-fly testing and modification, and covering the testing needs of various smart network cards.

Benefits of technology

It significantly reduces hardware dependence and cost, simplifies the test setup process, improves the efficiency and depth of test exploration, solves the compatibility challenges of network cards from different manufacturers, and enhances the flexibility and reliability of testing.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121644406A_ABST
    Figure CN121644406A_ABST
Patent Text Reader

Abstract

The invention discloses an interactive intelligent network card test method and system, a storage medium and computer equipment. The method comprises the following steps: receiving an intelligent network card test instruction; the method comprises the steps of obtaining a tested network card type identifier and a test scene parameter based on an intelligent network card test instruction, calling a driving interface corresponding to a tested network card according to the tested network card type identifier, establishing communication connection with the tested network card based on the driving interface, and constructing a virtual network test topology according to the test scene parameter. Determining hardware function configuration parameters of the tested network card; sending the hardware function configuration parameters to the tested network card, generating test flow data corresponding to the test scene parameters after configuration is completed, and sending the test flow data to the tested network card through the virtual network test topology to execute a test; and in a test execution process, displaying index data of each preset test index of the tested network card in real time, and when an intervention instruction is received in a test process, dynamically adjusting a test scene parameter or a test state.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of smart network interface card (NIC) testing technology, and in particular to an interactive smart NIC testing method and system, storage medium, and computer equipment. Background Technology

[0002] With the rapid growth of data traffic in data centers and cloud computing networks, network interface bandwidth continues to increase, placing enormous processing pressure on host CPUs. To address this challenge, smart network interface cards (NICs) have emerged. Smart NICs not only possess the network data transmission capabilities of traditional NICs but also integrate programmable hardware acceleration engines. These engines can offload and efficiently handle network functions originally handled by the host processor, such as virtual switching, remote direct memory access, and encryption / decryption, thereby significantly improving overall system performance. However, the complexity of the hardware structure and the diversity of functions of smart NICs mean that their testing scope far exceeds that of traditional NICs. It is no longer limited to basic data forwarding but also requires comprehensive verification of their various hardware acceleration functions, programmability, and effectiveness in working with servers. Traditional testing methods face severe challenges in terms of efficiency, coverage, and flexibility.

[0003] Currently, in the testing practice of smart network interface cards (NICs), it is usually necessary to configure peripheral devices such as displays and input devices for both the server under test and the smart NIC. Testers then manually operate these devices and compare logs from both ends. This process is costly, time-consuming, error-prone, and inefficient. Furthermore, many existing automated testing solutions rely on pre-written, fixed test scripts, and the test flow and parameters are difficult to change once started. When unexpected performance fluctuations occur during testing, or when it is necessary to temporarily explore the NIC's performance under specific parameters, the test must be interrupted and restarted, extending the testing cycle. Summary of the Invention

[0004] In view of this, this application provides an interactive smart network interface card (NIC) testing method and system, storage medium, and computer equipment. By completely simulating the test environment through software, it significantly reduces hardware dependence and cost. This application utilizes virtualization technology to construct a complete virtual network test topology on a single test host, replacing the complex tooling of configuring dedicated peripherals such as monitors and barcode scanners for servers and smart NICs in traditional testing. This not only simplifies the test setup process but also fundamentally solves the problems of high cost, complex wiring, and susceptibility to errors in test tooling. Testers can monitor performance indicators in real time through a graphical interface and instantly modify test scenario parameters at any stage of testing through intervention commands, thereby enabling on-the-fly testing and modification, quickly verifying hypotheses or locating problems. This changes the time-consuming process of having to interrupt the test, modify the script, and re-execute it, greatly improving the efficiency and depth of test exploration in complex scenarios. By pre-setting driver interface libraries for smart NICs of different manufacturers and models, it can automatically identify the NIC type and call the appropriate driver and configuration strategy, enabling the same test system to seamlessly cover the testing needs of multiple smart NICs. This effectively solves the compatibility challenges and operational complexity caused by the need for different operating systems and testing tools for NICs from different manufacturers.

[0005] According to one aspect of this application, an interactive smart network interface card (NIC) testing method is provided, comprising: Receive smart network card test commands; Based on the smart network card test command, the test network card type identifier and test scenario parameters are obtained. According to the test network card type identifier, the driver interface corresponding to the test network card is called. A communication connection between the test network card and the test network card is established based on the driver interface. According to the test scenario parameters, a virtual network test topology is constructed and the hardware function configuration parameters of the test network card are determined. The virtual network test topology is used to simulate the target network structure defined by the test scenario parameters. The hardware function configuration parameters are sent to the network card under test. After the network card under test is configured based on the hardware function configuration parameters, test traffic data corresponding to the test scenario parameters is generated. The test traffic data is then sent to the network card under test through the virtual network test topology to perform the test. During the test execution, the indicator data corresponding to each preset test indicator of the network card under test is displayed in real time. When an intervention command is received by the user during the test, the test scenario parameters or test status are dynamically adjusted based on the intervention command. The test continues after adjusting the test scenario parameters, or the test process is updated based on the test status.

[0006] Beneficial effects: By fully simulating the test environment through software, hardware dependence and costs are significantly reduced. It replaces the complex tooling of traditional testing, which requires separate configurations of dedicated peripherals such as monitors and barcode scanners for servers and smart network cards. This not only simplifies the test setup process but also fundamentally solves the problems of high cost, complex wiring, and susceptibility to errors associated with traditional test tooling. Testers can monitor performance indicators in real time through a graphical interface and modify test scenario parameters instantly at any stage of testing through intervention commands. This allows for simultaneous testing and modification, quickly verifying hypotheses or locating problems, eliminating the time-consuming process of interrupting tests, modifying scripts, and re-executing. This greatly improves the efficiency and depth of test exploration in complex scenarios. By pre-setting driver interface libraries for smart network cards from different manufacturers and models, the system can automatically identify network card types and call appropriate drivers and configuration strategies. This enables the same test system to seamlessly cover the testing needs of various smart network cards, effectively solving the compatibility challenges and operational complexity caused by the need for different operating systems and testing tools for network cards from different manufacturers.

[0007] Optionally, obtaining the network interface card type identifier and test scenario parameters based on the smart network interface card test command includes: The test command for the smart network card is parsed to extract the network card type identifier and user input parameters, wherein the user input parameters include the test data packet size and / or the target test component of the network card under test; Based on the network interface card type identifier under test, determine the preset capability parameters corresponding to the network interface card under test, and perform feasibility verification on the user input parameters based on the preset capability parameters; After the user input parameters pass the feasibility verification, a matching benchmark test template is obtained from the pre-configured test scenario template library based on the user input parameters. The benchmark test template includes multiple preset test scenario parameters. The user input parameters are used to replace the corresponding preset test scenario parameters in the benchmark template, and all the test scenario parameters in the replaced benchmark template are used as the final test scenario parameters.

[0008] Beneficial effects: The feasibility verification mechanism avoids configuration errors in advance, improving the reliability and security of testing; the template matching and parameter replacement mechanism quickly transforms simple user input into professional and comprehensive test plans, greatly reducing the professional threshold and configuration workload for testers, while ensuring the coverage quality and execution efficiency of test scenarios.

[0009] Optionally, the step of constructing a virtual network test topology based on the test scenario parameters and determining the hardware functional configuration parameters of the network interface card under test includes: Based on the test scenario parameters, determine the network topology simulation requirements and hardware function test requirements; According to the network topology simulation requirements, the application programming interface of the virtual switch is invoked, and a virtual network test topology containing virtual network cards, virtual links, and switching rules is created through the application programming interface. Based on the hardware function test requirements, generate the hardware function configuration parameters of the network card under test.

[0010] Beneficial effects: By automatically parsing abstract test scenario parameters into operable network topology simulation requirements and hardware function test requirements, the traditional cumbersome and error-prone manual network setup and equipment configuration process is replaced. This not only greatly improves the efficiency and consistency of test preparation, but also makes it possible to quickly create complex and varied network test scenarios, thereby enabling more comprehensive and realistic verification of the performance and functionality of smart network cards in various target deployment environments.

[0011] Optionally, generating test traffic data corresponding to the test scenario parameters and sending the test traffic data to the network interface card under test through the virtual network test topology to perform the test includes: Based on the test scenario parameters, a target traffic model is determined, wherein the target traffic model is defined by at least one of the following: traffic protocol type, test data packet size distribution, average rate, and traffic burst characteristics. Based on the target traffic model, the test data generation module is invoked to generate test traffic data that conforms to the target traffic model. The test traffic data is encapsulated and forwarded through the virtual network test topology to send the test traffic data to the network card under test for testing.

[0012] Beneficial effects: It seamlessly transforms the user's abstract definition of network conditions into test traffic that can realistically reflect complex network behavior and accurately reach the hardware functional points of the network card under test. This not only replaces the tedious process of manually configuring the traffic generator, but also ensures that the performance test is conducted in a highly simulated network environment, thereby making the evaluation results of the forwarding performance, latency, throughput and hardware acceleration performance of the network card under test more realistic and reliable.

[0013] Optionally, during the test execution process, the real-time display of indicator data corresponding to each preset test indicator of the network interface card under test includes: During the test execution, raw data generated during the test is collected in real time. The raw data includes at least one of the first type of data, the second type of data, and the third type of data. The first type of data is collected from the hardware registers and driver counters of the network card under test. The second type of data is collected from the flow table and port statistics of the virtual network test topology. The third type of data is collected from the operating system of the test host. The collected raw data is time-series aligned, and based on the alignment results, the statistical characteristic value of each preset test indicator is calculated based on each preset test indicator of the network card under test. The statistical characteristic value is used as the corresponding indicator data, and the indicator data is integrated into a dynamically updated visual dashboard for display.

[0014] Beneficial effects: Through a dynamic and visual dashboard, complex indicator data is presented intuitively and centrally, enabling testers to grasp the test status in real time, quickly identify performance bottlenecks or anomalies, and provide reliable data support for subsequent interactive interventions (such as dynamically adjusting test scenario parameters), thereby significantly improving the depth, efficiency and controllability of smart network card testing.

[0015] Optionally, after calculating the statistical characteristic value of each preset test indicator and using the statistical characteristic value as the corresponding indicator data, the method further includes: For each preset test index, the index data corresponding to the preset test index is compared point by point with the preset performance baseline data to generate a difference curve, and the difference curve is integrated into a dynamically updated visual dashboard for display. Accordingly, the method further includes: The difference curve is monitored in real time. When the difference at any point in time exceeds a preset threshold, an alarm event is generated. The abnormal time period corresponding to the alarm event is marked in the dynamically updated visualization dashboard, and a command-line interface is output so that the user can input intervention commands based on the command-line interface; and / or, In response to a command-line interface call command, the command-line interface is output so that the user can input the intervention command based on the command-line interface.

[0016] Beneficial effects: By automatically comparing the indicator data with the preset performance baseline data and visually displaying the differences, the objectivity and efficiency of performance evaluation can be greatly improved; through intelligent alarms and graphical anomaly markers, proactive and accurate location of performance problems can be achieved; by deeply integrating the command-line interface into the monitoring process and supporting dual startup modes of anomaly triggering and manual invocation, testers are provided with flexible real-time interactive capabilities.

[0017] Optionally, after receiving the smart network card test command, the method further includes: Based on the smart network card test command, user-defined anomaly injection parameters are obtained, and the anomaly type to be injected, the target link identifier, the injection trigger condition, and the injection duration are determined according to the anomaly injection parameters. Based on the injection target link identifier, locate the corresponding virtual switch in the virtual network test topology, and configure the anomaly simulation rules corresponding to the anomaly type through the virtual switch; During the test execution, the injection triggering conditions are continuously monitored. When the injection triggering conditions are met, an activation command for the abnormal simulation rule is sent to the virtual switch to inject abnormal traffic into the injection target link indicated by the injection target link identifier through the virtual switch, and the injection time is recorded. When the time difference between the injection time and the current time reaches the injection duration, a stop command for the abnormal simulation rule is sent to the virtual switch to control the virtual switch to stop generating abnormal traffic.

[0018] Beneficial effects: By abstracting abnormal scenarios into configurable parameters and pre-setting them in virtual switches, it is possible to achieve precise spatiotemporal triggering and elimination of abnormal behaviors. This allows for efficient and repeatable simulation of various real network fault scenarios without physically damaging the link or introducing additional hardware. This not only greatly improves the efficiency and coverage of the robustness and fault tolerance testing of the network card under test in abnormal environments, but also provides testers with a better testing experience.

[0019] According to another aspect of this application, an interactive smart network interface card (NIC) testing system is provided, comprising: The interactive control module is used to receive smart network card test commands; The test management module is used to obtain the network card type identifier and test scenario parameters based on the smart network card test instructions; The intelligent network interface card (NIC) adapter module is used to call the driver interface corresponding to the NIC under test according to the NIC type identifier under test, and establish a communication connection with the NIC under test based on the driver interface. The scenario configuration module is used to construct a virtual network test topology based on the test scenario parameters and determine the hardware function configuration parameters of the network card under test, wherein the virtual network test topology is used to simulate the target network structure defined by the test scenario parameters; The smart network interface card (NIC) adapter module is also used to send the hardware function configuration parameters to the NIC under test. The test data generation module is used to generate test traffic data corresponding to the test scenario parameters after the network card under test is configured based on the hardware function configuration parameters, and send the test traffic data to the network card under test through the virtual network test topology to perform the test; The interactive control module is also used to display the indicator data corresponding to each preset test indicator of the network card under test in real time during the test execution process, and when it receives the intervention command input by the user during the test, it sends the intervention command to the test management module so as to dynamically adjust the test scenario parameters or test status based on the intervention command, continue the test after adjusting the test scenario parameters, or update the test process based on the test status.

[0020] According to another aspect of this application, a storage medium is provided that stores a computer program thereon, which, when executed by a processor, implements the above-described interactive smart network card testing method.

[0021] According to another aspect of this application, a computer device is provided, including a storage medium, a processor, and a computer program stored on the storage medium and executable on the processor, wherein the processor executes the program to implement the above-described interactive smart network card testing method.

[0022] By employing the above technical solutions, this application provides an interactive smart network interface card (NIC) testing method and system, storage medium, and computer equipment. Through software-based complete simulation of the testing environment, it significantly reduces hardware dependence and cost. This application utilizes virtualization technology to construct a complete virtual network test topology on a single test host, replacing the complex setup required in traditional testing, which necessitates configuring dedicated peripherals such as monitors and barcode scanners for both the server and smart NIC. This not only simplifies the test setup process but also fundamentally solves the problems of high test tooling costs, complex wiring, and susceptibility to errors. Testers can monitor performance indicators in real time through a graphical interface and participate in the testing process. At any stage of testing, test scenario parameters can be modified instantly through intervention commands, enabling on-the-fly testing and rapid verification of hypotheses or identification of problems. This changes the time-consuming process of interrupting testing, modifying scripts, and re-executing, greatly improving the efficiency and depth of testing exploration in complex scenarios. By pre-setting driver interface libraries for smart network cards from different manufacturers and models, the system can automatically identify network card types and call appropriate drivers and configuration strategies. This allows the same testing system to seamlessly cover the testing needs of various smart network cards, effectively solving the compatibility challenges and operational complexity caused by the need for different operating systems and testing tools for network cards from different manufacturers.

[0023] The above description is only an overview of the technical solution of this application. In order to better understand the technical means of this application and to implement it in accordance with the contents of the specification, and to make the above and other objects, features and advantages of this application more obvious and understandable, the following are specific embodiments of this application. Attached Figure Description

[0024] The accompanying drawings, which are included to provide a further understanding of this application and form part of this application, illustrate exemplary embodiments and are used to explain this application, but do not constitute an undue limitation of this application. In the drawings: Figure 1 This illustration shows a flowchart of an interactive smart network interface card (NIC) testing method provided in an embodiment of this application. Figure 2 This illustration shows a flowchart of another interactive smart network interface card (NIC) testing method provided in an embodiment of this application. Figure 3 A schematic diagram of the structure of an interactive smart network interface card (NIC) testing system provided in an embodiment of this application is shown. Figure 4 A schematic diagram of another interactive smart network card testing system provided in an embodiment of this application is shown; Figure 5 A schematic diagram of the device structure of a computer device provided in an embodiment of this application is shown. Detailed Implementation

[0025] The present application will be described in detail below with reference to the accompanying drawings and embodiments. It should be noted that, unless otherwise specified, the embodiments and features described in the embodiments of the present application can be combined with each other.

[0026] This embodiment provides an interactive smart network interface card (NIC) testing method, such as... Figure 1 As shown, the method includes: Step 101: Receive smart network card test command.

[0027] Step 102: Based on the smart network card test command, obtain the network card type identifier and test scenario parameters. According to the network card type identifier, call the driver interface corresponding to the network card under test. Establish a communication connection between the network card under test and the network card under test based on the driver interface. According to the test scenario parameters, construct a virtual network test topology and determine the hardware function configuration parameters of the network card under test. The virtual network test topology is used to simulate the target network structure defined by the test scenario parameters.

[0028] Step 103: Send the hardware function configuration parameters to the network card under test. After the network card under test is configured based on the hardware function configuration parameters, generate test traffic data corresponding to the test scenario parameters, and send the test traffic data to the network card under test through the virtual network test topology to execute the test.

[0029] Step 104: During the test execution, the indicator data corresponding to each preset test indicator of the network card under test is displayed in real time. When an intervention command is received from the user during the test, the test scenario parameters or test status are dynamically adjusted based on the intervention command. The test continues after adjusting the test scenario parameters, or the test process is updated based on the test status.

[0030] This application provides an interactive smart network card testing method. When testing a smart network card, the user can interrupt the process at any time based on the monitoring results and dynamically adjust the test scenario parameters or test status, transforming the static automated execution into an interactive process that can be dynamically explored, diagnosed, and optimized.

[0031] First, it can receive smart network interface card (NIC) test commands. These commands can contain the basic intent and requirements of the test in a structured data format. Here, the smart NIC test commands can be issued by the user or automatically generated by the system; no limitation is made here.

[0032] Next, based on the smart network interface card (NIC) test command, two core elements can be obtained: first, a type identifier representing the specific model or series of the NIC under test; and second, test scenario parameters defining the test objectives, conditions, and scope. The test scenario parameters can be a comprehensive set of configurations, including key information such as the target test component (e.g., the processor and memory controller on the NIC), the network protocol to be simulated, the traffic model (which can be defined such as test packet size and sending rate), and whether specific hardware acceleration functions are enabled.

[0033] Furthermore, based on the type identifier of the network interface card (NIC) under test, a dedicated driver interface matching that type of smart NIC can be invoked. The driver interface serves as a software bridge for control and data exchange between the operating system or test system and the hardware NIC. Through this driver interface, a stable and reliable communication connection can be established with the physical smart NIC, laying the foundation for subsequent configuration and control. Simultaneously, based on the network environment requirements in the test scenario parameters, a test network can be built at the software level, thereby constructing a virtual network test topology. This involves using software-defined networking technologies such as virtual switches to flexibly create a network connection structure composed of virtual NICs, virtual link paths, and switching rules to simulate real, complex network deployment scenarios (such as multi-subnets, VLAN isolation, etc.). In addition, based on the test scenario parameters, specific hardware function configuration parameters that need to be sent to the NIC under test can be intelligently analyzed and determined. For example, it can explicitly instruct the NIC under test whether to enable or disable specific hardware acceleration engines such as RDMA (Remote Direct Memory Access) and TLS encryption offloading.

[0034] Afterwards, the generated hardware configuration parameters can be sent to the network interface card under test (NIC) via the established driver connection, adjusting its internal hardware state to the target mode required for testing. Once the configuration is confirmed to be effective, the core step of the testing process can be initiated: generating test traffic data that matches the test scenario parameters. This test traffic data simulates real network application load and is transmitted through the previously constructed virtual network test topology. That is, the test traffic undergoes encapsulation, forwarding, and processing processes similar to those in a real network before being sent to the NIC under test, thus comprehensively verifying its data plane processing performance, acceleration function effectiveness, and stability under the test scenario parameters.

[0035] Once the test starts, it enters the real-time monitoring and interaction phase. Specifically, it continuously collects multi-dimensional performance data from the tested network card's hardware counters, drivers, and virtual network test topology, such as throughput, latency, packet loss rate, and chip temperature. This data is then integrated according to preset test indicators to obtain the indicator data for each preset test indicator. This indicator data can be presented to the user in real time in intuitive forms such as charts. Furthermore, users can intervene at any time during the entire test execution process. When users observe anomalies or wish to explore the impact of different test scenario parameters, they can input intervention commands through command lines on the visual interface. Upon receiving such intervention commands, the ongoing test can be dynamically adjusted, such as instantly modifying traffic volume, switching test hardware components, or even pausing or resuming the test process. This ability to test and modify simultaneously allows users to quickly locate performance bottlenecks or verify specific hypotheses, much like interactive debugging, greatly enhancing the depth and flexibility of the test.

[0036] By applying the technical solution of this embodiment, the test environment is completely simulated by software, significantly reducing hardware dependence and cost. This application constructs a complete virtual network test topology on a single test host using virtualization technology, replacing the complex tooling of configuring dedicated peripherals such as monitors and barcode scanners for servers and smart network cards in traditional testing. This not only simplifies the test setup process but also fundamentally solves the problems of high cost, complex wiring, and error-proneness of test tooling. Testers can monitor performance indicators in real time through a graphical interface and modify test scenario parameters instantly through intervention commands at any stage of testing, thereby testing and modifying simultaneously, quickly verifying hypotheses or locating problems. This changes the time-consuming process of having to interrupt testing, modify scripts, and re-execute, greatly improving the efficiency and depth of test exploration in complex scenarios. By pre-setting driver interface libraries for smart network cards of different manufacturers and models, the network card type can be automatically identified and the appropriate driver and configuration strategy can be called. This allows the same test system to seamlessly cover the testing needs of multiple smart network cards, effectively solving the compatibility challenges and operational complexity caused by the need for different operating systems and test tools for network cards from different manufacturers.

[0037] Furthermore, as a refinement and extension of the specific implementation methods of the above embodiments, and to fully illustrate the specific implementation process of this embodiment, another interactive smart network interface card (NIC) testing method is provided, such as... Figure 2 As shown, the method includes: Step 201: Receive smart network card test command.

[0038] Step 202: Parse the smart network card test command to extract the network card type identifier and user input parameters, wherein the user input parameters include the test data packet size and / or the target test component of the network card under test.

[0039] Step 203: Determine the preset capability parameters corresponding to the network card under test according to the network card type identifier, and perform feasibility verification on the user input parameters based on the preset capability parameters.

[0040] Step 204: After the user input parameters pass the feasibility verification, a matching benchmark test template is obtained from the pre-configured test scenario template library according to the user input parameters, wherein the benchmark test template includes multiple preset test scenario parameters.

[0041] Step 205: Replace the corresponding preset test scenario parameters in the benchmark template with the user input parameters, and use all the test scenario parameters in the replaced benchmark template as the final test scenario parameters.

[0042] In this embodiment, by introducing feasibility verification and benchmark test templates, the user's initial testing intentions are transformed into reliable and complete executable solutions, ultimately generating test scenario parameters that meet personalized testing objectives while possessing professionalism and completeness, thereby achieving intelligent and standardized pre-test configuration.

[0043] Specifically, firstly, the received smart network interface card (NIC) test commands are parsed. By identifying specific fields or structures in the smart NIC test commands, two key pieces of information are extracted: one is the NIC type identifier, which is a code used to uniquely identify the NIC manufacturer, model, or hardware version; the other is the user input parameters, which are the core test conditions that the tester directly specifies and is most concerned with. These can include the size of each test packet in the test traffic, and specify the internal components of the smart NIC that need to be evaluated in this test, such as its processor (CPU), memory controller, or specific hardware acceleration engine.

[0044] Next, based on the extracted network interface card (NIC) type identifier, the system queries its integrated knowledge base to determine the preset capability parameters corresponding to the NIC. These preset capability parameters essentially define the capability boundaries of the NIC, such as which hardware acceleration functions it supports (e.g., whether it supports RDMA), the theoretical upper limits of various performance parameters, and compatibility rules between different functions. Subsequently, the preset capability parameters are used to verify the feasibility of the user-input parameters. For example, it verifies whether the target test component requested by the user actually exists on the NIC of that model, or whether the requested combination of functions has any known hardware conflicts. This verification step can prevent test failures or device malfunctions caused by improper configuration from the outset.

[0045] After verifying the user input's validity, the test scenario parameter confirmation phase begins. Specifically, based on the test characteristics reflected in the user input parameters (e.g., "testing high-performance network storage"), the most suitable benchmark test template is intelligently matched from a pre-configured test scenario template library. The benchmark test template can be a predefined, complete test plan skeleton, containing numerous preset test scenario parameters for a typical test scenario, such as default traffic models, detailed network topology configurations, and data collection indicator lists. Benchmark test templates provide a validated foundation of best practices, ensuring the professionalism and standardization of the testing.

[0046] Finally, user-input parameters, such as a specific test data package size of "1500 bytes," are used to replace or populate the corresponding preset test scenario parameters in the selected benchmark template. Specifically, user-input parameters take precedence, while aspects not entered by the user are replaced with high-quality default values ​​provided by the benchmark template. The complete set of parameters generated after the replacement is determined as the final test scenario parameters for this test. This set of parameters not only incorporates the user's personalized testing intentions but also inherits the comprehensiveness and reliability of the standardized template, laying a precise and directly operable configuration foundation for subsequent automated test execution.

[0047] This application's embodiments avoid configuration errors in advance through a feasibility verification mechanism, thereby improving the reliability and security of testing. Through template matching and parameter replacement mechanisms, simple user input is quickly transformed into professional and comprehensive test plans, greatly reducing the professional threshold and configuration workload for testers, while ensuring the coverage quality and execution efficiency of test scenarios.

[0048] Step 206: Based on the network card type identifier under test, call the driver interface corresponding to the network card under test, and establish a communication connection with the network card under test based on the driver interface.

[0049] Step 207: Determine the network topology simulation requirements and hardware function test requirements based on the test scenario parameters.

[0050] Step 208: According to the network topology simulation requirements, call the application programming interface of the virtual switch, and create a virtual network test topology containing virtual network cards, virtual links, and switching rules through the application programming interface.

[0051] Step 209: Generate the hardware function configuration parameters of the network card under test according to the hardware function test requirements.

[0052] In this embodiment, by automatically decomposing test scenario parameters, software control logic for guiding virtual switches to build virtual network test topologies and hardware function configuration parameters for accurately setting the internal hardware function states of smart network cards are generated synchronously. This achieves automated coordination and state alignment between the software-simulated test network and the hardware capabilities of the network card under test, providing an accurate and consistent software and hardware foundation for subsequent execution of highly simulated scenario-based tests.

[0053] Specifically, firstly, the obtained test scenario parameters are analyzed in depth and tasks are decomposed. Specifically, two core requirements can be identified and separated from these test scenario parameters: one is the network topology simulation requirement, which defines what kind of virtual network connection structure needs to be built for testing, such as simulating a data center network architecture containing multiple subnets interconnected by Layer 3 devices; the other is the hardware functional testing requirement, which clarifies which specific hardware capabilities of the smart network interface card need to be verified, such as testing its Remote Direct Memory Access (RDMA) function or tunnel encapsulation offloading capability.

[0054] Next, based on the network topology simulation requirements determined in the previous step, the application programming interface (API) of the virtual switch is invoked. A virtual switch is a network switching device implemented entirely in software and is the cornerstone of building flexible virtual networks; the application programming interface (API) is a set of predefined functions that allow other programs to instruct it to perform specific operations. By calling these APIs, the core components of the virtual network test topology can be automatically created programmatically, such as virtual network interface cards (NICs) simulating server or virtual machine network ports, virtual links connecting these devices to form pathways, and switching rules that determine how data is forwarded (such as VLAN tagging and IP routing tables). The entire process of building the virtual network test topology is entirely code-driven, efficient, and repeatable.

[0055] Simultaneously, hardware configuration tasks can be processed in parallel. Specifically, based on the parsed hardware functional test requirements, a set of specific, executable hardware functional configuration parameters can be generated. These hardware functional configuration parameters are essentially a set of control commands or register settings for the smart network interface card (NIC) under test (NIC), aiming to precisely control the state of the NIC's internal hardware circuitry. For example, if testing RDMA functionality is required, the generated hardware functional configuration parameters could include instructions for enabling the RDMA engine, configuring queue pairs, and registering memory; if disabling a certain uninstallation function is required for comparative testing, the hardware functional configuration parameters could include corresponding disable instructions. This ensures a high degree of coordination between the NIC's hardware state and the software-simulated network topology and preset test objectives.

[0056] This application's embodiments automatically parse abstract test scenario parameters into operable network topology simulation requirements and hardware function test requirements, replacing the cumbersome and error-prone manual network setup and equipment configuration process in the traditional method. This not only greatly improves the efficiency and consistency of test preparation, but also makes it possible to quickly create complex and varied network test scenarios, thereby enabling more comprehensive and realistic verification of the performance and functionality of smart network cards in various target deployment environments.

[0057] Step 210: Send the hardware function configuration parameters to the network card under test. After the network card under test is configured based on the hardware function configuration parameters, determine the target traffic model according to the test scenario parameters. The target traffic model defines at least one of the following: traffic protocol type, test data packet size distribution, average rate, and traffic burst characteristics.

[0058] Step 211: Based on the target traffic model, call the test data generation module to generate test traffic data that conforms to the target traffic model.

[0059] Step 212: The test traffic data is encapsulated and forwarded via the virtual network test topology to send the test traffic data to the network card under test for testing.

[0060] In this embodiment, by using a target traffic model and a virtual network test topology, it is ensured that the traffic ultimately applied to the network card under test meets user needs and can realistically simulate the transmission characteristics and challenges in the target network environment. This allows for a more accurate evaluation of the performance and acceleration capabilities of the smart network card in complex scenarios.

[0061] Specifically, firstly, based on the test scenario parameters, the target traffic model is determined. Here, the target traffic model is a mathematical or rule-based description of the network data flow characteristics, forming the basis for generating realistic and valid test traffic data. The target traffic model can define traffic protocol type, test packet size distribution, average rate, and traffic burst characteristics, among others. The traffic protocol type defines the basic format and interaction rules of the test packets, such as whether to use the traditional TCP protocol or the high-performance RDMA protocol; the test packet size distribution specifies the pattern of the test packet size, which can be a fixed size (e.g., 1500 bytes) or a random distribution conforming to a certain statistical law, crucial for testing the ability of smart network interface cards to handle packets of different sizes; the average rate and traffic burst characteristics jointly characterize the temporal dynamics of the test traffic, with the former determining the overall load level and the latter simulating common instantaneous traffic spikes in real networks (e.g., video buffering or database query bursts). Through these parameters, abstract test requirements can be transformed into a quantifiable and executable test traffic data generation specification.

[0062] Based on this target traffic model, a dedicated test data generation module can be scheduled to generate actual test traffic data. This module can be a hardware and software combined traffic generation engine that can strictly construct test data packets with specified protocol headers and specific packet length sequences according to the definition of the target traffic model, and inject them into the system at a precisely controlled rate (including simulated bursts). The test data generation module ensures a high degree of controllability and repeatability of test traffic data in terms of content, format, and time, providing a stable and reliable input source for performance testing.

[0063] Finally, the generated test traffic data is not directly sent to the network interface card (NIC) under test (NIC), but is instead directed to a pre-built virtual network test topology. The virtual network test topology can perform necessary encapsulation and forwarding processing on the test traffic data according to its preset rules. For example, if the virtual network test topology simulates a cross-VLAN network, the virtual switch can tag the test packets with the corresponding VLAN tags; if the virtual network test topology includes routing simulation, the test traffic data can undergo a table lookup and forwarding process similar to that of a real router. After a series of processing steps, the test traffic data finally arrives at the port of the NIC under test. This process makes the test traffic data no longer an isolated, idealized data stream, but rather contextualized traffic carrying the semantics of a specific network scenario, thus realistically stimulating and testing the hardware processing logic and acceleration performance of the NIC under test in the target deployment environment.

[0064] This application's embodiments seamlessly transform the user's abstract definition of network conditions into test traffic that can realistically reflect complex network behavior and accurately reach the hardware functional points of the network card under test. This not only replaces the tedious process of manually configuring the traffic generator, but also ensures that the performance test is conducted in a highly simulated network environment, thereby making the evaluation results of the forwarding performance, latency, throughput, and hardware acceleration performance of the network card under test more realistic and reliable.

[0065] Step 213: During the test execution, the raw data generated during the test is collected in real time. The raw data includes at least one of the first type of data, the second type of data, and the third type of data. The first type of data is collected from the hardware registers and driver counters of the network card under test. The second type of data is collected from the flow table and port statistics of the virtual network test topology. The third type of data is collected from the operating system of the test host.

[0066] Step 214: Perform time-series alignment processing on the collected raw data, and based on the alignment results, calculate the statistical characteristic value of each preset test indicator based on each preset test indicator of the network card under test, use the statistical characteristic value as the corresponding indicator data, and integrate the indicator data into a dynamically updated visualization dashboard for display.

[0067] In this embodiment, an automated analysis process from data acquisition, processing to presentation is constructed. By synchronously collecting multi-dimensional raw data covering the hardware layer, virtual network layer and host system resource layer, the scattered underlying data is transformed into indicator data that can be understood in real time. This provides testers with a decision support interface that allows them to grasp the system status in real time and quickly locate performance bottlenecks, forming a key data foundation for achieving interactivity in the testing process.

[0068] Specifically, during test execution, a parallel real-time data acquisition mechanism can be initiated to continuously capture raw data generated by the test from one or more layers. Specifically, the raw data can include three types of data: first-class data, second-class data, and third-class data. The first type of data directly originates from the hardware registers and driver counters of the network interface card (NIC) under test. Hardware registers are storage units within the NIC chip used to temporarily store state and control information, reflecting the lowest-level physical layer operational details, such as frame counts and error flags. Driver counters are software statistics maintained by the NIC driver running in the host operating system kernel, recording higher-level traffic summaries and event counts, such as the number of successfully sent / received packets. The second type of data can be collected from the flow tables and port statistics of the virtual network test topology. In a software-defined virtual network, a flow table is a set of rules defining packet matching and corresponding processing actions (such as forwarding, dropping, and modifying); port statistics record the traffic details of each virtual network interface, such as the number of bytes, packets, and dropped packets. This second type of data can reveal the paths, strategies, and potential congestion or packet loss that test traffic data undergoes in the simulated network environment. The third type of data can be obtained from the operating system of the test host, including system resource indicators such as CPU utilization, memory usage, and interrupt frequency, which are used to assess the impact of the network card under test on the overall load of the host. By synchronously collecting these three types of data, full-stack observation from the underlying hardware and virtual network to the host system is achieved.

[0069] Next, the collected raw data undergoes time-series alignment. Specifically, this is achieved by assigning a high-precision timestamp to each data point and interpolating or resampling using a unified time base, ensuring that data from different sources correspond precisely on the timeline. After alignment, relevant sequences are extracted from the aligned dataset based on predefined test metrics (such as throughput, latency, packet loss rate, and CPU utilization) for the network interface card under test. Statistical characteristics of each metric are calculated, such as the average, peak, standard deviation, or percentile within a sliding time window, and these statistical characteristics are used as the metric data. Subsequently, all metric data is integrated in real-time into a dynamically updated visualization dashboard. This dashboard can present data in the form of line charts, bar charts, or numerical panels, and automatically refreshes as the test progresses, providing testers with a centralized, intuitive, and real-time performance monitoring interface.

[0070] This application embodiment presents complex indicator data intuitively and centrally through a dynamic and visual dashboard, enabling testers to grasp the test status in real time, quickly identify performance bottlenecks or anomalies, and provide reliable data support for subsequent interactive interventions (such as dynamically adjusting test scenario parameters), thereby significantly improving the depth, efficiency, and controllability of smart network card testing.

[0071] Step 215: When an intervention instruction is received from the user during the test, the test scenario parameters or test status are dynamically adjusted based on the intervention instruction. The test continues after adjusting the test scenario parameters, or the test process is updated based on the test status.

[0072] In this embodiment of the application, optionally, after step 213, which involves "calculating the statistical characteristic value of each preset test indicator and using the statistical characteristic value as the corresponding indicator data", the method further includes: for each preset test indicator, comparing the indicator data corresponding to the preset test indicator with the preset performance baseline data point by point to generate a difference curve, and integrating the difference curve into a dynamically updated visualization dashboard for display; correspondingly, the method further includes: monitoring the difference curve in real time, generating an alarm event when the difference at any point in time in the difference curve exceeds a preset threshold range, marking the abnormal time period corresponding to the alarm event in the dynamically updated visualization dashboard, and outputting a command line interface so that the user can input intervention commands based on the command line interface; and / or, in response to the command line interface call command, outputting a command line interface so that the user can input the intervention commands based on the command line interface.

[0073] In this embodiment, an intelligent closed loop is constructed, from automatic anomaly identification to real-time debugging intervention. The monitoring of indicator data is upgraded from passive observation to a collaborative workflow that integrates "automatic diagnosis, visual alarms and interactive debugging channels". It provides testers with a command line interface to directly input intervention commands while discovering problems, thereby achieving seamless connection between monitoring, diagnosis and intervention, and significantly improving the efficiency of problem location and closed-loop verification in complex testing scenarios.

[0074] Specifically, after calculating the real-time performance metrics, the first step is to compare the metric data for each preset test metric (such as throughput and latency) with pre-stored preset performance baseline data point by point in time. Here, the preset performance baseline data represents the standard, expected, or historically normal performance level. By calculating the difference between the metric data and the preset performance baseline data, a difference curve over time can be generated, which visually shows the degree and trend of performance deviation from the baseline. Subsequently, this difference curve can be integrated into a real-time refreshed visualization dashboard for separate display, or displayed alongside or overlaid with the real-time curve generated from the metric data, allowing testers to clearly identify whether the performance meets the standards and when the deviation occurred.

[0075] Next, based on the aforementioned difference curve, each data point on the curve can be continuously analyzed. If the difference at any given moment exceeds a preset threshold range, an alarm event can be automatically triggered. Here, the preset threshold range defines a reasonable range for performance fluctuations. After the alarm is triggered, the time period corresponding to the abnormal data point can be clearly marked on the visualization dashboard using a highlighted background, marker lines, and other visually prominent methods, thus transforming the abstract alarm into a precise location on the interface.

[0076] While marking anomalies, a command-line interface can be automatically output for rapid intervention. For example, an embedded or associated command-line terminal window can pop up in the monitoring interface. This interface can be triggered bidirectionally: on one hand, it can be automatically triggered by the aforementioned alarm events; on the other hand, testers can also actively trigger it at any time by clicking interface buttons or other methods to manually request the interface to open. Regardless of how it is started, this command-line interface can serve as a control channel, allowing users to immediately input intervention commands, thereby achieving real-time control of the running test and seamlessly transitioning from problem discovery to problem-solving attempts.

[0077] This application embodiment automatically compares the indicator data with the preset performance baseline data and visualizes the differences, which can greatly improve the objectivity and efficiency of performance evaluation; through intelligent alarms and graphical anomaly markers, it realizes proactive and accurate localization of performance problems; by deeply integrating the command line interface into the monitoring process and supporting dual start modes of anomaly triggering and manual invocation, it provides testers with flexible real-time interactive capabilities.

[0078] Optionally, after step 201, the method further includes: obtaining user-defined anomaly injection parameters based on the smart network interface card (NIC) test command, and determining the anomaly type to be injected, the injection target link identifier, the injection trigger condition, and the injection duration according to the anomaly injection parameters; locating the corresponding virtual switch in the virtual network test topology according to the injection target link identifier, and configuring anomaly simulation rules corresponding to the anomaly type through the virtual switch; continuously monitoring the injection trigger condition during test execution, and sending an activation command for the anomaly simulation rule to the virtual switch when the injection trigger condition is met, so as to inject abnormal traffic into the injection target link indicated by the injection target link identifier through the virtual switch, and recording the injection time; when the time difference between the injection time and the current time reaches the injection duration, sending a stop command for the anomaly simulation rule to the virtual switch to control the virtual switch to stop generating abnormal traffic.

[0079] In this embodiment, uncontrollable real network faults are abstracted into standardized test events that can be precisely scheduled and executed by software. This enables the automated injection of faults into specific network links with time and space constraints and repeatability without physical intervention. This effectively verifies the robustness, self-healing ability, and performance of the smart network card and the overall system under abnormal scenarios.

[0080] Specifically, upon receiving the smart network interface card (NIC) test command, the user-defined anomaly injection parameters are parsed. These parameters simulate network failures or abnormal behavior. Specifically, they can include the anomaly type to be injected, the target link identifier, the injection trigger condition, and the injection duration. The anomaly type defines the specific failure to be simulated, such as random packet loss, a fixed increase in latency, or packet corruption. The target link identifier specifies which virtual link in the constructed virtual network test topology will experience an anomaly. The injection trigger condition sets the timing of the anomaly injection, which can be a specific time point (e.g., 5 seconds after the test begins) or an event trigger (e.g., when throughput reaches a certain threshold). The injection duration specifies the duration of the abnormal state.

[0081] Once the anomaly injection parameters are defined, pre-configuration can be performed in a software-defined environment. Specifically, during configuration, the virtual switch responsible for forwarding data on that link can be located within a complex virtual network test topology based on the target link identifier. In a specific embodiment, configuration commands can be issued to the virtual switch through its management interface (e.g., OpenvSwitch's database management protocol) to set an anomaly simulation rule corresponding to the anomaly type. For example, if the anomaly type is "50% packet loss," the configured anomaly simulation rule could be "execute a 50% probability drop action on packets matching this link." After configuration, the anomaly simulation rule in the virtual switch is in a standby state, waiting to be activated.

[0082] After the test process starts, while performing tests on the network interface card under test, the previously set injection trigger conditions can be continuously monitored. Specifically, a separate monitoring thread can continuously compare the current test status (such as time and performance indicators) with the injection trigger conditions. Once the injection trigger conditions are met, an activation command can be immediately sent to the virtual switch with configured rules, notifying the virtual switch to immediately enable the abnormal simulation rules. At this time, the virtual switch can interfere with normal test traffic data flowing through the target link in its data forwarding plane, injecting abnormal traffic. For example, it can start randomly dropping data packets. At the same time, the injection time can be accurately recorded as the starting point for controlling the duration of the abnormality.

[0083] Furthermore, the difference between the current time and the recorded injection time is continuously calculated. If this difference reaches a preset injection duration, a stop command can be sent to the same virtual switch to revoke or disable the previously activated abnormal simulation rule. Upon receiving the stop command, the virtual switch can cease applying abnormal interference to the target link, restoring its fully normal forwarding behavior.

[0084] This application embodiment abstracts abnormal scenarios into configurable parameters and pre-sets them in a virtual switch, enabling precise spatiotemporal triggering and elimination of abnormal behavior. This allows for efficient and repeatable simulation of various real network fault scenarios without physically damaging the link or introducing additional hardware. This not only greatly improves the efficiency and coverage of robustness and fault tolerance testing of the network card under test in abnormal environments, but also provides testers with a better testing experience.

[0085] In one specific embodiment, the above-described interactive smart NIC testing method can be implemented based on the following system deployment: Hardware environment: test host (equipped with CPU, memory, PCIe slot), the smart network card under test, and auxiliary network devices (switch, traffic generator).

[0086] Software environment: The interactive control module uses the Qt framework to develop the GUI, the test management module uses Python to write the core logic, the smart network card adaptation module integrates the SDK provided by the manufacturer (such as NVIDIA DOCA, Intel DPDK), and the scene configuration module simulates the network test topology by calling the Open vSwitch API.

[0087] Furthermore, as Figure 1 To specifically implement the method, this application provides an interactive smart network interface card (NIC) testing system, such as... Figure 3 As shown, the system includes: The interactive control module is used to receive smart network card test commands; The test management module is used to obtain the network card type identifier and test scenario parameters based on the smart network card test instructions; The intelligent network interface card (NIC) adapter module is used to call the driver interface corresponding to the NIC under test according to the NIC type identifier under test, and establish a communication connection with the NIC under test based on the driver interface. The scenario configuration module is used to construct a virtual network test topology based on the test scenario parameters and determine the hardware function configuration parameters of the network card under test, wherein the virtual network test topology is used to simulate the target network structure defined by the test scenario parameters; The smart network interface card (NIC) adapter module is also used to send the hardware function configuration parameters to the NIC under test. The test data generation module is used to generate test traffic data corresponding to the test scenario parameters after the network card under test is configured based on the hardware function configuration parameters, and send the test traffic data to the network card under test through the virtual network test topology to perform the test; The interactive control module is also used to display the indicator data corresponding to each preset test indicator of the network card under test in real time during the test execution process, and when it receives the intervention command input by the user during the test, it sends the intervention command to the test management module so as to dynamically adjust the test scenario parameters or test status based on the intervention command, continue the test after adjusting the test scenario parameters, or update the test process based on the test status.

[0088] Optionally, the test management module is used for: The test command for the smart network card is parsed to extract the network card type identifier and user input parameters, wherein the user input parameters include the test data packet size and / or the target test component of the network card under test; Based on the network interface card type identifier under test, determine the preset capability parameters corresponding to the network interface card under test, and perform feasibility verification on the user input parameters based on the preset capability parameters; The scene configuration module is used for: After the user input parameters pass the feasibility verification, a matching benchmark test template is obtained from the pre-configured test scenario template library based on the user input parameters. The benchmark test template includes multiple preset test scenario parameters. The user input parameters are used to replace the corresponding preset test scenario parameters in the benchmark template, and all the test scenario parameters in the replaced benchmark template are used as the final test scenario parameters.

[0089] Optionally, the scene configuration module is further used for: Based on the test scenario parameters, determine the network topology simulation requirements and hardware function test requirements; According to the network topology simulation requirements, the application programming interface of the virtual switch is invoked, and a virtual network test topology containing virtual network cards, virtual links, and switching rules is created through the application programming interface. Based on the hardware function test requirements, generate the hardware function configuration parameters of the network card under test.

[0090] Optionally, the test data generation module is used to: Based on the test scenario parameters, a target traffic model is determined, wherein the target traffic model is defined by at least one of the following: traffic protocol type, test data packet size distribution, average rate, and traffic burst characteristics. Based on the target traffic model, the test data generation module is invoked to generate test traffic data that conforms to the target traffic model. The test traffic data is encapsulated and forwarded through the virtual network test topology to send the test traffic data to the network card under test for testing.

[0091] Optionally, the system further includes a test data collection module; the test data collection module is used for: During the test execution, raw data generated during the test is collected in real time. The raw data includes at least one of the first type of data, the second type of data, and the third type of data. The first type of data is collected from the hardware registers and driver counters of the network card under test. The second type of data is collected from the flow table and port statistics of the virtual network test topology. The third type of data is collected from the operating system of the test host. The collected raw data is time-series aligned, and based on the alignment result, the statistical characteristic value of each preset test indicator is calculated based on each preset test indicator of the network card under test. The statistical characteristic value is used as the corresponding indicator data, and the indicator data is integrated into the dynamically updated visual dashboard of the interactive control module for display.

[0092] Optionally, the test data collection module is further configured to: The process involves calculating the statistical characteristic value of each preset test indicator, using the statistical characteristic value as the corresponding indicator data, comparing the indicator data corresponding to each preset test indicator with the preset performance baseline data point by point to generate a difference curve, and integrating the difference curve into the dynamically updated visual dashboard of the interactive control module for display. Accordingly, the interactive control module is also used for: The difference curve is monitored in real time. When the difference at any point in time exceeds a preset threshold, an alarm event is generated. The abnormal time period corresponding to the alarm event is marked in the dynamically updated visualization dashboard, and a command-line interface is output so that the user can input intervention commands based on the command-line interface; and / or, In response to a command-line interface call command, the command-line interface is output so that the user can input the intervention command based on the command-line interface.

[0093] Optionally, the test management module is further configured to: After receiving the smart network card test command, the system obtains user-defined exception injection parameters based on the smart network card test command and sends the exception injection parameters to the scenario configuration module. The scene configuration module is also used for: Based on the aforementioned anomaly injection parameters, determine the anomaly type to be injected, the target link identifier, the injection triggering condition, and the injection duration. Based on the injection target link identifier, locate the corresponding virtual switch in the virtual network test topology, and configure the anomaly simulation rules corresponding to the anomaly type through the virtual switch; During the test execution, the injection triggering conditions are continuously monitored. When the injection triggering conditions are met, an activation command for the abnormal simulation rule is sent to the virtual switch to inject abnormal traffic into the injection target link indicated by the injection target link identifier through the virtual switch, and the injection time is recorded. When the time difference between the injection time and the current time reaches the injection duration, a stop command for the abnormal simulation rule is sent to the virtual switch to control the virtual switch to stop generating abnormal traffic.

[0094] Furthermore, as a refinement and extension of the specific implementation methods of the above embodiments, and to fully illustrate the specific implementation process of this embodiment, another interactive smart network interface card (NIC) testing system is provided, such as... Figure 4 As shown, the system includes an interactive control module, a test management module, a scenario configuration module, a smart network card adaptation module, a test data collection module, and a test data generation module (not shown in the figure): Users trigger the generation of smart network interface card (NIC) test commands through the interface provided by the interactive control module. This module converts the user's NIC test commands (such as start, pause, adjust) into structured commands and sends them to the test management module.

[0095] As the core scheduler, the test management module, upon receiving a smart NIC test command, first invokes the scenario configuration module. The scenario configuration module, based on the network topology simulation requirements in the test scenario parameters, manipulates a virtual switch via a software interface to construct the specified virtual network test environment (i.e., the virtual network test topology). Simultaneously, the test management module can schedule the smart NIC adaptation module. The smart NIC adaptation module integrates driver interfaces for NICs from different manufacturers. Based on the type identifier of the NIC under test, it invokes the corresponding driver interface, establishes communication with the smart NIC under test, and issues hardware function configuration parameters (such as enabling RDMA acceleration) to complete the initial configuration of the NIC under test. Here, the hardware function configuration parameters can be generated by the scenario adaptation module based on hardware function test requirements, which can be determined based on the test scenario parameters.

[0096] Next, the test management module schedules the test data generation module to generate test traffic data that conforms to the target traffic model. This test traffic data is processed and forwarded through the constructed virtual switch network topology and finally delivered to the smart NIC under test, thereby initiating the test. Throughout the test execution process, the test data collection module is scheduled to synchronously collect raw data from three aspects: performance data from the hardware registers and driver interfaces of the smart NIC under test, network flow forwarding information from the flow tables and ports of the virtual switch, and system resource (such as CPU / memory) consumption data from the host operating system.

[0097] The test management module monitors the entire process and supports advanced control commands issued by users through the interactive control module, such as pause, adjust, stop, and resume testing from a breakpoint. For example, when a user discovers a performance anomaly, they can pause the test, adjust the parameters, and then resume execution from the breakpoint.

[0098] The test data collection module processes the raw data in real time. On the one hand, it feeds back key performance indicators to the interactive control module for real-time display. On the other hand, it performs in-depth analysis and finally generates detailed test reports (such as PDF reports / charts) for users to export.

[0099] In one specific embodiment, users can also directly select test scenarios through the interactive control module, such as setting the data packet size, setting the smart network card test components to CPU, memory, hard disk, network, etc.

[0100] The interactive smart network card testing system of this application embodiment has the following features: (1) High interactivity: Users can intervene in the testing process in real time through a visual interface, dynamically adjust parameters, and quickly verify the performance of smart network cards in complex scenarios. (2) Scenario flexibility: It supports custom target traffic models, virtual network test topologies, and anomaly injection, covering all scenario requirements from functional verification to extreme performance testing. (3) Efficient compatibility testing: It automatically switches between test environments and various components of the smart network card under test, reducing the operational complexity of cross-system and cross-version testing. (4) Intuitive results: It visualizes key indicators in real time, helping users quickly locate the performance bottlenecks or functional defects of smart network cards.

[0101] It should be noted that other corresponding descriptions of the functional units involved in the interactive smart network card testing system provided in this application embodiment can be found in the following references. Figures 1 to 2 The corresponding descriptions in the method will not be repeated here.

[0102] This application also provides a computer device, which may specifically be a personal computer, a server, a network device, etc. Figure 5 As shown, the computer device includes a bus, a processor, memory, and a communication interface, and may also include an input / output interface and a display device. The processor provides computing and control capabilities. The memory includes a non-volatile storage medium and internal memory. The non-volatile storage medium stores an operating system, computer programs, and a database. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage medium. The database stores location information. The network interface allows communication with external terminals via a network connection. When the computer program is executed by the processor, it implements the steps in the various method embodiments.

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

[0104] In one embodiment, a computer-readable storage medium is provided, which may be non-volatile or volatile, having stored thereon a computer program that, when executed by a processor, implements the steps in the above method embodiments.

[0105] In one embodiment, a computer program product is provided, including a computer program that, when executed by a processor, implements the steps in the above method embodiments.

[0106] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, data stored, data displayed, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties.

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

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

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

Claims

1. An interactive intelligent network card test method, characterized in that, Comprising: Receiving an intelligent network card test instruction; Based on the intelligent network card test instruction, obtaining the type identification of the measured network card and the test scene parameters, calling the driving interface corresponding to the measured network card according to the type identification of the measured network card, establishing the communication connection between the driving interface and the measured network card, and constructing the virtual network test topology according to the test scene parameters, and determining the hardware function configuration parameters of the measured network card, wherein the virtual network test topology is used to simulate the target network structure defined by the test scene parameters; The hardware function configuration parameters are sent to the measured network card, and after the measured network card is configured based on the hardware function configuration parameters, the test flow data corresponding to the test scene parameters is generated, and the test flow data is sent to the measured network card through the virtual network test topology to execute the test; During the test execution, the index data corresponding to each preset test index of the measured network card is displayed in real time, and when the intervention instruction input by the user is received during the test, the test scene parameters or the test state are dynamically adjusted based on the intervention instruction, and the test is continued after the test scene parameters are adjusted, or the test flow is updated based on the test state.

2. The method of claim 1, wherein, The test flow data corresponding to the test scene parameters is generated, and the test flow data is sent to the measured network card through the virtual network test topology to execute the test; The type identification of the measured network card and the test scene parameters are obtained based on the intelligent network card test instruction, comprising: The intelligent network card test instruction is parsed, and the type identification of the measured network card and the user input parameters are extracted, wherein the user input parameters include test data packet size and / or target test components of the measured network card; According to the type identification of the measured network card, the preset capability parameters corresponding to the measured network card are determined, and the user input parameters are verified based on the preset capability parameters; After the user input parameters pass the feasibility verification, the matching reference test template is obtained from the preconfigured test scene template library according to the user input parameters, wherein the reference test template includes a plurality of preset test scene parameters; 3. The method of claim 1, wherein, The user input parameters are used to replace the corresponding preset test scene parameters in the reference test template, and all test scene parameters in the replaced reference test template are used as the final test scene parameters. According to the test scene parameters, the virtual network test topology is constructed, and the hardware function configuration parameters of the measured network card are determined, comprising: According to the test scene parameters, the network topology simulation requirements and the hardware function test requirements are determined; According to the network topology simulation requirements, the application programming interface of the virtual switch is called, and the virtual network test topology containing the virtual network card, the virtual link and the switching rule is created through the application programming interface; 4. The method of claim 1, wherein, According to the hardware function test requirements, the hardware function configuration parameters of the measured network card are generated. The test flow data corresponding to the test scene parameters is generated, and the test flow data is sent to the measured network card through the virtual network test topology to execute the test, comprising: According to the test scene parameter, a target traffic model is determined, wherein the target traffic model defines at least one of a traffic protocol type, a test data packet size distribution, an average rate, and a traffic burst feature; According to the target traffic model, a test data generation module is called to generate test traffic data conforming to the target traffic model through the test data generation module; The test traffic data is encapsulated and forwarded via the virtual network test topology to send the test traffic data to the tested network card for testing.

5. The method of claim 1, wherein, During the test execution, the method further includes: During the test execution, raw data generated in the test process is collected in real time, wherein the raw data includes at least one of first data, second data, and third data, the first data is collected from hardware registers and driver counters of the tested network card, the second data is collected from flow table and port statistical information of the virtual network test topology, and the third data is collected from an operating system of a test host; The collected raw data is time-aligned, and based on the alignment result, statistical characteristic values of each preset test index of the tested network card are calculated, the statistical characteristic values are taken as corresponding index data, and the index data are integrated into a dynamically updated visual dashboard for display.

6. The method of claim 5, wherein, After the statistical characteristic values of each preset test index are calculated and the statistical characteristic values are taken as corresponding index data, the method further includes: For each preset test index, the index data corresponding to the preset test index are compared with preset performance baseline data point by point to generate a difference curve, and the difference curve is integrated into the dynamically updated visual dashboard for display. Correspondingly, the method further includes: Real-time monitoring of the difference curve, when the difference at any time point in the difference curve exceeds a preset threshold range, an alarm event is generated, an abnormal period corresponding to the alarm event is marked in the dynamically updated visual dashboard, and a command line interface is output to enable a user to input an intervention instruction based on the command line interface; and / or In response to a calling instruction of the command line interface, a command line interface is output to enable a user to input the intervention instruction based on the command line interface.

7. The method of claim 1, wherein, After the intelligent network card test instruction is received, the method further includes: Based on the intelligent network card test instruction, user-defined abnormal injection parameters are obtained, and based on the abnormal injection parameters, a type of abnormality to be injected, an injection target link identifier, an injection trigger condition, and an injection duration are determined; According to the injection target link identifier, a corresponding virtual switch in the virtual network test topology is located, and an abnormality simulation rule corresponding to the type of abnormality is configured through the virtual switch; During the test execution, the injection trigger condition is continuously monitored, and when the injection trigger condition is met, an activation instruction of the abnormal simulation rule is sent to the virtual switch to inject abnormal traffic on the injection target link indicated by the injection target link identifier through the virtual switch, and the injection time is recorded; When the time difference between the injection time and the current time reaches the injection duration, a stop instruction of the abnormal simulation rule is sent to the virtual switch to control the virtual switch to stop generating abnormal traffic.

8. An interactive intelligent network card testing system, characterized in that, Comprise: An interaction control module configured to receive a smart network interface card test instruction; A test management module configured to obtain a type identifier of a network interface card under test and test scenario parameters based on the smart network interface card test instruction; A smart network interface card adaptation module configured to call a driver interface corresponding to the network interface card under test according to the type identifier of the network interface card under test, and establish a communication connection between the smart network interface card adaptation module and the network interface card under test based on the driver interface; A scenario configuration module configured to construct a virtual network test topology according to the test scenario parameters, and determine hardware function configuration parameters of the network interface card under test, wherein the virtual network test topology is used to simulate a target network structure defined by the test scenario parameters; The smart network interface card adaptation module is further configured to send the hardware function configuration parameters to the network interface card under test; A test data generation module configured to generate test traffic data corresponding to the test scenario parameters after the network interface card under test is configured based on the hardware function configuration parameters, and send the test traffic data to the network interface card under test through the virtual network test topology to perform a test; The interaction control module is further configured to display index data corresponding to each preset test index of the network interface card under test in real time during the test execution, and when an intervention instruction input by a user is received during the test, send the intervention instruction to the test management module to dynamically adjust the test scenario parameters or the test state based on the intervention instruction, and continue the test after adjusting the test scenario parameters, or update the test process based on the test state.

9. A storage medium having stored thereon a computer program, characterized in that The computer program is executed by the processor to implement the method of any one of claims 1-7.

10. A computer device comprising a storage medium, a processor, and a computer program stored on the storage medium and executable on the processor, characterized in that, The processor executes the computer program to implement the method of any one of claims 1-7.