Drainage control method, device and equipment

By extending the BGP FLowspec protocol and utilizing the Remak action and Remark color to generate routing information, the problem of traffic redirection when the next-hop forwarding device cannot be predicted is solved, enabling flexible tunnel selection and quality of service assurance for high-value user traffic.

CN121940329APending Publication Date: 2026-04-28CHINA MOBILE COMM LTD RES INST +1
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
CHINA MOBILE COMM LTD RES INST
Filing Date
2024-10-25
Publication Date
2026-04-28

AI Technical Summary

Technical Problem

In existing technologies, when the next-hop forwarding device cannot be predicted, the traffic of high-value users cannot be accurately routed to a specific SRv6 or G-SRv6 tunnel, affecting service quality.

Method used

By using the extended BGP FLowspec protocol, remark actions and remark colors are used to generate routing information, indicate traffic characteristics, and send them to a second network device, enabling flexible routing of traffic to a specific tunnel.

Benefits of technology

Even when the next-hop forwarding device cannot be predicted, the quality of service for high-value user traffic can still be guaranteed, enabling flexible traffic management and tunnel selection.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121940329A_ABST
    Figure CN121940329A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides a drainage control method, device and equipment, and the method comprises the steps: building a preset neighbor relation with second network equipment, and obtaining the traffic characteristics of traffic; generating routing information based on the traffic characteristics of the traffic, the routing information comprising at least one of the following items: first information, the first information being used for indicating a Remak action; the second information is used for indicating a value of a Remark color, and the value of the color is used for determining to guide traffic to a specific tunnel; and sending the routing information to the second network equipment.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of communication technology, specifically to a diversion control method, apparatus, and device. Background Technology

[0002] In existing traffic redirection schemes, user services (video, games, etc.) are identified using methods such as IP 5-tuple information. This is combined with the deployment of accelerated channels based on IPv6 forwarding plane segment routing (SRv6) or generalized segment routing (G-SRv6) header compression technology. High-value user services are then routed to low-latency accelerated channels as needed, improving the service experience for high-value users. Currently, directing user traffic to a specific SRv6 or G-SRv6 tunnel requires advance path planning and prior knowledge of the destination server's address. Traffic is then directed to the corresponding SRv6 or G-SRv6 tunnel based on the user traffic's final destination IP address. If the next-hop forwarding device corresponding to the user traffic's destination address cannot be predicted in advance, traffic may not be directed to the corresponding SRv6 or G-SRv6 tunnel, thus impacting service quality. Summary of the Invention

[0003] This application provides a diversion control method, apparatus, and device to solve the problem of how to flexibly select tunnels for traffic transmission.

[0004] Firstly, a traffic diversion control method is provided, applied to a first network device, comprising:

[0005] Establish a preset neighbor relationship with the second network device to obtain the traffic characteristics of the traffic;

[0006] Routing information is generated based on the traffic characteristics of the traffic, and the routing information includes at least one of the following: first information, which is used to indicate a remark action; second information, which is used to indicate the value of the remark color, and the value of the color is used to determine to direct traffic to a specific tunnel;

[0007] The routing information is sent to the second network device.

[0008] Optionally, sending the routing information to the second network device includes:

[0009] The routing information is sent to the second network device via the extended BGP FLowspec protocol.

[0010] Optionally, the extended BGP FLowspec protocol includes a remark subtype message format, wherein the field types of the remark subtype message format include at least one of the following: a subtype, which is used to indicate a Remak action in the message; a flag, which is used to indicate the content in the message; and the value of the flag.

[0011] Optionally, the routing information is used by the second network device to generate forwarding table entries, the forwarding table entries including at least one of the following: third information, the third information being used to indicate remarking for the traffic characteristics; fourth information, the fourth information being used to indicate that traffic with the value of the Remark color is directed to a specific tunnel.

[0012] Optionally, the tunnel includes at least one of the following: SRv6 tunnel, SRv6 Group tunnel.

[0013] Secondly, a traffic diversion control method is provided, applied to a second network device, including:

[0014] Receive traffic and obtain the traffic characteristics of the traffic;

[0015] Based on the traffic characteristics and routing information of the traffic, the traffic is remarked. The routing information includes at least one of the following: first information, which is used to indicate the remark action; and second information, which is used to indicate the value of the remark color, which is used to determine to guide the traffic to a specific tunnel.

[0016] The corresponding tunnel is determined based on the color of the traffic remark.

[0017] The traffic is forwarded through the tunnel.

[0018] Optionally, based on the traffic characteristics and routing information, the traffic is remarked, including:

[0019] A forwarding table entry is generated based on the routing information. The forwarding table entry includes at least one of the following: third information, which is used to indicate remarking for the traffic characteristics; and fourth information, which is used to indicate that traffic with the value of the Remark color should be directed to a specific tunnel.

[0020] The traffic is remarked based on the forwarding entries and the traffic characteristics.

[0021] Optionally, the corresponding tunnel is determined based on the color of the traffic remark, including:

[0022] The corresponding tunnel is determined based on the color of the traffic remark and the traffic characteristics.

[0023] Optionally, the method further includes:

[0024] Receive the routing information sent by the first network device.

[0025] Optionally, the tunnel includes at least one of the following: SRv6 tunnel, SRv6 Group tunnel.

[0026] Thirdly, a traffic diversion control device is provided, applied to a first network device, comprising: a first transceiver unit and a first processing unit;

[0027] The first processing unit is used to establish a preset neighbor relationship with the second network device and obtain the traffic characteristics of the traffic.

[0028] The first processing unit is further configured to generate routing information based on the traffic characteristics of the traffic, the routing information including at least one of the following: first information, the first information being used to indicate a remark action; second information, the second information being used to indicate the value of a remark color, the value of the color being used to determine to direct traffic to a specific tunnel;

[0029] The first transceiver unit is used to send the routing information to the second network device.

[0030] Fourthly, a traffic control device is provided, applied to a second network device, comprising: a second transceiver unit and a second processing unit.

[0031] The second processing unit is used to receive traffic and obtain the traffic characteristics of the traffic;

[0032] The second processing unit is further configured to remark the traffic based on the traffic characteristics and routing information of the traffic, wherein the routing information includes at least one of the following: first information, which is used to indicate the remark action; and second information, which is used to indicate the value of the remark color, wherein the value of the color is used to determine to guide the traffic to a specific tunnel.

[0033] The second processing unit is further configured to determine the corresponding tunnel based on the color of the traffic remark;

[0034] The second transceiver unit is used to forward the traffic through the tunnel.

[0035] Fifthly, a communication device is provided, including a processor, a memory, and a program or instructions stored in the memory and executable on the processor, wherein the program or instructions, when executed by the processor, implement the steps of the method described in the first or second aspect.

[0036] A sixth aspect provides a readable storage medium on which a program or instructions are stored, which, when executed by a processor, implement the steps of the method as described in the first or second aspect.

[0037] A seventh aspect provides a computer program product including computer instructions that, when executed by a processor, implement the steps of the method described in the first or second aspect.

[0038] In this application, a first network device sends routing information to a second network device. The routing information includes at least one of the following: first information, used to instruct a remark action; and second information, used to indicate the value of a remark color, the value of which is used to determine which tunnel to direct traffic to. This allows the second network device to remark the traffic based on the routing information and the traffic characteristics, thereby directing the traffic to the specific tunnel. This solution flexibly addresses different types of traffic demands and ensures service quality even when the next-hop forwarding device cannot be predicted. Attached Figure Description

[0039] Various other advantages and benefits will become apparent to those skilled in the art upon reading the following detailed description of preferred embodiments. The accompanying drawings are for illustrative purposes only and are not intended to limit the scope of this application. Furthermore, the same reference numerals denote the same parts throughout the drawings. In the drawings:

[0040] Figure 1 This is a diagram illustrating traffic redirection based on the destination IP address;

[0041] Figure 2 This is a flowchart illustrating a drainage control method provided by an embodiment of this application;

[0042] Figure 3 This is a flowchart illustrating another drainage control method provided by an embodiment of this application;

[0043] Figure 4 This is a schematic diagram of the remark sub-type message definition format provided in an embodiment of this application;

[0044] Figure 5 This is a schematic diagram of the drainage provided in an embodiment of this application;

[0045] Figure 6 This is a schematic diagram of a communication processing device provided by an embodiment of this application;

[0046] Figure 7 This is a schematic diagram illustrating another communication processing apparatus provided by an embodiment of this application;

[0047] Figure 8 This is a schematic diagram of a communication device provided in an embodiment of this application. Detailed Implementation

[0048] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.

[0049] The term "comprising," and any variations thereof, used in the specification and claims of this application, is intended to cover a non-exclusive inclusion. For example, a process, method, system, product, or apparatus that includes a series of steps or units is not necessarily limited to those explicitly listed, but may include other steps or units not explicitly listed or inherent to such process, method, product, or apparatus. Furthermore, the use of "and / or" in the specification and claims indicates at least one of the connected objects, such as A and / or B, indicating the inclusion of A alone, B alone, or both A and B.

[0050] In the embodiments of this application, the terms "exemplary" or "for example" are used to indicate that something is an example, illustration, or description. Any embodiment or design that is described as "exemplary" or "for example" in the embodiments of this application should not be construed as being more preferred or advantageous than other embodiments or design. Specifically, the use of the terms "exemplary" or "for example" is intended to present the relevant concepts in a specific manner.

[0051] User services (video, games, etc.) are identified through methods such as IP 5-tuple information. Combined with the deployment of accelerated channels based on IPv6 forwarding plane segment routing (SRv6) or SRv6 header compression technology (Generalized Segment Routing IPv6, G-SRv6), services of high-value users are sent to low-latency accelerated channels as needed, improving the service experience of high-value users. Currently, to introduce user traffic to a specific SRv6 or G-SRv6 tunnel, path planning needs to be performed in advance and the address of the destination server needs to be known in advance. Then, based on the final destination IP address of the user traffic, the traffic is introduced to the corresponding SRv6 or G-SRv6 tunnel.

[0052] In traffic redirection technology, the forwarding path on the forwarding device is mainly controlled by issuing Border Gateway Protocol Flow Specification (BGP Flowspec) routes through the controller.

[0053] like Figure 1 As shown, if a user's high-value service accesses resource pool 1, the BGPFlowspec route is issued by the controller on backbone BB1, and the traffic is introduced into the SRv6 policy1 tunnel based on the source or destination address. If the user needs to access resource pool 2, the traffic is introduced into the SRv6 policy2 tunnel based on the source or destination address. Currently, BGPFlowspec only supports introducing traffic into a single SRv6 policy tunnel.

[0054] The above traffic diversion scheme requires advance knowledge of the forwarding device corresponding to the next hop of the user's business destination address to direct a user's traffic into a specific SRv6 tunnel. However, in actual network service acceleration scenarios, the resource pool where the service is located is not fixed. The same user and the same service may access resource pools in different regions due to different service operations. This makes it impossible to confirm the next hop device and address in advance when accelerating a certain user and a certain service, resulting in inaccurate acceleration. For example, for a certain user of XX game who only logs in once, the access destination IP address exceeds more than twenty, and the access resource pool is in multiple resource pools such as Beijing, Shanghai, and Guangdong. When accelerating based on a certain user (identified by the source address), it is impossible to accurately introduce the SRv6 low-latency tunnel.

[0055] See Figure 2 This application provides a traffic diversion control method applied to a first network device, which includes, but is not limited to, a controller, such as a Software Defined Network (SDN) controller. The specific steps include:

[0056] Step 21: Establish a preset neighbor relationship with the second network device and obtain the traffic characteristics of the traffic;

[0057] Optionally, the traffic characteristics include, but are not limited to, at least one of the following: source IP address, destination IP address, protocol number, source port, and destination port.

[0058] Optionally, the first network device establishes a neighbor relationship with the second network device via the BGP Flowspec protocol.

[0059] Optionally, the second network device may include, but is not limited to, a repeater.

[0060] Step 22: Generate routing information based on the traffic characteristics (e.g., source address or source port of the traffic), the routing information including at least one of the following: first information, the first information being used to indicate a remark action; second information, the second information being used to indicate the value of the remark color, the value of the color being used to determine to direct the traffic to a specific tunnel;

[0061] It is understandable that the first and second pieces of information mentioned above are associated with the traffic characteristics of the traffic (such as the source address or source port of the traffic).

[0062] Optionally, the color value can represent traffic priority, quality of service requirements, or other service characteristics. For example, a color value of 10 may correspond to a "low latency" SRv6 tunnel, while a color value of 20 may correspond to other tunnels with "high bandwidth".

[0063] Optionally, the tunnel includes at least one of the following: an SRv6 tunnel (e.g., an SRv6 policy tunnel) or an SRv6Group tunnel.

[0064] Step 23: Send the routing information to the second network device.

[0065] Optionally, routing information is used by the second network device to generate forwarding table entries, which include at least one of the following: third information, which indicates remarking based on the traffic characteristics (e.g., the source address or source port of the traffic); and fourth information, which indicates directing traffic with the Remark color value to a specific tunnel. That is, the second network device remarks traffic matching the traffic characteristics (e.g., the source address or source port of the traffic) according to the Remark color value.

[0066] In one embodiment of this application, sending the routing information to the second network device includes:

[0067] The routing information is sent to the second network device via the extended BGP FLowspec protocol.

[0068] In one embodiment of this application, the extended BGP FLowspec protocol includes a remark subtype message format, wherein the field types of the remark subtype message format include at least one of the following: sub-type, which is used to indicate a remak action in the message; flag, which is used to indicate the content in the message; and the value of the flag.

[0069] In one embodiment of this application, the tunnel includes at least one of the following: an SRv6 tunnel (e.g., an SRv6policy tunnel) or an SRv6 Group tunnel.

[0070] In this application, a first network device sends routing information to a second network device. The routing information includes at least one of the following: first information, used to instruct a remark action; and second information, used to indicate the value of a remark color, the value of which is used to determine which tunnel to direct traffic to. This allows the second network device to remark the traffic based on the routing information and the traffic characteristics, thereby directing the traffic to the specific tunnel. This solution flexibly addresses different types of traffic demands and ensures service quality even when the next-hop forwarding device cannot be predicted.

[0071] See Figure 3 This application provides a traffic diversion control method applied to a second network device, such as a repeater, and the specific steps include:

[0072] Step 31: Receive traffic and obtain the traffic characteristics of the traffic;

[0073] Step 32: Based on the traffic characteristics (e.g., source address or source port of the traffic) and routing information, remark the traffic. The routing information includes at least one of the following: first information, which is used to indicate the remark action; second information, which is used to indicate the value of the remark color, and the value of the color is used to determine to guide the traffic to a specific tunnel.

[0074] Optionally, the tunnel includes at least one of the following: an SRv6 tunnel (e.g., an SRv6 policy tunnel) or an SRv6Group tunnel.

[0075] Step 33: Determine the corresponding tunnel based on the color of the traffic remark;

[0076] Step 34: Forward the traffic through the tunnel.

[0077] In this embodiment, the routing information may be configured by the first network device and sent to the second network device, or the routing information may be configured by the second network device.

[0078] Optionally, based on the traffic characteristics and routing information, the traffic is remarked, including:

[0079] A forwarding table entry is generated based on the routing information. The forwarding table entry includes at least one of the following: third information, which is used to indicate remarking for the traffic characteristics; and fourth information, which is used to indicate that traffic with the value of the Remark color should be directed to a specific tunnel.

[0080] The traffic is remarked based on the forwarding entries and the traffic characteristics.

[0081] In one embodiment of this application, the method further includes:

[0082] Receive routing information sent by the first network device.

[0083] Optionally, the second network device receives routing information sent by the first network device via the extended BGP FLowspec protocol.

[0084] Optionally, the extended BGP FLowspec protocol includes a remark subtype message format, wherein the field types of the remark subtype message format include at least one of the following: a sub-type, which is used to indicate a remak action in the message; a flag, which is used to indicate the content in the message; and a value of the flag.

[0085] In one implementation, determining the corresponding tunnel based on the color of the traffic remark includes:

[0086] The corresponding tunnel is determined based on the color of the traffic remark and the traffic characteristics (e.g., the destination address of the traffic).

[0087] For example, the corresponding SRv6 Group is determined based on the color of the traffic remark, and the SRv6 Policy1 tunnel or the SRv6 Policy2 tunnel is determined from the SRv6 Group for forwarding based on the traffic characteristics (e.g., the destination address of the traffic).

[0088] In one implementation, by extending the BGP Flowspe protocol, flexible selection of multiple SRv6 tunnels in the network can be achieved based on the destination address next hop of the traffic.

[0089] In this application, the second network device remarks the traffic based on the routing information and traffic characteristics, thereby directing the traffic to a specific tunnel. This solution flexibly addresses different types of traffic demands and ensures service quality even when the next-hop forwarding device cannot be predicted.

[0090] The implementation methods of this application are described below with reference to Embodiments 1, 2 and 3, wherein the first network device is a controller, the second network device is a repeater, and the tunnel is an SRv6 policy tunnel or an SRv6 Group tunnel.

[0091] Example 1:

[0092] By extending the BGP Flowspec protocol, the controller sends routing information to the forwarders and sets the Flowspec action for specific routes to remark color. Based on the routing information, the forwarders remark the corresponding traffic. The remark color is the color corresponding to the low-latency or high-bandwidth SRv6 policy tunnel. The color enables the corresponding traffic to automatically iterate to the correct SRv6 policy tunnel or SRv6 group tunnel based on the destination address of the traffic.

[0093] Optionally, the routing information can be BGP Flowsepc routes, which include, but are not limited to, at least one of the following:

[0094] 1) Traffic matching rules: BGP FlowSpec routes define a set of conditions for matching specific traffic. These conditions are usually based on five-tuple information (source IP, destination IP, source port, destination port, protocol type) and other possible fields.

[0095] 2) Traffic Actions: For matched traffic, FlowSpec routes can specify various processing actions, such as remarking, dropping, redirecting, rate limiting, or mirroring. This allows network administrators to take appropriate measures for specific traffic, enhancing network security and efficiency.

[0096] 3) Priority and Order: Matching rules in FlowSpec routes typically have priority settings to determine the order in which multiple rules are processed. This ensures that higher-priority rules are applied first so that the expected action is taken in the event of a conflict.

[0097] 4) Scalability: FlowSpec routing allows for the future expansion and addition of new matching conditions and actions as needed, adapting to changing network environments and security requirements. This flexibility makes it ideal for cloud computing and virtualization environments. Optionally, routing information can be distributed and managed via the BGP Flowspec protocol.

[0098] Optionally, routing information can be transmitted via Remark messages.

[0099] Optionally, the routing information includes at least one of the following: first information, which is used to indicate a Remark action; and second information, which is used to indicate the value of a Remark color, the value of which is used to determine to direct traffic to a specific tunnel, including an SRv6 policy tunnel or an SRv6 Group tunnel.

[0100] This embodiment extends the BGP Flowspec protocol by adding a remark sub-type based on the FlowSpec Non-Transitive Extended Communities type. The remark sub-type message format is defined in Table 1 below.

[0101] Table 1: Definition of New Remark Types

[0102]

[0103] 2. When publishing protocol messages in BGP Flowspec, add a sub-type message definition format as follows: Figure 4 As shown, where:

[0104] Type: 0x47 indicates that it is a Flowspec extension.

[0105] Sub-Type: Identifies the FLOWSAPEC Remark action in the protocol message; it is unique and awaits allocation by the IETF.

[0106] Flags: Each ID represents the content of a Remark message, such as Flags=0x001, Remark color, Flags=0x002, Remark DHCP.

[0107] Reserved: Reserved field.

[0108] value: Used to identify the specific value of Flags, such as the value of a specific Color.

[0109] In one implementation, steps 1 to 6 are included:

[0110] Step 1: The controller and the repeater establish a BGP Flowspec neighbor relationship;

[0111] Step 2: Configure the traffic redirection strategy for the corresponding repeater in the controller.

[0112] Optionally, the traffic redirection strategy includes: traffic redirection rules and traffic redirection actions, which are determined based on the packet 5-tuple + Remark color action;

[0113] Optionally, the referral rules can specify which traffic needs to be redirected based on traffic characteristics.

[0114] Optionally, traffic characteristics include, but are not limited to, traffic type, 5-tuple, etc., wherein the 5-tuple includes: source IP address, destination IP address, protocol number, source port, and destination port.

[0115] Optionally, traffic redirection actions include a "Remark color" action, which labels successfully matched traffic with a color (i.e., sets a color value). This label can be used by subsequent processing rules, such as directing traffic to different tunnels based on the color value. Traffic redirection actions also include matching the corresponding traffic to the appropriate SRv6policy tunnel or SRv6 group tunnel based on the color value for transmission.

[0116] Step 3: The controller publishes specific routing information to the repeaters, publishing the routing information according to the above protocol extension fields;

[0117] For example, the controller generates a BGP Flowspec route update message with referral rules and referral actions. The controller then sends the BGP Flowspec route update message to the forwarder via a BGP session.

[0118] Step 4: The repeater receives routing information (e.g., BGP Flowsepc routes) and identifies the corresponding routing processing policy based on specific fields;

[0119] Specific protocol messages typically refer to BGP Flowspec route update messages transmitted via protocols such as BGP FlowSpec. These messages contain rules for network traffic control and management, such as redirection rules (how to identify traffic) and corresponding redirection actions (how to process traffic).

[0120] Optionally, specific fields are key information used to identify and parse traffic within a specific protocol message. Examples include 5-tuple information and remark color.

[0121] Optionally, routing processing policies are processing rules based on the specific protocol messages and fields received. These policies determine how traffic matching specific conditions is processed. For example: Traffic redirection: sending packets conforming to certain criteria to a designated tunnel or service. Dropping policy: dropping traffic that does not meet requirements or is marked as low priority. Traffic rate limiting: imposing bandwidth limits on traffic of specific colors or categories to ensure reasonable allocation of network resources.

[0122] Specifically, the repeater analyzes the received routing information and extracts the redirection rules and actions. For each redirection rule from the controller, the repeater establishes a corresponding routing processing strategy to determine whether the traffic meets the redirection conditions.

[0123] Step 5: After the traffic enters the repeater, the repeater performs a remark color action on the traffic based on the source address of the traffic;

[0124] Specifically, the repeater can monitor network traffic in real time and then extract traffic characteristics. By finding traffic redirection rules that match the traffic characteristics, the repeater applies the corresponding remark color value and appends that remark color value to the traffic, giving it an identifier that can be used for subsequent processing.

[0125] Step 6: Based on the color value of the packet, look up the routing information, and select the corresponding SRv6 policy tunnel or SRv6 Group tunnel based on the next hop of the destination IP packet and the color value.

[0126] The next hop of a destination IP packet refers to the address of the next router or network device on the forwarding path associated with the destination IP address of the data packet.

[0127] In SRv6 scenarios, the next hop is typically mapped to a specific SRv6 policy or SRv6Group. These policies define the path rules that packets must follow as they traverse the network, including how to switch between tunnels.

[0128] In step 6, the process of selecting the corresponding SRv6 policy tunnel or SRv6 group tunnel based on the next hop of the destination IP packet and the color value can be summarized as follows:

[0129] 1) Find routing information:

[0130] When a repeater receives a data packet, it first checks the destination IP address to determine the next hop for this traffic. This location is defined in the device's routing information.

[0131] Routing information contains the next-hop information needed to reach each destination and may be associated with different policies and processing rules.

[0132] 2) Combining the Color value:

[0133] When processing the packet, the forwarder also checks the remark color. The value of this color indicates the priority or category of the traffic. Based on this mark, the network can take different actions.

[0134] The color value plays an important role in some QoS (Quality of Service) applications, and can affect traffic scheduling and management.

[0135] 3) Select SRv6 Policy or Group tunnel:

[0136] Based on the next hop configured for a specific destination IP in the routing information and the color value of the current packet, the forwarder can determine which type of SRv6 policy tunnel to use:

[0137] SRv6 Policy Tunnel: If a specific SRv6 Policy is configured for this next hop in the routing information, the forwarder will forward the packet through the pre-designed path according to that policy. An SRv6 Policy can include multiple segments indicating the nodes and operations that the packet should traverse.

[0138] SRv6 Group Tunnel: If the path is set to SRv6 Group Tunnel, this will determine whether traffic enters a group channel with multiple exits based on the priority of the color value. This channel can be used for load balancing or failover to improve reliability.

[0139] Therefore, in step 6, the process by which the forwarder determines which SRv6 policy tunnel to use by finding the next hop of the destination IP and combining it with the color value is dynamic and fine-grained. This mechanism allows network administrators to achieve flexible traffic management and optimization based on actual traffic conditions.

[0140] Example 2

[0141] When the forwarder is configured for a specific Flowspec route, a remark action is performed on traffic from a certain user or service, and the next hop is found based on the color value to enter the different SRv6 policy tunnel.

[0142] In the repeater, set a Remark action for routes sent from specific BGP Flowspec neighbors, and start color-based numerical iteration to the next hop corresponding SRv6 policy tunnel. A specific command example is as follows:

[0143] [sys]flow-route route1;

[0144] [sys-flow-route-route1]if-match source-ip 1.1.1.0 24;

[0145] [sys-flow-route-route1]if-match source-port 10;

[0146] [sys-flow-route-route1]Remark color 10;

[0147] [sys-flow-route-route1]color 10nest-hop SRv6 xx.

[0148] The parameters in the last step are optional. If not configured, it means that only the route color is remarked. If configured as an SRv6 policy tunnel, it means that after the traffic enters the forwarder, it will be remarked based on the source address or source port of the traffic. Based on the remarked color, it will automatically find the correct SRv6 policy tunnel in the SRv6 Group, or automatically iterate to a specific SRv6 policy tunnel.

[0149] The command "[sys]flow-route route1" is used to enter configuration mode to define a specific traffic routing policy. route1 is the name of the routing policy and can be any specific identifier. After executing this command, various conditions and actions related to that route can be configured.

[0150] The command `[sys-flow-route-route1]if-match source-ip 1.1.1.0 24` adds a traffic matching condition to the routing policy. Specifically, this line means: `if-match source-ip 1.1.1.0 24`: This rule matches all traffic whose source IP address belongs to the 1.1.1.0 24 network. This means that as long as the source IP address of the traffic is within this subnet, the forwarder will consider applying the Remark action configured below.

[0151] The command "[sys-flow-route-route1]if-match source-port 10" adds another matching condition to the routing policy: if-match source-port 10. This rule specifies that only traffic with a source port of 10 will be matched. This means that the relevant Remark action will only be applied if the previous source IP matching condition and the source port is 10 are met.

[0152] The command "[sys-flow-route-route1]Remark color 10" defines an action that sets a color mark for matched traffic: Remark color 10: For traffic that meets the first two conditions (source IP and source port), it is remarked with a color value of 10. Remark color is typically used for subsequent path selection, flow control, etc.

[0153] The command "[sys-flow-route-route1]color 10next-hop SRv6 xx" sets the next-hop route for traffic with a specific Remark color.

[0154] `color 10next-hop SRv6 xx`: Specifies that all traffic marked with a color value of 10 will have its next hop be an SRv6 policy tunnel xx. This setting allows traffic to be directly routed to the appropriate tunnel, enabling more flexible and efficient traffic management.

[0155] In one implementation, steps 1 to 3 are included:

[0156] Step 1: The controller establishes a BGP Flowspec neighbor with the repeater and configures the corresponding Flowspec routing policy on the repeater. Refer to the above configuration for the specific command line.

[0157] Step 2: The controller publishes specific routing information (such as BGP Flowsepc routes) to the forwarders, such as directing the corresponding traffic to the corresponding SRv6 policy tunnel based on a certain source address. The forwarders then use the command identifier to determine the corresponding routing processing policy.

[0158] Commands typically refer to specific instructions issued by the controller to the forwarder via routing information. These instructions can include: Traffic matching instructions: defining the conditions for matching specific traffic, such as based on source IP address, destination IP address, protocol type, etc. Action instructions: describing the actions to be taken for the matched traffic. These commands enable the forwarder to take appropriate processing measures based on traffic characteristics.

[0159] Routing strategies are the specific operational methods and decisions that a forwarder determines based on received commands, such as forwarding matched traffic safely and efficiently, including selecting appropriate next hops and tunnels.

[0160] Step 3: After traffic enters the repeater, the repeater checks the source address of the traffic, re-marks the traffic with color, then checks the destination address of the traffic, checks the BGP next hop of the destination address, and finds the SRv6 policy tunnel of the next hop node in the SRv6 Group or SRv6policy tunnel based on the next hop.

[0161] Specifically, when a traffic packet arrives at the forwarder, the forwarder first captures the packet information, including the five-tuple information: source IP, destination IP, source port, and destination port. Based on the matching routing rules, the forwarder checks the source address of the traffic and decides whether to remark it. For traffic that meets the criteria, a remark color is added to the packet. The forwarder analyzes the destination IP of the packet and, based on the obtained remark color, looks up the associated BGP Flowspec route entry. By querying the routing information, it identifies the corresponding next-hop node. Based on the found next-hop information, the forwarder further searches for the relevant tunnels configured in the SRv6 Group / SRv6 Policy and determines which SRv6 Policy tunnel or SRv6 Group tunnel the traffic should be routed to for forwarding.

[0162] Example 3

[0163] Taking a user's high-value service requiring simultaneous access to two resource pools as an example, the corresponding high-value service needs to be accelerated through an SRv6 policy tunnel. The backbone network pre-deploys an SRv6 Group / SRv6 policy to accelerate the low-latency plane. The network topology is as follows. Figure 5 As shown, BB is the backbone network node in the network. The tunnel from BB1 to BB2 is policy1 with a color value of 1. The tunnel from BB1 to BB3 is policy2 with a color value of 1. The controller is the service management system.

[0164] The business and node address planning is as follows:

[0165] User source address: A:1::

[0166] Business access resource pool 1 destination address: A:2::

[0167] Business access resource pool 2 destination address: A:3::

[0168] BB2 node address: A:4::

[0169] BB3 node address: A:5::

[0170] Configure a game acceleration policy based on a specific user on the controller, introduce traffic to the corresponding SRv6Group or SRv6 policy low-latency plane, and the forwarding plane matches the specific user for traffic forwarding according to the controller requirements, and automatically iterates the corresponding SRv6 policy tunnel according to the destination address of the packet.

[0171] In one implementation, steps 1 to 4 are included:

[0172] Step 1: The controller establishes a BGP Flowsheet link with devices BB1, BB2, and BB3, and simultaneously sends out the SRv6 Group1 low-latency tunnel plane.

[0173] Specifically, the controller generates the configuration for SRv6 Group1, including the definition of the low-latency tunnel. The controller then sends the SRv6 Group1 configuration to the BB1, BB2, and BB3 devices via a BGP session, enabling these devices to recognize the low-latency path.

[0174] Step 2: The controller sends routing information (e.g., BGP flowspec route) to BB1 according to the policy, remarks the corresponding traffic as color 10 based on the user source address A:1::, and introduces the corresponding traffic into the SRv6 Group1 tunnel plane based on color 10.

[0175] Specifically, the controller determines routing information (e.g., BGP flowspec routes) and specifies that traffic with a source address of A:1:: will be remarked, as this address corresponds to high-value user services. The controller instructs BB1 to remark traffic with a source address of A:1::, setting the color value to 10. This operation aims to facilitate future traffic management. The controller publishes the above rules and remark information to BB1 via BGP, forming a complete process integrating traffic matching and processing actions.

[0176] Step 3: BB1 forms forwarding table entries based on the received routing information (e.g., BGP flowspec routes). Forwarding table entry 1 is remarked for the source address A:1::, and forwarding table entry 2 is iterated into SRv6 Group1 for packets with a color value of 10.

[0177] Specifically, BB1 parses the BGP Flowspec message from the controller and creates two forwarding entries. Forwarding entry 1: For traffic with a source address of A:1::, it performs a Remark action, i.e., remarking. Forwarding entry 2: For traffic with a color value of 10, it performs an iterative action to add it to SRv6 Group 1.

[0178] Step 4: Remark the source address A:1:: in the traffic, and mark the color value of the corresponding traffic as 10. BB1 checks the traffic with a color value of 10 and iterates it into the low latency tunnel plane. Check the destination address of the traffic. When the destination address is A:2::, it is automatically iterated to the SRv6 Policy1 tunnel for forwarding. When the destination address is A:3::, it is automatically iterated to the SRv6 Policy2 tunnel for forwarding.

[0179] Specifically, when a traffic packet arrives at BB1, BB1 checks the source address in the traffic. If the source address is A:1::, a remarking mechanism is triggered. The color value of the matching traffic is set to 10. This step ensures that subsequent processing can be based on this mark. BB1 then determines the destination address of the traffic packet: if the destination address is A:2::, BB1 looks up and forwards the corresponding traffic to the SRv6 Policy1 tunnel for low-latency access. If the destination address is A:3::, the corresponding traffic is forwarded to the SRv6 Policy2 tunnel.

[0180] See Figure 6 The embodiments of this application provide a traffic diversion control device, applied to a first network device, the device 600 including: a first transceiver unit 601 and a first processing unit 602;

[0181] The first processing unit 602 is used to establish a preset neighbor relationship with the second network device and obtain the traffic characteristics of the traffic.

[0182] The first processing unit 602 is further configured to generate routing information based on the traffic characteristics of the traffic, the routing information including at least one of the following: first information, the first information being used to indicate a remark action; second information, the second information being used to indicate the value of a remark color, the value of the color being used to determine to direct traffic to a specific tunnel;

[0183] The first transceiver unit 601 is used to send the routing information to the second network device.

[0184] In one implementation, the first transceiver unit 601 is further configured to send the routing information to the second network device via the extended BGP FLowspec protocol.

[0185] In one implementation, the extended BGP FLowspec protocol includes a remark subtype message format, wherein the field types of the remark subtype message format include at least one of the following: a subtype used to indicate a Remak action in the message; a flag used to indicate the content in the message; and a value of the flag.

[0186] Optionally, the routing information is used by the second network device to generate forwarding table entries, the forwarding table entries including at least one of the following: third information, the third information being used to indicate remarking for the traffic characteristics; fourth information, the fourth information being used to indicate that traffic with the value of the Remark color is directed to a specific tunnel.

[0187] In one embodiment, the tunnel includes at least one of the following: an SRv6 tunnel and an SRv6Group tunnel.

[0188] The apparatus provided in this application embodiment can achieve... Figure 2 The various processes implemented in the method embodiments shown achieve the same technical effects, and will not be described again here to avoid repetition.

[0189] See Figure 7 This application provides a traffic diversion control device applied to a second network device. The device 700 includes: a second transceiver unit 701 and a second processing unit 702.

[0190] The second processing unit 702 is used to receive traffic and obtain the traffic characteristics of the traffic.

[0191] The second processing unit 702 is further configured to remark the traffic based on the traffic characteristics and routing information of the traffic, wherein the routing information includes at least one of the following: first information, which is used to indicate the remark action; and second information, which is used to indicate the value of the remark color, wherein the value of the color is used to determine to guide the traffic to a specific tunnel.

[0192] The second processing unit 702 is further configured to determine the corresponding tunnel based on the color of the traffic remark;

[0193] The second transceiver unit 701 is used to forward the traffic through the tunnel.

[0194] In one embodiment, the second processing unit 702 is further configured to: determine the corresponding tunnel based on the color of the traffic remark and the traffic characteristics.

[0195] Optionally, based on the traffic characteristics and routing information, the traffic is remarked, including:

[0196] A forwarding table entry is generated based on the routing information. The forwarding table entry includes at least one of the following: third information, which is used to indicate remarking for the traffic characteristics; and fourth information, which is used to indicate that traffic with the value of the Remark color should be directed to a specific tunnel.

[0197] The traffic is remarked based on the forwarding entries and the traffic characteristics.

[0198] In one embodiment, the second transceiver unit 701 is further configured to: receive the routing information sent by the first network device.

[0199] In one embodiment, the tunnel includes at least one of the following: an SRv6 tunnel and an SRv6Group tunnel.

[0200] The apparatus provided in this application embodiment can achieve... Figure 3 The various processes implemented in the method embodiments shown achieve the same technical effects, and will not be described again here to avoid repetition.

[0201] like Figure 8 As shown, this application embodiment also provides a communication device 800, including a processor 801, a memory 802, and a program or instructions stored in the memory 802 and executable on the processor 801. When the program or instructions are executed by the processor 801, they implement the above-mentioned... Figure 2 or Figure 3 The various processes in the method embodiments can achieve the same technical effect. To avoid repetition, they will not be described again here.

[0202] This application embodiment also provides a readable storage medium storing a program or instructions that, when executed by a processor, implement the above-described functionality. Figure 2 or Figure 3 The various processes of the method embodiments shown can achieve the same technical effect, and will not be described again here to avoid repetition.

[0203] The processor mentioned above is the processor in the terminal described in the above embodiments. The readable storage medium includes computer-readable storage media, such as computer read-only memory (ROM), random access memory (RAM), magnetic disk, or optical disk.

[0204] The steps of the methods or algorithms described in this application can be implemented in hardware or by executing software instructions on a processor. The software instructions can consist of corresponding software modules, which can be stored in RAM, flash memory, ROM, EPROM, EEPROM, registers, hard disk, portable hard disk, read-only optical disk, or any other form of storage medium known in the art. An exemplary storage medium is coupled to the processor, enabling the processor to read information from and write information to the storage medium. Of course, the storage medium can also be a component of the processor. The processor and storage medium can be housed in an ASIC. Alternatively, the ASIC can be housed in a core network interface device. Of course, the processor and storage medium can also exist as discrete components in the core network interface device.

[0205] Those skilled in the art will recognize that, in one or more of the examples above, the functions described in this application can be implemented using hardware, software, firmware, or any combination thereof. When implemented in software, these functions can be stored in a computer-readable medium or transmitted as one or more instructions or code on a computer-readable medium. Computer-readable media include computer storage media and communication media, wherein communication media include any medium that facilitates the transfer of a computer program from one place to another. Storage media can be any available medium accessible to a general-purpose or special-purpose computer.

[0206] The specific embodiments described above further illustrate the purpose, technical solution, and beneficial effects of this application. It should be understood that the above description is only a specific embodiment of this application and is not intended to limit the scope of protection of this application. Any modifications, equivalent substitutions, improvements, etc., made on the basis of the technical solution of this application should be included within the scope of protection of this application.

[0207] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, embodiments of this application can take the form of entirely hardware embodiments, entirely software embodiments, or embodiments combining software and hardware aspects. Furthermore, embodiments of this application can take the form of computer program products implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0208] This application describes embodiments of methods, apparatus (systems), and computer program products according to embodiments of this application with reference to flowchart illustrations and / or block diagrams. It should be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0209] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.

[0210] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.

[0211] Obviously, those skilled in the art can make various modifications and variations to the embodiments of this application without departing from the spirit and scope of this application. Therefore, if these modifications and variations to the embodiments of this application fall within the scope of the claims of this application and their equivalents, this application also intends to include these modifications and variations.

Claims

1. A traffic diversion control method, applied to a first network device, characterized in that, include: Establish a preset neighbor relationship with the second network device to obtain the traffic characteristics of the traffic; Routing information is generated based on the traffic characteristics of the traffic, and the routing information includes at least one of the following: first information, which is used to indicate a remark action; second information, which is used to indicate the value of the remark color, and the value of the color is used to determine to direct traffic to a specific tunnel; The routing information is sent to the second network device.

2. The method according to claim 1, characterized in that, Sending the routing information to the second network device includes: The routing information is sent to the second network device via the Extended Border Gateway Protocol Flow Rules (BGP Flowspec) protocol.

3. The method according to claim 2, characterized in that, The extended BGP FLowspec protocol includes a remark subtype message format, wherein the field types of the remark subtype message format include at least one of the following: a subtype, the subtype being used to indicate a Remak action in the message; a flag, the flag being used to indicate the content in the message; and the value of the flag.

4. The method according to claim 1, characterized in that, The routing information is used by the second network device to generate forwarding table entries, the forwarding table entries including at least one of the following: third information, the third information being used to indicate remarking for the traffic characteristics; fourth information, the fourth information being used to indicate that traffic with the value of the Remark color is directed to a specific tunnel.

5. The method according to claim 1, characterized in that, The tunnel includes at least one of the following: a segment route SRv6 tunnel in the IPv6 forwarding plane, or an SRv6 group tunnel.

6. A traffic diversion control method, applied to a second network device, characterized in that, include: Receive traffic and obtain the traffic characteristics of the traffic; Based on the traffic characteristics and routing information of the traffic, the traffic is remarked. The routing information includes at least one of the following: first information, which is used to indicate the remark action; and second information, which is used to indicate the value of the remark color, which is used to determine to guide the traffic to a specific tunnel. The corresponding tunnel is determined based on the color of the traffic remark. The traffic is forwarded through the tunnel.

7. The method according to claim 6, characterized in that, Based on the traffic characteristics and routing information, the traffic is remarked, including: A forwarding table entry is generated based on the routing information. The forwarding table entry includes at least one of the following: third information, which is used to indicate remarking for the traffic characteristics; and fourth information, which is used to indicate that traffic with the value of the Remark color should be directed to a specific tunnel. The traffic is remarked based on the forwarding entries and the traffic characteristics.

8. The method according to claim 6, characterized in that, Based on the color of the traffic remark, the corresponding tunnel is determined, including: The corresponding tunnel is determined based on the color of the traffic remark and the traffic characteristics.

9. The method according to claim 6, characterized in that, The method further includes: Receive the routing information sent by the first network device.

10. The method according to claim 6, characterized in that, The tunnel includes at least one of the following: SRv6 tunnel, SRv6 group tunnel.

11. A traffic control device, applied to a first network device, characterized in that, include: First transceiver unit and first processing unit; The first processing unit is used to establish a preset neighbor relationship with the second network device and obtain the traffic characteristics of the traffic. The first processing unit is further configured to generate routing information based on the traffic characteristics of the traffic, the routing information including at least one of the following: first information, the first information being used to indicate a remark action; second information, the second information being used to indicate the value of a remark color, the value of the color being used to determine to direct traffic to a specific tunnel; The first transceiver unit is used to send the routing information to the second network device.

12. A traffic control device, applied to a second network device, characterized in that, include: Second transceiver unit and second processing unit: The second processing unit is used to receive traffic and obtain the traffic characteristics of the traffic; The second processing unit is further configured to remark the traffic based on the traffic characteristics and routing information of the traffic, wherein the routing information includes at least one of the following: first information, which is used to indicate the remark action; and second information, which is used to indicate the value of the remark color, wherein the value of the color is used to determine to guide the traffic to a specific tunnel. The second processing unit is further configured to determine the corresponding tunnel based on the color of the traffic remark; The second transceiver unit is used to forward the traffic through the tunnel.

13. A communication device, characterized in that, It includes a processor, a memory, and a program or instructions stored in the memory and executable on the processor, wherein the program or instructions, when executed by the processor, implement the steps of the method as claimed in any one of claims 1 to 10.

14. A readable storage medium, characterized in that, The readable storage medium stores a program or instructions that, when executed by a processor, implement the steps of the method as described in any one of claims 1 to 10.

15. A computer program product, characterized in that, It includes computer instructions that, when executed by a processor, implement the steps of the method as described in any one of claims 1 to 10.