A time delay measurement method and related device

Through the data interaction between the kernel module and the forwarding server, low-cost and high-efficiency delay measurement is achieved, the problems of low and high cost of delay measurement in the existing technology are solved, and the high requirements for delay accuracy in 5G network technology are met.

CN116192694BActive Publication Date: 2025-03-07CHINA INTERNET NETWORK INFORMATION CENTER
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202310207216.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-03-03
Publication Date
2025-03-07
Estimated Expiration
2043-03-03

AI Technical Summary

Technical Problem

The prior art has problems of inefficiency and high measurement cost in delay measurement, especially in 5G network technology, the need to improve latency accuracy increases the requirements for network equipment and program processing delays.

Method used

Through data interaction between the kernel module and the forwarding server, the target test message is sent and the reception time is determined to calculate the forwarding delay. This method does not require additional hardware configuration, has low measurement costs and improves time-delay measurement efficiency.

Benefits of technology

It realizes low-cost and high-efficiency delay measurement, avoids frequent data copying and system call problems caused by user-state operation, and meets the high requirements for delay accuracy in 5G network technology.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116192694B_ABST
    Figure CN116192694B_ABST
Patent Text Reader

Abstract

The present application discloses a delay measurement method and related devices. When measuring the forwarding delay, a target test message is sent to a forwarding server through a kernel module, and then the target test message is forwarded to the kernel module through the forwarding server. Since the target test message includes the sending time of the kernel module sending the target test message, the receiving time of the target test message can be determined by the kernel module, and then the forwarding delay is determined according to the receiving time and the sending time. Based on this, the forwarding delay measurement can be completed through the data interaction between the kernel module and the forwarding server, without the need to configure additional hardware equipment, and the measurement cost is low. At the same time, compared with the delay measurement method in which the evaluation software runs in the user state in the related art, since the kernel module runs in the kernel state and is used for the measurement of the forwarding delay, it can avoid the problems of frequent data copying and system calls caused by running in the user state, thereby improving the delay measurement efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of data processing technology, and in particular to a delay measurement method and related devices. Background Art

[0002] Latency refers to the total transmission time of a data frame from the source to the destination, which can include the processing time of the data frame by the network node and the propagation time of the data frame in the transmission medium. The data frame can be a message, etc., and the network node can refer to the relevant network equipment and programs that process the data frame, such as the DNS forwarding server.

[0003] With the rapid development of network technology, the accuracy of delay has been improved, especially in 5G network technology, the accuracy of delay has entered the sub-millisecond era, and the delay has been shortened compared with 4G network technology. Correspondingly, the requirements for processing delay of network equipment and programs are higher. In practical applications, accurate delay measurement is of great significance for delay accuracy.

[0004] In the related art, delay measurement is usually completed using evaluation software or hardware equipment such as packet generators. However, the measurement method using evaluation software has measurement bottlenecks that make the delay measurement efficiency low, and the measurement using packet generators requires the configuration of hardware equipment, which has high measurement costs. Summary of the invention

[0005] In order to solve the above technical problems, the present application provides a delay measurement method and related devices, which can complete the forwarding delay measurement through data interaction between the kernel module and the forwarding server. The measurement cost is low and the delay measurement efficiency can be improved.

[0006] The embodiments of the present application disclose the following technical solutions:

[0007] On the one hand, an embodiment of the present application provides a delay measurement method, characterized in that the method includes:

[0008] Sending a target test message to a forwarding server through a kernel module; the target test message includes a sending time when the kernel module sends the target test message, and the kernel module runs in a kernel state;

[0009] Forwarding the target test message to the kernel module through the forwarding server;

[0010] Determining, by means of the kernel module, a receiving time of receiving the target test message;

[0011] A forwarding delay is determined by the kernel module according to the receiving time and the sending time.

[0012] On the other hand, an embodiment of the present application provides a delay measurement device, characterized in that the device includes a sending unit, a forwarding unit and a determining unit:

[0013] The sending unit is used to send a target test message to the forwarding server through the kernel module; the target test message includes the sending time of the target test message sent by the kernel module, and the kernel module runs in the kernel state;

[0014] The forwarding unit is used to forward the target test message to the kernel module through the forwarding server;

[0015] The determining unit is used to determine the receiving time of the target test message through the kernel module;

[0016] The determining unit is further configured to determine a forwarding delay through the kernel module according to the receiving time and the sending time.

[0017] In another aspect, an embodiment of the present application provides a computer device, the computer device comprising a processor and a memory:

[0018] The memory is used to store program code and transmit the program code to the processor;

[0019] The processor is used to execute the delay measurement method described in the above aspects according to the instructions in the program code.

[0020] On the other hand, an embodiment of the present application provides a computer-readable storage medium, wherein the computer-readable storage medium is used to store a computer program, and the computer program is used to execute the delay measurement method described in the above aspects.

[0021] It can be seen from the above technical solution that when measuring the forwarding delay, the target test message is sent to the forwarding server through the kernel module, and then the target test message is forwarded to the kernel module through the forwarding server. Since the target test message includes the sending time of the kernel module sending the target test message, the receiving time of the target test message can be determined by the kernel module, and then the forwarding delay is determined according to the receiving time and the sending time. Based on this, the forwarding delay measurement can be completed through the data interaction between the kernel module and the forwarding server, without the need for additional configuration of hardware equipment, and the measurement cost is low. At the same time, compared with the delay measurement method in which the evaluation software runs in the user state in the related art, since the kernel module runs in the kernel state and is used for the measurement of the forwarding delay, it can avoid the problems of frequent data copying and system calls caused by running in the user state, thereby improving the delay measurement efficiency. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0023] Figure 1 A flowchart of a delay measurement method provided in an embodiment of the present application;

[0024] Figure 2 A structural diagram of a test network topology diagram provided in an embodiment of the present application;

[0025] Figure 3 A forwarding delay measurement timing diagram provided in an embodiment of the present application;

[0026] Figure 4 A schematic diagram of a measurement result of a forwarding delay provided in an embodiment of the present application;

[0027] Figure 5 A structural diagram of a delay measurement device provided in an embodiment of the present application. DETAILED DESCRIPTION

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

[0029] The delay measurement method provided in the embodiment of the present application can be implemented by a computer device, which can be a terminal device or a server, wherein the server can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server providing cloud computing services. Terminal devices include but are not limited to mobile phones, computers, intelligent voice interaction devices, smart home appliances, vehicle-mounted terminals, etc. The terminal device and the server can be directly or indirectly connected via wired or wireless communication, and this application does not impose any restrictions on this.

[0030] The specific examples are as follows:

[0031] Figure 1 A flowchart of a delay measurement method provided in an embodiment of the present application is described by taking a server as the aforementioned computer device as an example. The method includes:

[0032] S101: Send a target test message to a forwarding server through a kernel module.

[0033] When measuring the forwarding delay, a target test message may be sent to the forwarding server through the kernel module. The target test message may include the sending time of the target test message sent by the kernel module. The kernel module runs in kernel state.

[0034] In practical applications, the sending time of the target test message can be determined by the kernel module. Specifically, the time when the target test message is to be sent can be obtained through the kernel module, and the time can be filled into the timestamp field of the target test message as the sending time. After the sending time is filled, the target test message can be sent to the forwarding server. For example, the kernel module can perform Base32 encoding on the time when the target test message is to be sent, and fill it into the timestamp field of the target test message after the encoding is completed. At the same time, after the filling is completed, the target test message can also be updated and verified to determine that the sending time has been successfully filled into the timestamp field. Usually, the timestamp field can be a reserved field to facilitate the kernel module to fill in the sending time.

[0035] It should be noted that this application does not impose any limitation on the type of the forwarding server. For example, the forwarding server may be a DNS forwarding server.

[0036] In order to meet the test requirements of high-pressure test traffic, in a possible implementation method, the target test message can be determined in the following way: first, the initial test message can be obtained through the kernel module, and the initial test message can include a test traffic amplification factor, and then the initial test message is amplified by the kernel module according to the test traffic amplification factor to obtain the target test message. Among them, the test traffic amplification factor can be used to instruct the kernel module to amplify the test traffic by a certain multiple to meet the test requirements of high-pressure test traffic. Based on this, the test traffic amplification factor can be set according to the actual test requirements, so as to determine the target test message that can meet the high-pressure test traffic. At the same time, there is no need to add other test hardware equipment, but the test traffic is amplified by the kernel space, which can break through the performance bottleneck of the test software in the relevant technology and save the test cost.

[0037] In actual applications, the kernel module can clone the initial test message according to the test traffic magnification factor, so as to achieve the purpose of amplifying the initial test message and obtain the target test message. In specific implementation, the eBPF kernel module can be used to capture the initial test message. When the test traffic magnification factor is determined to be M times, the initial test message can be cloned by cyclically calling the bpf_clone_redirect function, and cloned a total of (M-1) times, so that the target test message is amplified M times compared to the initial test message to meet the test requirements of high-pressure test traffic. It can be seen that the application module can multiply the test traffic of the initial test message received each time by the test traffic magnification factor to obtain the actual test traffic sent to the forwarding server, that is, the test traffic of the target test message, thereby meeting the test requirements of high-pressure test traffic.

[0038] In a possible implementation, the specific implementation of obtaining the initial test message through the kernel module may include: first, the initial test message can be constructed through the application module according to the query message format corresponding to the forwarding server, and then the initial test message is obtained from the application module through the kernel module. Among them, the application module and the kernel module can jointly constitute a test machine for forwarding delay measurement, the kernel module runs in the kernel state, and is used for measuring the forwarding delay, and the application module can run in the user state to construct the initial test message. Based on this, the measurement part of the forwarding delay can be responsible for the kernel module running in the kernel state, while the construction of the initial test message is still constructed by the application module running in the user state, which can avoid the problems of frequent data copying and system calls caused by running in the user state, thereby improving the delay measurement efficiency. Usually, when constructing the initial test message, the RFC specification can be used to encode the message information so that it can be compatible with various forwarding servers.

[0039] In actual applications, the test traffic amplification factor can be determined by the application module. Specifically, the test traffic amplification factor can be Base32 encoded by the application module according to the test requirements, and after the encoding is completed, it is filled into the amplification factor field of the initial test message. After the filling is completed, the initial test message containing the test traffic amplification factor can be obtained. In actual measurement, the initial test message can be sent to the kernel module at a fixed frequency through the application module, so that the kernel module can measure the forwarding delay at a fixed frequency.

[0040] S102: Forward the target test message to the kernel module through the forwarding server.

[0041] After the forwarding server receives the target test message sent by the kernel module, the target test message may be forwarded to the kernel module via the forwarding server, so that the kernel module can determine the forwarding delay.

[0042] In actual applications, the target test message can be parsed through the forwarding server to obtain the test flow identifier of the target test message, wherein the test flow identifier is used to reflect the test type of the target test message, etc., and can be matched with the forwarding rule of the forwarding server, so that the forwarding server can determine which module to forward the target test message to. Furthermore, the target test message can be forwarded to the kernel module through the forwarding server according to the test flow identifier and the forwarding rule corresponding to the forwarding server.

[0043] Usually, the target test message can be parsed to identify the suffix field of the target test message, thereby determining the test traffic identifier. In actual applications, the suffix fields of the initial test message and the target test message are the same, and are both determined when the application module constructs the initial test message.

[0044] S103: Determine the receiving time of the target test message through the kernel module.

[0045] S104: Determine the forwarding delay through the kernel module according to the receiving time and the sending time.

[0046] When the kernel module receives the target test message, the kernel module can determine the receiving time of the target test message. Further, the kernel module can determine the forwarding delay according to the receiving time and the sending time. Based on this, the kernel module can be used to complete the measurement of the forwarding delay.

[0047] In a possible implementation, the kernel module can determine the difference between the receiving time and the sending time as the forwarding delay, based on which the forwarding delay is measured. In practical applications, the kernel module can obtain the sending time from the timestamp field of the target test message to facilitate the determination of the forwarding delay.

[0048] It should be noted that, in actual applications, it is usually module A that sends a message to forwarding server B, and then forwarding server B forwards the message to module C. Correspondingly, the forwarding delay is the time difference between the sending time of the message sent by module A and the receiving time of the message received by module C. In the present application, by configuring the forwarding rules of the forwarding server and the test traffic identifier of the target test message, the target test message and the receiving test message are both sent by the aforementioned kernel module. In other words, based on the present application, module A and module C are the same, which can simplify the measurement process of the forwarding delay.

[0049] It can be seen that the forwarding delay is determined by the kernel module, and the kernel module runs in the kernel state. In order to facilitate the measurement engineer to view the measurement results of the forwarding delay, in a possible implementation, the forwarding delay can also be stored in the shared memory through the kernel module. Among them, the shared memory can be used to store the forwarding delay, and the application module can access the shared memory, so that the measurement project can access the shared memory through the application module to view the measurement results. After completing the storage of the forwarding delay, the target test message can be deleted through the kernel module, thereby releasing the corresponding computer resources, etc., which is conducive to the next forwarding delay measurement.

[0050] In actual applications, when a measurement engineer wants to view the measurement results, he can initiate a delay acquisition request through the application module, and then respond to the delay acquisition request to obtain the forwarding delay from the shared memory through the application module. Among them, the application module runs in user mode, based on which, it is convenient for the measurement engineer to view the measurement results. Since the measurement of the forwarding delay can be performed at a fixed frequency, therefore. The forwarding delay can also be stored through the target file in the application module, and the target file can be used to store the forwarding delay. Based on this, the target file can be used to store multiple forwarding delays measured at a fixed frequency, which is conducive to the measurement engineer to view multiple forwarding delays at one time.

[0051] It can be seen from the above technical solution that when measuring the forwarding delay, the target test message is sent to the forwarding server through the kernel module, and then the target test message is forwarded to the kernel module through the forwarding server. Since the target test message includes the sending time of the kernel module sending the target test message, the receiving time of the target test message can be determined by the kernel module, and then the forwarding delay is determined according to the receiving time and the sending time. Based on this, the forwarding delay measurement can be completed through the data interaction between the kernel module and the forwarding server, without the need for additional configuration of hardware equipment, and the measurement cost is low. At the same time, compared with the delay measurement method in which the evaluation software runs in the user state in the related art, since the kernel module runs in the kernel state and is used for the measurement of the forwarding delay, it can avoid the problems of frequent data copying and system calls caused by running in the user state, thereby improving the delay measurement efficiency.

[0052] For ease of understanding, the present application embodiment takes the DNS forwarding server as an example and provides the following Figure 2 A test network topology diagram shown includes a test machine and a DNS forwarding server, wherein the test machine may include an application module and a kernel module, specifically:

[0053] The application module, running in user mode, can construct an initial test message according to the DNS forwarding server query message format. For example, the format of the initial test message can be <prefix>.<test traffic magnification factor>.<timestamp>.<suffix>. Among them, the <timestamp> field can be a reserved field, which is convenient for the kernel module to fill in the sending time of the target test message. Corresponding to the DNS forwarding server, the <suffix> can be text. For example, the initial test message can be *.M.{000…000}.test, where M is the test traffic magnification factor. In actual applications, the application module can send the initial test message to the kernel module at a fixed frequency, see step ①.

[0054] The kernel module, running in kernel state, can amplify the initial test message according to the test traffic amplification factor to obtain the target test message and fill the sending time into the <timestamp> field. In actual applications, the kernel module can also send the target test message to the DNS forwarding server at a fixed frequency, see step ②.

[0055] The DNS forwarding server can forward the target test message to the kernel module according to the <suffix> text and its corresponding forwarding rules, see step ③.

[0056] Furthermore, when receiving the target test message, the kernel module can obtain the Base code of the sending time from the target test message, decode it to determine the sending time T1, and simultaneously obtain the receiving time T2 of the receiving target test message. Further, the forwarding delay T=T2-T1 can be calculated.

[0057] In actual application work, the kernel module can store the forwarding delay T in the shared memory, and the application module can obtain the forwarding delay from the shared memory. That is to say, after determining the forwarding delay, the measurement result of the forwarding delay can be viewed through data interaction between the application module and the kernel module, see step ④.

[0058] Correspondingly, the present application embodiment also provides Figure 3 The forwarding delay measurement timing diagram shown is as follows:

[0059] Step 1: The initial test message may be constructed by the application module, the format of which may be <prefix>.<test traffic magnification factor>.<timestamp>.<suffix>, and the initial test message may be sent to the kernel module;

[0060] Step 2: Message cloning can be performed through the kernel module to amplify the test traffic amplification multiple of the initial test message to obtain the target test message;

[0061] Step 3: The Base32 encoding of the sending time can be filled into the <timestamp> field by the application module;

[0062] Step 4: After filling the sending time, the target test message can be obtained through the application module update verification, and the target test message can be sent to the DNS forwarding server;

[0063] Step 5: The target test message can be forwarded to the kernel module through the DNS forwarding server response;

[0064] Step 6: The forwarding delay can be determined by the kernel module and stored in the shared memory;

[0065] Step 7: The forwarding delay can be obtained from the shared memory through the application module.

[0066] In actual applications, in order to test the delay measurement effect provided by the embodiment of the present application, five different test traffic groups, 0Gbps, 205Gbps, 5G, 7.5G and 10G, were constructed, and the forwarding delay was measured using two different byte test messages of 128Bytes and 256Bytes. The measurement results can be found in Figure 4 As shown, it can be seen that with the increase of test traffic, the forwarding delay increases, but the delay measurement method provided in the embodiment of the present application can support the forwarding delay measurement requirements of high-pressure test traffic. At the same time, the measurement accuracy of the forwarding delay can reach the microsecond level, which can better meet the high requirements for forwarding delay measurement under the development of network technology.

[0067] It can be understood that it basically corresponds to the method embodiment, so the relevant parts can refer to the partial description of the method embodiment.

[0068] Figure 5 A structural diagram of a delay measurement device provided in an embodiment of the present application, the device includes a sending unit 501, a forwarding unit 502 and a determining unit 503:

[0069] The sending unit 501 is used to send a target test message to the forwarding server through the kernel module; the target test message includes the sending time of the target test message sent by the kernel module, and the kernel module runs in the kernel state;

[0070] The forwarding unit 502 is used to forward the target test message to the kernel module through the forwarding server;

[0071] The determining unit 503 is used to determine the receiving time of the target test message through the kernel module;

[0072] The determining unit 503 is further configured to determine a forwarding delay through the kernel module according to the receiving time and the sending time.

[0073] In a possible implementation, the target test message is determined in the following manner:

[0074] Obtaining an initial test message through the kernel module; the initial test message includes a test flow magnification factor;

[0075] According to the test traffic amplification factor, the initial test message is amplified by the kernel module to obtain the target test message.

[0076] In a possible implementation, the device further includes a construction unit and an acquisition unit:

[0077] The construction unit is used to construct the initial test message through the application module according to the query message format corresponding to the forwarding server;

[0078] The acquisition unit is used to acquire the initial test message from the application module through the kernel module.

[0079] In a possible implementation manner, the forwarding unit is further configured to:

[0080] Parsing the target test message through the forwarding server to obtain a test flow identifier of the target test message;

[0081] According to the test traffic identifier and the forwarding rule corresponding to the forwarding server, the target test message is forwarded to the kernel module through the forwarding server.

[0082] In a possible implementation, the device further includes a storage unit and a deletion unit:

[0083] The storage unit is used to store the forwarding delay in a shared memory through the kernel module;

[0084] The deleting unit is used to delete the target test message through the kernel module after completing the storage of the forwarding delay.

[0085] In a possible implementation, the acquisition unit is further configured to, in response to a delay acquisition request, acquire the forwarding delay from the shared memory through an application module; the application module runs in a user state;

[0086] The storage unit is further used to store the forwarding delay via a target file in the application module.

[0087] In a possible implementation manner, the determining unit is further configured to:

[0088] The kernel module determines the difference between the receiving time and the sending time as the forwarding delay.

[0089] It can be seen from the above technical solution that when measuring the forwarding delay, the target test message is sent to the forwarding server through the kernel module, and then the target test message is forwarded to the kernel module through the forwarding server. Since the target test message includes the sending time of the kernel module sending the target test message, the receiving time of the target test message can be determined by the kernel module, and then the forwarding delay is determined according to the receiving time and the sending time. Based on this, the forwarding delay measurement can be completed through the data interaction between the kernel module and the forwarding server, without the need for additional configuration of hardware equipment, and the measurement cost is low. At the same time, compared with the delay measurement method in which the evaluation software runs in the user state in the related art, since the kernel module runs in the kernel state and is used for the measurement of the forwarding delay, it can avoid the problems of frequent data copying and system calls caused by running in the user state, thereby improving the delay measurement efficiency.

[0090] In another aspect, an embodiment of the present application provides a computer device, the computer device comprising a processor and a memory:

[0091] The memory is used to store program code and transmit the program code to the processor;

[0092] The processor is used to execute the delay measurement method provided in the above embodiment according to the instructions in the program code.

[0093] The computer device may include a terminal device or a server, and the aforementioned delay measurement device may be configured in the computer device.

[0094] On the other hand, an embodiment of the present application further provides a storage medium, wherein the storage medium is used to store a computer program, and the computer program is used to execute the delay measurement method provided in the above embodiment.

[0095] A person of ordinary skill in the art can understand that all or part of the steps of implementing the above method embodiment can be completed by hardware related to program instructions, and the aforementioned program can be stored in a computer-readable storage medium. When the program is executed, it executes the steps of the above method embodiment; and the aforementioned storage medium can be at least one of the following media: read-only memory (English: Read-only Memory, abbreviated: ROM), RAM, magnetic disk or optical disk, etc. Various media that can store program codes.

[0096] For the device embodiment, since it basically corresponds to the method embodiment, the relevant parts can refer to the partial description of the method embodiment. The device embodiment described above is only schematic, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without paying creative work.

[0097] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.

[0098] The above is a detailed introduction to a delay measurement method and related devices provided by the embodiment of the present application. The principle and implementation method of the present application are described in detail using specific examples. The description of the above embodiments is only used to help understand the method of the present application. At the same time, for those skilled in the art, according to the method of the present application, there will be changes in the specific implementation method and application scope.

[0099] In summary, the content of this specification should not be understood as limiting the present application, and any changes or substitutions that can be easily thought of by a person skilled in the art within the technical scope disclosed in this application should be included in the protection scope of this application. Moreover, based on the implementations provided in the above aspects, this application can also be further combined to provide more implementations.

Claims

1. A delay measurement method, characterized in that: The method comprises: Sending a target test message to a forwarding server through a kernel module; the target test message includes a sending time when the kernel module sends the target test message, and the kernel module runs in a kernel state; Forwarding the target test message to the kernel module through the forwarding server; Determining, by means of the kernel module, a receiving time of receiving the target test message; Determining a forwarding delay through the kernel module according to the receiving time and the sending time; The target test message is determined in the following manner: According to the query message format corresponding to the forwarding server, an initial test message is constructed through an application module; the application module runs in user mode, and the initial test message includes a test traffic amplification factor, and the test traffic amplification factor is used to instruct the kernel module to amplify the test traffic corresponding to the initial test message by a certain multiple; Acquire the initial test message from the application module through the kernel module; According to the test traffic amplification multiple, the initial test message is amplified by the kernel module to obtain the target test message; the test traffic corresponding to the target test message meets the test requirements of high-pressure test traffic.

2. The method according to claim 1, characterized in that The forwarding of the target test message to the kernel module through the forwarding server includes: Parsing the target test message through the forwarding server to obtain a test flow identifier of the target test message; According to the test traffic identifier and the forwarding rule corresponding to the forwarding server, the target test message is forwarded to the kernel module through the forwarding server.

3. The method according to claim 1, characterized in that The method further comprises: Storing the forwarding delay in a shared memory through the kernel module; After completing the storage of the forwarding delay, the target test message is deleted through the kernel module.

4. The method according to claim 3, characterized in that The method further comprises: In response to a delay acquisition request, acquiring the forwarding delay from the shared memory through the application module; The forwarding delay is stored via a target file in the application module.

5. The method according to any one of claims 1 to 4, characterized in that: Determining the forwarding delay by the kernel module according to the receiving time and the sending time includes: The kernel module determines the difference between the receiving time and the sending time as the forwarding delay.

6. A delay measurement device, characterized in that: The device includes a sending unit, a forwarding unit, a determining unit, a building unit and an acquiring unit: The sending unit is used to send a target test message to the forwarding server through the kernel module; the target test message includes the sending time of the target test message sent by the kernel module, and the kernel module runs in the kernel state; The forwarding unit is used to forward the target test message to the kernel module through the forwarding server; The determining unit is used to determine the receiving time of the target test message through the kernel module; The determining unit is further configured to determine a forwarding delay through the kernel module according to the receiving time and the sending time; The construction unit is used to construct an initial test message through an application module according to the query message format corresponding to the forwarding server; The application module runs in user mode, the initial test message includes a test traffic amplification factor, and the test traffic amplification factor is used to instruct the kernel module to amplify the test traffic corresponding to the initial test message by a certain factor; The acquisition unit is used to acquire the initial test message from the application module through the kernel module; The determination unit is further used to amplify the initial test message through the kernel module according to the test traffic amplification factor to obtain the target test message; the test traffic corresponding to the target test message meets the test requirements of high-pressure test traffic.

7. A computer device, characterized in that: The computer device comprises a processor and a memory: The memory is used to store program code and transmit the program code to the processor; The processor is configured to execute the method according to any one of claims 1 to 5 according to the instructions in the program code.

8. A computer-readable storage medium, characterized in that: The computer-readable storage medium is used to store a computer program, and the computer program is used to execute the method according to any one of claims 1 to 5.

Citation Information

Patent Citations

  • Transmission delay probing method, device and system

    CN108737207A