Traffic simulation method and device, electronic equipment, storage medium and product

By obtaining the basic network simulation information of the traffic simulation network and dividing the molecule set for parallel simulation, the problem of too long large-scale traffic simulation time in the existing technology is solved, and the effect of shortening the simulation time without affecting the simulation results is achieved.

CN119211138APending Publication Date: 2024-12-27PURPLE MOUNTAIN LAB
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411225227.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-03
Publication Date
2024-12-27

AI Technical Summary

Technical Problem

The simulation time of existing traffic simulation tools in large-scale traffic scenarios is too long, which affects the accuracy of simulation results, and it is difficult to shorten the simulation time without affecting the simulation results.

Method used

By obtaining the basic network simulation information of the traffic simulation network, determining the traffic attribute information of the traffic to be simulated, and dividing the set of traffic to be simulated into at least two subsets according to the preset simulation purpose, parallel simulation is carried out to determine the sub-simulation result, thereby shortening the simulation time.

Benefits of technology

Without affecting the simulation results, it effectively reduces the simulation time of large-scale traffic and improves simulation efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119211138A_ABST
    Figure CN119211138A_ABST
Patent Text Reader

Abstract

The invention discloses a traffic simulation method and device, electronic equipment, a storage medium and a product, and relates to the technical field of computers. The traffic simulation method comprises the following steps: acquiring network simulation basic information of a traffic simulation network and a to-be-simulated traffic set, and determining traffic attribute information of to-be-simulated traffic in the to-be-simulated traffic set according to the network simulation basic information; dividing the to-be-simulated traffic set into at least two traffic subsets according to a preset simulation purpose and the traffic attribute information; and performing parallel simulation on each traffic subset to determine a sub-simulation result, and determining a traffic simulation result according to the sub-simulation result. According to the embodiment of the invention, the to-be-simulated traffic set is split and simulated in parallel according to the preset simulation purpose and the traffic attribute information, so that the traffic simulation time is greatly shortened and the traffic simulation efficiency is improved on the premise of not influencing the simulation result.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of computer technology, and in particular to a flow simulation method, device, electronic equipment, storage medium and product. Background Art

[0002] Time Sensitive Networking (TSN) refers to a set of "sub-standards" developed under the IEEE802.1 standard framework based on specific application requirements. It aims to establish a "universal" time-sensitive mechanism for the Ethernet protocol to ensure the time determinism of network data transmission.

[0003] In order to better apply the TSN protocol and enable it to be implemented in the actual network, it helps key traffic to transmit messages according to the expected delay, eliminate interference, and make up for shortcomings to better ensure the determinism of the network. In real applications, especially in large-scale traffic scenarios, algorithm configuration and delivery adaptation require a lot of time. Simulation can well verify the accuracy of the solution before actual application and improve the success rate of actual application. Therefore, the efficiency of simulation will also affect the actual application.

[0004] Currently, most popular simulation tools use discrete event mode, that is, a single thread simulates each network event. When simulating large-scale traffic, it takes a lot of time. Therefore, how to greatly shorten the simulation time without affecting the simulation results has become an urgent problem to be solved. Summary of the invention

[0005] The present invention provides a flow simulation method, device, electronic device, storage medium and product to solve the problem that the prior art cannot shorten the simulation time and improve the simulation efficiency without affecting the simulation results.

[0006] According to one aspect of the present invention, a traffic simulation method is provided, wherein the method comprises:

[0007] Obtain network simulation basic information of the traffic simulation network and a set of traffic to be simulated, and determine traffic attribute information of the traffic to be simulated in the set of traffic to be simulated according to the network simulation basic information;

[0008] Dividing the to-be-simulated traffic set into at least two traffic subsets according to a preset simulation purpose and the traffic attribute information;

[0009] The flow subsets are simulated in parallel to determine sub-simulation results, and the flow simulation result is determined according to the sub-simulation results.

[0010] According to another aspect of the present invention, a flow simulation device is provided, wherein the device comprises:

[0011] The attribute information determination module is used to obtain network simulation basic information of the traffic simulation network and a set of traffic to be simulated, and determine the traffic attribute information of the traffic to be simulated in the set of traffic to be simulated according to the network simulation basic information;

[0012] A subset division module, used for dividing the to-be-simulated traffic set into at least two traffic subsets according to a preset simulation purpose and the traffic attribute information;

[0013] The simulation result determination module is used to perform parallel simulation on each of the flow subsets to determine a sub-simulation result, and determine a flow simulation result according to the sub-simulation results.

[0014] According to another aspect of the present invention, there is provided an electronic device, the electronic device comprising:

[0015] at least one processor; and

[0016] a memory communicatively connected to the at least one processor; wherein,

[0017] The memory stores a computer program that can be executed by the at least one processor, and the computer program is executed by the at least one processor so that the at least one processor can execute the traffic simulation method described in any embodiment of the present invention.

[0018] According to another aspect of the present invention, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a processor to implement the traffic simulation method described in any embodiment of the present invention when executed.

[0019] According to another aspect of the present invention, an embodiment of the present invention further provides a computer program product, the computer program product includes a computer program, and when the computer program is executed by a processor, the traffic simulation method of any embodiment of the present invention is implemented.

[0020] The technical solution of the embodiment of the present invention obtains network simulation basic information of the traffic simulation network and the traffic set to be simulated, determines the traffic attribute information of the traffic to be simulated in the traffic set to be simulated according to the network simulation basic information, and ensures the accuracy of the traffic attribute information; divides the traffic set to be simulated into at least two traffic subsets according to the preset simulation purpose and the traffic attribute information, simulates each traffic subset in parallel to determine a sub-simulation result, and determines the traffic simulation result according to the sub-simulation result, thereby effectively reducing the simulation time of large-scale traffic and improving the simulation efficiency without affecting the simulation results.

[0021] It should be understood that the contents described in this section are not intended to identify the key or important features of the embodiments of the present invention, nor are they intended to limit the scope of the present invention. Other features of the present invention will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS

[0022] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0023] Figure 1 is a flow chart of a traffic simulation method provided according to the first embodiment of the present invention;

[0024] Figure 2 is a flow chart of a traffic simulation method provided according to Embodiment 2 of the present invention;

[0025] Figure 3 This is an example diagram of a network topology structure provided by Embodiment 3 of the present invention;

[0026] Figure 4 is a flow chart of a traffic simulation method provided according to Embodiment 3 of the present invention;

[0027] Figure 5 is a structural schematic diagram of a flow simulation device provided according to Embodiment 4 of the present invention;

[0028] Figure 6 It is a structural schematic diagram of an electronic device for implementing a flow simulation method according to an embodiment of the present invention. DETAILED DESCRIPTION

[0029] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.

[0030] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0031] Embodiment 1

[0032] Figure 1 1 is a flow chart of a traffic simulation method provided according to the first embodiment of the present invention. This embodiment is applicable to the simulation of large-scale traffic in a time-sensitive network. The method can be executed by a traffic simulation device. The traffic simulation device can be implemented in the form of hardware and / or software. The traffic simulation device can be configured in an electronic device. Figure 1 As shown, the method includes:

[0033] S110, obtaining network simulation basic information of the traffic simulation network and a set of traffic to be simulated, and determining traffic attribute information of the traffic to be simulated in the set of traffic to be simulated according to the network simulation basic information.

[0034] Among them, the traffic simulation network can be understood as a network environment that simulates the real environment for simulation. In the actual operation process, the traffic simulation network can be used to simulate a time-sensitive network; or, the traffic simulation network can be a time-sensitive network. The basic information of network simulation can be understood as the basic network information of the traffic simulation network, such as the network topology, the address information of the simulation device, and the traffic forwarding list. The set of traffic to be simulated can be understood as a set composed of traffic to be simulated, and the set of traffic to be simulated can include multiple traffic to be simulated. The task of the traffic to be simulated can be the traffic data in the actual network environment that needs to be simulated, which is used to troubleshoot problems such as message delay and network processing performance in the actual network, and better ensure the operation of the network. The traffic attribute information can be understood as information used to describe the characteristics of the traffic to be simulated. Exemplarily, the traffic attribute information can at least include information such as traffic size, traffic cycle, starting address, target address, transmission protocol through simulation equipment, and traffic transmission path. For different traffic to be simulated, the traffic attribute information can be different. In one embodiment, the traffic attribute information of the traffic to be simulated can be pre-set.

[0035] In an embodiment, the network topology of the traffic simulation network can be obtained by a pre-set network management tool, the address information of the simulation device of each node is determined as the device address information, and the traffic forwarding list stored in each simulation device is extracted, and the network topology, the simulation device address information and the traffic forwarding list are used as the network simulation basic information. In the actual operation process, the traffic transmission path of the traffic to be simulated can be stored in the traffic forwarding list. The traffic size, traffic cycle, starting address, target address, and transmission protocol of the traffic to be simulated can be extracted, and the simulation device through which the traffic to be simulated and the traffic transmission path of the traffic to be simulated can be determined according to the network topology, the simulation device address information and the traffic forwarding list, and the information such as the traffic size, traffic cycle, transmission protocol, the simulation device through which the traffic to be simulated and the traffic transmission path are used as the traffic attribute information of the traffic to be simulated. In an embodiment, the link bandwidth size, device type, device name, etc. between the simulation devices can also be parsed as the network simulation basic information. In addition, the priority of the traffic to be simulated can also be determined, and the tag (VLAN Tag) of the traffic can be determined, and the priority and tag can also be used as the traffic attribute information of the traffic to be simulated.

[0036] In the actual operation process, the traffic transmission path of some traffic to be simulated may not exist in the traffic forwarding list. At this time, all reachable paths from the start address to the target address can be found according to the network topology structure, and sorted according to the shortest path. All reachable paths are checked cyclically. If the preset path conditions are met, such as the reachable path does not have any faults, the reachable path can be used as the traffic transmission path for the simulated traffic.

[0037] S120: Divide the traffic set to be simulated into at least two traffic subsets according to a preset simulation purpose and traffic attribute information.

[0038] The preset simulation purpose may be understood as a preset simulation traffic purpose. Exemplarily, the preset simulation purpose may at least include link bandwidth load verification, message delay verification, device processing performance verification, and protocol type verification. Among them, link bandwidth load verification can be understood as the main purpose of this simulation is to verify the bandwidth usage of all links in the network topology, and the traffic to be simulated with synchronized traffic cycles can be simulated at the same time; message delay verification is to understand that the main purpose of this simulation experiment is to obtain statistical values ​​such as minimum delay, maximum delay, average delay, jitter, etc. of the traffic, as well as the situation when messages compete with each other for the export channel at the same export of the same simulation device. Therefore, it is necessary to ensure that the traffic to be simulated on the same traffic transmission path is simulated at the same time; device processing performance verification means that the main purpose of this simulation is to verify the processing performance of the switching node, whether the device can process multiple inlet flows into the simulation device in time, whether it can forward the flow in time, and whether the device cache is sufficient. Therefore, it is necessary to ensure that the traffic to be simulated passing through the same simulation device is simulated at the same time; protocol verification means that the main purpose of this simulation is to verify whether the protocol used by the message can be correctly processed between different simulation devices, including establishing connections and identifying protocols between simulation devices, etc., in order to verify protocol consistency, and it is necessary to ensure that the same transmission protocol is simulated at the same time.

[0039] The traffic subset can be considered as a set of traffic to be simulated that has specific characteristics or meets specific conditions and is divided from the traffic set to be simulated. In actual operation, the traffic subset can be divided according to the simulation purpose.

[0040] In an embodiment, the preset simulation purpose may be determined first, the corresponding traffic attribute information may be divided according to the preset simulation purpose, and then the traffic to be simulated to which the traffic attribute information belongs may be divided into at least two traffic subsets. In the actual operation process, different traffic segmentation characteristics may exist for different preset simulation purposes. Exemplarily, when the preset simulation purpose is link bandwidth load verification, the traffic segmentation characteristic may be traffic cycle synchronization; when the preset simulation purpose is message delay verification, the traffic segmentation characteristic may be the same traffic transmission path; when the preset simulation purpose is device processing performance verification, the traffic segmentation characteristic may be passing through the same simulation device; when the preset simulation purpose is protocol class verification, the traffic segmentation characteristic may be the same transmission protocol. The corresponding traffic attribute information is extracted according to the traffic segmentation characteristic, and the traffic to be simulated is divided according to the traffic attribute information.

[0041] In one embodiment, when the traffic segmentation feature is traffic cycle synchronization, it can be determined that the traffic to be simulated has the same cycle, or the cycle of the traffic to be simulated has an integer divisibility relationship, and these traffic to be simulated can be divided into the same traffic subset; when the traffic segmentation feature is the same traffic transmission path, it can be determined that the traffic to be simulated with the same traffic transmission path is divided into the same traffic subset; when the traffic segmentation feature is passing through the same simulation device, it can be determined that the traffic to be simulated with the same simulation device is divided into the same traffic subset; when the traffic segmentation feature is the same transmission protocol, the transmission protocol of each traffic to be simulated can be determined, and the traffic to be simulated with the same transmission protocol can be divided into the same traffic subset. In one embodiment, after the traffic set to be simulated is divided into multiple traffic subsets, the number of traffic to be simulated in each traffic subset can be determined as the first number, and the number of traffic to be simulated in the traffic set to be simulated can be determined as the second number, and the ratio of the first number to the second number can be determined. When it is determined that the ratio is greater than the preset ratio, the traffic subset corresponding to the ratio greater than the preset ratio is divided into at least two traffic subsets to ensure rapid simulation of the traffic subsets.

[0042] S130, performing parallel simulation on each flow subset to determine a sub-simulation result, and determining a flow simulation result according to the sub-simulation results.

[0043] Among them, the sub-simulation result can be understood as the simulation result obtained after the traffic simulation is performed on each traffic subset. In the actual operation process, the sub-simulation result may include but is not limited to statistical values ​​such as minimum traffic delay, maximum delay, average delay, jitter, and network resource usage. The type of sub-simulation result may be related to the simulation purpose. The traffic simulation result can be considered as the simulation result of all the traffic to be simulated. The traffic simulation result can be the sum of the sub-simulation results.

[0044] In an embodiment, each traffic subset can be input in parallel to the traffic simulation network, and simulated in parallel in the traffic simulation network to obtain a sub-simulation result of each traffic subset, and then the sub-simulation results are summarized as traffic simulation results. In the actual operation process, since the traffic simulation network is a time-sensitive network, the time-sensitive network configuration information of each traffic subset can be determined by a preset controller according to the traffic attribute information of the traffic to be simulated in the traffic subset, such as queuing and forwarding based on time-aware shaping (Queuing and Forwarding based on Time-Aware Shaping, QBV) configuration, quality of service-aware clock independent (Quality of Service-aware Clock Independent, QCI) configuration, credit-based shaper (Credit-Based Shaper, CB) configuration and quarter cycle hopping (Quarter Cycle Hop, QCH) configuration, etc. After simulating the traffic to be simulated in each traffic subset based on the time-sensitive network configuration information, a sub-simulation result is obtained, and then the sub-simulation result is summarized as the traffic simulation result.

[0045] The embodiments of the present invention obtain network simulation basic information of the traffic simulation network and a traffic set to be simulated, determine the traffic attribute information of the traffic to be simulated in the traffic set to be simulated according to the network simulation basic information, and ensure the accuracy of the traffic attribute information; divide the traffic set to be simulated into at least two traffic subsets according to a preset simulation purpose and the traffic attribute information, simulate each traffic subset in parallel to determine a sub-simulation result, and determine the traffic simulation result according to the sub-simulation result, thereby effectively reducing the simulation time of large-scale traffic and improving the simulation efficiency without affecting the simulation result.

[0046] Embodiment 2

[0047] Figure 2 This is a flow chart of a traffic simulation method provided by the second embodiment of the present invention. This embodiment is a further description of a traffic simulation method based on the above embodiment. Figure 2 As shown, the method includes:

[0048] S201. Determine basic network simulation information, where the basic network simulation information includes a network topology structure of a traffic simulation network, address information of a simulation device, and a traffic forwarding list.

[0049] Among them, the network topology structure can be understood as the connection mode and layout of each node (simulation device) and link in the traffic simulation network. Exemplarily, the network topology structure can include but is not limited to ring topology, star topology and tree topology. The simulation device address information can be understood as the address information of the simulation device. The traffic forwarding list can be used to record the transmission path of the traffic to be simulated from the starting address to the target address. Exemplarily, the traffic forwarding list can be a forwarding port list determined according to the target address and the virtual subnet identifier.

[0050] In an embodiment, the network topology of the traffic simulation network can be obtained through a network management tool, and the simulation device address information and traffic forwarding list stored in each simulation device can be queried, and the network topology, simulation device address information, traffic forwarding list and other information can be used as basic information for network simulation.

[0051] S202: extract the traffic to be simulated from the set of traffic to be simulated, and determine the traffic size, traffic cycle, start address, destination address, and transmission protocol of the traffic to be simulated.

[0052] Among them, the traffic size refers to the data volume of the traffic to be simulated; the traffic period refers to the regular repetitive pattern presented by the traffic to be simulated within a certain period of time; the starting address refers to the source address of the traffic to be simulated; the destination address refers to the destination address of the traffic to be simulated; the transmission protocol can be understood as the protocol for traffic transmission, such as the Transmission Control Protocol, the User Datagram Protocol, etc.

[0053] In an embodiment, the traffic to be simulated in the traffic set to be simulated may be determined, and the traffic size, traffic cycle, start address, destination address, and transmission protocol of the traffic to be simulated may be identified.

[0054] S203: Determine the simulation device through which the traffic to be simulated passes and the traffic transmission path of the traffic to be simulated according to the network topology, the simulation device address information and the traffic forwarding list.

[0055] The simulated device passed through can be considered as the simulated device passed through by the traffic to be simulated in the process of going from the starting address to the target address.

[0056] In an embodiment, after determining the network topology result, the simulation device address information and the traffic forwarding list, the transmission path of the traffic to be simulated in the traffic forwarding list can be extracted as the traffic transmission path of the traffic to be simulated. If the transmission path of the traffic to be simulated does not exist in the traffic forwarding list, all reachable paths from the start address to the target address can be determined according to the network topology structure, and the reachable paths can be sorted in order from short to long, and all reachable paths can be traversed. The shortest reachable path among the reachable paths that meet the preset path conditions is used as the traffic transmission path of the traffic to be simulated. Then identify the simulation device passing through the traffic transmission path as the simulation device passing through the traffic to be simulated.

[0057] In one embodiment, determining the simulated device through which the traffic to be simulated passes and the traffic transmission path of the traffic to be simulated according to the network topology, the simulated device address information and the traffic forwarding list includes:

[0058] Determine whether the traffic forwarding list contains a transmission path for the traffic to be simulated;

[0059] If it exists, the transmission path is used as the traffic transmission path corresponding to the traffic to be simulated;

[0060] If it does not exist, determine the reachable path from the start address to the target address of the traffic to be transmitted according to the network topology, the start address and the target address, sort the reachable paths in order from short to long, and determine the shortest reachable path among the reachable paths that meet the preset path conditions as the traffic transmission path of the traffic to be simulated;

[0061] Determine the simulation device through which each flow to be simulated passes according to the network topology, simulation device address information and flow transmission path.

[0062] Among them, the preset path condition can be understood as a pre-set condition that meets the path requirements. Exemplarily, the preset path condition can at least include that the reachable path of the traffic does not conflict with the traffic forwarding list of the simulation device. Exemplarily, when the virtual local area network identifier (vlan ID) and destination address of the traffic to be simulated exist in the traffic forwarding list, its forwarding table exit and the simulation device exit of the forwarding path must be the same. If they are not the same, it is considered that the preset path condition is not met; if the vlan ID and destination address of the traffic do not exist in the forwarding table, it can also be considered that the condition is met. After determining the traffic transmission path, the simulation device that each traffic to be simulated passes through can be determined as a passing simulation device according to the network topology, the simulation device address information and the traffic transmission path.

[0063] In an embodiment, it can be determined whether there is a transmission path for the traffic to be simulated in the traffic forwarding list. If so, the transmission path can be directly used as the traffic transmission path corresponding to the traffic to be simulated. If not, the reachable path from the start address to the target address can be determined by the network topology, the start address and the target address. And the reachable paths are sorted from short to long to facilitate the traversal of the reachable paths. The shortest reachable path among the reachable paths that meet the preset path conditions is used as the traffic transmission path for the traffic to be simulated. In one embodiment, if all reachable paths do not meet the preset path conditions, the traffic to be simulated can be deleted.

[0064] S204: Determine the flow attribute information of the flow to be simulated according to the flow size, flow period, transmission protocol, simulated equipment passed through, and flow transmission path.

[0065] In an embodiment, after determining the traffic size, traffic cycle, transmission protocol, simulated device and traffic transmission path, attribute information such as traffic size, traffic cycle, transmission protocol, simulated device and traffic transmission path can be used as traffic attribute information of the traffic to be simulated.

[0066] S205: Determine a preset simulation purpose, and determine traffic segmentation characteristics according to the preset simulation purpose.

[0067] The traffic segmentation feature may be understood as a feature for segmenting the traffic to be simulated.

[0068] Among them, the preset simulation purposes include at least one of the following: link bandwidth load verification, message delay verification, equipment processing performance verification and protocol verification. Link bandwidth load verification can be understood as the main purpose of this simulation is to verify the bandwidth usage of all links in the network topology; message delay verification is to understand that the main purpose of this simulation experiment is to obtain statistical values ​​such as minimum delay, maximum delay, average delay, jitter, and the situation when messages compete for export channels at the same exit of the same simulation device; equipment processing performance verification means that the main purpose of this simulation is to verify the processing performance of the switching node, whether the device can process multiple inlet flows into the simulation device in time, whether it can forward the flow in time, and whether the device cache is sufficient; protocol verification means that the main purpose of this simulation is to verify whether the protocol used by the message can be correctly processed between different simulation devices, including establishing connections and identifying protocols between simulation devices.

[0069] In one embodiment, determining a preset simulation purpose, and determining a traffic segmentation feature according to the preset simulation purpose includes:

[0070] When it is determined that the preset simulation purpose is link bandwidth load verification, the traffic segmentation feature is determined to be traffic cycle synchronization;

[0071] When it is determined that the preset simulation purpose is message delay verification, the traffic segmentation feature is determined to be the same traffic transmission path;

[0072] When the preset simulation purpose is determined to be device processing performance verification, the traffic segmentation feature is determined to be passing through the same simulation device;

[0073] When the preset simulation purpose is determined to be protocol type verification, the traffic segmentation feature is determined to be the same transmission protocol.

[0074] In an embodiment, the preset simulation purpose can be determined. If the preset simulation purpose is link bandwidth load verification, the traffic segmentation feature can be determined to be traffic cycle synchronization; if the preset simulation purpose is message delay verification, the traffic segmentation feature can be determined to be the same traffic transmission path; if the preset simulation purpose is device processing performance verification, the traffic segmentation feature can be determined to be passing through the same simulation device; if the preset simulation purpose is protocol class verification, the traffic segmentation feature can be determined to be the same transmission protocol.

[0075] S206. Extract the traffic attribute information associated with the traffic segmentation feature, and determine the traffic attribute information having the same traffic segmentation feature.

[0076] In an embodiment, the traffic attribute information associated with the traffic segmentation feature can be determined, and the traffic attribute information having the same traffic segmentation feature can be determined. Exemplarily, when the traffic segmentation feature is traffic cycle synchronization, the cycle size in the traffic attribute information can be extracted to determine the cycle size having the same cycle size, or the cycle of the traffic to be simulated has an integer divisibility relationship; when the traffic segmentation feature is the same traffic transmission path, the traffic transmission path in the traffic attribute information can be extracted to determine the same traffic transmission path; when the traffic segmentation feature is passing through the same simulation device, the passing simulation device in the traffic attribute information can be extracted to determine the same passing simulation device; when the traffic segmentation feature is the same transmission protocol, the transmission protocol in the traffic attribute information can be extracted to determine the same transmission protocol.

[0077] S207: Store the traffic attribute information having the same traffic segmentation characteristics into the same traffic subset.

[0078] In an embodiment, traffic attribute information with the same traffic segmentation characteristics can be stored as the same traffic subset. In actual operation, traffic to be simulated with the same period or the period of the traffic to be simulated that is divisible by an integer can be divided into the same traffic subset; traffic to be simulated with the same traffic transmission path can be divided into the same traffic subset; traffic to be simulated that is determined to have the same simulation device can be divided into the same traffic subset; or traffic to be simulated with the same transmission protocol can be divided into the same traffic subset.

[0079] In one embodiment, after storing the traffic attribute information having the same traffic segmentation characteristics into the same traffic subset, the method further includes:

[0080] Determine the number of to-be-simulated flows in each flow subset as a first number, and determine the number of to-be-simulated flows in the to-be-simulated flow set as a second number;

[0081] A ratio of the first quantity to the second quantity is determined, and when the ratio is determined to be greater than a preset ratio, a flow subset corresponding to the ratio greater than the preset ratio is divided into at least two flow subsets.

[0082] In one embodiment, the preset ratio may include but is not limited to 19%, 20%, 21%, etc.

[0083] In an embodiment, after dividing the traffic subsets, the number of traffic to be simulated in each traffic subset can be determined, and the number of traffic to be simulated in the traffic subset can be used as the first number. The number of traffic to be simulated in the traffic set to be simulated can be determined as the second number. The ratio of the first number to the second number is determined, and when the ratio is determined to be less than or equal to a preset ratio, the traffic subset is kept unchanged; when the ratio of the first number to the second number is determined to be greater than the preset ratio, the traffic subset corresponding to the ratio greater than the preset ratio is divided into at least two traffic subsets.

[0084] S208: Determine the time-sensitive network configuration information of each traffic subset according to the traffic attribute information of the traffic to be simulated in the traffic subset.

[0085] The time-sensitive network configuration information includes at least one of the following: queuing and forwarding configuration based on time-aware shaping, clock-independent configuration based on quality of service awareness, credit-based shaper configuration, and quarter-cycle frequency hopping configuration.

[0086] Among them, the time-sensitive network configuration information can be a necessary parameter to meet the requirements of the simulated device to transmit the traffic to be simulated. The queuing and forwarding configuration based on time-aware shaping is used for deterministic transmission of the traffic to be simulated; the clock-independent configuration based on quality of service awareness can classify the traffic to be simulated according to its characteristics and set corresponding quality of service parameters for different categories of traffic to be simulated; the credit-based shaper configuration allocates a certain number of credit values ​​to each simulated device, and the credit value is used to determine the sending rate of the traffic to be simulated; the quarter-cycle frequency hopping configuration performs frequency hopping operations on multiple frequency channels to improve the anti-interference ability and reliability of the network.

[0087] In an embodiment, after determining the traffic attribute information of the traffic to be simulated in each traffic subset, time-sensitive network configuration information such as queuing and forwarding configuration based on time-aware shaping, clock-independent configuration based on quality of service awareness, credit-based shaper configuration, and quarter-cycle frequency hopping configuration can be configured for each traffic subset based on the traffic attribute information. In the actual operation process, the time-sensitive network configuration information of each traffic subset can be determined by a pre-set controller. Exemplarily, the controller can include but is not limited to a software-defined network controller and a time-sensitive network controller.

[0088] S209: Use the traffic subset and the time-sensitive network configuration information corresponding to the traffic subset as subset simulation parameters.

[0089] The subset simulation parameters may be understood as parameters used by each traffic subset for traffic simulation.

[0090] In an embodiment, the traffic subset and the time-sensitive network configuration information corresponding to the traffic subset may be combined as a subset simulation parameter.

[0091] S210, simulating the simulation parameters of each subset in parallel to obtain a sub-simulation result corresponding to each subset simulation parameter, and summarizing the sub-simulation results as a traffic simulation result.

[0092] In an embodiment, each subset simulation parameter may be input into the traffic simulation network in parallel, a sub-simulation result corresponding to each subset simulation parameter may be obtained through a simulator, and each sub-simulation result may be summarized as a traffic simulation result.

[0093] The embodiment of the present invention determines the network topology structure, simulation device address information and traffic forwarding list of the traffic simulation network as the basic information of the network simulation, extracts the traffic to be simulated in the traffic set to be simulated, determines the traffic size, traffic cycle, start address, destination address and transmission protocol of the traffic to be simulated, determines the simulation device through which the traffic to be simulated passes and the traffic transmission path of the traffic to be simulated according to the network topology structure, simulation device address information and traffic forwarding list, takes the traffic size, traffic cycle, transmission protocol, simulation device through which the traffic to be simulated passes and the traffic transmission path as the traffic attribute information of the traffic to be simulated, and ensures the accuracy of the traffic attribute information; determines the preset simulation purpose, determines the traffic segmentation feature according to the preset simulation purpose, extracts the traffic segmentation feature and the traffic segmentation feature, and extracts the traffic segmentation feature. The flow attribute information associated with the characteristics is determined, and the flow attribute information with the same flow segmentation characteristics is determined, and the flow attribute information with the same flow segmentation characteristics is stored in the same flow subset, so that the flow set to be simulated is segmented according to the preset simulation purpose; the time-sensitive network configuration information of each flow subset is determined according to the flow attribute information of the flow to be simulated in the flow subset based on the preset controller, the flow subset and the time-sensitive network configuration information corresponding to the flow subset are used as subset simulation parameters, the simulation parameters of each subset are simulated in parallel to obtain the sub-simulation results corresponding to the simulation parameters of each subset, and the sub-simulation results are summarized as the flow simulation results, so as to realize the parallel simulation of the flow to be simulated and shorten the time of simulating large-scale flow to be simulated.

[0094] Embodiment 3

[0095] Figure 3 This is an example diagram of a network topology structure provided by Embodiment 3 of the present invention. Figure 3 As shown, a traffic simulation method is further explained by taking a traffic simulation network containing 6 terminal devices, 3 switches, link bandwidth information of 1 Gbps, and no traffic forwarding list at present as an example.

[0096] Step 1: Get the traffic attribute information of the traffic to be simulated, including 4 traffics to be simulated, namely:

[0097] Traffic 1 to be simulated has a traffic size of 1000B, a traffic cycle of 10 milliseconds, a traffic transmission path of (terminal device 1→TSN switch 1→TSN switch 3→receiving terminal 1), a VLAN ID of 10, a starting address of terminal device 1, and a destination address of receiving terminal 1;

[0098] Traffic 2 to be simulated has a traffic size of 100B, a traffic cycle of 100 microseconds, a traffic transmission path of (terminal device 1→TSN switch 1→TSN switch 2→receiving terminal 2), a VLAN ID of 100, a starting address of terminal device 1, and a destination address of receiving terminal 2;

[0099] Traffic 3 to be simulated has a traffic size of 1400B, a traffic cycle of 100 milliseconds, a traffic transmission path of (terminal device 2 → TSN switch 1 → TSN switch 2 → receiving terminal 3), a VLAN ID of 4, a starting address of terminal device 2, and a destination address of receiving terminal 3;

[0100] The traffic 4 to be simulated has a traffic size of 1000B, a traffic cycle of 10 milliseconds, a traffic transmission path of (terminal device 2→TSN switch 1→TSN switch 3→receiving terminal 4), a VLAN ID of 10, a starting address of terminal device 2, and a target address of receiving terminal 4.

[0101] The traffic to be simulated 1, traffic to be simulated 2, traffic to be simulated 3 and traffic to be simulated 4 are combined into a traffic set to be simulated. The transmission device plus the device outlet in the transmission path is used as the traffic segmentation feature. It can be seen from the traffic transmission path in the traffic attribute information that the traffic to be simulated 1 and the traffic to be simulated 4 both pass through the TSN switch 1 and the outlet (TSN switch 2), and the traffic to be simulated 2 and the traffic to be simulated 3 both pass through the TSN switch 1 and the outlet (TSN switch 3). Therefore, the traffic to be simulated 1 and the traffic to be simulated 4 are divided into one traffic subset, and the traffic to be simulated 2 and the traffic to be simulated 3 are divided into another traffic subset. The TSN protocol configuration is calculated for the two traffic subsets respectively, and the two traffic subsets are formed into network simulations respectively. The two subsets are simulated in parallel, and the two sub-simulation results are recovered and merged into the total traffic simulation result.

[0102] In one embodiment, Figure 4 is a flow chart of a traffic simulation method provided according to Embodiment 3 of the present invention. Figure 4 This is a further description of a traffic simulation method, taking the case where there is a traffic forwarding list as an example. The method includes:

[0103] Obtain the network topology and traffic forwarding list of the traffic simulation network, configure the traffic attribute information of the traffic to be simulated, and determine the traffic segmentation characteristics according to the simulation purpose.

[0104] Determine whether there is undivided traffic to be simulated. If so, determine whether there is a traffic transmission path in the traffic forwarding list. If so, but it does not meet the preset path conditions, then end the simulation of the traffic to be simulated. If there is no traffic transmission path in the traffic forwarding list, determine all reachable paths according to the network topology, and perform cyclic judgment on all reachable paths until there is a reachable path that meets the preset path conditions as the traffic transmission path of the traffic to be simulated. Then determine whether there is a traffic subset. If there is a traffic subset, determine whether there is a traffic subset with the same traffic segmentation characteristics. If so, add the corresponding traffic subset; if not, create a new traffic subset until there is no undivided traffic to be simulated. Calculate the TSN configuration of each traffic subset, simulate each traffic subset in parallel to obtain sub-simulation results, and summarize the subset simulation results as traffic simulation results to improve the efficiency of traffic simulation.

[0105] In one embodiment, if the purpose of the simulation is to verify the link bandwidth load, the traffic to be simulated can be sorted according to the cycle size first, and then the traffic to be simulated can be rotated. If the cycle is divisible by the cycle to be simulated in the traffic subset, it is added to the traffic subset, otherwise a new traffic subset is added; then the number of traffic to be simulated in each traffic subset is checked. When the number of traffic to be simulated in the traffic subset is too large compared to the proportion of the total traffic to be simulated (an empirical value of 20% can be used), it is necessary to split it again according to the cycle sorting within the traffic subset. If the purpose of simulation is message delay verification, the traffic to be simulated is first sorted according to whether the simulation device of the starting address is consistent. If the simulation device (source device) of the starting address is consistent, it is sorted according to the traffic priority, and then the traffic to be simulated is cycled. When the traffic to be simulated has the same traffic transmission path characteristics as the traffic to be simulated in the traffic subset, it is added to the traffic subset, otherwise a new traffic subset is created to add it; if the purpose of simulation is device processing performance verification, the traffic to be simulated is first sorted according to whether the simulation device of the starting address is consistent. If the simulation device (source device) of the starting address is consistent, it is sorted according to the traffic priority, and then the traffic to be simulated is cycled. When the traffic to be simulated passes through the simulation device When there is any identical simulation device as the simulated device in the traffic subset, the traffic subset is added to it, otherwise a new traffic subset is created to add it; if the simulation purpose is protocol verification, the traffic to be simulated is first sorted according to the protocol used, and then the traffic to be simulated is cycled. When the traffic transmission protocol of the traffic to be simulated is consistent with the traffic transmission protocol used by the traffic to be simulated in the traffic subset, it is added to the traffic subset, otherwise a new traffic subset is added; then the number of traffic to be simulated in each traffic subset is checked. When the number of traffic to be simulated in the traffic subset is too large compared to the total traffic to be simulated (the empirical value of 20%), the traffic subset is split again.

[0106] Embodiment 4

[0107] Figure 5Schematic diagram of a flow simulation device according to the fourth embodiment of the present invention. Figure 5 As shown, the device includes: an attribute information determination module 51, a subset division module 52 and a simulation result determination module 53.

[0108] The attribute information determination module 51 is used to obtain network simulation basic information of the traffic simulation network and a set of traffic to be simulated, and determine the traffic attribute information of the traffic to be simulated in the set of traffic to be simulated according to the network simulation basic information.

[0109] The subset division module 52 is used to divide the traffic set to be simulated into at least two traffic subsets according to a preset simulation purpose and traffic attribute information.

[0110] The simulation result determination module 53 is used to perform parallel simulation on each flow subset to determine a sub-simulation result, and determine the flow simulation result according to the sub-simulation result.

[0111] In an embodiment of the present invention, a network simulation basic information of a traffic simulation network and a traffic set to be simulated are obtained through an attribute information determination module, and traffic attribute information of the traffic to be simulated in the traffic set to be simulated is determined according to the network simulation basic information, so as to ensure the accuracy of the traffic attribute information; a subset division module is used to divide the traffic set to be simulated into at least two traffic subsets according to a preset simulation purpose and traffic attribute information, a simulation result determination module simulates each traffic subset in parallel to determine a sub-simulation result, and a traffic simulation result is determined according to the sub-simulation result, so as to effectively reduce the simulation time of large-scale traffic and improve the simulation efficiency without affecting the simulation result.

[0112] In one embodiment, the attribute information determination module 51 includes:

[0113] A basic information determination unit, used to determine network simulation basic information, wherein the network simulation basic information includes a network topology structure of a traffic simulation network, address information of a simulation device, and a traffic forwarding list;

[0114] A data acquisition unit is used to extract the traffic to be simulated from the traffic set to be simulated, and determine the traffic size, traffic cycle, start address, destination address and transmission protocol of the traffic to be simulated;

[0115] A path determination unit, used to determine the simulation device through which the traffic to be simulated passes and the traffic transmission path of the traffic to be simulated according to the network topology, the simulation device address information and the traffic forwarding list;

[0116] The attribute information determination unit is used to determine the flow attribute information of the flow to be simulated according to the flow size, flow period, transmission protocol, simulated equipment passed through and flow transmission path.

[0117] In one embodiment, the path determination unit is specifically configured to:

[0118] Determine whether the traffic forwarding list contains a transmission path for the traffic to be simulated;

[0119] If it exists, the transmission path is used as the traffic transmission path corresponding to the traffic to be simulated;

[0120] If it does not exist, determine the reachable path from the start address to the target address of the traffic to be transmitted according to the network topology, the start address and the target address, sort the reachable paths in order from short to long, and determine the shortest reachable path among the reachable paths that meet the preset path conditions as the traffic transmission path of the traffic to be simulated;

[0121] Determine the simulation device through which each flow to be simulated passes according to the network topology, simulation device address information and flow transmission path.

[0122] In one embodiment, the subset partitioning module 52 includes:

[0123] A feature determination unit, used to determine a preset simulation purpose, and determine the traffic segmentation feature according to the preset simulation purpose; wherein the preset simulation purpose includes at least one of the following: link bandwidth load verification, message delay verification, device processing performance verification, and protocol class verification;

[0124] An information extraction unit, used to extract traffic attribute information associated with the traffic segmentation feature, and determine traffic attribute information having the same traffic segmentation feature;

[0125] The subset division unit is used to store the traffic attribute information having the same traffic segmentation characteristics into the same traffic subset.

[0126] In one embodiment, the feature determination unit is specifically configured to:

[0127] When it is determined that the preset simulation purpose is link bandwidth load verification, the traffic segmentation feature is determined to be traffic cycle synchronization;

[0128] When it is determined that the preset simulation purpose is message delay verification, the traffic segmentation feature is determined to be the same traffic transmission path;

[0129] When the preset simulation purpose is determined to be device processing performance verification, the traffic segmentation feature is determined to be passing through the same simulation device;

[0130] When the preset simulation purpose is determined to be protocol type verification, the traffic segmentation feature is determined to be the same transmission protocol.

[0131] In one embodiment, the traffic simulation device further includes:

[0132] A quantity determination module, used to determine the quantity of to-be-simulated traffic in each traffic subset as a first quantity, and to determine the quantity of to-be-simulated traffic in a to-be-simulated traffic set as a second quantity;

[0133] The set segmentation module is used to determine the ratio of the first quantity to the second quantity, and when the ratio is determined to be greater than a preset ratio, segment the flow subset corresponding to the ratio greater than the preset ratio into at least two flow subsets.

[0134] In one embodiment, the simulation result determination module 53 includes:

[0135] An information configuration unit, configured to determine time-sensitive network configuration information of each traffic subset according to traffic attribute information of the traffic to be simulated in the traffic subset; wherein the time-sensitive network configuration information includes at least one of the following: queuing and forwarding configuration based on time-aware shaping, clock-independent configuration based on quality of service awareness, credit-based shaper configuration, and quarter-cycle frequency hopping configuration;

[0136] A parameter determination unit, configured to use a traffic subset and time-sensitive network configuration information corresponding to the traffic subset as a subset simulation parameter;

[0137] The simulation result determination unit is used to simulate the simulation parameters of each subset in parallel to obtain a sub-simulation result corresponding to each subset simulation parameter, and summarize the sub-simulation results as the traffic simulation result.

[0138] The traffic simulation device provided in the embodiment of the present invention can execute the traffic simulation method provided in any embodiment of the present invention, and has the corresponding functional modules and beneficial effects of the execution method.

[0139] Embodiment 5

[0140] Figure 6 1 is a schematic diagram of the structure of an electronic device for implementing a traffic simulation method of an embodiment of the present invention. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workbenches, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices (such as helmets, glasses, watches, etc.) and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present invention described and / or required herein.

[0141] like Figure 6As shown, the electronic device 10 includes at least one processor 11, and a memory connected to the at least one processor 11, such as a read-only memory (ROM) 12, a random access memory (RAM) 13, etc., wherein the memory stores a computer program that can be executed by at least one processor, and the processor 11 can perform various appropriate actions and processes according to the computer program stored in the read-only memory (ROM) 12 or the computer program loaded from the storage unit 18 to the random access memory (RAM) 13. In the RAM 13, various programs and data required for the operation of the electronic device 10 can also be stored. The processor 11, the ROM 12, and the RAM 13 are connected to each other through a bus 14. An input / output (I / O) interface 15 is also connected to the bus 14.

[0142] A number of components in the electronic device 10 are connected to the I / O interface 15, including: an input unit 16, such as a keyboard, a mouse, etc.; an output unit 17, such as various types of displays, speakers, etc.; a storage unit 18, such as a disk, an optical disk, etc.; and a communication unit 19, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 19 allows the electronic device 10 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.

[0143] The processor 11 may be a variety of general and / or special processing components with processing and computing capabilities. Some examples of the processor 11 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, a digital signal processor (DSP), and any appropriate processor, controller, microcontroller, etc. The processor 11 executes the various methods and processes described above, such as the traffic simulation method.

[0144] In some embodiments, the traffic simulation method may be implemented as a computer program, which is tangibly contained in a computer-readable storage medium, such as a storage unit 18. In some embodiments, part or all of the computer program may be loaded and / or installed on the electronic device 10 via the ROM 12 and / or the communication unit 19. When the computer program is loaded into the RAM 13 and executed by the processor 11, one or more steps of the traffic simulation method described above may be performed. Alternatively, in other embodiments, the processor 11 may be configured to perform the traffic simulation method in any other appropriate manner (e.g., by means of firmware).

[0145] Various implementations of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various implementations can include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a special purpose or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.

[0146] Computer programs for implementing the methods of the present invention may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, so that when the computer program is executed by the processor, the functions / operations specified in the flow chart and / or block diagram are implemented. The computer program may be executed entirely on the machine, partially on the machine, partially on the machine and partially on a remote machine as a stand-alone software package, or entirely on a remote machine or server.

[0147] In the context of the present invention, a computer-readable storage medium may be a tangible medium that may contain or store a computer program for use by or in combination with an instruction execution system, device or equipment. A computer-readable storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices or equipment, or any suitable combination of the foregoing. Alternatively, a computer-readable storage medium may be a machine-readable signal medium. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0148] To provide interaction with a user, the systems and techniques described herein may be implemented on an electronic device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and a pointing device (e.g., a mouse or trackball) through which the user can provide input to the electronic device. Other types of devices may also be used to provide interaction with the user; for example, the feedback provided to the user may be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form (including acoustic input, voice input, or tactile input).

[0149] The systems and techniques described herein may be implemented in a computing system that includes backend components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes frontend components (e.g., a user computer with a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such backend components, middleware components, or frontend components. The components of the system may be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: a local area network (LAN), a wide area network (WAN), a blockchain network, and the Internet.

[0150] A computing system may include a client and a server. The client and the server are generally remote from each other and usually interact through a communication network. The client and server relationship is generated by computer programs running on the corresponding computers and having a client-server relationship with each other. The server may be a cloud server, also known as a cloud computing server or cloud host, which is a host product in the cloud computing service system to solve the defects of difficult management and weak business scalability in traditional physical hosts and VPS services.

[0151] In one embodiment, the embodiment of the present invention further includes a computer program product, the computer program product includes a computer program, and the computer program implements the traffic simulation method of any embodiment of the present invention when executed by a processor.

[0152] In the process of implementation, the computer program product can be written in one or more programming languages ​​or a combination thereof to perform the computer program code of the present invention, including object-oriented programming languages, such as Java, Smalltalk, C++, and conventional procedural programming languages, such as "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer can be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or can be connected to an external computer (for example, using an Internet service provider to connect through the Internet).

[0153] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps described in the present invention can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solution of the present invention can be achieved, and this document does not limit this.

[0154] The above specific implementations do not constitute a limitation on the protection scope of the present invention. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions can be made according to design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

Claims

1. A traffic simulation method, characterized in that: include: Obtain network simulation basic information of the traffic simulation network and a set of traffic to be simulated, and determine traffic attribute information of the traffic to be simulated in the set of traffic to be simulated according to the network simulation basic information; Dividing the to-be-simulated traffic set into at least two traffic subsets according to a preset simulation purpose and the traffic attribute information; The flow subsets are simulated in parallel to determine sub-simulation results, and the flow simulation result is determined according to the sub-simulation results.

2. The method according to claim 1, characterized in that The step of acquiring network simulation basic information of the traffic simulation network and a set of traffic to be simulated, and determining traffic attribute information of the traffic to be simulated in the set of traffic to be simulated according to the network simulation basic information includes: Determine network simulation basic information, wherein the network simulation basic information includes a network topology structure of a traffic simulation network, simulation device address information, and a traffic forwarding list; Extract the traffic to be simulated from the traffic set to be simulated, and determine the traffic size, traffic cycle, starting address, destination address and transmission protocol of the traffic to be simulated; Determine the simulation device through which the traffic to be simulated passes and the traffic transmission path of the traffic to be simulated according to the network topology, the simulation device address information and the traffic forwarding list; The flow attribute information of the flow to be simulated is determined according to the flow size, the flow period, the transmission protocol, the simulated device passed through, and the flow transmission path.

3. The method according to claim 2, characterized in that The step of determining the simulated device through which the traffic to be simulated passes and the traffic transmission path of the traffic to be simulated according to the network topology, the simulated device address information and the traffic forwarding list includes: Determine whether the traffic forwarding list contains a transmission path for the traffic to be simulated; If so, use the transmission path as the traffic transmission path corresponding to the traffic to be simulated; If it does not exist, determine the reachable path from the start address to the target address of the traffic to be transmitted according to the network topology, the start address and the target address, sort the reachable paths in order from short to long, and determine the shortest reachable path among the reachable paths that meet the preset path conditions as the traffic transmission path of the traffic to be simulated; The simulation device through which each flow to be simulated passes is determined according to the network topology, the simulation device address information and the flow transmission path.

4. The method according to claim 1, characterized in that: The dividing the to-be-simulated traffic set into at least two traffic subsets according to the preset simulation purpose and the traffic attribute information includes: Determine a preset simulation purpose, and determine the traffic segmentation characteristics according to the preset simulation purpose; wherein the preset simulation purpose includes at least one of the following: link bandwidth load verification, message delay verification, device processing performance verification, and protocol class verification; Extracting traffic attribute information associated with the traffic segmentation feature, and determining traffic attribute information having the same traffic segmentation feature; The traffic attribute information with the same traffic segmentation characteristics is stored in the same traffic subset.

5. The method according to claim 4, characterized in that The step of determining a preset simulation purpose and determining a traffic segmentation feature according to the preset simulation purpose includes: When it is determined that the preset simulation purpose is link bandwidth load verification, determining the traffic segmentation feature is traffic cycle synchronization; When it is determined that the preset simulation purpose is message delay verification, determining that the traffic segmentation feature is the same traffic transmission path; When it is determined that the preset simulation purpose is to verify the processing performance of the device, the traffic segmentation feature is determined to pass through the same simulation device; When it is determined that the preset simulation purpose is protocol type verification, the traffic segmentation feature is determined to be the same transmission protocol.

6. The method according to claim 4, characterized in that After storing the traffic attribute information having the same traffic segmentation feature into the same traffic subset, the method further includes: Determine the number of flows to be simulated in each of the flow subsets as a first number, and determine the number of flows to be simulated in the flow set to be simulated as a second number; A ratio of the first number to the second number is determined, and when it is determined that the ratio is greater than a preset ratio, a flow subset corresponding to the ratio greater than the preset ratio is divided into at least two flow subsets.

7. The method according to claim 1, characterized in that The step of simulating each of the traffic subsets in parallel to determine a sub-simulation result, and determining a traffic simulation result according to the sub-simulation results, comprises: Determine the time-sensitive network configuration information of each of the traffic subsets according to the traffic attribute information of the traffic to be simulated in the traffic subsets; wherein the time-sensitive network configuration information includes at least one of the following: queuing and forwarding configuration based on time-aware shaping, clock-independent configuration based on quality of service awareness, credit-based shaper configuration, and quarter-cycle frequency hopping configuration; Using the traffic subset and the time-sensitive network configuration information corresponding to the traffic subset as subset simulation parameters; The simulation parameters of each subset are simulated in parallel to obtain a sub-simulation result corresponding to each subset simulation parameter, and the sub-simulation results are summarized as the traffic simulation result.

8. A flow simulation device, characterized in that: include: The attribute information determination module is used to obtain network simulation basic information of the traffic simulation network and a set of traffic to be simulated, and determine the traffic attribute information of the traffic to be simulated in the set of traffic to be simulated according to the network simulation basic information; A subset division module, used for dividing the to-be-simulated traffic set into at least two traffic subsets according to a preset simulation purpose and the traffic attribute information; The simulation result determination module is used to perform parallel simulation on each of the flow subsets to determine a sub-simulation result, and determine a flow simulation result according to the sub-simulation results.

9. An electronic device, characterized in that: The electronic device comprises: at least one processor; and a memory communicatively connected to the at least one processor; wherein, The memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor so that the at least one processor can execute the traffic simulation method according to any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a processor to implement the traffic simulation method according to any one of claims 1 to 7 when executed.

11. A computer program product, characterized in that The computer program product comprises a computer program, which, when executed by a processor, implements the traffic simulation method according to any one of claims 1 to 7.

Citation Information

Cited By

  • Network interface card testing method and device

    CN121000648A