CN113783789B - Message speed limiting method and device - Google Patents

Message speed limiting method and device Download PDF

Info

Publication number
CN113783789B
CN113783789B CN202111148271.8A CN202111148271A CN113783789B CN 113783789 B CN113783789 B CN 113783789B CN 202111148271 A CN202111148271 A CN 202111148271A CN 113783789 B CN113783789 B CN 113783789B
Authority
CN
China
Prior art keywords
speed limit
data message
output interface
index
limit value
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202111148271.8A
Other languages
Chinese (zh)
Other versions
CN113783789A (en
Inventor
马申骁
孙磊
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
New H3C Security Technologies Co Ltd
Original Assignee
New H3C Security Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by New H3C Security Technologies Co Ltd filed Critical New H3C Security Technologies Co Ltd
Priority to CN202111148271.8A priority Critical patent/CN113783789B/en
Publication of CN113783789A publication Critical patent/CN113783789A/en
Application granted granted Critical
Publication of CN113783789B publication Critical patent/CN113783789B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/70Admission control; Resource allocation
    • H04L47/82Miscellaneous aspects
    • H04L47/825Involving tunnels, e.g. MPLS
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/10Flow control; Congestion control
    • H04L47/33Flow control; Congestion control using forward notification
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L2212/00Encapsulation of packets
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/50Reducing energy consumption in communication networks in wire-line communication networks, e.g. low power modes or reduced link rate

Abstract

The application provides a message speed limiting method and a device, the method is applied to a main control board in network equipment and comprises the following steps: acquiring a speed limit index and a speed limit value of a forwarding chip where an outlet interface of a target SRv6 tunnel is located; the method comprises the steps that the method is issued to all line card boards in network equipment, so that when any line card board receives a first data message needing to be forwarded by using a target SRv6 tunnel, a speed limit index is added to the first data message to obtain a second data message, an output interface of the second data message is determined, and when the output interface is on the line card board, the SRv6 message packaged based on the first data message is subjected to speed limit processing and forwarded according to the speed limit value of a corresponding forwarding chip; and when the output interface is not on the line card board, sending the second data message to the corresponding line card board, so that the corresponding line card board performs speed limit processing on the SRv6 message packaged based on the first data message according to the related speed limit value and forwards the SRv6 message. The application can improve network experience.

Description

Message speed limiting method and device
Technical Field
The present application relates to the field of communications technologies, and in particular, to a message speed limiting method and apparatus.
Background
At present, when a network device forwards a data packet using a Segment Routing and Internet Protocol version six (SRv 6) tunnel, a relevant speed limit processing is not usually performed, which easily causes a network congestion problem and results in poor network experience.
Disclosure of Invention
In order to overcome the problems in the related art, the application provides a message speed limiting method and a message speed limiting device.
According to a first aspect of an embodiment of the present application, a method for limiting a packet speed is provided, where the method is applied to an active main control board in a network device, and the method includes:
acquiring a speed limit index and a speed limit value of a forwarding chip where an output interface of a target SRv6 tunnel is located;
the obtained speed limit index and the speed limit value are issued to all wire clamping plates in the network equipment, so that when any wire clamping plate in the network equipment receives a first data message which needs to be forwarded by using the target SRv6 tunnel, the speed limit index is added to the first data message to obtain a second data message, an output interface of the second data message is determined, and when the determined output interface is on the wire clamping plate, the SRv6 message packaged on the basis of the first data message obtained after the speed limit index in the second data message is deleted is forwarded after speed limit processing is carried out according to the speed limit value corresponding to a forwarding chip on which the determined output interface corresponding to the speed limit index is located; and when the determined output interface is not on the line card board, sending the second data message to the line card board where the determined output interface is located, and carrying out speed-limiting processing on the SRv6 message packaged by the first data message obtained by deleting the speed-limiting index in the second data message according to the speed-limiting value corresponding to the forwarding chip where the determined output interface corresponding to the speed-limiting index is located by the corresponding line card board.
According to a second aspect of the embodiments of the present application, a method for limiting a message speed is provided, where the method is applied to any line card board in a network device, and the method includes:
receiving a speed limit index and a speed limit value of a forwarding chip where an output interface of a target SRv6 tunnel is located, wherein the speed limit index and the speed limit value are obtained by a main control board in the network equipment;
when a first data message is received and the target SRv6 tunnel is needed to be used for forwarding the first data message, adding the speed limit index into the first data message to obtain a second data message, and determining an output interface of the second data message;
judging whether the determined outlet interface is on the cable clamping board or not;
when the judgment result is yes, according to the speed limit value corresponding to the forwarding chip where the determined outlet interface corresponding to the speed limit index is located, carrying out speed limit processing on the SRv6 message packaged based on the first data message obtained after deleting the speed limit index in the second data message, and then forwarding the SRv6 message;
and if not, sending the second data message to the line card board where the determined output interface is located, so that the corresponding line card board performs speed limit processing on the SRv6 message packaged by the first data message obtained after the speed limit index in the second data message is deleted according to the speed limit value corresponding to the forwarding chip where the determined output interface is located and corresponding to the speed limit index, and then forwards the SRv6 message.
According to a third aspect of the embodiments of the present application, there is provided a packet speed limiting device, where the device is applied to an active main control board in a network device, and the device includes:
the acquisition module is used for acquiring a speed limit index and a speed limit value of a forwarding chip where an output interface of the target SRv6 tunnel is located;
the issuing module is used for issuing the acquired speed limit index and the acquired speed limit value to all line card boards in the network equipment, so that when any line card board in the network equipment receives a first data message which needs to be forwarded by using the target SRv6 tunnel, the speed limit index is added into the first data message to obtain a second data message, an output interface of the second data message is determined, and when the determined output interface is on the line card board, the SRv6 message encapsulated based on the first data message obtained after the speed limit index in the second data message is deleted is subjected to speed limit processing and forwarded according to the speed limit value corresponding to a forwarding chip of the determined output interface corresponding to the speed limit index; and when the determined output interface is not on the line card board, sending the second data message to the line card board where the determined output interface is located, and forwarding the SRv6 message encapsulated on the basis of the first data message obtained by deleting the speed limit index in the second data message after carrying out speed limit processing on the speed limit value corresponding to the forwarding chip where the determined output interface is located and corresponding to the speed limit index by the corresponding line card board.
According to a fourth aspect of the embodiments of the present application, there is provided a packet speed limiting device, where the device is applied to any line card board in a network device, and the device includes:
a receiving module, configured to receive a speed limit index and a speed limit value of a forwarding chip where an output interface of a target segment route and an internet protocol sixth version SRv6 tunnel obtained by a main control board in the network device is located, where the forwarding chip is sent by the main control board;
the adding and determining module is used for adding the speed limit index into the first data message to obtain a second data message and determining an output interface of the second data message when the first data message is received and the target SRv6 tunnel is required to be used for forwarding the first data message;
the judging module is used for judging whether the determined outlet interface is on the cable clamping board or not;
the first speed limit module is used for carrying out speed limit processing on an SRv6 message packaged by the first data message obtained by deleting the speed limit index in the second data message according to the speed limit value corresponding to the forwarding chip on which the determined output interface corresponding to the speed limit index is positioned when the judgment result of the judgment module is yes;
and the second speed limit module is used for sending the second data message to the line card board where the determined output interface is located when the judgment result of the judgment module is negative, so that the corresponding line card board limits the speed of the SRv6 message packaged by the first data message obtained by deleting the speed limit index in the second data message according to the speed limit value corresponding to the forwarding chip where the determined output interface corresponding to the speed limit index is located and forwards the SRv6 message.
The technical scheme provided by the embodiment of the application can have the following beneficial effects:
in the embodiment of the present application, a message speed limit flow is added in the process of forwarding a data message using an SRv6 tunnel, and the specific flow is as follows:
firstly, a main control board in the network equipment acquires a speed limit index and a speed limit value of a forwarding chip where an output interface of a target SRv6 tunnel is located, and transmits the acquired speed limit index and speed limit value to all line card boards in the network equipment; then, when any line card board in the network equipment receives a first data message which needs to be forwarded by using a target SRv6 tunnel, adding a speed limit index into the first data message to obtain a second data message, determining an output interface of the second data message, and when the determined output interface is on the line card board, carrying out speed limit processing on the SRv6 message packaged based on the first data message obtained after deleting the speed limit index in the second data message according to a speed limit value corresponding to a forwarding chip on which the determined output interface is located and corresponding to the speed limit index and then forwarding the SRv6 message; and when the determined output interface is not on the line card board, sending the second data message to the line card board where the determined output interface is located, and carrying out speed limit processing on the SRv6 message packaged by the first data message obtained by deleting the speed limit index in the second data message according to the speed limit value corresponding to the forwarding chip where the determined output interface corresponding to the speed limit index is located by the corresponding line card board.
Therefore, through the message speed limiting process, the problem of network congestion can be avoided to a certain extent, and network experience is improved.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the application.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this application, illustrate embodiments consistent with the present application and together with the description, serve to explain the principles of the application.
Fig. 1 is a schematic flow diagram of a message speed limiting method according to an embodiment of the present application;
fig. 2 is a second schematic flowchart of a message speed limiting method according to an embodiment of the present application;
fig. 3 is a schematic structural diagram of a message speed limiting device according to an embodiment of the present application;
fig. 4 is a second schematic structural diagram of a message speed limiting device according to an embodiment of the present application;
fig. 5 is a schematic structural diagram of an electronic device according to an embodiment of the present application.
Detailed Description
Reference will now be made in detail to the exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, like numbers in different drawings represent the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present application. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the present application, as detailed in the appended claims.
The terminology used herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the application. As used in this application and the appended claims, the singular forms "a", "an", and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It should also be understood that the term "and/or" as used herein refers to and encompasses any and all possible combinations of one or more of the associated listed items.
It is to be understood that although the terms first, second, third, etc. may be used herein to describe various information, such information should not be limited to these terms. These terms are only used to distinguish one type of information from another. For example, first information may also be referred to as second information, and similarly, second information may also be referred to as first information, without departing from the scope of the present application. The word "if" as used herein may be interpreted as "at" \8230; "or" when 8230; \8230; "or" in response to a determination ", depending on the context.
Next, examples of the present application will be described in detail.
An embodiment of the present application provides a message speed limiting method, which is applied to an active main control board in a network device, and as shown in fig. 1, the method may include the following steps:
s11, acquiring a speed limit index and a speed limit value of a forwarding chip where an output interface of the target SRv6 tunnel is located.
S12, issuing the obtained speed limit index and the obtained speed limit value to all line card boards in the network equipment, so that when any line card board in the network equipment receives a first data message which needs to be forwarded by using a target SRv6 tunnel, the speed limit index is added into the first data message to obtain a second data message, an output interface of the second data message is determined, and when the determined output interface is on the line card board, the SRv6 message packaged on the basis of the first data message obtained after the speed limit index in the second data message is deleted is forwarded after speed limit processing is carried out on the SRv6 message according to the speed limit value corresponding to the determined output interface corresponding to the speed limit index and corresponding to a forwarding chip; and when the determined output interface is not on the line card board, sending the second data message to the line card board where the determined output interface is located, and carrying out speed limit processing on the SRv6 message packaged by the first data message obtained by deleting the speed limit index in the second data message according to the speed limit value corresponding to the forwarding chip where the determined output interface corresponding to the speed limit index is located by the corresponding line card board.
It should be noted that, for the line card board, when determining the outgoing interface of the second data message, if the outgoing interface of the target SRv6 tunnel is a physical port, it may be directly determined that the physical port is the outgoing interface of the second data message; if the outgoing interface of the target SRv6 tunnel is an aggregation port, it may be determined by a hash algorithm which member port of the aggregation port the outgoing interface of the second data packet is.
In addition, the specific encapsulation process of the cable card board encapsulating the first data message into the SRv6 message obtained after deleting the speed limit index in the second data message is the prior art, and detailed description is not provided herein.
Specifically, in step S11, the main master control board may obtain the speed limit index and the speed limit value of the forwarding chip on which the output interface corresponding to the target SRv6 tunnel is located in the following manner:
when an output interface of a target SRv6 tunnel is a physical port, acquiring a speed limit value corresponding to the physical port, determining the acquired speed limit value as the speed limit value of a forwarding chip where the physical port is located, and applying for a unique speed limit index for the forwarding chip where the physical port is located from a preset speed limit index pool;
when the output interface of the target SRv6 tunnel is an aggregation port, acquiring a speed limit value corresponding to the aggregation port, calculating the speed limit values of forwarding chips in which all member ports are located according to the bandwidth of the member ports belonging to the aggregation port on the forwarding chip in which all the member ports are located in the aggregation port, and applying for a unique speed limit index for the forwarding chips in which all the member ports are located in a preset speed limit index pool.
It should be noted that, in an example, the speed limit value of the forwarding chip where the output interface corresponding to the target SRv6 tunnel is located, acquired by the main control board, may be presented on a speed limit template, where different speed limit values are recorded on different speed limit templates, and the template IDs of the different speed limit templates are different. In this case, the speed limit value of the forwarding chip on which the output interface corresponding to the target SRv6 tunnel obtained by the main control board is located may be represented by a template Identifier (ID) of the speed limit template.
In addition, in the acquiring process, the main control board may specifically calculate the speed limit values of the forwarding chips where all the member ports are located in the following manner:
aiming at each forwarding chip in the forwarding chips where all the member ports are located, performing product operation on the sum of the bandwidths of the member ports belonging to the aggregation port on the forwarding chip and the speed limit value corresponding to the aggregation port to obtain a first operation result;
summing the bandwidths of the member ports belonging to the aggregation port on the forwarding chip where all the member ports are located to obtain a second operation result;
and carrying out quotient calculation on the first operation result and the second operation result to obtain the speed limit value of the forwarding chip.
For example, it is assumed that the network device includes a main master control board 11, a line card board 1, a line card board 2, and a line card board 3. An output interface of a certain SRv6 tunnel on the network equipment is assumed to be an aggregation port 4, and a corresponding speed limit value is A; the aggregation port 4 comprises 4 member ports, namely a member port 41, a member port 42, a member port 43 and a member port 44; assuming that the member port 41 and the member port 42 are both on the forwarding chip 21 on the cable card board 2 in the network device, the bandwidth of the member port 41 is B, and the bandwidth of the member port 42 is C; assuming that the member port 43 is on the forwarding chip 22 on the line card board 2 in the network device, the bandwidth of the member port 43 is D; assume that the member port 44 is on the forwarding chip 31 of the cable card board 3 in the network device, and the bandwidth of the member port 44 is E.
Then, the forwarding chips where the egress interfaces of the SRv6 tunnel are located are the forwarding chip 21, the forwarding chip 22 and the forwarding chip 31. The main control board 11 can calculate the speed limit value of the forwarding chip 21 as
Figure BDA0003286250950000071
/>
The main control board 11 can calculate the speed limit value of the forwarding chip 22 to be
Figure BDA0003286250950000072
The main control board 11 can calculate the speed limit value of the forwarding chip 31 as
Figure BDA0003286250950000073
It should be further noted that, in order to ensure that the network device can operate normally when the primary main control board fails, after the primary main control board obtains the speed-limiting index and the speed-limiting value of the forwarding chip on which the output interface of the target SRv6 tunnel is located, the obtained speed-limiting index and the obtained speed-limiting value of the forwarding chip on which the output interface of the target SRv6 tunnel is located may also be synchronized to the standby main control board in the network device, so as to be used when the primary main control board fails.
The embodiment of the application provides a message speed limiting method, which is applied to any cable card board in network equipment, and as shown in fig. 2, the method can comprise the following steps:
s21, receiving a speed limit index and a speed limit value of a forwarding chip where an output interface of a target SRv6 tunnel is located, which are obtained by a main control board in the network equipment and sent by the main control board.
S22, when the first data message is received and the target SRv6 tunnel is needed to be used for forwarding the first data message, adding the speed limit index into the first data message to obtain a second data message, and determining an output interface of the second data message;
s23, judging whether the determined outlet interface is on the cable clamping board; if the determination result is yes, step S24 is executed, and if the determination result is no, step S25 is executed.
And S24, according to the speed limit value corresponding to the determined forwarding chip where the output interface is located and corresponding to the speed limit index, carrying out speed limit processing on the SRv6 message packaged based on the first data message obtained after deleting the speed limit index in the second data message, and then forwarding the SRv6 message.
And S25, sending the second data message to the line card board where the determined output interface is located, so that the corresponding line card board performs speed limit processing on the SRv6 message packaged by the first data message obtained by deleting the speed limit index in the second data message according to the speed limit value corresponding to the forwarding chip where the determined output interface is located and corresponding to the speed limit index, and then forwards the SRv6 message.
It should be noted that, for the line card board, how to determine the outgoing interface of the second data message and how to encapsulate the first data message obtained after deleting the speed limit index in the second data message into an SRv6 message have been described when the master board side describes the message speed limit method, and details are not described here.
In addition, for the main master control board, how to obtain the speed limit index and the speed limit value of the forwarding chip where the output interface of the target SRv6 tunnel is located has also been described when describing the message speed limit method on the main master control board side, and details are not described here.
According to the technical scheme, in the embodiment of the application, a message speed-limiting flow is additionally arranged in the process of forwarding the data message by using the SRv6 tunnel, and the specific flow is as follows:
firstly, a main control board in the network equipment acquires a speed limit index and a speed limit value of a forwarding chip where an output interface of a target SRv6 tunnel is located, and transmits the acquired speed limit index and speed limit value to all line card boards in the network equipment; then, when any line card board in the network equipment receives a first data message which needs to be forwarded by using a target SRv6 tunnel, adding a speed limit index into the first data message to obtain a second data message, determining an output interface of the second data message, and when the determined output interface is on the line card board, carrying out speed limit processing on the SRv6 message packaged based on the first data message obtained after deleting the speed limit index in the second data message according to a speed limit value corresponding to a forwarding chip on which the determined output interface is located and corresponding to the speed limit index and then forwarding the SRv6 message; and when the determined output interface is not on the line card board, sending the second data message to the line card board where the determined output interface is located, and forwarding the SRv6 message encapsulated on the basis of the first data message obtained by deleting the speed limit index in the second data message after carrying out speed limit processing on the speed limit value corresponding to the forwarding chip where the determined output interface is located and corresponding to the speed limit index by the corresponding line card board.
Therefore, the problem of network congestion can be avoided to a certain extent through the message speed-limiting flow, and network experience is improved.
Based on the same inventive concept, the present application further provides a message speed limiting device, where the device is applied to an active main control board in a network device, and a schematic structural diagram of the device is shown in fig. 3, and the device specifically includes:
the acquiring module 31 is configured to acquire a speed limit index and a speed limit value of a forwarding chip where an egress interface of a target segment route and an internet protocol sixth version SRv6 tunnel are located;
the issuing module 32 is configured to issue the obtained speed limit index and the obtained speed limit value to all line card boards in the network device, so that when any line card board in the network device receives a first data message that needs to be forwarded using the target SRv6 tunnel, the speed limit index is added to the first data message to obtain a second data message, an output interface of the second data message is determined, and when the determined output interface is on the line card board, according to the speed limit value corresponding to the forwarding chip on which the determined output interface corresponding to the speed limit index is located, the SRv6 message encapsulated based on the first data message obtained after the speed limit index in the second data message is deleted is forwarded after speed limit processing is performed; and when the determined output interface is not on the line card board, sending the second data message to the line card board where the determined output interface is located, and forwarding the SRv6 message encapsulated on the basis of the first data message obtained by deleting the speed limit index in the second data message after carrying out speed limit processing on the speed limit value corresponding to the forwarding chip where the determined output interface is located and corresponding to the speed limit index by the corresponding line card board.
Preferably, the obtaining module 31 is specifically configured to obtain the speed limit index and the speed limit value of the forwarding chip where the egress interface corresponding to the target SRv6 tunnel is located, through the following manners:
when an output interface of the target SRv6 tunnel is a physical port, acquiring a speed limit value corresponding to the physical port, determining the acquired speed limit value as the speed limit value of a forwarding chip where the physical port is located, and applying for a unique speed limit index for the forwarding chip where the physical port is located from a preset speed limit index pool;
when the output interface of the target SRv6 tunnel is an aggregation port, acquiring the speed limit value corresponding to the aggregation port, calculating the speed limit values of the forwarding chips of all the member ports according to the bandwidth of the member ports belonging to the aggregation port on the forwarding chip of all the member ports in the aggregation port, and applying for a unique speed limit index for the forwarding chips of all the member ports from the preset speed limit index pool.
Preferably, the obtaining module 31 is specifically configured to calculate the speed limit values of the forwarding chips where all the member ports are located in the following manner:
for each forwarding chip in the forwarding chips where all the member ports are located, performing product operation on the sum of the bandwidths of the member ports belonging to the aggregation port on the forwarding chip and the speed limit value corresponding to the aggregation port to obtain a first operation result;
summing the bandwidths of the member ports belonging to the aggregation port on the forwarding chip where all the member ports are located to obtain a second operation result;
and carrying out quotient calculation on the first operation result and the second operation result to obtain the speed limit value of the forwarding chip.
Preferably, the apparatus further comprises:
and a synchronization module (not shown in fig. 3) configured to synchronize the acquired speed limit index and the acquired speed limit value to a standby main control board in the network device.
The present application further provides a message speed limiting device, where the device is applied to any cable card board in a network device, and a schematic structural diagram of the device is shown in fig. 4, and specifically includes:
a receiving module 41, configured to receive a speed limit index and a speed limit value of a forwarding chip where an output interface of an SRv6 tunnel of a sixth version of internet protocol and a target segment route acquired by a main control board in the network device, where the output interface is located, where the target segment route and the target segment route are sent by the main control board;
an adding determining module 42, configured to add the speed limit index to the first data packet to obtain a second data packet and determine an output interface of the second data packet when the first data packet is received and the target SRv6 tunnel needs to be used for forwarding the first data packet;
a judging module 43, configured to judge whether the determined output interface is on the cable card board;
a first speed-limiting module 44, configured to, when the determination result of the determining module 43 is yes, perform speed-limiting processing on an SRv6 packet encapsulated in a first data packet obtained based on deleting the speed-limiting index in the second data packet according to the speed-limiting value corresponding to the forwarding chip on which the determined output interface is located and corresponding to the speed-limiting index, and forward the SRv6 packet;
and a second speed limit module 45, configured to, if the determination result of the determining module 43 is negative, send the second data message to the line card board where the determined output interface is located, so that the corresponding line card board, according to the speed limit value corresponding to the forwarding chip where the determined output interface corresponding to the speed limit index is located, performs speed limit processing on the SRv6 message encapsulated based on the first data message obtained after the speed limit index in the second data message is deleted, and then forwards the SRv6 message.
According to the technical scheme, in the embodiment of the application, a message speed-limiting flow is additionally arranged in the process of forwarding the data message by using the SRv6 tunnel, and the specific flow is as follows:
firstly, a main control board in the network equipment acquires a speed limit index and a speed limit value of a forwarding chip where an output interface of a target SRv6 tunnel is located, and transmits the acquired speed limit index and speed limit value to all line card boards in the network equipment; then, when any line card board in the network equipment receives a first data message which needs to be forwarded by using the target SRv6 tunnel, adding a speed limit index into the first data message to obtain a second data message, determining an output interface of the second data message, and when the determined output interface is on the line card board, carrying out speed limit processing on an SRv6 message packaged based on the first data message obtained after deleting the speed limit index in the second data message according to a speed limit value corresponding to a forwarding chip on which the determined output interface is located and corresponding to the speed limit index, and then forwarding the SRv6 message; and when the determined output interface is not on the line card board, sending the second data message to the line card board where the determined output interface is located, and carrying out speed limit processing on the SRv6 message packaged by the first data message obtained by deleting the speed limit index in the second data message according to the speed limit value corresponding to the forwarding chip where the determined output interface corresponding to the speed limit index is located by the corresponding line card board.
Therefore, the problem of network congestion can be avoided to a certain extent through the message speed-limiting flow, and network experience is improved.
An electronic device is further provided in the embodiments of the present application, as shown in fig. 5, including a processor 51 and a machine-readable storage medium 52, where the machine-readable storage medium 52 stores machine-executable instructions that can be executed by the processor 51, and the processor 51 is caused by the machine-executable instructions to: and the steps of the message speed limiting method are realized.
The machine-readable storage medium may include a Random Access Memory (RAM) and a Non-Volatile Memory (NVM), such as at least one disk Memory. Alternatively, the machine-readable storage medium may be at least one memory device located remotely from the processor.
The Processor may be a general-purpose Processor, including a Central Processing Unit (CPU), a Network Processor (NP), and the like; but also Digital Signal Processors (DSPs), application Specific Integrated Circuits (ASICs), field Programmable Gate Arrays (FPGAs) or other Programmable logic devices, discrete Gate or transistor logic devices, discrete hardware components.
In another embodiment provided by the present application, a computer-readable storage medium is further provided, where a computer program is stored in the computer-readable storage medium, and when the computer program is executed by a processor, the computer program implements the steps of any one of the message speed limiting methods described above.
The above description is only exemplary of the present application and should not be taken as limiting the present application, as any modification, equivalent replacement, or improvement made within the spirit and principle of the present application should be included in the scope of protection of the present application.

Claims (10)

1. A message speed limiting method is characterized in that the method is applied to an active main control board in network equipment, and the method comprises the following steps:
acquiring a speed limit index and a speed limit value of a forwarding chip where an output interface of a target segment route and an SRv6 tunnel of the sixth version of the Internet protocol is located;
the acquired speed limit index and the acquired speed limit value are sent to all line card boards in the network equipment, so that when any line card board in the network equipment receives a first data message which needs to be forwarded by using a target SRv6 tunnel, the speed limit index is added to the first data message to obtain a second data message, an output interface of the second data message is determined, and when the determined output interface is on the line card board, the SRv6 message packaged based on the first data message obtained after the speed limit index in the second data message is deleted is forwarded after speed limit processing is carried out according to the speed limit value corresponding to a forwarding chip on which the determined output interface corresponding to the speed limit index is located; and when the determined output interface is not on the line card board, sending the second data message to the line card board where the determined output interface is located, and carrying out speed-limiting processing on the SRv6 message packaged by the first data message obtained by deleting the speed-limiting index in the second data message according to the speed-limiting value corresponding to the forwarding chip where the determined output interface corresponding to the speed-limiting index is located by the corresponding line card board.
2. The method according to claim 1, wherein obtaining the speed limit index and the speed limit value of the forwarding chip where the egress interface corresponding to the target SRv6 tunnel is located specifically comprises:
when an output interface of the target SRv6 tunnel is a physical port, acquiring a speed limit value corresponding to the physical port, determining the acquired speed limit value as the speed limit value of a forwarding chip where the physical port is located, and applying for a unique speed limit index for the forwarding chip where the physical port is located from a preset speed limit index pool;
when the output interface of the target SRv6 tunnel is an aggregation port, acquiring the speed limit value corresponding to the aggregation port, calculating the speed limit values of the forwarding chips of all the member ports according to the bandwidth of the member ports belonging to the aggregation port on the forwarding chip of all the member ports in the aggregation port, and applying for a unique speed limit index for the forwarding chips of all the member ports from the preset speed limit index pool.
3. The method of claim 2, wherein the speed limit values of the forwarding chips with all the member ports are calculated by:
for each forwarding chip in the forwarding chips where all the member ports are located, performing product operation on the sum of the bandwidths of the member ports belonging to the aggregation port on the forwarding chip and the speed limit value corresponding to the aggregation port to obtain a first operation result;
summing the bandwidths of the member ports belonging to the aggregation port on the forwarding chip where all the member ports are located to obtain a second operation result;
and carrying out quotient calculation on the first calculation result and the second calculation result to obtain the speed limit value of the forwarding chip.
4. The method of claim 1, further comprising:
and synchronizing the acquired speed limit index and the acquired speed limit value to a standby main control board in the network equipment.
5. A message speed limiting method is characterized in that the method is applied to any line card board in network equipment, and the method comprises the following steps:
receiving a speed limit index and a speed limit value of a forwarding chip where a target segment of a route acquired by a main control board in the network equipment and an output interface of an SRv6 tunnel of a sixth version of an Internet protocol are located, wherein the speed limit index and the speed limit value are sent by the main control board;
when a first data message is received and a target SRv6 tunnel is needed to be used for forwarding the first data message, adding the speed limit index into the first data message to obtain a second data message, and determining an output interface of the second data message;
judging whether the determined outlet interface is on the line card board or not;
when the judgment result is yes, according to the speed limit value corresponding to the forwarding chip where the determined outlet interface corresponding to the speed limit index is located, carrying out speed limit processing on the SRv6 message packaged based on the first data message obtained after deleting the speed limit index in the second data message, and then forwarding the SRv6 message;
and if not, sending the second data message to the line card board where the determined output interface is located, so that the corresponding line card board performs speed limit processing on the SRv6 message packaged by the first data message obtained after the speed limit index in the second data message is deleted according to the speed limit value corresponding to the forwarding chip where the determined output interface is located and corresponding to the speed limit index, and then forwards the SRv6 message.
6. A message speed limiting device is characterized in that the device is applied to an active main control board in network equipment, and the device comprises:
the acquisition module is used for acquiring a speed limit index and a speed limit value of a forwarding chip where an output interface of a target segment route and an SRv6 tunnel of the sixth version of the Internet protocol is located;
the issuing module is used for issuing the acquired speed limit index and the acquired speed limit value to all line card boards in the network equipment, so that when any line card board in the network equipment receives a first data message which needs to be forwarded by using a target SRv6 tunnel, the speed limit index is added into the first data message to obtain a second data message, an output interface of the second data message is determined, and when the determined output interface is on the line card board, the SRv6 message packaged based on the first data message obtained after the speed limit index in the second data message is deleted is forwarded after speed limit processing is carried out on the SRv6 message according to the speed limit value corresponding to the forwarding chip of the determined output interface corresponding to the speed limit index; and when the determined output interface is not on the line card board, sending the second data message to the line card board where the determined output interface is located, and carrying out speed-limiting processing on the SRv6 message packaged by the first data message obtained by deleting the speed-limiting index in the second data message according to the speed-limiting value corresponding to the forwarding chip where the determined output interface corresponding to the speed-limiting index is located by the corresponding line card board.
7. The apparatus according to claim 6, wherein the obtaining module is specifically configured to obtain the speed limit index and the speed limit value of the forwarding chip on which the egress interface corresponding to the target SRv6 tunnel is located, through the following manners:
when an output interface of the target SRv6 tunnel is a physical port, acquiring a speed limit value corresponding to the physical port, determining the acquired speed limit value as the speed limit value of a forwarding chip where the physical port is located, and applying for a unique speed limit index for the forwarding chip where the physical port is located from a preset speed limit index pool;
when the output interface of the target SRv6 tunnel is an aggregation port, acquiring a speed limit value corresponding to the aggregation port, calculating the speed limit values of forwarding chips of all member ports according to the bandwidth of the member ports belonging to the aggregation port on the forwarding chip of all the member ports in the aggregation port, and applying for a unique speed limit index for the forwarding chips of all the member ports from the preset speed limit index pool.
8. The apparatus according to claim 7, wherein the obtaining module is specifically configured to calculate the speed limit values of the forwarding chips where all the member ports are located by:
for each forwarding chip in the forwarding chips where all the member ports are located, performing product operation on the sum of the bandwidths of the member ports belonging to the aggregation port on the forwarding chip and the speed limit value corresponding to the aggregation port to obtain a first operation result;
summing the bandwidths of the member ports belonging to the aggregation port on the forwarding chip where all the member ports are located to obtain a second operation result;
and carrying out quotient calculation on the first operation result and the second operation result to obtain the speed limit value of the forwarding chip.
9. The apparatus of claim 6, further comprising:
and the synchronization module is used for synchronizing the acquired speed limit index and the acquired speed limit value to a standby main control board in the network equipment.
10. A message speed limiting device is characterized in that the device is applied to any line card board in network equipment, and the device comprises:
a receiving module, configured to receive a speed limit index and a speed limit value of a forwarding chip where an output interface of a target segment route and an internet protocol sixth version SRv6 tunnel obtained by a main control board in the network device is located, where the forwarding chip is sent by the main control board;
the adding and determining module is used for adding the speed limit index into the first data message to obtain a second data message and determining an output interface of the second data message when the first data message is received and the target SRv6 tunnel is required to be used for forwarding the first data message;
the judging module is used for judging whether the determined outlet interface is on the cable clamping board or not;
the first speed limit module is used for carrying out speed limit processing on an SRv6 message packaged by the first data message obtained by deleting the speed limit index in the second data message according to the speed limit value corresponding to the forwarding chip on which the determined output interface corresponding to the speed limit index is positioned when the judgment result of the judgment module is yes;
and the second speed limit module is used for sending the second data message to the line card board where the determined output interface is located when the judgment result of the judgment module is negative, so that the corresponding line card board limits the speed of the SRv6 message packaged by the first data message obtained by deleting the speed limit index in the second data message according to the speed limit value corresponding to the forwarding chip where the determined output interface corresponding to the speed limit index is located and forwards the SRv6 message.
CN202111148271.8A 2021-09-29 2021-09-29 Message speed limiting method and device Active CN113783789B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111148271.8A CN113783789B (en) 2021-09-29 2021-09-29 Message speed limiting method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111148271.8A CN113783789B (en) 2021-09-29 2021-09-29 Message speed limiting method and device

Publications (2)

Publication Number Publication Date
CN113783789A CN113783789A (en) 2021-12-10
CN113783789B true CN113783789B (en) 2023-03-31

Family

ID=78854198

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111148271.8A Active CN113783789B (en) 2021-09-29 2021-09-29 Message speed limiting method and device

Country Status (1)

Country Link
CN (1) CN113783789B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116055007B (en) * 2023-03-17 2023-06-13 无锡沐创集成电路设计有限公司 Device and method for rate matching of MAC (media access control) direct-connected switching chip
CN116303474B (en) * 2023-05-09 2023-08-18 新华三技术有限公司 Tunnel information statistical method, device, network equipment and storage medium

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105429908A (en) * 2015-11-09 2016-03-23 福建星网锐捷网络有限公司 Message processing method and device
CN108809849A (en) * 2018-08-30 2018-11-13 新华三技术有限公司 A kind of Limit Rate method, apparatus and controller
CN109639594A (en) * 2018-12-04 2019-04-16 杭州迪普科技股份有限公司 Method for limiting speed and device based on the frame network equipment
US10736029B1 (en) * 2019-05-02 2020-08-04 Verizon Patent And Licensing Inc. Enabling network-slice functions in transport domains
CN111510386A (en) * 2019-01-30 2020-08-07 华为技术有限公司 Method and device for processing message
CN112422435A (en) * 2020-11-13 2021-02-26 新华三技术有限公司合肥分公司 Message forwarding control method and device and electronic equipment
CN112532519A (en) * 2020-12-21 2021-03-19 安徽皖通邮电股份有限公司 Method for slightly controlling data Flow behavior by adopting BGP Flow Specification
CN113206794A (en) * 2021-03-31 2021-08-03 新华三信息安全技术有限公司 Forwarding speed limiting method and device
CN113347084A (en) * 2021-06-23 2021-09-03 新华三信息安全技术有限公司 Message forwarding method and device

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105429908A (en) * 2015-11-09 2016-03-23 福建星网锐捷网络有限公司 Message processing method and device
CN108809849A (en) * 2018-08-30 2018-11-13 新华三技术有限公司 A kind of Limit Rate method, apparatus and controller
CN109639594A (en) * 2018-12-04 2019-04-16 杭州迪普科技股份有限公司 Method for limiting speed and device based on the frame network equipment
CN111510386A (en) * 2019-01-30 2020-08-07 华为技术有限公司 Method and device for processing message
US10736029B1 (en) * 2019-05-02 2020-08-04 Verizon Patent And Licensing Inc. Enabling network-slice functions in transport domains
CN112422435A (en) * 2020-11-13 2021-02-26 新华三技术有限公司合肥分公司 Message forwarding control method and device and electronic equipment
CN112532519A (en) * 2020-12-21 2021-03-19 安徽皖通邮电股份有限公司 Method for slightly controlling data Flow behavior by adopting BGP Flow Specification
CN113206794A (en) * 2021-03-31 2021-08-03 新华三信息安全技术有限公司 Forwarding speed limiting method and device
CN113347084A (en) * 2021-06-23 2021-09-03 新华三信息安全技术有限公司 Message forwarding method and device

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
基于SRv6的网络切片技术研究;石鸿伟等;《电子技术与软件工程》;20200815(第16期);全文 *

Also Published As

Publication number Publication date
CN113783789A (en) 2021-12-10

Similar Documents

Publication Publication Date Title
CN113783789B (en) Message speed limiting method and device
CN106685903B (en) SDN-based data transmission method, SDN controller and SDN system
WO2019127134A1 (en) Data transmission method and virtual switch
CN107547391A (en) A kind of message transmitting method and device
US20210281401A1 (en) Methods, systems, and computer readable media for utilizing predetermined encryption keys in a test simulation environment
US20140293825A1 (en) Timestamping data packets
CN111026324B (en) Updating method and device of forwarding table entry
WO2019075662A1 (en) Gateway multi-connection method and device
CN106941418B (en) SSL VPN configuration information synchronization method and device
CN106059964B (en) Message forwarding method and device
CN113986969A (en) Data processing method and device, electronic equipment and storage medium
CN107483369B (en) Message processing method and virtual switch
US20170019336A1 (en) Packet forwarding method, system, and apparatus
CN108156066B (en) Message forwarding method and device
CN109150707B (en) Routing path analysis method and device
CN110808909B (en) Message processing method and device across virtual systems
WO2022227484A1 (en) Data communication method and apparatus, computer device, and storage medium
CN109618015A (en) Stacking implementation method and device are removed based on data center
CN112822123A (en) Data acquisition method and device
CN107707485A (en) A kind of range type IP message strategy matching circuits and method
CN110336759B (en) RDMA (remote direct memory Access) -based protocol message forwarding method and device
CN109995606B (en) Virtualization deep packet inspection vDPI flow control method and network element equipment
WO2015169053A1 (en) Packet data processing method, device and system
CN116886463B (en) Cascade communication method, device, equipment and medium
US10009252B2 (en) Flow entry delivery method and communication system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant