WO2016150020A1 - Scheduling flow identifier-based packet scheduling method and device - Google Patents

Scheduling flow identifier-based packet scheduling method and device Download PDF

Info

Publication number
WO2016150020A1
WO2016150020A1 PCT/CN2015/082100 CN2015082100W WO2016150020A1 WO 2016150020 A1 WO2016150020 A1 WO 2016150020A1 CN 2015082100 W CN2015082100 W CN 2015082100W WO 2016150020 A1 WO2016150020 A1 WO 2016150020A1
Authority
WO
WIPO (PCT)
Prior art keywords
packet
flow identifier
scheduling
forwarding device
scheduling flow
Prior art date
Application number
PCT/CN2015/082100
Other languages
French (fr)
Chinese (zh)
Inventor
徐春松
钟炜
张树冲
蔡广平
Original Assignee
中兴通讯股份有限公司
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 中兴通讯股份有限公司 filed Critical 中兴通讯股份有限公司
Publication of WO2016150020A1 publication Critical patent/WO2016150020A1/en

Links

Images

Definitions

  • This document relates to the field of communications, and in particular, to a message scheduling method and apparatus based on a scheduling flow identifier.
  • QoS Quality of Service
  • the traffic classification uses certain rules to identify packets that meet certain characteristics. It is the premise and basis for differentiated services.
  • the traffic classification rule can use the priority bits of the ToS (Type of Service) field in the IP packet header to identify traffic with different priority characteristics.
  • the network administrator can also set the traffic classification policy, for example, through the integration. The source address, the destination address, the MAC (Media Access Control) address, the IP protocol, or the port number of the application are classified.
  • the purpose of traffic classification is to provide services in a differentiated manner.
  • the traffic classification is associated with the flow control or resource allocation actions to complete the Qos function.
  • the current QoS technology usually processes incoming messages, and then extracts message information that needs to be processed by TCAM (Ternary Content Addressable Memory) device or software algorithm. After the classification, traffic policing, traffic shaping, congestion management, and congestion avoidance are further processed, and such processing is required for each incoming message. This way is very wasteful of system resources and performance.
  • TCAM Ternary Content Addressable Memory
  • a device that is classified on a medium or high-end router or a packet forwarding device is usually a TCAM.
  • the classification of QoS requires a large key value, and the TCAM performance and space are limited. Each message comes in one or more TCAMs. Lookups can cause a drop in forwarding performance.
  • software algorithms are usually used to classify messages. However, there are many key values, and search also requires a certain amount of performance, which affects the performance of the entire system.
  • the embodiment of the invention provides a packet scheduling method and device based on a scheduling flow identifier, and the technical problem to be solved is how to simplify the processing complexity of the traffic classification.
  • the embodiment of the present invention provides the following technical solutions:
  • a packet scheduling method based on a scheduling flow identifier includes:
  • the forwarding device obtains the scheduling flow identifier corresponding to the next forwarding device of the packet in the forwarding path, in the process of forwarding the received packet.
  • the forwarding device adds the scheduling flow identifier to the packet
  • the forwarding device sends a packet including the scheduling flow identifier to the next forwarding device.
  • the forwarding device acquires a scheduling flow identifier corresponding to the next forwarding device of the packet on the forwarding path, including:
  • the forwarding device acquires packet feature information of the packet
  • the forwarding device searches for the scheduling flow identifier of the next forwarding device corresponding to the packet feature information of the packet according to the correspondence between the local pre-stored packet feature information and the scheduling flow identifier of the next forwarding device;
  • the forwarding device uses the found result as the scheduling flow identifier corresponding to the packet;
  • the forwarding device sends a query request to the next forwarding device, where the query request includes packet feature information of the packet; and receives a query response fed back by the next forwarding device,
  • the query response includes scheduling flow identification information of the packet.
  • the forwarding device adds the scheduling flow identifier to the packet, including:
  • the forwarding device adds a field after the Layer 2 protocol header of the packet, and adds the scheduling flow identifier to the added field.
  • a packet scheduling method based on a scheduling flow identifier includes:
  • the forwarding device After receiving the packet including the scheduling flow identifier, the forwarding device acquires the scheduling flow in the packet. Identification
  • the forwarding device performs a scheduling operation on the packet according to the scheduling flow identifier.
  • the method further includes:
  • the forwarding device acquires a scheduling flow identifier corresponding to the next forwarding device of the packet on the forwarding path;
  • the forwarding device replaces the forwarding identifier in the packet with the scheduling stream identifier corresponding to the next forwarding device;
  • the forwarding device sends the packet that has been replaced by the scheduled flow identifier.
  • a message scheduling device based on a scheduling flow identifier comprising:
  • the first obtaining module is configured to: in the process of scheduling the received packet, obtain the scheduling flow identifier corresponding to the next forwarding device of the packet in the forwarding path;
  • Adding a module configured to add the scheduling flow identifier to the packet
  • the first sending module is configured to send a packet including the scheduling flow identifier to the next forwarding device.
  • the first acquiring module includes:
  • An obtaining unit configured to obtain message feature information of the packet
  • the search unit is configured to search for a scheduling flow identifier of the next forwarding device corresponding to the packet feature information of the packet according to the correspondence between the local pre-stored packet feature information and the scheduling flow identifier of the next forwarding device;
  • a first determining unit configured to: if found, the forwarding device uses the found result as a scheduling flow identifier corresponding to the packet;
  • a sending unit configured to send a query request to the next forwarding device if not found, where the query request includes message feature information of the packet;
  • the receiving unit is configured to receive a query response fed back by the next forwarding device, where the query response includes scheduling flow identification information of the packet.
  • the adding module is configured to: add a field after the Layer 2 protocol header of the packet, and add the scheduling flow identifier to the added field.
  • a message scheduling device based on a scheduling flow identifier comprising:
  • the second obtaining module is configured to: after receiving the packet that includes the scheduling flow identifier, obtain the scheduling flow identifier in the packet;
  • the scheduling module is configured to perform a scheduling operation on the packet according to the scheduling flow identifier.
  • the apparatus further includes:
  • a third acquiring module configured to obtain a scheduling flow identifier corresponding to a next forwarding device of the packet on the forwarding path;
  • the replacement module is configured to replace the forwarding identifier in the packet with the scheduling flow identifier corresponding to the next forwarding device;
  • the second sending module is configured to send the packet after the completion of the scheduling flow identifier is replaced.
  • a computer storage medium having stored therein computer executable instructions for performing the methods described above.
  • the forwarding device adds the scheduling flow identifier of the packet on the next forwarding device in the forwarding path to the next forwarding device, and reduces the feature information of the next forwarding device to parse the packet again.
  • Obtaining the time of the scheduling flow identifier corresponding to the packet improves the information processing efficiency and reduces the hardware consumption.
  • FIG. 1 is a flowchart of a packet scheduling method based on a scheduling flow identifier according to an embodiment of the present disclosure
  • FIG. 2 is a flowchart of another method for scheduling a packet based on a scheduling flow identifier according to an embodiment of the present disclosure
  • FIG. 3 is a schematic structural diagram of a header of a packet in a scheduling flow identifier request distribution protocol according to an embodiment of the present disclosure
  • FIG. 4 is a structural diagram of a message body of a message in a scheduling flow identifier request distribution protocol according to an embodiment of the present invention
  • FIG. 5 is a schematic diagram of comparison of packet formats according to an embodiment of the present invention.
  • FIG. 6 is a schematic structural diagram of a scheduling flow identifier field according to an embodiment of the present disclosure.
  • FIG. 7 is a schematic diagram of an Ethernet network according to an embodiment of the present invention.
  • FIG. 8 is a schematic diagram of a packet format change in a packet process based on a scheduling flow identifier in an Ethernet network according to an embodiment of the present disclosure
  • FIG. 9 is a schematic diagram of a format of a packet encapsulated by a forwarding device R1 according to an embodiment of the present disclosure.
  • FIG. 10 is a structural diagram of a packet scheduling apparatus based on a scheduling flow identifier according to an embodiment of the present disclosure
  • FIG. 11 is a structural diagram of another packet scheduling apparatus based on a scheduling flow identifier according to an embodiment of the present invention.
  • FIG. 1 is a flowchart of a packet scheduling method based on a scheduling flow identifier according to an embodiment of the present invention. The method shown in Figure 1 includes:
  • Step 101 The forwarding device acquires a scheduling flow identifier corresponding to the next forwarding device of the packet in the forwarding path, in the process of scheduling the received packet.
  • Step 102 The forwarding device adds the scheduling flow identifier to the packet.
  • Step 103 The forwarding device sends a packet including the scheduling flow identifier to the next forwarding device.
  • the forwarding device in the process of processing the packet, obtains the scheduling flow identifier of the next forwarding device on the forwarding path by using the result of the local processing, and the scheduling is performed.
  • the flow identifier is carried to the next forwarding device, which reduces the time for the next forwarding device to parse the packet feature information again to obtain the scheduling flow identifier corresponding to the packet, thereby improving information processing efficiency and reducing hardware consumption.
  • FIG. 2 is a flowchart of another method for scheduling a message based on a scheduling flow identifier according to an embodiment of the present invention.
  • the method shown in Figure 2 includes:
  • Step 201 After receiving the packet including the scheduling flow identifier, the forwarding device acquires the scheduling flow identifier in the packet.
  • Step 202 The forwarding device performs a scheduling operation on the packet according to the scheduling flow identifier.
  • the forwarding device uses the scheduling flow identifier in the packet to schedule the packet, and does not need to parse the feature information of the packet again to obtain the scheduling flow identifier, so that the packet scheduling can be completed, thereby saving local
  • the scheduling time improves the efficiency of information processing and reduces hardware consumption.
  • the forwarding device obtains the scheduling flow identifier corresponding to the next forwarding device of the packet on the forwarding path, including:
  • the forwarding device acquires packet feature information of the packet
  • the forwarding device searches for the scheduling flow identifier corresponding to the packet feature information of the packet according to the correspondence between the locally stored packet feature information and the scheduling flow identifier;
  • the forwarding device uses the found result as the scheduling flow identifier corresponding to the packet;
  • the forwarding device sends a query request to the next forwarding device, where the query request includes packet feature information of the packet; and receives a query response fed back by the next forwarding device,
  • the query response includes scheduling flow identification information of the packet.
  • the packet feature information may be information such as an integrated source address, a destination address, a MAC address, a label exp, an IP protocol, or an application port number.
  • the correspondence between the packet feature information and the scheduling flow identifier is obtained by:
  • the forwarding device requests the next forwarding device to obtain the corresponding scheduling flow identifier of the packet feature information on the next forwarding device;
  • the next forwarding device After receiving the request, the next forwarding device feeds back the information of the local traffic classification, and feeds back the scheduling flow identifier corresponding to the feature information to the forwarding device.
  • the forwarding device After the forwarding device obtains the packet flow information corresponding to the scheduling flow identifier corresponding to the next forwarding device, the corresponding relationship between the two is saved for subsequent use.
  • the scheduling flow identifier request distribution protocol is based on the TCP protocol (the port number is a temporary port number of 1024-5000), and the scheduling flow identifier request distribution protocol is divided into a scheduling flow identifier request packet and a scheduling flow identifier response packet, and the packet header is sent by the header.
  • the department and the message body are composed of two parts.
  • FIG. 3 is a schematic structural diagram of a header of a message in a scheduling flow identifier request distribution protocol according to an embodiment of the present invention.
  • the protocol header shown in Figure 3 has a total of 8 bytes, each of which is described as follows:
  • Version 1 byte, used to identify the version of the dispatch stream identifier request distribution protocol.
  • Protocol payload length 2 bytes, the total length of the protocol payload, excluding the protocol header length.
  • Message Type Identifies the packet type. The request is 0 and the response is 1.
  • Request number 3 bytes are used to identify the request. (The attachment protocol format has been modified)
  • FIG. 4 is a structural diagram of a message body of a message in a scheduling flow identifier request distribution protocol according to an embodiment of the present invention.
  • the message body shown in Figure 4 consists of a type, length, and value (Type, Length, Value, TLV) format. The description of each of these fields is as follows:
  • Type field indicating the content of the following fields, such as source IP, destination IP, source port number, destination port, and so on.
  • Length A length field that identifies the length of a group of TLVs.
  • Value corresponds to the value of the attribute. The specific length is determined according to the attribute. For example, Type is an IP address, then Value is 4 bytes. If Type is the destination mac, then it is 6 bytes, and the attribute is less than one byte. One byte indicates that the value of exp is 1 byte.
  • 0 The value of the scheduled flow identifier to be returned. Currently, the specific value of the scheduled flow identifier is 2 bytes.
  • the forwarding device adds the scheduling flow identifier to the packet, including:
  • the forwarding device adds a field after the Layer 2 protocol header of the packet, and adds the scheduling flow identifier to the added field.
  • the Ethernet packet is used as an example.
  • the added field is located between the packet header field and the IP header field of the Ethernet packet.
  • the IP packet is used as an example.
  • the added field is located between the IP header field and the data segment field.
  • FIG. 5 is a schematic diagram of comparison of packet formats according to an embodiment of the present invention.
  • the first packet format is the original packet format
  • the second packet format is the processed packet format.
  • the "Scheduled Flow Identifier" field is inserted between the Layer 2 Ethernet Header and the Layer 3 IP, so that the next forwarding device can directly search for the corresponding schedule according to the value of the "Scheduled Flow Identifier" field.
  • Information perform scheduling actions.
  • a corresponding protocol field is added in the Ethernet header to identify a packet with a scheduling flow identifier, and a flow identifier value may be added in the scheduling flow identifier field to increase the upper protocol type. Value, which is convenient for the device to parse the message.
  • FIG. 6 is a schematic structural diagram of a scheduling flow identifier field according to an embodiment of the present invention.
  • the schematic diagram shown in FIG. 6 includes a scheduling flow identifier and upper layer protocol number information.
  • the upper layer protocol number information is used to indicate data protocol information corresponding to the data of the subsequent field.
  • the forwarding device of the next forwarding device acquires the scheduling flow identifier corresponding to the next forwarding device of the packet on the forwarding path;
  • the forwarding device replaces the forwarding identifier in the packet with the scheduling stream identifier corresponding to the next forwarding device;
  • the forwarding device sends the packet that has been replaced by the scheduled flow identifier.
  • FIG. 7 is a schematic diagram of an Ethernet network according to an embodiment of the present invention.
  • R1, R2, and R3 are three forwarding devices on the forwarding path.
  • the packets are forwarded from R1 to R2, and R2 forwards them to R3.
  • R3 forwards them again.
  • QoS processing is performed on R1, R2, and R3, it is classified according to information such as source address, destination address, MAC address, label exp, IP protocol, or application port number, and then scheduled.
  • the packets are forwarded through R1, R2, and R3, and the three forwarding devices perform protocol interaction and negotiation in advance, so that the output packet format on the forwarding device changes. .
  • FIG. 8 is a schematic diagram of a packet format change in a packet process based on a scheduling flow identifier in an Ethernet network according to an embodiment of the present invention.
  • the packet forwarding path is R1->R2->R3, then R1 is the upstream device of R2, and R2 is the downstream device of R1. Others are similar.
  • the following figure illustrates the process of scheduling flow identification request and distribution, and requests are distributed from upstream to downstream.
  • the message format becomes the "processed message" in the figure (that is, the output message of R1), and after R2 processing, Replace the "scheduling flow identifier" in the input message with the corresponding local "scheduling flow identifier" (R3 assigned to R2), and then send it to R3, and R3 performs a similar action on R2.
  • R2, R3, and subsequent forwarding devices do not need to be classified according to information such as source address, destination address, MAC address, label exp, IP protocol, or application port number, but can be directly based on the pre-allocated scheduling stream identifier. Perform the correct scheduling action.
  • the processing method in the related art is that the forwarding device needs to be identified according to the characteristics of the message, and this operation step is very cost-effective. In addition, it is considered that the same type of packets on the network are always persistent for a certain period of time. In the related art, even if the packets of the same type are received, the forwarding device repeatedly recognizes the packets according to the characteristics of the packets. The action of classification. Different from the related art, the embodiment of the present invention identifies the flow in advance through the interaction on the control plane protocol, and the upstream forwarding device The scheduling flow identifier is sent to the downstream forwarding device.
  • the downstream forwarding device does not need to perform the classification action by using the scheduling flow identification information, and does not need to identify each packet one by one when it is the same type of packet for a period of time. Because the scheduled flow identifier requested by the upstream device is a preparatory action for triggering the downstream device to perform the corresponding scheduling mode of the device, the prepared action avoids the persistent classification action that is originally necessary.
  • the forwarding device detects that the scheduling identifier carried in the received packet changes, the packet is scheduled according to the newly obtained scheduling flow identifier in a preset time.
  • the scheduled flow identifier of the previously obtained packet is A, and the currently received scheduling flow identifier becomes B, according to the law of data transmission in the network, the received packet is received in the next one end time.
  • the packet feature information is the same. Therefore, the scheduling flow identifier of the subsequent packets is also B. Therefore, the forwarding device does not need to identify the packet characteristics one by one, which reduces the processing pressure of the forwarding device and reduces hardware consumption.
  • the communication between the forwarding device R1 and the forwarding device R2 is taken as an example for description:
  • Steps A01 and R1 enable the functions of the embodiment of the present invention, and configure the entry quintuple information such as: the destination IP address is 200.1.1.10, the source IP address is 210.1.1.10, the protocol number is UDP, the source port number is 1000, and the destination port number is It is 1000.
  • Steps A02 and R1 process the message to obtain the characteristics of the output message. For example, if the quintuple information remains unchanged and a layer of tag information is added, then R1 puts the quintuple information and the tag value (for example, 1200) and exp (for example, 1) into the request message of the scheduling flow identification request distribution protocol. , sent to the next hop device R2.
  • the quintuple information remains unchanged and a layer of tag information is added
  • R1 puts the quintuple information and the tag value (for example, 1200) and exp (for example, 1) into the request message of the scheduling flow identification request distribution protocol. , sent to the next hop device R2.
  • Steps A03 and R2 receive the received packet feature information, obtain an index of the corresponding local scheduling classification entry according to the actual forwarding process, and send the index as a scheduling flow identifier in the response packet of the scheduling flow identifier request distribution protocol.
  • R1 is L2 in the above figure, and the specific value is, for example, 0x1200.
  • This classification is the same as the normal classification implementation (eg using TCAM).
  • Step A05 When R1 receives the feature traffic from the interface (the destination IP address of the quintuple information is 200.1.1.10, the source IP address is 210.1.1.10, the protocol number is UDP, the source port number is 1000, and the destination port number is 1000.
  • the classification is performed, the scheduling flow identifier in the classification table is obtained, and then encapsulated into the packet. .
  • FIG. 9 is a schematic diagram of a format of a packet encapsulated by a forwarding device R1 according to an embodiment of the present invention.
  • 0x1200 is the scheduling flow identifier of the downstream branch
  • 0x0800 is the protocol number of the upper layer protocol.
  • Steps A06 and R1 send the message.
  • the embodiment of the invention implements a method for distributing a scheduling flow identifier in a network, and performing QoS scheduling based on the distributed scheduling flow identifier.
  • the main implementation steps are as follows:
  • Embodiment 1 is a diagrammatic representation of Embodiment 1:
  • Step 1 Enable the function of distributing the scheduling flow identifier and performing the QoS scheduling based on the distributed scheduling flow identifier on each forwarding device.
  • Step 2 Configure the stream characteristics to be processed, such as the source address, the destination address, the MAC address, the label exp, the IP protocol, or the port number of the application, on the entire forwarding path upstream device R1. It can be either an entry or an outgoing message feature.
  • Step 3 If it is an inbound packet feature, the upstream device R1 processes the packet characteristics of the egress, and then carries the packet feature field to send a request to the downstream device R2 to request distribution of the scheduling flow identifier. If the egress message feature is configured, the downstream device is directly requested to distribute the scheduling flow identifier.
  • Step 4 R1 downstream device R2 receives the request of the upstream device, generates a scheduling flow identifier L2 as a response and sends it to the upstream device R1, and obtains the egress packet feature of the device according to the ingress packet processing, and then sends the egress packet feature of the device to the downstream device R3.
  • the request to dispatch the flow identifier is distributed, and R3 responds to the request, so that R2 also obtains the dispatch flow identifier L3 allocated by R3, and R2 associates the dispatch flow identifier L3 with the dispatch flow identifier L2 that is sent to R1 by itself. That is, L3 can be found according to L2.
  • each device associates the scheduling flow identifier assigned to the upstream device with its own scheduling action, that is, the scheduling action can be found according to the scheduling flow identifier.
  • Step 5 The devices on the forwarding path perform similar functions until the last forwarding device, and the scheduling flow identifier is distributed.
  • Step 6 Receive a packet on R1 to find out whether it is a configured flow feature. If yes, the L2 scheduling flow identifier is encapsulated in the normal forwarding process, and then forwarded to R2.
  • R2 parses the packet according to the protocol number, and then finds the associated scheduling action according to L2, performs scheduling, and sends the packet. When you replace L2 with an L3 tag, send it to R2.
  • Step 7 R3 performs an R2-like action until the message is forwarded to the destination.
  • the devices dynamically negotiate the allocation of the scheduling flow identifiers through the protocol, and perform scheduling according to the scheduling flow identifier.
  • Embodiment 2 is a diagrammatic representation of Embodiment 1:
  • the present embodiment is such that the manner is completed by static configuration.
  • the specific instructions are as follows:
  • Step 1 Each forwarding device enables distribution of the scheduling flow identifier, and performs QoS scheduling based on the distributed scheduling flow identifier.
  • Step 2 Configure flow characteristics on each device and specify the dispatch flow identifier to be distributed to the upstream device.
  • the outbound encapsulated scheduling flow identifier L1 is specified for the particular flow.
  • the scheduled flow identifier L1 of the ingress and the scheduled flow identifier L2 of the egress are configured, and the ingress scheduling flow identifier L2 is configured on R3.
  • R2 and R3 associate the scheduling action with the ingress scheduling flow identifier.
  • Step 3 The packet enters R1, and R1 encapsulates the configured scheduling flow identifier L1 when forwarding the packet according to the flow characteristics and configuration.
  • Step 4 Relevant scheduling is performed according to L1 on R2, and L2 is sent to R3 on the egress package.
  • Step 5 R3 receives the packet, similar to R2 for related scheduling, forwarding, and the like.
  • the forwarding device performs the interaction, assigns a specific identifier to a specific flow, and sends a request message of the scheduling flow identifier requesting the distribution protocol to the downstream device.
  • the downstream device convects the flow according to the processing of the device. Assigning a specific identifier, and then notifying the upstream forwarding device by sending a response packet of the scheduling distribution identifier requesting the distribution protocol, so that the upstream forwarding device encapsulates the specific scheduling flow identifier into the packet when processing the packet.
  • the downstream forwarding device is sent to the downstream forwarding device, and the downstream forwarding device can directly perform related action processing and scheduling according to the scheduling flow identifier, without performing classification processing, thereby improving processing performance and even saving hardware devices such as TCAM.
  • FIG. 10 is a structural diagram of a message scheduling apparatus based on a scheduling flow identifier according to an embodiment of the present invention.
  • the device shown in Figure 10 includes:
  • the first obtaining module 1001 is configured to: in the process of processing the received packet, obtain a scheduling flow identifier corresponding to the next forwarding device of the packet in the forwarding path;
  • the adding module 1002 is configured to add the scheduling flow identifier to the packet.
  • the first sending module 1003 is configured to send a packet including the scheduling flow identifier to the next forwarding device.
  • the first obtaining module 1001 includes:
  • An obtaining unit configured to obtain message feature information of the packet
  • the searching unit searches for the scheduling flow identifier of the next forwarding device corresponding to the packet feature information of the packet according to the correspondence between the local pre-stored packet feature information and the scheduling flow identifier of the next forwarding device;
  • a first determining unit configured to: if found, the forwarding device uses the found result as a scheduling flow identifier corresponding to the packet;
  • a sending unit configured to send a query request to the next forwarding device if not found, where the query request includes message feature information of the packet;
  • the receiving unit is configured to receive a query response fed back by the next forwarding device, where the query response includes message feature information of the packet.
  • the adding module 1002 is configured to: add a field after the Layer 2 protocol header of the packet, and add the scheduling flow identifier to the added field.
  • the device provided by the embodiment of the present invention obtains the scheduling flow identifier of the next forwarding device on the forwarding path by using the result of the local scheduling process in the process of scheduling the packet, and identifies the scheduling flow identifier.
  • the notification is sent to the next forwarding device, which reduces the time for the next forwarding device to parse the packet feature information again to obtain the scheduling flow identifier corresponding to the packet, which improves the information processing efficiency and reduces the hardware consumption.
  • FIG. 11 is another packet scheduling device based on a scheduling flow identifier according to an embodiment of the present invention. Structure diagram. The device shown in Figure 11 includes:
  • the second obtaining module 1101 is configured to: after receiving the packet that includes the scheduling flow identifier, obtain the scheduling flow identifier in the packet;
  • the scheduling module 1102 is configured to perform a scheduling operation on the packet according to the scheduling flow identifier.
  • the device further comprises:
  • a third acquiring module configured to obtain a scheduling flow identifier corresponding to a next forwarding device of the packet on the forwarding path;
  • the replacement module is configured to replace the forwarding identifier in the packet with the scheduling flow identifier corresponding to the next forwarding device;
  • the second sending module is configured to send the packet after the completion of the scheduling flow identifier is replaced.
  • the device provided by the embodiment of the present invention in the process of processing the packet, obtains the scheduling flow identifier of the next forwarding device on the forwarding path by using the result of the local processing, and carries the scheduling flow identifier
  • the next forwarding device is used to reduce the time when the next forwarding device parses the packet feature information to obtain the scheduling flow identifier corresponding to the packet, which improves information processing efficiency and reduces hardware consumption.
  • all or part of the steps of the above embodiments may also be implemented by using an integrated circuit. These steps may be separately fabricated into individual integrated circuit modules, or multiple modules or steps may be fabricated into a single integrated circuit module. achieve. Thus, the invention is not limited to any specific combination of hardware and software.
  • the devices/function modules/functional units in the above embodiments may be implemented by a general-purpose computing device, which may be centralized on a single computing device or distributed over a network of multiple computing devices.
  • each device/function module/functional unit in the above embodiment When each device/function module/functional unit in the above embodiment is implemented in the form of a software function module and sold or used as a stand-alone product, it can be stored in a computer readable storage medium.
  • the above mentioned computer readable storage medium may be a read only memory, a magnetic disk or an optical disk or the like.
  • the foregoing technical solution reduces the time for the next forwarding device to parse the packet feature information again to obtain the scheduling flow identifier corresponding to the packet, thereby improving information processing efficiency and reducing hardware consumption.

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

A scheduling flow identifier-based packet scheduling method and device, the method comprising: during forwarding processing of a received packet, a forwarding device obtains a corresponding scheduling flow identifier of a next forwarding device of a packet in a forwarding path; the forwarding device adds the scheduling flow identifier to the packet; the forwarding device sends the packet comprising the scheduling flow identifier to the next forwarding device. The present technical solution reduces the time wherein the next forwarding device analyses packet feature information once again so as to obtain the corresponding scheduling flow identifier of the packet, thereby increasing information processing efficiency, and reducing hardware consumption.

Description

基于调度流标识的报文调度方法和装置Message scheduling method and device based on scheduling flow identifier 技术领域Technical field
本文涉及通信领域,尤其涉及一种基于调度流标识的报文调度方法和装置。This document relates to the field of communications, and in particular, to a message scheduling method and apparatus based on a scheduling flow identifier.
背景技术Background technique
QoS(Quality of Service,服务质量)是用来解决网络延迟和阻塞等问题的一种技术,其为指定的网络通信提供更好的服务能力。QoS功能包括流分类、访问控制、流量监管、流量整形、拥塞管理和拥塞避免。其中流分类采用一定的规则识别符合某类特征的报文,它是有区别地进行服务的前提和基础。流分类规则可以使用IP报文头中ToS(Type of Service,服务类型)字段的优先级位,识别出有不同优先级特征的流量;也可以由网络管理者设置流分类的策略,例如通过综合源地址、目的地址、MAC(Media Access Control,媒体访问控制)地址、IP协议或应用程序的端口号等信息对流进行分类。进行流分类的目的就是为了有区别地提供服务,流分类与流控或资源分配动作关联起来共同完成了Qos功能。QoS (Quality of Service) is a technology used to solve problems such as network delay and congestion, which provides better service capabilities for designated network communications. QoS features include traffic classification, access control, traffic policing, traffic shaping, congestion management, and congestion avoidance. The traffic classification uses certain rules to identify packets that meet certain characteristics. It is the premise and basis for differentiated services. The traffic classification rule can use the priority bits of the ToS (Type of Service) field in the IP packet header to identify traffic with different priority characteristics. The network administrator can also set the traffic classification policy, for example, through the integration. The source address, the destination address, the MAC (Media Access Control) address, the IP protocol, or the port number of the application are classified. The purpose of traffic classification is to provide services in a differentiated manner. The traffic classification is associated with the flow control or resource allocation actions to complete the Qos function.
关于流分类,目前的QoS技术通常是对进入的报文进行处理,然后提取需要关心的报文信息通过TCAM(Ternary Content Addressable Memory,三态内容寻址存储器)器件或者软件算法等进行报文分类,分类后进一步进行流量监管、流量整形、拥塞管理和拥塞避免等处理,每进来一个报文都需要进行这样的处理。这样的方式是非常浪费系统资源和性能的。例如,在中、高端路由器或者分组转发设备上进行分类的器件通常是TCAM,QoS的分类需要较大的键值,TCAM性能、空间都有限,每个报文进来都进行一次或者多次的TCAM查找会导致转发性能下降。在一些低、中端设备上,通常采用软件算法来实现报文的分类,但键值很多,搜索也需要耗费一定的性能,从而影响整个系统的性能。Regarding flow classification, the current QoS technology usually processes incoming messages, and then extracts message information that needs to be processed by TCAM (Ternary Content Addressable Memory) device or software algorithm. After the classification, traffic policing, traffic shaping, congestion management, and congestion avoidance are further processed, and such processing is required for each incoming message. This way is very wasteful of system resources and performance. For example, a device that is classified on a medium or high-end router or a packet forwarding device is usually a TCAM. The classification of QoS requires a large key value, and the TCAM performance and space are limited. Each message comes in one or more TCAMs. Lookups can cause a drop in forwarding performance. On some low- and medium-end devices, software algorithms are usually used to classify messages. However, there are many key values, and search also requires a certain amount of performance, which affects the performance of the entire system.
因此,如何简化流分类的处理复杂度是亟待解决的问题。 Therefore, how to simplify the processing complexity of stream classification is an urgent problem to be solved.
发明内容Summary of the invention
本发明实施例提供一种基于调度流标识的报文调度方法和装置,要解决的技术问题是如何简化流分类的处理复杂度。The embodiment of the invention provides a packet scheduling method and device based on a scheduling flow identifier, and the technical problem to be solved is how to simplify the processing complexity of the traffic classification.
为解决上述技术问题,本发明实施例提供了如下技术方案:In order to solve the above technical problem, the embodiment of the present invention provides the following technical solutions:
一种基于调度流标识的报文调度方法,包括:A packet scheduling method based on a scheduling flow identifier includes:
转发设备在对接收到的报文进行转发处理过程中,获取所述报文在转发路径的下一转发设备对应的调度流标识;The forwarding device obtains the scheduling flow identifier corresponding to the next forwarding device of the packet in the forwarding path, in the process of forwarding the received packet.
所述转发设备在所述报文中增加所述调度流标识;The forwarding device adds the scheduling flow identifier to the packet;
所述转发设备向所述下一转发设备发送包括所述调度流标识的报文。The forwarding device sends a packet including the scheduling flow identifier to the next forwarding device.
在上述方法的一种实施方式中,所述转发设备获取所述报文在转发路径上的下一转发设备对应的调度流标识,包括:In an implementation manner of the foregoing method, the forwarding device acquires a scheduling flow identifier corresponding to the next forwarding device of the packet on the forwarding path, including:
所述转发设备获取所述报文的报文特征信息;The forwarding device acquires packet feature information of the packet;
所述转发设备根据本地预先存储的报文特征信息与下一转发设备的调度流标识的对应关系,查找所述报文的报文特征信息对应的下一转发设备的调度流标识;And the forwarding device searches for the scheduling flow identifier of the next forwarding device corresponding to the packet feature information of the packet according to the correspondence between the local pre-stored packet feature information and the scheduling flow identifier of the next forwarding device;
如果查找到,则所述转发设备将查找到的结果作为所述报文对应的调度流标识;If found, the forwarding device uses the found result as the scheduling flow identifier corresponding to the packet;
如果未查找到,则所述转发设备向所述下一转发设备发送查询请求,其中所述查询请求包括所述报文的报文特征信息;并接收所述下一转发设备反馈的查询响应,其中所述查询响应包括所述报文的调度流标识信息。If not found, the forwarding device sends a query request to the next forwarding device, where the query request includes packet feature information of the packet; and receives a query response fed back by the next forwarding device, The query response includes scheduling flow identification information of the packet.
在上述方法的一种实施方式中,所述转发设备在所述报文中增加所述调度流标识,包括:In an implementation manner of the foregoing method, the forwarding device adds the scheduling flow identifier to the packet, including:
所述转发设备在所述报文的二层协议头后增加一个字段,并在增加的字段中增加所述调度流标识。The forwarding device adds a field after the Layer 2 protocol header of the packet, and adds the scheduling flow identifier to the added field.
一种基于调度流标识的报文调度方法,包括:A packet scheduling method based on a scheduling flow identifier includes:
转发设备在接收到包括调度流标识的报文后,获取所述报文中的调度流 标识;After receiving the packet including the scheduling flow identifier, the forwarding device acquires the scheduling flow in the packet. Identification
所述转发设备根据所述调度流标识,对所述报文进行调度操作。The forwarding device performs a scheduling operation on the packet according to the scheduling flow identifier.
在上述方法的一种实施方式中,所述方法还包括:In an embodiment of the above method, the method further includes:
所述转发设备获取所述报文在转发路径上的下一转发设备对应的调度流标识;The forwarding device acquires a scheduling flow identifier corresponding to the next forwarding device of the packet on the forwarding path;
所述转发设备将所述报文中的转发标识替换为所述下一转发设备对应的调度流标识;The forwarding device replaces the forwarding identifier in the packet with the scheduling stream identifier corresponding to the next forwarding device;
所述转发设备将完成调度流标识替换后的报文发送出去。The forwarding device sends the packet that has been replaced by the scheduled flow identifier.
一种基于调度流标识的报文调度装置,包括:A message scheduling device based on a scheduling flow identifier, comprising:
第一获取模块,设置为在对接收到的报文进行调度过程中,获取所述报文在转发路径的下一转发设备对应的调度流标识;The first obtaining module is configured to: in the process of scheduling the received packet, obtain the scheduling flow identifier corresponding to the next forwarding device of the packet in the forwarding path;
增加模块,设置为在所述报文中增加所述调度流标识;Adding a module, configured to add the scheduling flow identifier to the packet;
第一发送模块,设置为向所述下一转发设备发送包括所述调度流标识的报文。The first sending module is configured to send a packet including the scheduling flow identifier to the next forwarding device.
在上述装置的一种实施方式中,所述第一获取模块包括:In an implementation manner of the foregoing apparatus, the first acquiring module includes:
获取单元,设置为获取所述报文的报文特征信息;An obtaining unit, configured to obtain message feature information of the packet;
查找单元,设置为根据本地预先存储的报文特征信息与下一转发设备的调度流标识的对应关系,查找所述报文的报文特征信息对应的下一转发设备的调度流标识;The search unit is configured to search for a scheduling flow identifier of the next forwarding device corresponding to the packet feature information of the packet according to the correspondence between the local pre-stored packet feature information and the scheduling flow identifier of the next forwarding device;
第一确定单元,设置为如果查找到,则所述转发设备将查找到的结果作为所述报文对应的调度流标识;a first determining unit, configured to: if found, the forwarding device uses the found result as a scheduling flow identifier corresponding to the packet;
发送单元,设置为如果未查找到,则向所述下一转发设备发送查询请求,其中所述查询请求包括所述报文的报文特征信息;a sending unit, configured to send a query request to the next forwarding device if not found, where the query request includes message feature information of the packet;
接收单元,设置为接收所述下一转发设备反馈的查询响应,其中所述查询响应包括所述报文的调度流标识信息。The receiving unit is configured to receive a query response fed back by the next forwarding device, where the query response includes scheduling flow identification information of the packet.
在上述装置的一种实施方式中,所述增加模块是设置为:在所述报文的二层协议头后增加一个字段,并在增加的字段中增加所述调度流标识。 In an implementation manner of the foregoing apparatus, the adding module is configured to: add a field after the Layer 2 protocol header of the packet, and add the scheduling flow identifier to the added field.
一种基于调度流标识的报文调度装置,包括:A message scheduling device based on a scheduling flow identifier, comprising:
第二获取模块,设置为在接收到包括调度流标识的报文后,获取所述报文中的调度流标识;The second obtaining module is configured to: after receiving the packet that includes the scheduling flow identifier, obtain the scheduling flow identifier in the packet;
调度模块,设置为根据所述调度流标识,对所述报文进行调度操作。The scheduling module is configured to perform a scheduling operation on the packet according to the scheduling flow identifier.
在上述装置的一种实施方式中,所述装置还包括:In an embodiment of the above apparatus, the apparatus further includes:
第三获取模块,设置为获取所述报文在转发路径上的下一转发设备对应的调度流标识;a third acquiring module, configured to obtain a scheduling flow identifier corresponding to a next forwarding device of the packet on the forwarding path;
替换模块,设置为将所述报文中的转发标识替换为所述下一转发设备对应的调度流标识;The replacement module is configured to replace the forwarding identifier in the packet with the scheduling flow identifier corresponding to the next forwarding device;
第二发送模块,设置为将完成调度流标识替换后的报文发送出去。The second sending module is configured to send the packet after the completion of the scheduling flow identifier is replaced.
一种计算机存储介质,所述计算机存储介质中存储有计算机可执行指令,所述计算机可执行指令用于执行上述的方法。A computer storage medium having stored therein computer executable instructions for performing the methods described above.
本发明实施例,转发设备在报文中添加该报文在转发路径上的下一转发设备上的调度流标识并发送给下一转发设备,减少了下一个转发设备再次解析报文特征信息以获取该报文对应的调度流标识的时间,提高了信息处理效率,降低了硬件的消耗。In the embodiment of the present invention, the forwarding device adds the scheduling flow identifier of the packet on the next forwarding device in the forwarding path to the next forwarding device, and reduces the feature information of the next forwarding device to parse the packet again. Obtaining the time of the scheduling flow identifier corresponding to the packet improves the information processing efficiency and reduces the hardware consumption.
附图概述BRIEF abstract
图1为本发明实施例提供的一种基于调度流标识的报文调度方法的流程图;FIG. 1 is a flowchart of a packet scheduling method based on a scheduling flow identifier according to an embodiment of the present disclosure;
图2为本发明实施例提供的另一种基于调度流标识的报文调度方法的流程图;FIG. 2 is a flowchart of another method for scheduling a packet based on a scheduling flow identifier according to an embodiment of the present disclosure;
图3为本发明实施例提供的调度流标识请求分发协议中报文的头部结构图;FIG. 3 is a schematic structural diagram of a header of a packet in a scheduling flow identifier request distribution protocol according to an embodiment of the present disclosure;
图4为本发明实施例提供的调度流标识请求分发协议中报文的消息体的结构图; 4 is a structural diagram of a message body of a message in a scheduling flow identifier request distribution protocol according to an embodiment of the present invention;
图5为本发明实施例提供的报文格式的对比示意图;FIG. 5 is a schematic diagram of comparison of packet formats according to an embodiment of the present invention;
图6为本发明实施例提供的调度流标识字段的结构示意图;FIG. 6 is a schematic structural diagram of a scheduling flow identifier field according to an embodiment of the present disclosure;
图7为本发明实施例提供的以太网络的示意图;FIG. 7 is a schematic diagram of an Ethernet network according to an embodiment of the present invention;
图8为本发明实施例提供的以太网网络中基于调度流标识的报文过程中报文格式的变化示意图;FIG. 8 is a schematic diagram of a packet format change in a packet process based on a scheduling flow identifier in an Ethernet network according to an embodiment of the present disclosure;
图9为本发明实施例中转发设备R1封装的报文的格式的示意图;FIG. 9 is a schematic diagram of a format of a packet encapsulated by a forwarding device R1 according to an embodiment of the present disclosure;
图10为本发明实施例提供的一种基于调度流标识的报文调度装置的结构图;FIG. 10 is a structural diagram of a packet scheduling apparatus based on a scheduling flow identifier according to an embodiment of the present disclosure;
图11为本发明实施例提供的另一种基于调度流标识的报文调度装置的结构图。FIG. 11 is a structural diagram of another packet scheduling apparatus based on a scheduling flow identifier according to an embodiment of the present invention.
本发明的较佳实施方式Preferred embodiment of the invention
下面将结合附图及具体实施例对本发明作进一步的详细描述。需要说明的是,在不冲突的情况下,本申请中的实施例及实施例中的特征可以相互任意组合。The invention will be further described in detail below with reference to the drawings and specific embodiments. It should be noted that, in the case of no conflict, the features in the embodiments and the embodiments in the present application may be arbitrarily combined with each other.
图1为本发明实施例提供的一种基于调度流标识的报文调度方法的流程图。图1所示方法,包括:FIG. 1 is a flowchart of a packet scheduling method based on a scheduling flow identifier according to an embodiment of the present invention. The method shown in Figure 1 includes:
步骤101、转发设备在对接收到的报文进行调度过程中,获取所述报文在转发路径的下一转发设备对应的调度流标识;Step 101: The forwarding device acquires a scheduling flow identifier corresponding to the next forwarding device of the packet in the forwarding path, in the process of scheduling the received packet.
步骤102、所述转发设备在所述报文中增加所述调度流标识;Step 102: The forwarding device adds the scheduling flow identifier to the packet.
步骤103、所述转发设备向所述下一转发设备发送包括所述调度流标识的报文。Step 103: The forwarding device sends a packet including the scheduling flow identifier to the next forwarding device.
本发明实施例提供的方法,转发设备在对报文进行处理过程中,借助本地的处理过程中的结果,获取报文在转发路径上的下一转发设备上的调度流标识,并将这个调度流标识携带给下一个转发设备,减少了下一个转发设备再次解析报文特征信息以获取该报文对应的调度流标识的时间,提高了信息处理效率,降低了硬件的消耗。 According to the method provided by the embodiment of the present invention, in the process of processing the packet, the forwarding device obtains the scheduling flow identifier of the next forwarding device on the forwarding path by using the result of the local processing, and the scheduling is performed. The flow identifier is carried to the next forwarding device, which reduces the time for the next forwarding device to parse the packet feature information again to obtain the scheduling flow identifier corresponding to the packet, thereby improving information processing efficiency and reducing hardware consumption.
图2为本发明实施例提供的另一种基于调度流标识的报文调度方法的流程图。图2所示方法,包括:FIG. 2 is a flowchart of another method for scheduling a message based on a scheduling flow identifier according to an embodiment of the present invention. The method shown in Figure 2 includes:
步骤201、转发设备在接收到包括调度流标识的报文后,获取所述报文中的调度流标识;Step 201: After receiving the packet including the scheduling flow identifier, the forwarding device acquires the scheduling flow identifier in the packet.
步骤202、所述转发设备根据所述调度流标识,对所述报文进行调度操作。Step 202: The forwarding device performs a scheduling operation on the packet according to the scheduling flow identifier.
本发明实施例提供的方法,转发设备利用报文中的调度流标识对报文进行调度,无需再次解析报文的特征信息以获取调度流标识,即可完成对报文的调度,节省了本地的调度时间,提高了信息处理效率,降低了硬件消耗。According to the method provided by the embodiment of the present invention, the forwarding device uses the scheduling flow identifier in the packet to schedule the packet, and does not need to parse the feature information of the packet again to obtain the scheduling flow identifier, so that the packet scheduling can be completed, thereby saving local The scheduling time improves the efficiency of information processing and reduces hardware consumption.
下面对本发明实施例提供的方法作进一步说明:The method provided by the embodiment of the present invention is further described below:
首先,对转发设备侧的报文调度进行说明:First, the packet scheduling on the forwarding device side is described:
其中,所述转发设备获取所述报文在转发路径上的下一转发设备对应的调度流标识,包括:The forwarding device obtains the scheduling flow identifier corresponding to the next forwarding device of the packet on the forwarding path, including:
所述转发设备获取所述报文的报文特征信息;The forwarding device acquires packet feature information of the packet;
所述转发设备根据本地预先存储的报文特征信息与调度流标识的对应关系,查找所述报文的报文特征信息对应的调度流标识;And the forwarding device searches for the scheduling flow identifier corresponding to the packet feature information of the packet according to the correspondence between the locally stored packet feature information and the scheduling flow identifier;
如果查找到,则所述转发设备将查找到的结果作为所述报文对应的调度流标识;If found, the forwarding device uses the found result as the scheduling flow identifier corresponding to the packet;
如果未查找到,则所述转发设备向所述下一转发设备发送查询请求,其中所述查询请求包括所述报文的报文特征信息;并接收所述下一转发设备反馈的查询响应,其中所述查询响应包括所述报文的调度流标识信息。If not found, the forwarding device sends a query request to the next forwarding device, where the query request includes packet feature information of the packet; and receives a query response fed back by the next forwarding device, The query response includes scheduling flow identification information of the packet.
对上述流程需要说明的是,所述报文特征信息可以为综合源地址、目的地址、MAC地址、标签exp、IP协议或应用程序的端口号等信息。It should be noted that the packet feature information may be information such as an integrated source address, a destination address, a MAC address, a label exp, an IP protocol, or an application port number.
其中,所述报文特征信息与调度流标识的对应关系是通过如下方式得到的:The correspondence between the packet feature information and the scheduling flow identifier is obtained by:
转发设备向下一个转发设备请求获取该报文特征信息在下一个转法设备上对应的调度流标识; The forwarding device requests the next forwarding device to obtain the corresponding scheduling flow identifier of the packet feature information on the next forwarding device;
下一个转发设备在接收到该请求后,通过查询本地的流分类的信息,向转发设备反馈该特征信息在本地对应的调度流标识;After receiving the request, the next forwarding device feeds back the information of the local traffic classification, and feeds back the scheduling flow identifier corresponding to the feature information to the forwarding device.
在转发设备得到该报文特征信息在下一个转发设备对应的调度流标识后,保存两者的对应关系,以便为后续使用。After the forwarding device obtains the packet flow information corresponding to the scheduling flow identifier corresponding to the next forwarding device, the corresponding relationship between the two is saved for subsequent use.
其中,调度流标识请求分发协议基于TCP协议(端口号选用1024-5000的临时端口号),调度流标识请求分发协议分为调度流标识请求报文和调度流标识响应报文,报文由头部和消息体两部分组成。The scheduling flow identifier request distribution protocol is based on the TCP protocol (the port number is a temporary port number of 1024-5000), and the scheduling flow identifier request distribution protocol is divided into a scheduling flow identifier request packet and a scheduling flow identifier response packet, and the packet header is sent by the header. The department and the message body are composed of two parts.
图3为本发明实施例提供的调度流标识请求分发协议中报文的头部结构图。图3所示的协议头共8个字节,其中每个字段的说明如下:FIG. 3 is a schematic structural diagram of a header of a message in a scheduling flow identifier request distribution protocol according to an embodiment of the present invention. The protocol header shown in Figure 3 has a total of 8 bytes, each of which is described as follows:
版本:1个字节,用于标识调度流标识请求分发协议的版本。Version: 1 byte, used to identify the version of the dispatch stream identifier request distribution protocol.
保留1:1个字节,用于后续扩展。1:1 bytes are reserved for subsequent expansion.
协议负载长度:2个字节,协议负载的总长度,不包括协议头长度。Protocol payload length: 2 bytes, the total length of the protocol payload, excluding the protocol header length.
消息类型:标识报文类型,请求为0,响应为1。Message Type: Identifies the packet type. The request is 0 and the response is 1.
请求编号:3个字节用于标识请求。(附件协议格式做了修改)Request number: 3 bytes are used to identify the request. (The attachment protocol format has been modified)
图4为本发明实施例提供的调度流标识请求分发协议中报文的消息体的结构图。图4所示的消息体以类型、长度和数值(Type、Length、Value,TLV)格式组成。其中每个字段的说明如下:FIG. 4 is a structural diagram of a message body of a message in a scheduling flow identifier request distribution protocol according to an embodiment of the present invention. The message body shown in Figure 4 consists of a type, length, and value (Type, Length, Value, TLV) format. The description of each of these fields is as follows:
Type:类型字段,表示后面的字段内容,如源IP、目的IP、源端口号、目的端口等。Type: Type field, indicating the content of the following fields, such as source IP, destination IP, source port number, destination port, and so on.
Length:长度字段,标识一组TLV的长度。Length: A length field that identifies the length of a group of TLVs.
Value:数值,Type对应属性的值,具体长度根据属性确定,例如Type为IP地址,那么Value就是4个字节;如果Type为目的mac,那么就是6个字节,不满一个字节的属性用一个字节表示,如exp的值占1个字节。Value: Value, Type corresponds to the value of the attribute. The specific length is determined according to the attribute. For example, Type is an IP address, then Value is 4 bytes. If Type is the destination mac, then it is 6 bytes, and the attribute is less than one byte. One byte indicates that the value of exp is 1 byte.
请求消息中Type的值及对应属性:The value of Type in the request message and the corresponding attribute:
0:目的mac0: Purpose mac
1:源mac1: source mac
3:802.1p值 3:802.1p value
4:源IP4: Source IP
5:目的IP5: Destination IP
6:IP头中的协议号6: Protocol number in the IP header
7:源端口7: source port
8:目的端口8: destination port
9:标签9: label
10:exp10:exp
其它:预留,用于扩展使用。Other: Reserved for extended use.
响应消息Type的值及对应属性:The value of the response message Type and the corresponding attribute:
0:返回的调度流标识值,目前调度流标识具体value占2个字节0: The value of the scheduled flow identifier to be returned. Currently, the specific value of the scheduled flow identifier is 2 bytes.
其中,所述转发设备在所述报文中增加所述调度流标识,包括:The forwarding device adds the scheduling flow identifier to the packet, including:
所述转发设备在所述报文的二层协议头后增加一个字段,并在增加的字段中增加所述调度流标识。The forwarding device adds a field after the Layer 2 protocol header of the packet, and adds the scheduling flow identifier to the added field.
以以太网报文为例,增加的字段位于以太网报文的报文头字段与IP头字段之间;以IP报文为例,增加的字段位于IP头字段与数据段字段之间。The Ethernet packet is used as an example. The added field is located between the packet header field and the IP header field of the Ethernet packet. The IP packet is used as an example. The added field is located between the IP header field and the data segment field.
图5为本发明实施例提供的报文格式的对比示意图。如图5所示,第一个报文格式为原始报文的报文格式,第二个报文格式为处理后的报文格式。其中参见处理后的报文格式,在二层以太头和三层IP之间插入了“调度流标识”字段,这样下一个转发设备可以根据这个“调度流标识”字段的值直接查找对应的调度信息,执行调度动作。FIG. 5 is a schematic diagram of comparison of packet formats according to an embodiment of the present invention. As shown in Figure 5, the first packet format is the original packet format, and the second packet format is the processed packet format. In the format of the processed packet, the "Scheduled Flow Identifier" field is inserted between the Layer 2 Ethernet Header and the Layer 3 IP, so that the next forwarding device can directly search for the corresponding schedule according to the value of the "Scheduled Flow Identifier" field. Information, perform scheduling actions.
为了能识别这种报文,以太头中增加相应的协议字段,用以标识后面是带有调度流标识的报文,另外调度流标识字段中可以带有流标识值还可以增加上层协议类型的值,方便设备解析报文。In order to identify such a packet, a corresponding protocol field is added in the Ethernet header to identify a packet with a scheduling flow identifier, and a flow identifier value may be added in the scheduling flow identifier field to increase the upper protocol type. Value, which is convenient for the device to parse the message.
图6为本发明实施例提供的调度流标识字段的结构示意图。图6所示示意图包括调度流标识和上层协议号信息。其中该上层协议号信息用于指示后续字段的数据对应的数据协议信息。FIG. 6 is a schematic structural diagram of a scheduling flow identifier field according to an embodiment of the present invention. The schematic diagram shown in FIG. 6 includes a scheduling flow identifier and upper layer protocol number information. The upper layer protocol number information is used to indicate data protocol information corresponding to the data of the subsequent field.
下面对下一个转发设备的报文调度进行说明: The following describes the packet scheduling of the next forwarding device:
下一个转发设备所述转发设备获取所述报文在转发路径上的下一转发设备对应的调度流标识;The forwarding device of the next forwarding device acquires the scheduling flow identifier corresponding to the next forwarding device of the packet on the forwarding path;
所述转发设备将所述报文中的转发标识替换为所述下一转发设备对应的调度流标识;The forwarding device replaces the forwarding identifier in the packet with the scheduling stream identifier corresponding to the next forwarding device;
所述转发设备将完成调度流标识替换后的报文发送出去。The forwarding device sends the packet that has been replaced by the scheduled flow identifier.
图7为本发明实施例提供的以太网络的示意图。图7所示网络中,R1、R2、R3是转发路径上3台转发设备,报文从R1进来转发到R2,R2再将其转发到R3,R3再转发出去,如图所示的报文在R1、R2、R3上进行QoS处理的时候都会根据源地址、目的地址、MAC地址、标签exp、IP协议或应用程序的端口号等信息进行分类,然后进行调度。FIG. 7 is a schematic diagram of an Ethernet network according to an embodiment of the present invention. In the network shown in Figure 7, R1, R2, and R3 are three forwarding devices on the forwarding path. The packets are forwarded from R1 to R2, and R2 forwards them to R3. R3 forwards them again. When QoS processing is performed on R1, R2, and R3, it is classified according to information such as source address, destination address, MAC address, label exp, IP protocol, or application port number, and then scheduled.
在本发明实施例中,报文经过R1、R2、R3转发,3台转发设备事先会进行协议上交互、协商,这样导致转发设备上的输出报文格式会发生变化。。In the embodiment of the present invention, the packets are forwarded through R1, R2, and R3, and the three forwarding devices perform protocol interaction and negotiation in advance, so that the output packet format on the forwarding device changes. .
图8为本发明实施例提供的以太网网络中基于调度流标识的报文过程中报文格式的变化示意图。报文转发路径为R1->R2->R3,则R1是R2的上游设备,R2是R1的下游设备,其他类似。下图说明调度流标识请求、分发的过程,由上游到下游逐级请求分发。FIG. 8 is a schematic diagram of a packet format change in a packet process based on a scheduling flow identifier in an Ethernet network according to an embodiment of the present invention. The packet forwarding path is R1->R2->R3, then R1 is the upstream device of R2, and R2 is the downstream device of R1. Others are similar. The following figure illustrates the process of scheduling flow identification request and distribution, and requests are distributed from upstream to downstream.
如图8所示,原始报文经过R1转发处理发送到R2的时候,报文格式变成了图中的“处理后报文”(即R1的输出报文),另外R2处理后,会将用对应的本地的“调度流标识”(R3分配给R2的)替换输入报文中的“调度流标识”,然后发给R3,R3执行R2上类似的动作。R2、R3以及后续的转发设备,都不需要根据源地址、目的地址、MAC地址、标签exp、IP协议或应用程序的端口号等信息进行分类,而直接根据这个预先分配的调度流标识就能执行正确的调度动作。As shown in Figure 8, when the original message is sent to R2 through the R1 forwarding process, the message format becomes the "processed message" in the figure (that is, the output message of R1), and after R2 processing, Replace the "scheduling flow identifier" in the input message with the corresponding local "scheduling flow identifier" (R3 assigned to R2), and then send it to R3, and R3 performs a similar action on R2. R2, R3, and subsequent forwarding devices do not need to be classified according to information such as source address, destination address, MAC address, label exp, IP protocol, or application port number, but can be directly based on the pre-allocated scheduling stream identifier. Perform the correct scheduling action.
相关技术中的处理方法是转发设备需要根据报文特征进行识别,这个操作步骤是非常消耗性能的。另外,考虑到网络上的同一类报文通常都是一定时间内持续出现的,而相关技术中,即使是同一类报文,转发设备在收到每个报文都会重复根据报文特征识别并分类的动作。与相关技术不同的是,本发明实施例通过控制面协议上的交互,预先将流做好识别,上游转发设备把 调度流标识发送给下游转发设备。因此,下游转发设备在得到调度流标识后,通过该调度流标识信息就不需要分类动作了,且,在一段时间内均为同一类报文时,也无需对每个报文都进行逐个识别了,因为上游设备请求的调度流标识是触发下游设备进行设备获取对应的调度方式的一个准备的动作,这个准备的动作避免了原本必须的持续的分类动作。The processing method in the related art is that the forwarding device needs to be identified according to the characteristics of the message, and this operation step is very cost-effective. In addition, it is considered that the same type of packets on the network are always persistent for a certain period of time. In the related art, even if the packets of the same type are received, the forwarding device repeatedly recognizes the packets according to the characteristics of the packets. The action of classification. Different from the related art, the embodiment of the present invention identifies the flow in advance through the interaction on the control plane protocol, and the upstream forwarding device The scheduling flow identifier is sent to the downstream forwarding device. Therefore, after obtaining the scheduling flow identifier, the downstream forwarding device does not need to perform the classification action by using the scheduling flow identification information, and does not need to identify each packet one by one when it is the same type of packet for a period of time. Because the scheduled flow identifier requested by the upstream device is a preparatory action for triggering the downstream device to perform the corresponding scheduling mode of the device, the prepared action avoids the persistent classification action that is originally necessary.
即,如果转发设备当检测到接收到的报文携带的调度标识发生变化后,在预先设置的时间内,均根据新得到的调度流标识对报文进行调度。That is, if the forwarding device detects that the scheduling identifier carried in the received packet changes, the packet is scheduled according to the newly obtained scheduling flow identifier in a preset time.
举例来说,如果之前得到的报文的调度流标识为A,当前接收的调度流标识变为B后,根据数据在网络中传输的规律可知,在接下来的一端时间内接收到的报文的报文特征信息相同,因此,后续报文的调度流标识也为B,因此,转发设备无需对报文进行逐个的报文特征识别,降低了转发设备的处理压力,减少了硬件消耗。For example, if the scheduled flow identifier of the previously obtained packet is A, and the currently received scheduling flow identifier becomes B, according to the law of data transmission in the network, the received packet is received in the next one end time. The packet feature information is the same. Therefore, the scheduling flow identifier of the subsequent packets is also B. Therefore, the forwarding device does not need to identify the packet characteristics one by one, which reduces the processing pressure of the forwarding device and reduces hardware consumption.
以转发设备R1与转发设备R2之间的通信为例进行说明:The communication between the forwarding device R1 and the forwarding device R2 is taken as an example for description:
步骤A01、R1上使能本发明实施例功能,配置了入口五元组信息如:目的IP为200.1.1.10,源IP为210.1.1.10,协议号为UDP,源端口号为1000,目的端口号为1000。Steps A01 and R1 enable the functions of the embodiment of the present invention, and configure the entry quintuple information such as: the destination IP address is 200.1.1.10, the source IP address is 210.1.1.10, the protocol number is UDP, the source port number is 1000, and the destination port number is It is 1000.
步骤A02、R1处理这种报文,得到输出报文的特征。例如五元组信息保持不变另外会加一层标签信息,那么R1将五元组信息和标签值(例如为1200)以及exp(例如为1)放到调度流标识请求分发协议的请求报文中,发送给下一跳设备R2。Steps A02 and R1 process the message to obtain the characteristics of the output message. For example, if the quintuple information remains unchanged and a layer of tag information is added, then R1 puts the quintuple information and the tag value (for example, 1200) and exp (for example, 1) into the request message of the scheduling flow identification request distribution protocol. , sent to the next hop device R2.
步骤A03、R2收到发送过来的报文特征信息,根据实际转发处理得到对应的本地调度分类条目的索引,将这个索引作为调度流标识放在调度流标识请求分发协议的响应报文中发送给R1即上图中的L2,具体值例如为0x1200。Steps A03 and R2 receive the received packet feature information, obtain an index of the corresponding local scheduling classification entry according to the actual forwarding process, and send the index as a scheduling flow identifier in the response packet of the scheduling flow identifier request distribution protocol. R1 is L2 in the above figure, and the specific value is, for example, 0x1200.
步骤A04、R1收到这个调度流标识(L2=0x1200),将其存储在本地的分类结果条目中(对应五元组信息目的IP为200.1.1.10,源IP为210.1.1.10,协议号为UDP,源端口号为1000,目的端口号为1000)。这个分类跟普通分类实现一样(如利用TCAM实现)。Step A04, R1 receives the scheduling flow identifier (L2=0x1200), and stores it in the local classification result entry (the destination IP of the corresponding quintuple information is 200.1.1.10, the source IP is 210.1.1.10, and the protocol number is UDP. The source port number is 1000 and the destination port number is 1000). This classification is the same as the normal classification implementation (eg using TCAM).
步骤A05、当R1从接口收到特征流量(对应五元组信息目的IP为 200.1.1.10,源IP为210.1.1.10,协议号为UDP,源端口号为1000,目的端口号为1000)进行分类时便得到分类表中的调度流标识,然后将其封装到报文中去。Step A05: When R1 receives the feature traffic from the interface (the destination IP address of the quintuple information is 200.1.1.10, the source IP address is 210.1.1.10, the protocol number is UDP, the source port number is 1000, and the destination port number is 1000. When the classification is performed, the scheduling flow identifier in the classification table is obtained, and then encapsulated into the packet. .
图9为本发明实施例中转发设备R1封装的报文的格式的示意图。图9所示示意图中,0x1200是下游分的调度流标识,0x0800是上层协议的协议号。FIG. 9 is a schematic diagram of a format of a packet encapsulated by a forwarding device R1 according to an embodiment of the present invention. In the diagram shown in FIG. 9, 0x1200 is the scheduling flow identifier of the downstream branch, and 0x0800 is the protocol number of the upper layer protocol.
步骤A06、R1发送该报文。Steps A06 and R1 send the message.
本发明实施例实现了一种在网络中分发调度流标识,基于分发的调度流标识进行QoS调度的方法,主要实施步骤如下:The embodiment of the invention implements a method for distributing a scheduling flow identifier in a network, and performing QoS scheduling based on the distributed scheduling flow identifier. The main implementation steps are as follows:
实施方式一:Embodiment 1:
步骤1:每个转发设备上使能分发调度流标识、基于分发的调度流标识进行QoS调度的功能。Step 1: Enable the function of distributing the scheduling flow identifier and performing the QoS scheduling based on the distributed scheduling flow identifier on each forwarding device.
步骤2:在整个转发路径入口上游设备R1上配置需要处理的流特征,如源地址、目的地址、MAC地址、标签exp、IP协议或应用程序的端口号等字段的值。可以是入口也可以是出口的报文特征。Step 2: Configure the stream characteristics to be processed, such as the source address, the destination address, the MAC address, the label exp, the IP protocol, or the port number of the application, on the entire forwarding path upstream device R1. It can be either an entry or an outgoing message feature.
步骤3:如果是入口报文特征,上游设备R1处理得到出口的报文特征,然后携带报文特征字段向下游设备R2发送请求,请求分发调度流标识。如果配置的是出口报文特征则直接向下游设备请求分发调度流标识。Step 3: If it is an inbound packet feature, the upstream device R1 processes the packet characteristics of the egress, and then carries the packet feature field to send a request to the downstream device R2 to request distribution of the scheduling flow identifier. If the egress message feature is configured, the downstream device is directly requested to distribute the scheduling flow identifier.
步骤4:R1下游设备R2收到上游设备的请求,生成调度流标识L2作为响应发送给上游设备R1,并且根据入口报文处理得到本设备的出口报文特征,然后向自己的下游设备R3发送分发调度流标识的请求,R3响应请求,这样R2也得到了R3分配的调度流标识L3,同时R2将此调度流标识L3与自己发送给R1的调度流标识L2联系起来。即可以根据L2查找到L3。并且每个设备将分配给上游设备的调度流标识和自己的调度动作关联起来,即根据调度流标识可以查找到调度动作。Step 4: R1 downstream device R2 receives the request of the upstream device, generates a scheduling flow identifier L2 as a response and sends it to the upstream device R1, and obtains the egress packet feature of the device according to the ingress packet processing, and then sends the egress packet feature of the device to the downstream device R3. The request to dispatch the flow identifier is distributed, and R3 responds to the request, so that R2 also obtains the dispatch flow identifier L3 allocated by R3, and R2 associates the dispatch flow identifier L3 with the dispatch flow identifier L2 that is sent to R1 by itself. That is, L3 can be found according to L2. And each device associates the scheduling flow identifier assigned to the upstream device with its own scheduling action, that is, the scheduling action can be found according to the scheduling flow identifier.
步骤5:转发路径上的设备都执行类似的功能,一直到最后一个转发设备,至此调度流标识分发完毕。Step 5: The devices on the forwarding path perform similar functions until the last forwarding device, and the scheduling flow identifier is distributed.
步骤6:R1上收到报文,查找是否是配置的流特征,不是则正常转发处 理,如果是则在正常转发处理的时候封装上L2调度流标识,然后转发到R2,R2根据协议号解析报文,然后根据L2查找到关联的调度动作,进行调度,并且在发送报文的时候将L2替换成L3标签发送给R2。Step 6: Receive a packet on R1 to find out whether it is a configured flow feature. If yes, the L2 scheduling flow identifier is encapsulated in the normal forwarding process, and then forwarded to R2. R2 parses the packet according to the protocol number, and then finds the associated scheduling action according to L2, performs scheduling, and sends the packet. When you replace L2 with an L3 tag, send it to R2.
步骤7:R3执行R2类似的动作,直到报文转发到目的地。Step 7: R3 performs an R2-like action until the message is forwarded to the destination.
这种方式是设备间通过协议动态地协商完成调度流标识的分配,并根据调度流标识进行调度。In this manner, the devices dynamically negotiate the allocation of the scheduling flow identifiers through the protocol, and perform scheduling according to the scheduling flow identifier.
实施方式二:Embodiment 2:
与实施方式一不同的是,本实施方式是这种方式是通过静态配置完成的。具体说明如下:Different from the first embodiment, the present embodiment is such that the manner is completed by static configuration. The specific instructions are as follows:
步骤1:每个转发设备使能分发调度流标识,基于分发的调度流标识进行QoS调度的功能Step 1: Each forwarding device enables distribution of the scheduling flow identifier, and performs QoS scheduling based on the distributed scheduling flow identifier.
步骤2:在每个设备上配置流特征,并指定向上游设备分发的调度流标识。对于转发路径入口的设备R1,针对特定的流指定出口封装的调度流标识L1。对于R2这种有上游设备和下游设备的情形,需要配置入口的调度流标识L1以及出口的调度流标识L2,R3上配置入口调度流标识L2。R2、R3将调度动作跟入口调度流标识关联起来。Step 2: Configure flow characteristics on each device and specify the dispatch flow identifier to be distributed to the upstream device. For device R1 that forwards the path entry, the outbound encapsulated scheduling flow identifier L1 is specified for the particular flow. For the case of R2, such as the upstream device and the downstream device, the scheduled flow identifier L1 of the ingress and the scheduled flow identifier L2 of the egress are configured, and the ingress scheduling flow identifier L2 is configured on R3. R2 and R3 associate the scheduling action with the ingress scheduling flow identifier.
步骤3:报文进入R1,R1根据流特征以及配置,在转发报文的时候封装配置的调度流标识L1。Step 3: The packet enters R1, and R1 encapsulates the configured scheduling flow identifier L1 when forwarding the packet according to the flow characteristics and configuration.
步骤4:R2上根据L1进行相关的调度,并且出口封装上L2发送给R3。Step 4: Relevant scheduling is performed according to L1 on R2, and L2 is sent to R3 on the egress package.
步骤5:R3收到报文,类似R2进行相关的调度、转发等处理。Step 5: R3 receives the packet, similar to R2 for related scheduling, forwarding, and the like.
综上可以看出,转发设备间进行交互,对特定的流分配特定的标识,并发送调度流标识请求分发协议的请求报文到下游设备,下游设备收到请求后根据本设备的处理情况对流分配特定的标识,然后通过发送调度流标识请求分发协议的响应报文将这个调度流标识通知给上游转发设备,这样上游转发设备对报文进行处理的时候,将特定的调度流标识封装到报文中去,发给下游的转发设备,下游转发设备根据这个调度流标识就可以直接进行相关的动作处理、调度,而不需要进行分类处理,从而提高处理性能,甚至可以节省TCAM等硬件器件。 In summary, the forwarding device performs the interaction, assigns a specific identifier to a specific flow, and sends a request message of the scheduling flow identifier requesting the distribution protocol to the downstream device. After receiving the request, the downstream device convects the flow according to the processing of the device. Assigning a specific identifier, and then notifying the upstream forwarding device by sending a response packet of the scheduling distribution identifier requesting the distribution protocol, so that the upstream forwarding device encapsulates the specific scheduling flow identifier into the packet when processing the packet. In the text, the downstream forwarding device is sent to the downstream forwarding device, and the downstream forwarding device can directly perform related action processing and scheduling according to the scheduling flow identifier, without performing classification processing, thereby improving processing performance and even saving hardware devices such as TCAM.
图10为本发明实施例提供的一种基于调度流标识的报文调度装置的结构图。图10所示装置,包括:FIG. 10 is a structural diagram of a message scheduling apparatus based on a scheduling flow identifier according to an embodiment of the present invention. The device shown in Figure 10 includes:
第一获取模块1001,设置为在对接收到的报文进行处理过程中,获取所述报文在转发路径的下一转发设备对应的调度流标识;The first obtaining module 1001 is configured to: in the process of processing the received packet, obtain a scheduling flow identifier corresponding to the next forwarding device of the packet in the forwarding path;
增加模块1002,设置为在所述报文中增加所述调度流标识;The adding module 1002 is configured to add the scheduling flow identifier to the packet.
第一发送模块1003,设置为向所述下一转发设备发送包括所述调度流标识的报文。The first sending module 1003 is configured to send a packet including the scheduling flow identifier to the next forwarding device.
其中,所述第一获取模块1001包括:The first obtaining module 1001 includes:
获取单元,设置为获取所述报文的报文特征信息;An obtaining unit, configured to obtain message feature information of the packet;
查找单元,根据本地预先存储的报文特征信息与下一转发设备的调度流标识的对应关系,查找所述报文的报文特征信息对应的下一转发设备的调度流标识;The searching unit searches for the scheduling flow identifier of the next forwarding device corresponding to the packet feature information of the packet according to the correspondence between the local pre-stored packet feature information and the scheduling flow identifier of the next forwarding device;
第一确定单元,设置为如果查找到,则所述转发设备将查找到的结果作为所述报文对应的调度流标识;a first determining unit, configured to: if found, the forwarding device uses the found result as a scheduling flow identifier corresponding to the packet;
发送单元,设置为如果未查找到,则向所述下一转发设备发送查询请求,其中所述查询请求包括所述报文的报文特征信息;a sending unit, configured to send a query request to the next forwarding device if not found, where the query request includes message feature information of the packet;
接收单元,设置为接收所述下一转发设备反馈的查询响应,其中所述查询响应包括所述报文的报文特征信息。The receiving unit is configured to receive a query response fed back by the next forwarding device, where the query response includes message feature information of the packet.
其中,所述增加模块1002是设置为:在所述报文的二层协议头后增加一个字段,并在增加的字段中增加所述调度流标识。The adding module 1002 is configured to: add a field after the Layer 2 protocol header of the packet, and add the scheduling flow identifier to the added field.
本发明实施例提供的装置,在对报文进行调度过程中,借助本地的调度过程中的结果,获取报文在转发路径上的下一转发设备上的调度流标识,并将这个调度流标识通知给下一个转发设备,减少了下一个转发设备再次解析报文特征信息以获取该报文对应的调度流标识的时间,提高了信息处理效率,降低了硬件的消耗。The device provided by the embodiment of the present invention obtains the scheduling flow identifier of the next forwarding device on the forwarding path by using the result of the local scheduling process in the process of scheduling the packet, and identifies the scheduling flow identifier. The notification is sent to the next forwarding device, which reduces the time for the next forwarding device to parse the packet feature information again to obtain the scheduling flow identifier corresponding to the packet, which improves the information processing efficiency and reduces the hardware consumption.
图11为本发明实施例提供的另一种基于调度流标识的报文调度装置的 结构图。图11所示装置,包括:FIG. 11 is another packet scheduling device based on a scheduling flow identifier according to an embodiment of the present invention. Structure diagram. The device shown in Figure 11 includes:
第二获取模块1101,设置为在接收到包括调度流标识的报文后,获取所述报文中的调度流标识;The second obtaining module 1101 is configured to: after receiving the packet that includes the scheduling flow identifier, obtain the scheduling flow identifier in the packet;
调度模块1102,设置为根据所述调度流标识,对所述报文进行调度操作。The scheduling module 1102 is configured to perform a scheduling operation on the packet according to the scheduling flow identifier.
其中,所述装置还包括:Wherein, the device further comprises:
第三获取模块,设置为获取所述报文在转发路径上的下一转发设备对应的调度流标识;a third acquiring module, configured to obtain a scheduling flow identifier corresponding to a next forwarding device of the packet on the forwarding path;
替换模块,设置为将所述报文中的转发标识替换为所述下一转发设备对应的调度流标识;The replacement module is configured to replace the forwarding identifier in the packet with the scheduling flow identifier corresponding to the next forwarding device;
第二发送模块,设置为将完成调度流标识替换后的报文发送出去。The second sending module is configured to send the packet after the completion of the scheduling flow identifier is replaced.
本发明实施例提供的装置在对报文进行处理过程中,借助本地的处理过程中的结果,获取报文在转发路径上的下一转发设备上的调度流标识,并将这个调度流标识携带给下一个转发设备,减少了下一个转发设备再次解析报文特征信息以获取该报文对应的调度流标识的时间,提高了信息处理效率,降低了硬件的消耗。The device provided by the embodiment of the present invention, in the process of processing the packet, obtains the scheduling flow identifier of the next forwarding device on the forwarding path by using the result of the local processing, and carries the scheduling flow identifier The next forwarding device is used to reduce the time when the next forwarding device parses the packet feature information to obtain the scheduling flow identifier corresponding to the packet, which improves information processing efficiency and reduces hardware consumption.
本领域普通技术人员可以理解上述实施例的全部或部分步骤可以使用计算机程序流程来实现,所述计算机程序可以存储于一计算机可读存储介质中,所述计算机程序在相应的硬件平台上(如系统、设备、装置、器件等)执行,在执行时,包括方法实施例的步骤之一或其组合。One of ordinary skill in the art will appreciate that all or a portion of the steps of the above-described embodiments can be implemented using a computer program flow, which can be stored in a computer readable storage medium, such as on a corresponding hardware platform (eg, The system, device, device, device, etc. are executed, and when executed, include one or a combination of the steps of the method embodiments.
可选地,上述实施例的全部或部分步骤也可以使用集成电路来实现,这些步骤可以被分别制作成一个个集成电路模块,或者将它们中的多个模块或步骤制作成单个集成电路模块来实现。这样,本发明不限制于任何特定的硬件和软件结合。Alternatively, all or part of the steps of the above embodiments may also be implemented by using an integrated circuit. These steps may be separately fabricated into individual integrated circuit modules, or multiple modules or steps may be fabricated into a single integrated circuit module. achieve. Thus, the invention is not limited to any specific combination of hardware and software.
上述实施例中的各装置/功能模块/功能单元可以采用通用的计算装置来实现,它们可以集中在单个的计算装置上,也可以分布在多个计算装置所组成的网络上。 The devices/function modules/functional units in the above embodiments may be implemented by a general-purpose computing device, which may be centralized on a single computing device or distributed over a network of multiple computing devices.
上述实施例中的各装置/功能模块/功能单元以软件功能模块的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。上述提到的计算机可读取存储介质可以是只读存储器,磁盘或光盘等。When each device/function module/functional unit in the above embodiment is implemented in the form of a software function module and sold or used as a stand-alone product, it can be stored in a computer readable storage medium. The above mentioned computer readable storage medium may be a read only memory, a magnetic disk or an optical disk or the like.
以上所述,仅为本发明的具体实施方式,但本发明的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本发明揭露的技术范围内,可轻易想到变化或替换,都应涵盖在本发明的保护范围之内。因此,本发明的保护范围应以权利要求所述的保护范围为准。The above is only a specific embodiment of the present invention, but the scope of the present invention is not limited thereto, and any person skilled in the art can easily think of changes or substitutions within the technical scope of the present invention. It should be covered by the scope of the present invention. Therefore, the scope of the invention should be determined by the scope of the claims.
工业实用性Industrial applicability
上述技术方案减少了下一个转发设备再次解析报文特征信息以获取该报文对应的调度流标识的时间,提高了信息处理效率,降低了硬件的消耗。 The foregoing technical solution reduces the time for the next forwarding device to parse the packet feature information again to obtain the scheduling flow identifier corresponding to the packet, thereby improving information processing efficiency and reducing hardware consumption.

Claims (12)

  1. 一种基于调度流标识的报文调度方法,包括:A packet scheduling method based on a scheduling flow identifier includes:
    转发设备在对接收到的报文进行转发处理过程中,获取所述报文在转发路径的下一转发设备对应的调度流标识;The forwarding device obtains the scheduling flow identifier corresponding to the next forwarding device of the packet in the forwarding path, in the process of forwarding the received packet.
    所述转发设备在所述报文中增加所述调度流标识;The forwarding device adds the scheduling flow identifier to the packet;
    所述转发设备向所述下一转发设备发送包括所述调度流标识的报文。The forwarding device sends a packet including the scheduling flow identifier to the next forwarding device.
  2. 根据权利要求1所述的方法,其中,所述转发设备获取所述报文在转发路径上的下一转发设备对应的调度流标识,包括:The method of claim 1, wherein the forwarding device obtains the scheduling flow identifier corresponding to the next forwarding device of the packet on the forwarding path, including:
    所述转发设备获取所述报文的报文特征信息;The forwarding device acquires packet feature information of the packet;
    所述转发设备根据本地预先存储的报文特征信息与下一转发设备的调度流标识的对应关系,查找所述报文的报文特征信息对应的下一转发设备的调度流标识;And the forwarding device searches for the scheduling flow identifier of the next forwarding device corresponding to the packet feature information of the packet according to the correspondence between the local pre-stored packet feature information and the scheduling flow identifier of the next forwarding device;
    如果查找到,则所述转发设备将查找到的结果作为所述报文对应的调度流标识;If found, the forwarding device uses the found result as the scheduling flow identifier corresponding to the packet;
    如果未查找到,则所述转发设备向所述下一转发设备发送查询请求,其中所述查询请求包括所述报文的报文特征信息;并接收所述下一转发设备反馈的查询响应,其中所述查询响应包括所述报文的调度流标识信息。If not found, the forwarding device sends a query request to the next forwarding device, where the query request includes packet feature information of the packet; and receives a query response fed back by the next forwarding device, The query response includes scheduling flow identification information of the packet.
  3. 根据权利要求1或2所述的方法,其中,所述转发设备在所述报文中增加所述调度流标识,包括:The method according to claim 1 or 2, wherein the forwarding device adds the scheduling flow identifier to the packet, including:
    所述转发设备在所述报文的二层协议头后增加一个字段,并在增加的字段中增加所述调度流标识。The forwarding device adds a field after the Layer 2 protocol header of the packet, and adds the scheduling flow identifier to the added field.
  4. 一种基于调度流标识的报文调度方法,包括:A packet scheduling method based on a scheduling flow identifier includes:
    转发设备在接收到包括调度流标识的报文后,获取所述报文中的调度流标识;After receiving the packet including the scheduling flow identifier, the forwarding device acquires the scheduling flow identifier in the packet.
    所述转发设备根据所述调度流标识,对所述报文进行调度操作。 The forwarding device performs a scheduling operation on the packet according to the scheduling flow identifier.
  5. 根据权利要求4所述的方法,所述方法还包括:The method of claim 4, further comprising:
    所述转发设备获取所述报文在转发路径上的下一转发设备对应的调度流标识;The forwarding device acquires a scheduling flow identifier corresponding to the next forwarding device of the packet on the forwarding path;
    所述转发设备将所述报文中的转发标识替换为所述下一转发设备对应的调度流标识;The forwarding device replaces the forwarding identifier in the packet with the scheduling stream identifier corresponding to the next forwarding device;
    所述转发设备将完成调度流标识替换后的报文发送出去。The forwarding device sends the packet that has been replaced by the scheduled flow identifier.
  6. 一种基于调度流标识的报文调度装置,包括:A message scheduling device based on a scheduling flow identifier, comprising:
    第一获取模块,设置为在对接收到的报文进行调度过程中,获取所述报文在转发路径的下一转发设备对应的调度流标识;The first obtaining module is configured to: in the process of scheduling the received packet, obtain the scheduling flow identifier corresponding to the next forwarding device of the packet in the forwarding path;
    增加模块,设置为在所述报文中增加所述调度流标识;Adding a module, configured to add the scheduling flow identifier to the packet;
    第一发送模块,设置为向所述下一转发设备发送包括所述调度流标识的报文。The first sending module is configured to send a packet including the scheduling flow identifier to the next forwarding device.
  7. 根据权利要求6所述的装置,其中,所述第一获取模块包括:The apparatus of claim 6, wherein the first obtaining module comprises:
    获取单元,设置为获取所述报文的报文特征信息;An obtaining unit, configured to obtain message feature information of the packet;
    查找单元,设置为根据本地预先存储的报文特征信息与下一转发设备的调度流标识的对应关系,查找所述报文的报文特征信息对应的下一转发设备的调度流标识;The search unit is configured to search for a scheduling flow identifier of the next forwarding device corresponding to the packet feature information of the packet according to the correspondence between the local pre-stored packet feature information and the scheduling flow identifier of the next forwarding device;
    第一确定单元,设置为如果查找到,则所述转发设备将查找到的结果作为所述报文对应的调度流标识;a first determining unit, configured to: if found, the forwarding device uses the found result as a scheduling flow identifier corresponding to the packet;
    发送单元,设置为如果未查找到,则向所述下一转发设备发送查询请求,其中所述查询请求包括所述报文的报文特征信息;a sending unit, configured to send a query request to the next forwarding device if not found, where the query request includes message feature information of the packet;
    接收单元,设置为接收所述下一转发设备反馈的查询响应,其中所述查询响应包括所述报文的调度流标识信息。The receiving unit is configured to receive a query response fed back by the next forwarding device, where the query response includes scheduling flow identification information of the packet.
  8. 根据权利要求6或7所述的装置,其中,所述增加模块是设置为:在所述报文的二层协议头后增加一个字段,并在增加的字段中增加所述调度流标识。 The apparatus according to claim 6 or 7, wherein the adding module is configured to: add a field after the layer 2 protocol header of the message, and add the scheduling stream identifier in the added field.
  9. 一种基于调度流标识的报文调度装置,包括:A message scheduling device based on a scheduling flow identifier, comprising:
    第二获取模块,设置为在接收到包括调度流标识的报文后,获取所述报文中的调度流标识;The second obtaining module is configured to: after receiving the packet that includes the scheduling flow identifier, obtain the scheduling flow identifier in the packet;
    调度模块,设置为根据所述调度流标识,对所述报文进行调度操作。The scheduling module is configured to perform a scheduling operation on the packet according to the scheduling flow identifier.
  10. 根据权利要求9所述的装置,所述装置还包括:The apparatus of claim 9 further comprising:
    第三获取模块,设置为获取所述报文在转发路径上的下一转发设备对应的调度流标识;a third acquiring module, configured to obtain a scheduling flow identifier corresponding to a next forwarding device of the packet on the forwarding path;
    替换模块,设置为将所述报文中的转发标识替换为所述下一转发设备对应的调度流标识;The replacement module is configured to replace the forwarding identifier in the packet with the scheduling flow identifier corresponding to the next forwarding device;
    第二发送模块,设置为将完成调度流标识替换后的报文发送出去。The second sending module is configured to send the packet after the completion of the scheduling flow identifier is replaced.
  11. 一种计算机存储介质,所述计算机存储介质中存储有计算机可执行指令,所述计算机可执行指令用于执行权利要求1~3中任一项所述的方法。A computer storage medium having stored therein computer executable instructions for performing the method of any one of claims 1 to 3.
  12. 一种计算机存储介质,所述计算机存储介质中存储有计算机可执行指令,所述计算机可执行指令用于执行权利要求4~5中任一项所述的方法。 A computer storage medium having stored therein computer executable instructions for performing the method of any one of claims 4-5.
PCT/CN2015/082100 2015-03-20 2015-06-23 Scheduling flow identifier-based packet scheduling method and device WO2016150020A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201510125978.5 2015-03-20
CN201510125978.5A CN106034089A (en) 2015-03-20 2015-03-20 Message scheduling method and device based on scheduling flow identification

Publications (1)

Publication Number Publication Date
WO2016150020A1 true WO2016150020A1 (en) 2016-09-29

Family

ID=56976931

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2015/082100 WO2016150020A1 (en) 2015-03-20 2015-06-23 Scheduling flow identifier-based packet scheduling method and device

Country Status (2)

Country Link
CN (1) CN106034089A (en)
WO (1) WO2016150020A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113364676A (en) * 2020-03-05 2021-09-07 华为技术有限公司 Data stream processing method and device

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108011824B (en) 2016-11-02 2021-07-09 华为技术有限公司 Message processing method and network equipment
CN107948088B (en) * 2018-01-05 2021-10-01 宝牧科技(天津)有限公司 Method for balancing network application layer load
CN110351030B (en) 2018-04-03 2022-07-12 华为技术有限公司 Message transmission method, device and system
WO2019192306A1 (en) * 2018-04-03 2019-10-10 华为技术有限公司 Message transmission method, apparatus and system

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102271079A (en) * 2010-06-04 2011-12-07 华为技术有限公司 Message forwarding method, node and system
CN103748842A (en) * 2013-06-26 2014-04-23 华为技术有限公司 Method, device and route device for forwarding data packages
US20140146677A1 (en) * 2012-11-09 2014-05-29 Aruba Networks, Inc. Dynamic determination of transmission parameters based on packet priority and network conditions

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102215160B (en) * 2010-04-07 2016-01-20 中兴通讯股份有限公司 Data communication system and method
CN102970239B (en) * 2012-11-28 2015-07-22 福建星网锐捷网络有限公司 Flow processing method, flow processing device, router and flow processing system

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102271079A (en) * 2010-06-04 2011-12-07 华为技术有限公司 Message forwarding method, node and system
US20140146677A1 (en) * 2012-11-09 2014-05-29 Aruba Networks, Inc. Dynamic determination of transmission parameters based on packet priority and network conditions
CN103748842A (en) * 2013-06-26 2014-04-23 华为技术有限公司 Method, device and route device for forwarding data packages

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113364676A (en) * 2020-03-05 2021-09-07 华为技术有限公司 Data stream processing method and device
WO2021174986A1 (en) * 2020-03-05 2021-09-10 华为技术有限公司 Data stream processing method and device
CN113364676B (en) * 2020-03-05 2023-05-02 华为技术有限公司 Method and device for processing data stream

Also Published As

Publication number Publication date
CN106034089A (en) 2016-10-19

Similar Documents

Publication Publication Date Title
US10110517B2 (en) System and method for open vSwitch virtual switch that supports IEEE 802.1p
EP3314827B1 (en) Method and system for managing data traffic in a computing network
WO2017070970A1 (en) Route determining method and corresponding apparatus and system
WO2016150020A1 (en) Scheduling flow identifier-based packet scheduling method and device
US8284789B2 (en) Methods and apparatus for providing dynamic data flow queues
US11165716B2 (en) Data flow processing method and device
WO2020087523A1 (en) Network communication method and apparatus, and electronic device
US20210367896A1 (en) Service Packet Processing Method, Apparatus, and System
WO2012065477A1 (en) Method and system for avoiding message congestion
WO2015101066A1 (en) Method and node for establishing quality of service reservation
WO2015039617A1 (en) Method, system, and device for packet processing
US11223568B2 (en) Packet processing method and apparatus
US8787160B2 (en) Method, apparatus, and system for judging path congestion
WO2021121086A1 (en) Traffic scheduling method, electronic device and storage medium
CN106789671B (en) Service message forwarding method and device
KR100585934B1 (en) Method of Dynamic Management of Traffic Conditioner Parameter and Table of Class of Service on Router
WO2022183879A1 (en) Packet forwarding method, electronic device, and storage medium
WO2017193814A1 (en) Service chain generation method and system
CN111865805B (en) Multicast GRE message processing method and system
US9215088B2 (en) Identification of application sessions
WO2023092322A1 (en) Method for sending uplink data packet and communication apparatus
CN110958185B (en) QoS configuration method and device based on service
WO2022237860A1 (en) Packet processing method, resource allocation method and related device
WO2023185662A1 (en) Deterministic service method for realizing network underlying resource awareness, and electronic device and computer-readable storage medium
WO2024104007A1 (en) Packet transmission method and apparatus, storage medium and electronic device

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 15885958

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 15885958

Country of ref document: EP

Kind code of ref document: A1