Implementation method for simulating packet sending intelligent detection on network equipment
By configuring the detection message template in the network device, generating and injecting the detection message, and combining the ACL rules to process the forwarding results of the detection message, it realizes the rapid location and analysis of the packet loss failure of the message forwarding in the network device, and solves the problem of the current There are problems with low detection efficiency in the technology, which improves the stability of the network environment.
Patent Information
- Application Number
- CN202411619368.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-13
- Publication Date
- 2025-02-18
AI Technical Summary
In the prior art, when forwarding packet loss fault location in network equipment, it relies on experienced maintenance engineers to perform manual analysis, resulting in low detection efficiency, especially when it is necessary to quickly restore services.
By obtaining message data, configuring a detection message template, generating a detection message, and sending a detection message through injection. According to the packet characteristics, the ACL rules are sent by forwarding chips, the forwarding results of the detection packet are processed, the forwarding path, packet loss location and reason of the detection packet are analyzed, and the ACL rules are sent out in the outgoing direction of the service port to prevent the detection packet from being detected. Give way.
It realizes the rapid location and analysis of packet loss failures in network equipment, improves the efficiency of packet loss abnormality detection, avoids the time-consuming and labor-intensive problem of manual analysis, and ensures the stability of the network environment.
Smart Images

Figure CN119484348A_ABST
Abstract
Description
Technical Field
[0001] The present application belongs to the field of computer network technology, and specifically is a method for implementing intelligent detection of simulated packet sending on a network device. Background Art
[0002] Current network solutions are becoming more and more complex, and the requirements for intelligent operation and maintenance are becoming more and more urgent, including real-time information collection, full network visualization, capacity management, and AI network fault analysis. In a large network system, various types of network devices are included, from simple box devices to complex frame devices, from single-machine devices to multiple stacked devices, from local interface boards to remote interface boards, and from single devices to multiple virtual devices. The form, hardware structure, and connection methods of network devices are becoming more and more complex. In this network system, in the case of packet forwarding loss, how to quickly locate which node forwards the packet loss is a very big challenge.
[0003] To locate packet loss during forwarding, we must not only determine which device the message was lost on, but also which chip on which board of the device the message was lost on. The most important thing is to be able to track and view the processing flow of the specified message, so that when a fault occurs, we can know where on which chip the message was lost, so as to facilitate further fault location. The existing method mainly relies on experienced maintenance engineers to manually analyze and locate the message step by step, which is time-consuming and laborious. In particular, some sites need to quickly restore services, and the time window for technicians to locate the message is very small, resulting in low detection efficiency when message loss occurs. Therefore, the intelligent detection method for message forwarding of network devices still needs to be further improved. Summary of the invention
[0004] The present application aims to solve at least one of the technical problems existing in the prior art; to this end, the present application proposes an implementation method for simulated packet sending intelligent detection on a network device, which is used to solve the technical problem that the prior art often relies on experienced maintenance engineers to manually analyze and locate packet loss step by step, which is time-consuming and labor-intensive, resulting in low detection efficiency when packet loss occurs.
[0005] To achieve the above-mentioned purpose, the first aspect of the present application provides a method for implementing intelligent detection of simulated packet transmission on a network device, comprising:
[0006] S0: Acquire message data; the message data is data that needs to be detected;
[0007] S1: Configure the detection message template, generate the detection message according to the message data; send the detection message by injection;
[0008] S2: Send ACL rules to the forwarding chip based on the message characteristics;
[0009] S3: performing data processing according to the forwarding result of the detection message after passing through the forwarding chip;
[0010] S4: Each single-board CPU encapsulates the received data and sends it to the CPU of the main control board for processing; the main control CPU obtains the forwarding path, packet loss location and packet loss reason of the detection message based on the received data analysis;
[0011] S5: Send a discard ACL rule in the outbound direction of each service port to discard the detection message.
[0012] The present application configures a detection message template to generate a detection message according to the message data; sends the detection message by injection; issues ACL rules to the forwarding chip according to the message characteristics; processes the data according to the forwarding result of the detection message after passing through the forwarding chip; the CPU of each single board encapsulates the received data and sends it to the CPU of the main control board for processing; the main control CPU obtains the forwarding path, packet loss location and packet loss cause of the detection message based on the received data analysis; issues a discard ACL rule in the outbound direction of each service port to discard the detection message, simulates the message forwarding between devices, determines the status of the detection message in each forwarding chip, finds the fault point and cause of the message loss, and improves the efficiency of packet loss anomaly detection.
[0013] Further, the generating of the detection message according to the message data includes:
[0014] Obtain message data and detection message templates;
[0015] The content in the message data is matched with the content in the detection message template and then input into the detection message template to obtain the detection message.
[0016] Furthermore, the injection method encapsulates a layer of system header for the detection message and includes the inbound port information.
[0017] Furthermore, the sending of ACL rules to the forwarding chip according to the message characteristics includes:
[0018] The ACL rule that matches the detection message characteristics in the inbound and outbound directions of all forwarding chips is "If the detection message characteristics are matched, a copy of the message is sent to the single-board CPU";
[0019] ACL rules that match detection message features and discard marks are issued to all forwarding chips. The ACL rule is "If a detection message matching the message features is discarded, the discard reason is sent to the single board CPU."
[0020] Further, the data processing according to the forwarding result of the detection message after passing through the forwarding chip includes:
[0021] Obtaining a forwarding result of the detection message after it passes through the forwarding chip; the forwarding result includes forwarding and discarding;
[0022] When the forwarding result is forwarding, the forwarded detection message is copied to obtain a copy detection message, and the copy detection message is uploaded to the single board CPU;
[0023] When the forwarding result is discarded, the reason why the detection message is discarded is obtained and uploaded to the single board CPU together with the detection message.
[0024] Furthermore, the discard ACL rule is sent in the outbound direction of each service port, and the discard ACL rule is set to "discard the message if it matches the message feature of the detection message".
[0025] This application issues a discard ACL rule in the outbound direction of each service port to discard the detection message, prevent the detection message from leaking to the outside of the device and causing network chaos, and improve the stability of the network environment.
[0026] Compared with the prior art, the beneficial effects of this application are:
[0027] 1. This application configures a detection message template to generate a detection message according to message data; sends the detection message by injection; issues ACL rules to the forwarding chip according to the message characteristics; performs data processing according to the forwarding result of the detection message after passing through the forwarding chip; each single-board CPU encapsulates the received data and sends it to the CPU of the main control board for processing; the main control CPU obtains the forwarding path, packet loss location and packet loss cause of the detection message based on the received data analysis; issues a discard ACL rule in the outbound direction of each service port, discards the detection message, simulates message forwarding between devices, determines the status of the detection message in each forwarding chip, finds the fault point and cause of message loss, and improves the efficiency of packet loss anomaly detection.
[0028] 2. This application issues discard ACL rules in the outbound direction of each service port to discard the detection message, prevent the detection message from leaking to the outside of the device and causing network chaos, and improve the stability of the network environment. BRIEF DESCRIPTION OF THE DRAWINGS
[0029] 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.
[0030] Figure 1 This is a flow chart of a method for implementing intelligent detection of simulated packet sending on a network device of the present application. DETAILED DESCRIPTION
[0031] The technical solution of the present application will be described clearly and completely in conjunction with the embodiments below. 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 the present application.
[0032] See also Figure 1 The first aspect of the present application provides a method for implementing intelligent detection of simulated packet transmission on a network device, including:
[0033] S0: Get message data; message data is the data that needs to be detected;
[0034] S1: Configure the detection message template, generate the detection message according to the message data; send the detection message by injection;
[0035] S2: Send ACL rules to the forwarding chip based on the message characteristics;
[0036] S3: performing data processing according to the forwarding result of the detection message after passing through the forwarding chip;
[0037] S4: Each single-board CPU encapsulates the received data and sends it to the CPU of the main control board for processing; the main control CPU obtains the forwarding path, packet loss location and packet loss reason of the detection message based on the received data analysis;
[0038] S5: Send a discard ACL rule in the outbound direction of each service port to discard the detection message.
[0039] This embodiment configures a detection message template to generate a detection message according to the message data; sends the detection message by injection; issues ACL rules to the forwarding chip according to the message characteristics; processes the data according to the forwarding result of the detection message after passing through the forwarding chip; the CPU of each single board encapsulates the received data and sends it to the CPU of the main control board for processing; the main control CPU obtains the forwarding path, packet loss location and packet loss cause of the detection message based on the received data analysis; issues a discard ACL rule in the outbound direction of each service port to discard the detection message, simulates the message forwarding between devices, determines the status of the detection message in each forwarding chip, finds the fault point and cause of the message loss, and improves the efficiency of packet loss anomaly detection.
[0040] In this embodiment, generating a detection message according to the message data includes:
[0041] Obtain message data and detection message templates;
[0042] The content in the message data is matched with the content in the detection message template and then input into the detection message template to obtain the detection message; the detection message content is consistent with the message data content.
[0043] The injection method in this embodiment is to encapsulate a layer of system header for the detection message (such as the common Dune chip carrying the FTMH header or the XGS chip carrying the HG header) and include the input port information; through such processing, when the detection message is sent from the CPU to the forwarding chip, the forwarding chip will consider it as a message entering from the specified input port, and perform subsequent table lookup forwarding, thereby simulating the network device chip's forwarding processing process of the message.
[0044] In this embodiment, the ACL rules are issued to the forwarding chip according to the message characteristics, including:
[0045] The ACL rule that matches the detection message characteristics in the inbound and outbound directions of all forwarding chips is "If the detection message characteristics are matched, a copy of the message is sent to the single-board CPU";
[0046] ACL rules that match detection message features and discard marks are issued to all forwarding chips. The ACL rule is "if the detection message matching the message features is discarded, the discard reason is sent to the single board CPU"; the ACL rules issued in this embodiment are custom rules and can be defined according to actual conditions.
[0047] In this embodiment, data processing is performed according to the forwarding result of the detection message after passing through the forwarding chip, including:
[0048] The forwarding chip will match the ACL rules that match the detection message characteristics that were previously issued, and perform corresponding operations based on the forwarding results;
[0049] When the forwarding result is forwarding, the forwarded detection message is copied to obtain a copy detection message, and the copy detection message is uploaded to the single board CPU;
[0050] When the forwarding result is discarded, the reason why the detection message is discarded is obtained and uploaded to the single board CPU together with the detection message.
[0051] In this embodiment, a discard ACL rule is issued in the outbound direction of each service port, and the discard ACL rule is set to "discard the message if the message feature of the detection message is matched".
[0052] This embodiment discards the detection message by sending a discard ACL rule in the outbound direction of each service port, because the detection message is not a real network message, and if it is leaked outside the device, it may cause network chaos. Therefore, it is necessary to send a discard ACL rule up and down all external service ports to discard the detection message, thereby improving the stability of the network environment.
[0053] The working principle of the present application is as follows: by acquiring message data; configuring a detection message template, and generating a detection message according to the message data; sending the detection message by injection; issuing ACL rules to the forwarding chip according to the message characteristics; performing data processing according to the forwarding result of the detection message after passing through the forwarding chip; the CPU of each single board encapsulates the received data and sends it to the CPU of the main control board for processing; the main control CPU can analyze the forwarding path, packet loss location and packet loss cause of the detection message according to the received data; issuing a discard ACL rule in the outbound direction of each service port, discarding the detection message, simulating the message forwarding between devices, judging the status of the detection message in each forwarding chip, and finding the fault point and cause of the message loss, thereby improving the efficiency of packet loss anomaly detection, and avoiding the problem that the existing technology often relies on experienced maintenance engineers to manually analyze and locate the message loss step by step when detecting the message loss, which is time-consuming and labor-intensive, resulting in low detection efficiency when the message is lost.
[0054] The above embodiments are only used to illustrate the technical method of the present application and are not intended to limit it. Although the present application has been described in detail with reference to the preferred embodiments, a person of ordinary skill in the art should understand that the technical method of the present application may be modified or replaced by equivalents without departing from the spirit and scope of the technical method of the present application.
Claims
1. A method for implementing intelligent detection of simulated packet transmission on a network device, characterized in that: include: S0: Get message data; The message data is data that needs to be detected; S1: Configure the detection message template, generate the detection message according to the message data; send the detection message by injection; S2: Send ACL rules to the forwarding chip based on the message characteristics; S3: performing data processing according to the forwarding result of the detection message after passing through the forwarding chip; S4: Each single-board CPU encapsulates the received data and sends it to the CPU of the main control board for processing; the main control CPU obtains the forwarding path, packet loss location and packet loss reason of the detection message based on the received data analysis; S5: Send a discard ACL rule in the outbound direction of each service port to discard the detection message.
2. A method for implementing intelligent detection of simulated packet transmission on a network device according to claim 1, characterized in that: The step of generating a detection message according to the message data includes: The message data and the detection message template are obtained, and the content in the message data is matched with the content in the detection message template and then input into the detection message template to obtain the detection message.
3. The method for implementing intelligent detection of simulated packet transmission on a network device according to claim 1, characterized in that: The injection method encapsulates a layer of system header for the detection message and includes the ingress port information.
4. The method for implementing intelligent detection of simulated packet transmission on a network device according to claim 1, characterized in that: The sending of ACL rules to the forwarding chip according to the message characteristics includes: The ACL rule that matches the detection message characteristics in the inbound and outbound directions of all forwarding chips is as follows: if the detection message characteristics are matched, a copy of the message is sent to the single-board CPU; ACL rules that match detection message features and discard marks are issued to all forwarding chips. The ACL rule is: if a detection message matching the message features is discarded, the discard reason is sent to the board CPU.
5. The method for implementing intelligent detection of simulated packet transmission on a network device according to claim 1, characterized in that: The data processing according to the forwarding result of the detection message after passing through the forwarding chip includes: Obtaining a forwarding result of the detection message after it passes through the forwarding chip; the forwarding result includes forwarding and discarding; When the forwarding result is forwarding, the forwarded detection message is copied to obtain a copy detection message, and the copy detection message is uploaded to the single board CPU; When the forwarding result is discarded, the reason why the detection message is discarded is obtained and uploaded to the single board CPU together with the detection message.
6. The method for implementing intelligent detection of simulated packet transmission on a network device according to claim 1, characterized in that: The discard ACL rule is sent in the outgoing direction of each service port, and the discard ACL rule is set to: discard the message if the message feature of the detection message is matched.