WO2015106623A1 - Method and apparatus for configuring and delivering flow table entry - Google Patents

Method and apparatus for configuring and delivering flow table entry Download PDF

Info

Publication number
WO2015106623A1
WO2015106623A1 PCT/CN2014/095230 CN2014095230W WO2015106623A1 WO 2015106623 A1 WO2015106623 A1 WO 2015106623A1 CN 2014095230 W CN2014095230 W CN 2014095230W WO 2015106623 A1 WO2015106623 A1 WO 2015106623A1
Authority
WO
WIPO (PCT)
Prior art keywords
flow
message
data packet
flow entry
switch
Prior art date
Application number
PCT/CN2014/095230
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 WO2015106623A1 publication Critical patent/WO2015106623A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/42Centralised routing
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/02Topology update or discovery
    • H04L45/036Updating the topology between route computation elements, e.g. between OpenFlow controllers

Definitions

  • the present invention relates to the field of communication network technologies, and in particular, to a method and an apparatus for configuring and sending a flow entry.
  • the OpenFlow network is a new type of network innovation architecture consisting mainly of controllers and switches.
  • the switch function is focused and simplified, and is only responsible for data forwarding.
  • the controller centrally controls the entire network to implement the control layer function.
  • the controller exchanges information with the switch through the standard OpenFlow protocol for unified, flexible, and efficient network maintenance and management.
  • the switch is the core component of the entire OpenFlow network, and the flow table records the rules for the switch to forward packets.
  • a flow table usually consists of multiple flow entries. Each flow entry is a packet forwarding rule.
  • the switch queries the flow table to obtain forwarding rules for forwarding packets.
  • the software system of the switch includes a software layer and a hardware layer. In the prior art, the working process of the switch and the controller is: after receiving a data packet, the switch searches for a flow entry matching the data packet in the flow table of the hardware layer. If no matching flow entry is found in the flow table of the hardware layer, the flow table entry is searched for in the flow table of the software layer.
  • the data packet is reported to the controller; the controller generates a flow entry that matches the data packet, and the data packet and the flow entry (the delivered flow entry may be all matching flow entries, or may be matched)
  • a flow entry that has never been sent from all the flow entries is sent to the switch.
  • the switch After receiving the flow entry sent by the controller, the switch saves it to the flow table of the software layer, and then at the software layer. All the flow entries matching the data packet are searched in the flow table.
  • the flow table entries of the hardware layer are saved to the flow table of the hardware layer. After the switch receives the data packet, it can directly find the matching flow entry in the flow table of the hardware layer, and forward the data packet according to the packet forwarding rule of the matched flow entry.
  • the present invention provides a method and a device for configuring and sending a flow entry, which are used to solve the problem that the configuration time of the flow entry of the hardware layer in the prior art is long, and the forwarding delay of the data packet is increased. And, the problem of data packet loss may occur, and the technical solution is as follows:
  • a first aspect is a method for configuring a flow entry, the method comprising:
  • the switch sends a request message to the controller for requesting the sending of the flow entry, where the request message carries the data packet to be forwarded;
  • the switch extracts, from the response message, all flow entries that match the data packet to be forwarded;
  • the switch aggregates all the extracted flow entries into the flow entry of the hardware layer, and configures the flow entry of the hardware layer to the hardware layer when the switch supports the flow entry of the hardware layer. In the flow table.
  • the method further includes:
  • the data packet to be forwarded is forwarded by all the flow entry items that are carried in the response message and that match the data packet to be forwarded.
  • the switch and the controller communicate by using an OpenFlow protocol, where the request is The message and the response message are transmitted through the OpenFlow protocol.
  • the response message is an extended ofp_flow_mod message
  • the extended ofp_flow_mod message is defined in the ofp_flow_mod message.
  • the message obtained after the array, and the extended ofp_flow_mod message can carry multiple flow table entries simultaneously through the defined array.
  • the response message further carries a message type identifier and a flow entry quantity identifier, where the message type identifier is used
  • the number of the flow table entries is used to indicate the number of flow entry entries carried in the extended of_p_flow_mod message, indicating that the response message is an extended ofp_flow_mod message.
  • the method further includes: configuring all the extracted flow entry items into a flow table of the software layer.
  • a second aspect is a method for sending a flow entry, the method comprising:
  • the controller receives a request message sent by the switch for requesting the sending of the flow entry, where the request message carries the data packet to be forwarded;
  • the controller generates all flow entry items that match the data packet to be forwarded
  • a response message to the switch where the response message carries all flow entries that match the data packet to be forwarded, where all flow entries matching the data packet are used.
  • the flow table entry is aggregated into a hardware layer, and the flow entry of the hardware layer is used to be configured in a flow table of a hardware layer of the switch.
  • the controller and the switch communicate by using an OpenFlow protocol, and the request message and the response message are transmitted by using the OpenFlow protocol. .
  • the response message is an extended ofp_flow_mod message
  • the extended ofp_flow_mod message is defined in the ofp_flow_mod message.
  • the message obtained after the array, and the extended ofp_flow_mod message can carry multiple flow table entries simultaneously through the defined array.
  • a third aspect is an apparatus for configuring a flow entry, the device comprising:
  • a sending module configured to send, to the controller, a request message for requesting the sending of the flow entry, where the request message carries the data packet to be forwarded;
  • a receiving module configured to receive a response message returned by the controller, where the response message carries all flow entry items that match the data packet to be forwarded;
  • An extracting module configured to extract, from the response message received by the receiving module, all flow entry items that match the data packet to be forwarded;
  • a hardware layer configuration module configured to aggregate all flow entries extracted by the extraction module into flow entry entries of the hardware layer, and when the switch supports the flow entry of the hardware layer, the hardware layer The flow entry is configured in the flow table of the hardware layer.
  • the device further includes:
  • a forwarding module configured to forward the data packet to be forwarded by using all the flow entry that is matched by the data packet to be forwarded in the response message that is received by the receiving module.
  • the switch and the controller communicate by using an OpenFlow protocol, the request The message and the response message are transmitted through the OpenFlow protocol.
  • the response message is an extended ofp_flow_mod message
  • the extended ofp_flow_mod message is defined in the ofp_flow_mod message.
  • the message obtained after the array, and the extended ofp_flow_mod message can carry multiple flow table entries simultaneously through the defined array.
  • the response message further carries a message type identifier and a flow entry quantity identifier, where the message type identifier
  • the number of the flow table entries is used to indicate the number of flow entry entries carried in the extended of_p_flow_mod message, which is used to indicate that the response message is an extended of_p_flow_mod message.
  • the device further includes:
  • the software layer configuration module is configured to configure all the extracted flow entry items into the flow table of the software layer.
  • a device for delivering a flow entry comprising:
  • a receiving module configured to receive, by the switch, a request message for requesting the sending of the flow entry, where the request message carries the data packet to be forwarded;
  • a flow entry generation module configured to generate all flow entry items that match the data packet to be forwarded
  • a sending module configured to return a response message to the switch, where the response message carries all flow entries that match the data packet to be forwarded, where all flows that match the data packet to be forwarded
  • the entry is used to aggregate the flow entry of the hardware layer, and the flow entry of the hardware layer is used to be configured in the flow table of the hardware layer of the switch.
  • the controller and the switch communicate by using an OpenFlow protocol, and the request message and the response message are transmitted by using the OpenFlow protocol. .
  • the response message is an extended ofp_flow_mod message
  • the extended ofp_flow_mod message is defined in the ofp_flow_mod message
  • the message obtained after the array, and the extended ofp_flow_mod message can carry multiple flow table entries simultaneously through the defined array.
  • the present invention provides a configuration, a method and a device for sending a flow entry, because the controller can bind all the flow entries matching the data packet to the switch through a message, so the switch receives the controller.
  • the controller can bind all the flow entries matching the data packet to the switch through a message, so the switch receives the controller.
  • all the flow entries matching the data packet can be obtained from the received message, so that all the flow entry matching the data packet can be directly aggregated into the hardware layer flow entry and configured to the hardware layer.
  • the method and the device provided by the present invention shorten the hardware layer because the switch does not need to find all flow entries matching the data packet in the laminar flow table of the software.
  • the configuration time of the flow entry shortens the forwarding delay of the data packet and reduces the number of packet loss.
  • FIG. 1 is a schematic flowchart of a method for configuring a flow entry according to an embodiment of the present disclosure
  • FIG. 2 is a schematic flowchart diagram of another method for configuring a flow entry according to an embodiment of the present disclosure
  • FIG. 3 is a schematic flowchart diagram of a method for sending a flow entry according to an embodiment of the present disclosure
  • FIG. 4 is a schematic diagram of a flow entry generated by a controller that matches a data packet
  • FIG. 5 is a schematic structural diagram of an apparatus 50 for configuring a flow entry according to an embodiment of the present disclosure
  • FIG. 6 is a schematic structural diagram of an apparatus 60 for sending a flow entry according to an embodiment of the present disclosure
  • FIG. 7 is a schematic structural diagram of a switch 70 according to an embodiment of the present invention.
  • FIG. 8 is a schematic structural diagram of a controller 80 according to an embodiment of the present invention.
  • the controller After the controller determines the flow entry that matches the data packet reported by the switch, the controller sends the data packet and the matched flow entry to the switch.
  • the controller sends the packet. All the flow entries matching the data packet.
  • the controller sends only the flow entry that has not been delivered. Specifically, the controller sends the flow entry through the ofp_flow_mod message to the ofp_flow_mod. In the case of a message, it can only carry one flow entry.
  • the flow entry matching the data packet is a flow entry a, a flow entry b, a flow entry c, and a flow entry d.
  • the controller matches the flow with the data packet.
  • the table entry a, the flow entry b, the flow entry c, and the flow entry d are all delivered. Specifically, the controller sends the flow entry a, the flow entry b, the flow entry c, and the flow table through the four of_p_flow_mod messages. For the second possible case, if the flow entry b and the flow entry c have been delivered, the controller sends only the flow entry a and the flow entry d. Specifically, the controller passes two The flow table entry a and the flow entry d are sent by the ofp_flow_mod message.
  • the switch can receive all the flow entries that are sent by the controller and match the data packets. However, because the flow entries are sent by multiple ofp_flow_mod messages, the flow entries are sent. For a switch, it is an isolated flow entry. The switch does not know whether there is any association between these flow entries. On the other hand, the switch does not know whether there is any association between the flow entries sent by the controller. On the other hand, because the controller sends only some flow entries that match the data packet, The switch cannot know other flow entries that match the packet.
  • the switch After the switch receives the flow entry sent by the controller, the switch must first save the received flow entry to the flow table of the software layer, and then look it up in the flow table of the software layer to obtain and receive the flow entry. All the flow entries of the data packet are matched, and then the flow table entries of the hardware layer are configured. The process of finding all the flow entries matching the data packet in the flow table of the software layer causes the delay of configuring the flow entry of the hardware layer to the hardware layer to increase, thereby causing the delay of forwarding the data packet at the hardware layer to increase. And, in the case of high-speed packet delivery, packet loss is severe.
  • FIG. 1 is a schematic flowchart of a method for configuring a flow entry according to an embodiment of the present invention.
  • the technical solution in this embodiment may be specifically applied to an OpenFlow network, and a switch and control in an OpenFlow network. Communicating between the devices through the OpenFlow protocol, the method may include:
  • Step S101 The switch sends a request message for requesting the sending of the flow entry to the controller, where the request message carries the data packet to be forwarded.
  • the switch When receiving the data packet to be forwarded, the switch searches for the flow entry matching the data packet to be forwarded in the flow table of the hardware layer. If the flow entry matching the data packet to be forwarded is not found, the switch then proceeds. The flow table entry matching the data packet to be forwarded is searched in the flow table of the software layer. If the flow table entry matching the data packet to be forwarded is not found in the flow table of the software layer, a flow entry is sent to the controller. The request message of the flow entry is requested, and the request message carries the data packet to be forwarded.
  • the request message for requesting the sending of the flow entry may be a packet_in message.
  • Step S102 The switch receives a response message returned by the controller.
  • the response message carries all the flow entry items that match the data packet to be forwarded.
  • the controller sends all the flow entries matching the data packet to be forwarded to the switch through a response message, that is, all the flow entries matching the data packet to be forwarded are bound together. A message was sent down.
  • Step S103 The switch extracts, from the response message, all flow entries that match the data packet to be forwarded.
  • Step S104 The switch aggregates all the extracted flow entries into the flow entry of the hardware layer, and configures the flow entry of the hardware layer into the flow table of the hardware layer when the switch supports the flow entry of the hardware layer. .
  • the switch Since the flow entry extracted from the received response message is all flow entries matching the data packet to be forwarded, the switch does not need to look up the flow table matching the data packet to be forwarded in the flow table of the software layer.
  • the flow entry of the hardware layer can be directly configured into the flow table of the hardware layer when the switch supports the flow entry of the hardware layer. in.
  • the controller can bind all the flow entries matching the data packet to the switch through a message, so the switch sends the switch to the controller. All the flow entries matching the data packet can be obtained, and all the flow entries matching the data packet can be directly aggregated into the flow table entries of the hardware layer and configured into the flow table of the hardware layer.
  • the method for configuring a flow entry in the embodiment of the present invention shortens the configuration of the flow entry of the hardware layer because the flow entry matching the data packet is not found in the flow table of the software layer. Time, which in turn shortens the forwarding delay of the packet.
  • the hardware layer because the processing capability of the software layer is limited (the forwarding speed of data packets is slow), when the number of data packets sent by the hardware layer to the software layer exceeds the processing capability of the software layer, some data packets are discarded (for example, the software layer). 5 packets can be forwarded every second, but now the hardware layer receives 10 packets, then the hardware layer will discard 5 packets when sending packets to the software layer. In this embodiment, the hardware layer flows. The configuration time of the entry is shortened, which enables the data packet that should be sent to the software layer for forwarding to be forwarded at the hardware layer. Compared with the software layer, the hardware layer has a stronger processing capability (the packet forwarding speed is faster), so , reducing the number of packets lost.
  • FIG. 2 is a schematic flowchart of another method for configuring a flow entry according to an embodiment of the present invention.
  • the technical solution in this embodiment may be specifically applied to an OpenFlow network, between a switch and a controller in an OpenFlow network. Communicating through the OpenFlow protocol, the method can include:
  • Step S201 The switch sends a request message for requesting the delivery of the flow entry to the controller, where the request message carries the data packet to be forwarded.
  • the switch After receiving the data packet to be forwarded, the switch searches for the flow entry matching the data packet to be forwarded in the flow table of the hardware layer. If the flow table matching the data packet to be forwarded is not found, the flow table is not found. Then, the flow table entry matching the data packet to be forwarded is searched in the flow table of the software layer. If the flow table entry matching the data packet to be forwarded is not found in the flow table of the software layer, then The controller sends a request message for requesting the delivery of the flow entry, and the request message carries the data packet to be forwarded.
  • the request message for requesting the sending of the flow entry may be a packet_in message.
  • Step S202 The switch receives a response message returned by the controller.
  • the response message carries all the flow entry items that match the data packet to be forwarded.
  • the controller sends all the flow entries matching the data packet to be forwarded to the switch through a response message, that is, all the flow entries matching the data packet to be forwarded are bound together. A message was sent down.
  • the response message returned by the controller may be an extended ofp_flow_mod message.
  • the extended ofp_flow_mod message is a message obtained after defining an array in the ofp_flow_mod message, and the extended fpt_flow_mod message can carry multiple flow table entries simultaneously through the defined array.
  • the ofp_flow_mod message is a message defined by the OpenFlow protocol in the prior art.
  • Each of the ofp_flow_mod messages in the prior art can only carry one flow entry, that is, if there are multiple flow entries to be delivered by the OpenFlow controller, Then, it needs to deliver multiple ofp_flow_mod messages.
  • the extended ofp_flow_mod message carries a message type identifier and a flow entry quantity identifier in addition to all the flow entry items that match the data packet.
  • the message type identifier is used to indicate that the response message is an extended ofp_flow_mod message
  • the number of flow entry entries is used to indicate the number of flow entry entries carried in the extended ofp_flow_mod message.
  • the number of the flow table entries of the extended ofp_flow_mod message indicates that the number of flow entries that are carried by the extended ofp_flow_mod message is indicated by the number of the flow entry entries.
  • the switch may need to support the configuration of the flow entry in the prior art, and support the configuration of the flow entry provided by the embodiment of the present invention.
  • there are two kinds of response messages received by the switch one is the ofp_flow_mod message in the prior art, and the other is an extension provided by the embodiment of the present invention.
  • the ofp_flow_mod message in order to distinguish the two types of messages, may carry the message type identifier in the extended ofp_flow_mod message. After receiving the extended ofp_flow_mod message, the switch can know that the received message is carried by the message type identifier carried in the message. An extended ofp_flow_mod message for multiple flow entries.
  • the number indicates the number of flow entries carried in the extended ofp_flow_mod message, and the flow_mod contains all the flow entries matching the data packet to be forwarded.
  • Step S203 The switch extracts, from the response message, all flow entries that match the data packet to be forwarded.
  • the switch extracts, from the extended ofp_flow_mod message, all flow entries that match the data packet to be forwarded. Further, the number of the flow entry to be extracted may be verified by the number of the flow entry indicated by the number of the flow entry.
  • Step S204 The switch aggregates all the extracted flow entries into the flow entry of the hardware layer.
  • Each flow entry includes matching domain information and forwarding action information.
  • the switch aggregates all the flow entries into the flow entries of the hardware layer. Specifically, the matching domain information of all the flow entries is aggregated, and the matching domain information of the flow entries of the hardware layer is obtained. The forwarding action information in the flow entry is aggregated to obtain the forwarding action information of the flow entry of the hardware layer. The matching domain information of the flow entry of the hardware layer and the forwarding action information of the flow entry of the hardware layer form a flow table of the hardware layer. item.
  • Step S205 The switch determines whether it supports the flow entry of the hardware layer. If yes, the process goes to step S206a, otherwise, the process goes to step S206b.
  • the switch determines whether the flow entry of the hardware layer is supported by the switch: the matching domain information in the flow entry obtained by the switch and the matching domain information in the flow table of the hardware layer are In the row comparison, if the matching domain information in the flow entry obtained by the aggregation is the same as the matching domain information in the flow table of the hardware layer, or the matching domain information in the flow table of the hardware layer includes the flow entry obtained by the aggregation. Matching the domain information determines that it supports the flow entry of the hardware layer. Otherwise, it determines that it does not support the flow entry of the hardware layer.
  • the matching domain information in the aggregated flow entry includes three matching fields A, B, and C.
  • the matching domain information in the flow table of the hardware layer also includes three matching fields A, B, and C, and then The switch supports flow table entries at the hardware layer.
  • the matching domain information in the aggregated flow entry includes three matching fields A, B, and C.
  • the matching information in the flow table of the hardware layer includes five matching fields A, B, C, D, and E. Since the matching information A, B, C, D, and E in the flow table of the hardware layer includes the matching domain information A, B, and C in the aggregated flow entry, the determination switch supports the flow entry of the hardware layer.
  • the matching domain information in the aggregated flow entry includes three matching fields A, B, and C.
  • the matching information in the flow table of the hardware layer includes five matching fields A, B, D, E, and F. Since the matching information in the matching information in the flow table of the hardware layer does not include the matching field C, it is determined that the switch does not support the flow entry of the hardware layer.
  • Step S206a When the switch itself supports the flow entry of the hardware layer, the flow entry of the hardware layer is configured into the flow table of the hardware layer.
  • the switch can directly aggregate all the extracted flow entry into a hardware layer flow entry, and the switch supports the hardware.
  • the flow entry of the hardware layer is configured in the flow table of the hardware layer.
  • the switch can directly find the matching flow entry in the flow table of the hardware layer. And forwarding the data packet according to the packet forwarding rule of the matched flow entry, instead of saving the received flow entry to the software layer as in the prior art, and finding the matching with the data packet in the flow table of the software layer After all the flow entries are added, all the flow entries can be aggregated into the flow entries of the hardware layer.
  • Step S206b When the switch does not support the flow entry of the hardware layer, all the extracted flow entries are configured in the flow table of the software layer.
  • the switch when the switch does not support the flow entry of the hardware layer, it indicates that when the same data packet is received, the data packet cannot be forwarded at the hardware layer, in order to implement the data packet. Forwarding, all the extracted flow entries are configured in the flow table of the software layer, so that when the hardware layer cannot forward the data packet, the software layer can implement the data packet forwarding.
  • the switch when the switch does not support the flow entry of the hardware layer, all the extracted flow entries are saved to the flow table of the software layer, and another possible
  • the switch saves all the extracted flow entries to the flow table of the software layer, and aggregates all the extracted flow entries into a flow table of the hardware layer.
  • the flow entry of the hardware layer is supported by the hardware layer, the flow entry of the hardware layer is configured in the flow table of the hardware layer, and the flow of the hardware layer is discarded when the flow entry of the hardware layer is not supported by itself.
  • the entry that is, in this implementation manner, the switch first configures all the extracted flow entry items into the flow table of the software layer regardless of whether the switch supports the flow entry of the hardware layer.
  • the controller can bind all the flow entries matching the data packet to the switch through a message, so the switch sends the switch to the controller. All the flow entries matching the data packet can be obtained, and all the flow entries matching the data packet can be directly aggregated into the flow table entries of the hardware layer and configured into the flow table of the hardware layer.
  • the method for configuring a flow entry in the embodiment of the present invention shortens the configuration of the flow entry of the hardware layer by not searching for the flow entry matching the data packet in the flow table of the software layer.
  • the hardware layer time which in turn shortens the packet forwarding delay.
  • the hardware layer because the processing capability of the software layer is limited (the forwarding speed of data packets is slow), when the number of data packets sent by the hardware layer to the software layer exceeds the processing capability of the software layer, some data packets are discarded (for example, the software layer). 5 packets can be forwarded every second, but now the hardware layer receives 10 packets, then the hardware layer will discard 5 packets when sending packets to the software layer. In this embodiment, the hardware layer flows. The configuration time of the entry is shortened, which enables the data packet that should be sent to the software layer for forwarding to be forwarded at the hardware layer. Compared with the software layer, the hardware layer has a stronger processing capability (the packet forwarding speed is faster), so , reducing the number of packets lost.
  • the method for configuring a flow entry may further include: after receiving the response message sent by the controller, forwarding the data packet to be forwarded.
  • the data packet to be forwarded is directly forwarded through all the flow entries that are matched by the data packet to be forwarded in the response message.
  • the data packet to be forwarded is forwarded from the software layer, and another possible In the implementation manner, after the flow entry of the hardware layer obtained by the aggregation is configured to the hardware layer, the data packet to be forwarded is forwarded from the hardware layer.
  • FIG. 3 is a schematic flowchart of a method for sending a flow entry according to an embodiment of the present disclosure, where the method may include:
  • Step S301 The controller receives a request message sent by the switch for requesting the sending of the flow entry.
  • the request message carries a data packet to be forwarded.
  • Step S302 The controller generates all flow entry items that match the data packet to be forwarded.
  • the controller determines, by using information in the data packet to be forwarded, a flow entry that matches the data packet to be forwarded.
  • the controller after receiving the data packet with the Mpls_label of 10 and the destination IP address of 192.168.0.6, the controller generates the T0_1 flow entry and the T2_1 flow entry as shown in FIG. 4, and then T0_1 and T2_1 through a message.
  • the two flow entries are bound together and delivered to the switch. Specifically, the controller determines the flow table T0 table and the T1 table that match the data packet through the Mpls_label and the destination IP, and then determines the flow table entries T0_1 and T2_1 that match the data packet in the T0 table and the T1 table.
  • the Mpls_label in the T0 table is a matching field supported by the T0 table
  • the Eth_type, Src_ip, and Dst_ip in the T1 table are matching fields supported by the T2 table
  • the actions in the T0 table and the T1 table indicate forwarding actions.
  • Step S303 The controller returns a response message to the switch.
  • the response message carries all the flow entries that match the data packet to be forwarded, and all the flow entries that match the data packet to be forwarded are used to be aggregated into the flow table entry of the hardware layer, and the flow table of the hardware layer.
  • the item is used to configure the flow table to the hardware layer of the switch.
  • the response message is an extended ofp_flow_mod message
  • the extended ofp_flow_mod message is a message obtained after defining an array in the ofp_flow_mod message
  • the extended fpt_flow_mod message can carry multiple multiple times through the defined array.
  • the ofp_flow_mod message is a message defined by the OpenFlow protocol in the prior art.
  • Each of the ofp_flow_mod messages in the prior art can only carry one flow entry, that is, if there are multiple flow entries to be delivered by the controller, It needs to issue multiple ofp_flow_mod messages.
  • the extended ofp_flow_mod message carries a message type identifier and a flow entry quantity identifier in addition to all the flow entry items that match the data packet to be forwarded.
  • the message type identifier is used to indicate that the response message is an extended ofp_flow_mod message
  • the number of flow entry entries is used to indicate the number of flow entry entries carried in the extended ofp_flow_mod message.
  • the controller can bind all the flow entries matching the data packet to the switch through a message, so that the switch sends the switch to the controller. All the flow entries matching the data packet can be obtained, and all the flow entries matching the data packet can be directly aggregated into the flow table entries of the hardware layer and configured into the flow table of the hardware layer.
  • the method for sending a flow entry in the embodiment of the present invention does not need to find a flow entry matching the data packet in the flow table of the software layer, so that the switch configures the flow entry of the hardware layer to the flow of the hardware layer.
  • the time of the table is shortened, which in turn reduces the delay for the switch to forward packets.
  • the hardware layer because the processing capability of the software layer is limited (the forwarding speed of data packets is slow), when the number of data packets sent by the hardware layer to the software layer exceeds the processing capability of the software layer, some data packets are discarded (for example, the software layer). 5 packets can be forwarded every second, but now the hardware layer receives 10 packets, then the hardware layer will discard 5 packets when sending packets to the software layer. In this embodiment, the hardware layer flows. The configuration time of the entry is shortened, which enables the data packet that should be sent to the software layer for forwarding to be forwarded at the hardware layer. Compared with the software layer, the hardware layer has a stronger processing capability (the packet forwarding speed is faster), so , reducing the number of packets lost.
  • FIG. 5 is a schematic structural diagram of an apparatus for configuring a flow entry according to an embodiment of the present invention.
  • the apparatus may include: a sending module 501, a receiving module 502, an extracting module 503, and a hardware configuration module 504. among them:
  • the sending module 501 is configured to send a request message for requesting the sending of the flow entry to the controller.
  • the request message carries a data packet to be forwarded.
  • the receiving module 502 is configured to receive a response message returned by the controller.
  • the response message carries all the flow entry items that match the data packet to be forwarded.
  • the extracting module 503 is configured to extract, from the response message received by the receiving module 502, all flow entries that match the data packet.
  • the hardware configuration module 504 is configured to aggregate all the flow entries extracted by the extraction module 503 into the flow entry of the hardware layer, and configure the flow entry of the hardware layer to the flow entry of the hardware layer when the switch supports the flow entry of the hardware layer. In the flow table of the hardware layer.
  • the controller can bind all the flow entries matching the data packet to the switch through a message, so the switch sends the switch to the controller. All the flow entries matching the data packet can be obtained, and all the flow entries matching the data packet can be directly aggregated into the flow table entries of the hardware layer and configured into the flow table of the hardware layer.
  • the device for configuring a flow entry in the embodiment of the present invention shortens the flow entry of the hardware layer by not searching for a flow entry matching the data packet in the flow table of the software layer. The configuration time, which in turn shortens the forwarding delay of the packet, and. Reduce the number of packets lost.
  • the apparatus for configuring a flow entry may further include: a forwarding module.
  • the forwarding module is configured to forward the data packet to be forwarded by all the flow entry items that are matched by the data packet to be forwarded and carried in the response message received by the receiving module 502.
  • the apparatus for configuring a flow entry may further include: a software configuration module.
  • the software configuration module is configured to configure all flow entries extracted by the extraction module 503 into a flow table of the software layer.
  • the response message received by the receiving module 502 in the foregoing embodiment is an extended ofp_flow_mod message.
  • the extended ofp_flow_mod message is a message obtained after defining an array in the ofp_flow_mod message, and the extended fpt_flow_mod message can carry multiple flow table entries simultaneously through the defined array.
  • the ofp_flow_mod message is a message defined by the OpenFlow protocol in the prior art.
  • Each of the ofp_flow_mod messages in the prior art can only carry one flow entry, that is, if there are multiple flow entries to be delivered by the controller, It needs to issue multiple ofp_flow_mod messages.
  • FIG. 6 is a schematic structural diagram of an apparatus for sending a flow entry according to an embodiment of the present disclosure.
  • the device may include: a receiving module 601, a flow entry generating module 602, and a sending module 603. among them:
  • the receiving module 601 is configured to receive a request message sent by the switch for requesting the sending of the flow entry, where the request message carries the data packet to be forwarded.
  • the flow entry generation module 602 is configured to generate all flow entry items that match the data packet received by the receiving module 601.
  • the sending module 603 is configured to return a response message to the switch, where the response message carries all flow entries that are generated by the flow entry generation module 602 and that match the data packet.
  • All the flow entries matching the data packet are used to be aggregated into the flow entry of the hardware layer, and the flow entry of the hardware layer is configured to be configured in the flow table of the hardware layer of the switch.
  • the response message returned by the sending module 603 to the switch is an extended ofp_flow_mod message.
  • the extended ofp_flow_mod message is a message obtained after defining an array in the ofp_flow_mod message, and the extended fpt_flow_mod message can carry multiple flow entry items simultaneously through the defined array.
  • the device for sending a flow entry can bind all the flow entries matching the data packet to the switch through a message, so that the switch receives the message sent by the controller. All the flow entries matching the data packet can be obtained, and all the flow entries matching the data packet can be directly aggregated into the flow table entry of the hardware layer and configured into the flow table of the hardware layer.
  • the method for sending a flow entry in the embodiment of the present invention does not need to find a flow entry matching the data packet in the flow table of the software layer, so that the switch configures the flow entry of the hardware layer to the flow of the hardware layer.
  • the time in the table is shortened, which in turn shortens the forwarding delay of the data packet and reduces the packet loss amount of the data packet.
  • the device for configuring the flow entry shown in FIG. 5 is applied to the switch in the switch, and the switch of the device configured with the flow entry shown in FIG. 5 is configured to shorten the configuration time of the flow entry of the hardware layer. , thereby shortening the forwarding delay of the data packet, and reducing the number of packet loss of the data packet.
  • FIG. 7 is a schematic structural diagram of a switch 70 according to an embodiment of the present invention.
  • the switch 70 may include at least a memory 701 and a processor 702 connected to the memory 701 through a communication bus.
  • the memory 701 can be used to store software programs and modules.
  • the processor 702 executes various functional applications and data processing of the switch 70 by running software programs and modules stored in the memory 701.
  • the memory 701 can mainly include a storage program area and a storage data area, wherein the storage program area can store an operating system, an application required for at least one function; and the storage data area can store data created according to the use of the switch 70.
  • the memory 701 may include a high speed random access memory, and may also include a nonvolatile memory such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device.
  • the processor 702 is the control center of the switch 70, connecting various portions of the entire server using various interfaces and lines, by running or executing software programs and/or modules stored in the memory 701, and recalling data stored in the memory 701, The various functions and processing data of the switch 70 are performed to perform overall monitoring of the switch 70.
  • the processor 702 may include one or more processing units; preferably, the processor 702 may integrate an application processor and a modem processor, where the application processor mainly processes an operating system, a user interface, an application, and the like.
  • the modem processor primarily handles wireless communications. It can be understood that the above modem processor may not be integrated into the processor 702.
  • the processor 7602 included in the switch 70 has the following functions:
  • the device for sending a flow entry shown in FIG. 6 is specifically applied to a controller, and a controller for deploying a device that sends a flow entry as shown in FIG. 6 can be configured to configure a hardware layer of the switch.
  • the time of the flow entry is shortened, which shortens the delay of forwarding packets and reduces the number of packets lost.
  • FIG. 8 is a schematic structural diagram of a controller 80 according to an embodiment of the present invention.
  • the switch 80 may include at least a memory 801 and a processor 802 connected to the memory 801 through a communication bus.
  • the memory 801 can be used to store software programs and modules, and the processor 802 executes various functional applications and data processing of the controller 80 by running software programs and modules stored in the memory 801.
  • the memory 801 may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application required for at least one function; and the storage data area may store data created according to the use of the controller 80.
  • the memory 801 may include a high speed random access memory, and may also include a nonvolatile memory such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device.
  • Processor 802 is the control center of controller 80, which connects various portions of the server with various interfaces and lines, by running or executing software programs and/or modules stored in memory 801, and recalling data stored in memory 801. The various functions and processing data of the controller 80 are executed to perform overall monitoring of the controller 80.
  • the processor 802 may include one or more processing units; preferably, the processor 802 may integrate an application processor and a modem processor, where the application processor mainly processes an operating system, a user interface, an application, and the like.
  • the modem processor primarily handles wireless communications. It will be appreciated that the above described modem processor may also not be integrated into the processor 802.
  • the processor 802 included in the controller 80 has the following functions:
  • the disclosed methods, apparatus, and devices may be implemented in other manners.
  • the device embodiments described above are merely illustrative.
  • the division of the unit is only a logical function division.
  • there may be another division manner for example, multiple units or components may be combined or Can be integrated into another system, or some features can be ignored or not executed.
  • the mutual coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection through some communication interface, device or unit, and may be electrical, mechanical or otherwise.
  • the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of the embodiment.
  • each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
  • the functions may be stored in a computer readable storage medium if implemented in the form of a software functional unit and sold or used as a standalone product.
  • the technical solution of the present invention which is essential or contributes to the prior art, or a part of the technical solution, may be embodied in the form of a software product, which is stored in a storage medium, including
  • the instructions are used to cause a computer device (which may be a personal computer, server, or network device, etc.) to perform all or part of the steps of the methods described in various embodiments of the present invention.
  • the foregoing storage medium includes: a U disk, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk, and the like. .

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computing Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The present application provides a method and an apparatus for configuring and delivering a flow table entry. The method comprises: a switch sending, to a controller, a request message for requesting delivering a flow table entry, the request message carrying a to-be-forwarded data packet; after the controller receives the request message, the controller generating all flow table entries matching the to-be-forwarded data packet, and returning, to the switch, a response message carrying all the flow table entries matching the to-be-forwarded data packet; after then switch receives the response message, the switch extracting all the flow table entries matching the to-be-forwarded data packet from the response message; and aggregating all the extracted flow table entries into flow table entries of a hardware layer, and when the switch supports the flow table entries of the hardware layer, the switch configuring the flow table entries of the hardware layer into a flow table of the hardware layer. The method and the apparatus for configuring and delivering a flow table entry in the present application can shorten the time of configuring flow table entries of a hardware layer into a flow table of the hardware layer, can shorten the delay of forwarding the data packets, and can reduce the number of lost packets of the data packets.

Description

一种配置、下发流表项的方法及装置Method and device for configuring and sending flow entry 技术领域Technical field
本发明涉及通信网络技术领域,尤其涉及一种配置、下发流表项的方法及装置。The present invention relates to the field of communication network technologies, and in particular, to a method and an apparatus for configuring and sending a flow entry.
背景技术Background technique
OpenFlow网络,是一种新型的网络创新架构,主要由控制器和交换机组成。交换机功能专注而简化,只负责数据转发,控制器则对整个网络进行集中控制,实现控制层功能。控制器通过标准的OpenFlow协议与交换机进行信息交互,从而进行统一、灵活、高效的网络维护和管理。The OpenFlow network is a new type of network innovation architecture consisting mainly of controllers and switches. The switch function is focused and simplified, and is only responsible for data forwarding. The controller centrally controls the entire network to implement the control layer function. The controller exchanges information with the switch through the standard OpenFlow protocol for unified, flexible, and efficient network maintenance and management.
交换机是整个OpenFlow网络的核心部件,而流表记录了交换机转发数据包的规则。流表通常由多个流表项组成,每个流表项为一个数据包转发规则,交换机通过查询流表来获得转发数据包的转发规则。交换机的软件系统包括软件层和硬件层,在现有技术中,交换机与控制器的工作过程为:交换机接收到一个数据包后,在硬件层的流表中查找与数据包匹配的流表项,如果在硬件层的流表中没有查找到匹配的流表项,则在软件层的流表中接着查找流表项,如果在软件层的流表中也没有查找到匹配的流表项,就把数据包上报给控制器;控制器产生与数据包匹配的流表项,并将数据包和流表项(下发的流表项可以是匹配的所有流表项,也可以是匹配的所有流表项中从未下发过的流表项)下发给交换机;交换机接收到控制器下发的流表项后,先将其保存到软件层的流表中,然后在软件层的流表中查找与数据包匹配的所有流表项,最后将匹配的所有流表项聚合为硬件层的流表项,并将该硬件层的流表项保存到硬件层的流表中。当交换机后续再接收到数据包后,就可以直接在硬件层的流表中查找匹配的流表项,并按照该匹配的流表项的数据包转发规则转发该数据包。The switch is the core component of the entire OpenFlow network, and the flow table records the rules for the switch to forward packets. A flow table usually consists of multiple flow entries. Each flow entry is a packet forwarding rule. The switch queries the flow table to obtain forwarding rules for forwarding packets. The software system of the switch includes a software layer and a hardware layer. In the prior art, the working process of the switch and the controller is: after receiving a data packet, the switch searches for a flow entry matching the data packet in the flow table of the hardware layer. If no matching flow entry is found in the flow table of the hardware layer, the flow table entry is searched for in the flow table of the software layer. If no matching flow entry is found in the flow table of the software layer, The data packet is reported to the controller; the controller generates a flow entry that matches the data packet, and the data packet and the flow entry (the delivered flow entry may be all matching flow entries, or may be matched) A flow entry that has never been sent from all the flow entries is sent to the switch. After receiving the flow entry sent by the controller, the switch saves it to the flow table of the software layer, and then at the software layer. All the flow entries matching the data packet are searched in the flow table. The flow table entries of the hardware layer are saved to the flow table of the hardware layer. After the switch receives the data packet, it can directly find the matching flow entry in the flow table of the hardware layer, and forward the data packet according to the packet forwarding rule of the matched flow entry.
发明人在实现本发明创造的过程中发现:在现有技术中,当交换机配置硬件层的流表项时,需要在软件层的流表中查找与数据包匹配的所有流表项,而在软件层的流表中查找匹配的所有流表项的过程本身往往会经历比较 长的时间,由此也会增加硬件层的流表项的配置时间,进而导致数据包的转发时延增大,并且,可能产生数据丢包的问题,特别是在高速转发数据包的情况下,数据包丢包的问题可能会更加严重。In the process of implementing the invention, the inventor finds that, in the prior art, when the switch configures the flow entry of the hardware layer, all the flow entries matching the data packet need to be searched in the flow table of the software layer, and The process of finding all matching flow entries in the flow table of the software layer is often compared. For a long period of time, the configuration time of the flow entry of the hardware layer is also increased, which leads to an increase in the forwarding delay of the data packet, and may cause data packet loss, especially in the case of high-speed forwarding of the data packet. The problem of packet loss can be more serious.
发明内容Summary of the invention
有鉴于此,本发明提供了一种配置、下发流表项的方法及装置,用以解决现有技术中硬件层的流表项的配置时间较长,导致数据包的转发时延增大,并且,可能产生数据丢包的问题,其技术方案如下:In view of the above, the present invention provides a method and a device for configuring and sending a flow entry, which are used to solve the problem that the configuration time of the flow entry of the hardware layer in the prior art is long, and the forwarding delay of the data packet is increased. And, the problem of data packet loss may occur, and the technical solution is as follows:
第一方面,一种配置流表项的方法,所述方法包括:A first aspect is a method for configuring a flow entry, the method comprising:
交换机向控制器发送一个请求下发流表项的请求消息,所述请求消息中携带有待转发的数据包;The switch sends a request message to the controller for requesting the sending of the flow entry, where the request message carries the data packet to be forwarded;
所述交换机接收所述控制器返回的一个响应消息,所述响应消息中携带有与所述待转发的数据包匹配的所有流表项;Receiving, by the switch, a response message returned by the controller, where the response message carries all flow entry items that match the data packet to be forwarded;
所述交换机从所述响应消息中提取与所述待转发的数据包匹配的所有流表项;The switch extracts, from the response message, all flow entries that match the data packet to be forwarded;
所述交换机将提取出的所有流表项聚合为硬件层的流表项,并在所述交换机支持所述硬件层的流表项时,将所述硬件层的流表项配置到硬件层的流表中。The switch aggregates all the extracted flow entries into the flow entry of the hardware layer, and configures the flow entry of the hardware layer to the hardware layer when the switch supports the flow entry of the hardware layer. In the flow table.
结合第一方面,在第一方面的第一种可能的实现方式中,所述方法还包括:In conjunction with the first aspect, in a first possible implementation of the first aspect, the method further includes:
通过所述响应消息中携带的,与所述待转发的数据包匹配的所有流表项转发所述待转发的数据包。The data packet to be forwarded is forwarded by all the flow entry items that are carried in the response message and that match the data packet to be forwarded.
结合第一方面、第一方面的第一种可能的实现方式,在第一方面的第二种可能的实现方式中,所述交换机和所述控制器之间通过OpenFlow协议进行通信,所述请求消息和所述响应消息通过所述OpenFlow协议传输。With reference to the first aspect, the first possible implementation manner of the first aspect, in a second possible implementation manner of the first aspect, the switch and the controller communicate by using an OpenFlow protocol, where the request is The message and the response message are transmitted through the OpenFlow protocol.
结合第一方面的第二种可能的实现方式,在第一方面的第三种可能的实现方式中,所述响应消息为扩展的ofp_flow_mod消息,所述扩展的ofp_flow_mod消息为在ofp_flow_mod消息中定义一个数组后所得到的消息,并且,所述扩展的ofp_flow_mod消息通过定义的数组可同时携带多个流表项。 With reference to the second possible implementation of the first aspect, in a third possible implementation manner of the first aspect, the response message is an extended ofp_flow_mod message, and the extended ofp_flow_mod message is defined in the ofp_flow_mod message. The message obtained after the array, and the extended ofp_flow_mod message can carry multiple flow table entries simultaneously through the defined array.
结合第一方面的第三种可能的实现方式,在第一方面的第四种可能的实现方式中,所述响应消息还携带有消息类型标识以及流表项数量标识,所述消息类型标识用于指示所述响应消息为扩展的ofp_flow_mod消息,所述流表项数量标识用于指示所述扩展的ofp_flow_mod消息中携带的流表项的数量。In conjunction with the third possible implementation of the first aspect, in a fourth possible implementation manner of the first aspect, the response message further carries a message type identifier and a flow entry quantity identifier, where the message type identifier is used The number of the flow table entries is used to indicate the number of flow entry entries carried in the extended of_p_flow_mod message, indicating that the response message is an extended ofp_flow_mod message.
结合第一方面、第一方面的第一种可能的实现方式、第一方面的第二种可能的实现方式、第一方面的第三种可能的实现方式、第一方面的第四种可能的实现方式,在第一方面的第五种可能的实现方式中,所述方法还包括:将提取出的所有流表项配置到软件层的流表中。With reference to the first aspect, the first possible implementation of the first aspect, the second possible implementation of the first aspect, the third possible implementation of the first aspect, the fourth possible aspect of the first aspect The implementation manner is the fifth possible implementation manner of the first aspect, the method further includes: configuring all the extracted flow entry items into a flow table of the software layer.
第二方面,一种下发流表项的方法,所述方法包括:A second aspect is a method for sending a flow entry, the method comprising:
控制器接收交换机发送的一个请求下发流表项的请求消息,所述请求消息中携带有待转发的数据包;The controller receives a request message sent by the switch for requesting the sending of the flow entry, where the request message carries the data packet to be forwarded;
所述控制器生成与所述待转发的数据包匹配的所有流表项;The controller generates all flow entry items that match the data packet to be forwarded;
所述控制器向所述交换机返回一个响应消息,所述响应消息中携带有与所述待转发的数据包匹配的所有流表项,其中,与所述数据包匹配的所有流表项用于聚合为硬件层的流表项,所述硬件层的流表项用于配置到所述交换机的硬件层的流表中。Returning, by the controller, a response message to the switch, where the response message carries all flow entries that match the data packet to be forwarded, where all flow entries matching the data packet are used. The flow table entry is aggregated into a hardware layer, and the flow entry of the hardware layer is used to be configured in a flow table of a hardware layer of the switch.
结合第二方面,在第二方面的第一种可能的实现方式中,所述控制器和所述交换机之间通过OpenFlow协议进行通信,所述请求消息和所述响应消息通过所述OpenFlow协议传输。With reference to the second aspect, in a first possible implementation manner of the second aspect, the controller and the switch communicate by using an OpenFlow protocol, and the request message and the response message are transmitted by using the OpenFlow protocol. .
结合第二方面的第一种可能的实现方式,在第二方面的第二种可能的实现方式中,所述响应消息为扩展的ofp_flow_mod消息,所述扩展的ofp_flow_mod消息为在ofp_flow_mod消息中定义一个数组后所得到的消息,并且,所述扩展的ofp_flow_mod消息通过定义的数组可同时携带多个流表项。With reference to the first possible implementation manner of the second aspect, in a second possible implementation manner of the second aspect, the response message is an extended ofp_flow_mod message, and the extended ofp_flow_mod message is defined in the ofp_flow_mod message. The message obtained after the array, and the extended ofp_flow_mod message can carry multiple flow table entries simultaneously through the defined array.
第三方面,一种配置流表项的装置,所述装置包括:A third aspect is an apparatus for configuring a flow entry, the device comprising:
发送模块,用于向控制器发送一个请求下发流表项的请求消息,所述请求消息中携带有待转发的数据包;a sending module, configured to send, to the controller, a request message for requesting the sending of the flow entry, where the request message carries the data packet to be forwarded;
接收模块,用于接收所述控制器返回的一个响应消息,所述响应消息中携带有与所述待转发的数据包匹配的所有流表项; a receiving module, configured to receive a response message returned by the controller, where the response message carries all flow entry items that match the data packet to be forwarded;
提取模块,用于从所述接收模块接收的所述响应消息中提取与所述待转发的数据包匹配的所有流表项;An extracting module, configured to extract, from the response message received by the receiving module, all flow entry items that match the data packet to be forwarded;
硬件层配置模块,用于将所述提取模块提取出的所有流表项聚合为硬件层的流表项,并在所述交换机支持所述硬件层的流表项时,将所述硬件层的流表项配置到硬件层的流表中。a hardware layer configuration module, configured to aggregate all flow entries extracted by the extraction module into flow entry entries of the hardware layer, and when the switch supports the flow entry of the hardware layer, the hardware layer The flow entry is configured in the flow table of the hardware layer.
结合第三方面,在第三方面的第一种可能的实现方式中,所述装置还包括:In conjunction with the third aspect, in a first possible implementation manner of the third aspect, the device further includes:
转发模块,用于通过所述接收模块接收的所述响应消息中携带的与所述待转发的数据包匹配的所有流表项转发所述待转发的数据包。And a forwarding module, configured to forward the data packet to be forwarded by using all the flow entry that is matched by the data packet to be forwarded in the response message that is received by the receiving module.
结合第三方面、第三方面的第一种可能的实现方式,在第三方面的第二种可能的实现方式中,所述交换机和所述控制器之间通过OpenFlow协议进行通信,所述请求消息和所述响应消息通过所述OpenFlow协议传输。With reference to the third aspect, the first possible implementation manner of the third aspect, in a second possible implementation manner of the third aspect, the switch and the controller communicate by using an OpenFlow protocol, the request The message and the response message are transmitted through the OpenFlow protocol.
结合第三方面的第二种可能的实现方式,在第三方面的第三种可能的实现方式中,所述响应消息为扩展的ofp_flow_mod消息,所述扩展的ofp_flow_mod消息为在ofp_flow_mod消息中定义一个数组后所得到的消息,并且,所述扩展的ofp_flow_mod消息通过定义的数组可同时携带多个流表项。With reference to the second possible implementation of the third aspect, in a third possible implementation manner of the third aspect, the response message is an extended ofp_flow_mod message, and the extended ofp_flow_mod message is defined in the ofp_flow_mod message. The message obtained after the array, and the extended ofp_flow_mod message can carry multiple flow table entries simultaneously through the defined array.
结合第三方面的第三种可能的实现方式中,在第三方面的第四种可能的实现方式中,所述响应消息还携带有消息类型标识以及流表项数量标识,所述消息类型标识用于指示所述响应消息为扩展的ofp_flow_mod消息,所述流表项数量标识用于指示所述扩展的ofp_flow_mod消息中携带的流表项的数量。In conjunction with the third possible implementation manner of the third aspect, in a fourth possible implementation manner of the third aspect, the response message further carries a message type identifier and a flow entry quantity identifier, where the message type identifier The number of the flow table entries is used to indicate the number of flow entry entries carried in the extended of_p_flow_mod message, which is used to indicate that the response message is an extended of_p_flow_mod message.
结合第三方面、第三方面的第一种可能的实现方式、第三方面的第二种可能的实现方式、第三方面的第三种可能的实现方式、第三方面的第四种可能的实现方式,在第三方面的第五种可能的实现方式中,所述装置还包括:With reference to the third aspect, the first possible implementation of the third aspect, the second possible implementation of the third aspect, the third possible implementation of the third aspect, and the fourth possible aspect of the third aspect In a fifth possible implementation manner of the third aspect, the device further includes:
软件层配置模块,用于将提取出的所有流表项配置到软件层的流表中。The software layer configuration module is configured to configure all the extracted flow entry items into the flow table of the software layer.
第四方面,一种下发流表项的装置,所述装置包括:A device for delivering a flow entry, the device comprising:
接收模块,用于接收交换机发送的一个请求下发流表项的请求消息,所述请求消息中携带有待转发的数据包;a receiving module, configured to receive, by the switch, a request message for requesting the sending of the flow entry, where the request message carries the data packet to be forwarded;
流表项生成模块,用于生成与所述待转发的数据包匹配的所有流表项; a flow entry generation module, configured to generate all flow entry items that match the data packet to be forwarded;
发送模块,用于向所述交换机返回一个响应消息,所述响应消息中携带有与所述待转发的数据包匹配的所有流表项,其中,与所述待转发的数据包匹配的所有流表项用于聚合为硬件层的流表项,所述硬件层的流表项用于配置到所述交换机的硬件层的流表中。a sending module, configured to return a response message to the switch, where the response message carries all flow entries that match the data packet to be forwarded, where all flows that match the data packet to be forwarded The entry is used to aggregate the flow entry of the hardware layer, and the flow entry of the hardware layer is used to be configured in the flow table of the hardware layer of the switch.
结合第四方面,在第四方面的第一种可能的实现方式中,所述控制器和所述交换机之间通过OpenFlow协议进行通信,所述请求消息和所述响应消息通过所述OpenFlow协议传输。With reference to the fourth aspect, in a first possible implementation manner of the fourth aspect, the controller and the switch communicate by using an OpenFlow protocol, and the request message and the response message are transmitted by using the OpenFlow protocol. .
结合第四方面的第一种可能的实现方式,在第四方面的第二种可能的实现方式中,所述响应消息为扩展的ofp_flow_mod消息,所述扩展的ofp_flow_mod消息为在ofp_flow_mod消息中定义一个数组后所得到的消息,并且,所述扩展的ofp_flow_mod消息通过定义的数组可同时携带多个流表项。With reference to the first possible implementation manner of the fourth aspect, in a second possible implementation manner of the fourth aspect, the response message is an extended ofp_flow_mod message, and the extended ofp_flow_mod message is defined in the ofp_flow_mod message The message obtained after the array, and the extended ofp_flow_mod message can carry multiple flow table entries simultaneously through the defined array.
上述技术方案具有如下有益效果:The above technical solution has the following beneficial effects:
本发明提供的配置、下发流表项的方法及装置,由于控制器可将与数据包匹配的所有流表项绑定在一起通过一条消息下发至交换机,因此,交换机在接收到控制器下发的消息时,可从接收的消息中获取与数据包匹配的所有流表项,从而可以直接将与数据包匹配的所有流表项聚合为硬件层的流表项并配置到硬件层的流表中。本发明提供的配置、下发流表项的方法及装置与现有技术相比,由于交换机不用在软件的层流表中查找与数据包匹配的所有流表项,因此,缩短了硬件层的流表项的配置时间,进而缩短了数据包的转发时延,并且,降低了数据包的丢包数量。The present invention provides a configuration, a method and a device for sending a flow entry, because the controller can bind all the flow entries matching the data packet to the switch through a message, so the switch receives the controller. When the message is delivered, all the flow entries matching the data packet can be obtained from the received message, so that all the flow entry matching the data packet can be directly aggregated into the hardware layer flow entry and configured to the hardware layer. In the flow table. Compared with the prior art, the method and the device provided by the present invention shorten the hardware layer because the switch does not need to find all flow entries matching the data packet in the laminar flow table of the software. The configuration time of the flow entry shortens the forwarding delay of the data packet and reduces the number of packet loss.
附图说明DRAWINGS
为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据提供的附图获得其他的附图。In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the embodiments or the description of the prior art will be briefly described below. Obviously, the drawings in the following description are only It is an embodiment of the present invention, and those skilled in the art can obtain other drawings according to the provided drawings without any creative work.
图1为本发明实施例提供的一种配置流表项的方法的流程示意图;FIG. 1 is a schematic flowchart of a method for configuring a flow entry according to an embodiment of the present disclosure;
图2为本发明实施例提供的另一种配置流表项的方法的流程示意图;FIG. 2 is a schematic flowchart diagram of another method for configuring a flow entry according to an embodiment of the present disclosure;
图3为本发明实施例提供的一种下发流表项的方法的流程示意图; FIG. 3 is a schematic flowchart diagram of a method for sending a flow entry according to an embodiment of the present disclosure;
图4为控制器产生的与数据包匹配的流表项的示意图;4 is a schematic diagram of a flow entry generated by a controller that matches a data packet;
图5为本发明实施例提供的一种配置流表项的装置50的结构示意图;FIG. 5 is a schematic structural diagram of an apparatus 50 for configuring a flow entry according to an embodiment of the present disclosure;
图6为本发明实施例提供的一种下发流表项的装置60的结构示意图;FIG. 6 is a schematic structural diagram of an apparatus 60 for sending a flow entry according to an embodiment of the present disclosure;
图7为本发明实施例提供的一种交换机70的结构示意图;FIG. 7 is a schematic structural diagram of a switch 70 according to an embodiment of the present invention;
图8为本发明实施例提供的一种控制器80的结构示意图。FIG. 8 is a schematic structural diagram of a controller 80 according to an embodiment of the present invention.
具体实施方式detailed description
下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。The technical solutions in the embodiments of the present invention are clearly and completely described in the following with reference to the accompanying drawings in the embodiments of the present invention. It is obvious that the described embodiments are only a part of the embodiments of the present invention, but not all embodiments. All other embodiments obtained by those skilled in the art based on the embodiments of the present invention without creative efforts are within the scope of the present invention.
在现有技术中,控制器确定出与交换机上报的数据包匹配的流表项之后,将数据包和匹配的流表项下发给交换机,在第一种可能的情况中,控制器下发与数据包匹配的所有流表项,在第二种可能的情况中,控制器只下发其没有下发过的流表项,具体的,控制器通过ofp_flow_mod消息下发流表项,对于ofp_flow_mod消息而言,其只能携带一个流表项。示例性的,与数据包匹配的流表项为流表项a、流表项b、流表项c和流表项d,对于第一种可能的情况,控制器将与数据包匹配的流表项a、流表项b、流表项c和流表项d全部下发,具体的,控制器通过四条ofp_flow_mod消息下发流表项a、流表项b、流表项c和流表项d;对于第二种可能的情况,如果流表项b和流表项c已下发过,那么控制器只下发流表项a和流表项d,具体的,控制器通过两条ofp_flow_mod消息下发流表项a和流表项d。In the prior art, after the controller determines the flow entry that matches the data packet reported by the switch, the controller sends the data packet and the matched flow entry to the switch. In the first possible scenario, the controller sends the packet. All the flow entries matching the data packet. In the second possible case, the controller sends only the flow entry that has not been delivered. Specifically, the controller sends the flow entry through the ofp_flow_mod message to the ofp_flow_mod. In the case of a message, it can only carry one flow entry. Exemplarily, the flow entry matching the data packet is a flow entry a, a flow entry b, a flow entry c, and a flow entry d. For the first possible case, the controller matches the flow with the data packet. The table entry a, the flow entry b, the flow entry c, and the flow entry d are all delivered. Specifically, the controller sends the flow entry a, the flow entry b, the flow entry c, and the flow table through the four of_p_flow_mod messages. For the second possible case, if the flow entry b and the flow entry c have been delivered, the controller sends only the flow entry a and the flow entry d. Specifically, the controller passes two The flow table entry a and the flow entry d are sent by the ofp_flow_mod message.
对于第一种可能的情况,交换机虽然能够接收到控制器下发的与数据包匹配的所有流表项,但由于这些流表项是通过多条ofp_flow_mod消息下发下来,因此,这些流表项对于交换机而言就是一个个孤立的流表项,交换机不知道这些流表项之间是否有关联。对于第二种可能情况,一方面,交换机不知道控制器下发的流表项之间是否有关联,另一方面,由于控制器下发的只是与数据包匹配的部分流表项,因此,交换机无法得知其它与数据包匹配的流表项。 For the first possible case, the switch can receive all the flow entries that are sent by the controller and match the data packets. However, because the flow entries are sent by multiple ofp_flow_mod messages, the flow entries are sent. For a switch, it is an isolated flow entry. The switch does not know whether there is any association between these flow entries. On the other hand, the switch does not know whether there is any association between the flow entries sent by the controller. On the other hand, because the controller sends only some flow entries that match the data packet, The switch cannot know other flow entries that match the packet.
上述过程导致,交换机在接收到控制器下发的流表项后,必须先把接收的流表项保存到软件层的流表中,然后再在软件层的流表中查找,才能得到与接收的数据包匹配的所有流表项,进而进行硬件层的流表项的配置。而在软件层的流表中查找与数据包匹配的所有流表项的过程导致硬件层的流表项配置到硬件层的时延增大,进而导致在硬件层转发数据包的时延增大,并且,在高速发包的情况下,数据包丢包严重。After the switch receives the flow entry sent by the controller, the switch must first save the received flow entry to the flow table of the software layer, and then look it up in the flow table of the software layer to obtain and receive the flow entry. All the flow entries of the data packet are matched, and then the flow table entries of the hardware layer are configured. The process of finding all the flow entries matching the data packet in the flow table of the software layer causes the delay of configuring the flow entry of the hardware layer to the hardware layer to increase, thereby causing the delay of forwarding the data packet at the hardware layer to increase. And, in the case of high-speed packet delivery, packet loss is severe.
基于上述问题,请参阅图1,为本发明实施例提供的一种配置流表项的方法的流程示意图,本实施例所述技术方案可具体应用于OpenFlow网络中,OpenFlow网络中的交换机和控制器之间通过OpenFlow协议进行通信,该方法可以包括:Based on the above problem, refer to FIG. 1 , which is a schematic flowchart of a method for configuring a flow entry according to an embodiment of the present invention. The technical solution in this embodiment may be specifically applied to an OpenFlow network, and a switch and control in an OpenFlow network. Communicating between the devices through the OpenFlow protocol, the method may include:
步骤S101:交换机向控制器发送一个请求下发流表项的请求消息,请求消息中携带有待转发的数据包。Step S101: The switch sends a request message for requesting the sending of the flow entry to the controller, where the request message carries the data packet to be forwarded.
交换机在接收到待转发的数据包时,先在硬件层的流表中查找与待转发的数据包匹配的流表项,如果没有查找到与待转发的数据包匹配的流表项,则接着在软件层的流表中查找与待转发的数据包匹配的流表项,如果在软件层的流表中也没有查找到与待转发的数据包匹配的流表项,则向控制器发送一个请求下发流表项的请求消息,请求消息中携带待转发的数据包。When receiving the data packet to be forwarded, the switch searches for the flow entry matching the data packet to be forwarded in the flow table of the hardware layer. If the flow entry matching the data packet to be forwarded is not found, the switch then proceeds. The flow table entry matching the data packet to be forwarded is searched in the flow table of the software layer. If the flow table entry matching the data packet to be forwarded is not found in the flow table of the software layer, a flow entry is sent to the controller. The request message of the flow entry is requested, and the request message carries the data packet to be forwarded.
具体的,在OpenFlow网络中,请求下发流表项的请求消息可以为packet_in消息。Specifically, in the OpenFlow network, the request message for requesting the sending of the flow entry may be a packet_in message.
步骤S102:交换机接收控制器返回的一个响应消息。Step S102: The switch receives a response message returned by the controller.
其中,响应消息中携带有与待转发的数据包匹配的所有流表项。The response message carries all the flow entry items that match the data packet to be forwarded.
在本实施例中,控制器通过一个响应消息将与待转发的数据包匹配的所有流表项下发给交换机,即,与待转发的数据包匹配的所有流表项是绑定在一起通过一条消息下发下来的。In this embodiment, the controller sends all the flow entries matching the data packet to be forwarded to the switch through a response message, that is, all the flow entries matching the data packet to be forwarded are bound together. A message was sent down.
步骤S103:交换机从响应消息中提取与待转发的数据包匹配的所有流表项。Step S103: The switch extracts, from the response message, all flow entries that match the data packet to be forwarded.
当交换机接收到控制器发送的响应消息时,可从该响应消息中提取出与待转发的数据包匹配的所有流表项。 When the switch receives the response message sent by the controller, all the flow entry matching the data packet to be forwarded may be extracted from the response message.
步骤S104:交换机将提取出的所有流表项聚合为硬件层的流表项,并在交换机支持该硬件层的流表项时,将该硬件层的流表项配置到硬件层的流表中。Step S104: The switch aggregates all the extracted flow entries into the flow entry of the hardware layer, and configures the flow entry of the hardware layer into the flow table of the hardware layer when the switch supports the flow entry of the hardware layer. .
由于从接收的响应消息中提取的流表项为与待转发的数据包匹配的所有流表项,因此,交换机不需要再在软件层的流表中查找与待转发的数据包匹配的流表项,而是可以直接将提取出的所有流表项聚合成硬件层的流表项,在交换机支持该硬件层的流表项时,将该硬件层的流表项配置到硬件层的流表中。Since the flow entry extracted from the received response message is all flow entries matching the data packet to be forwarded, the switch does not need to look up the flow table matching the data packet to be forwarded in the flow table of the software layer. The flow entry of the hardware layer can be directly configured into the flow table of the hardware layer when the switch supports the flow entry of the hardware layer. in.
本发明实施例提供的配置流表项的方法中,由于控制器可将与数据包匹配的所有流表项绑定在一起通过一条消息下发至交换机,因此,交换机在接收到控制器下发的消息时,可获取与数据包匹配的所有流表项,从而可以直接将与数据包匹配的所有流表项聚合为硬件层的流表项并配置到硬件层的流表中。本发明实施例提供的配置流表项的方法与现有技术相比,由于不用在软件层的流表中查找与数据包匹配的流表项,因此,缩短了硬件层的流表项的配置时间,进而缩短了数据包的转发时延。In the method for configuring a flow entry, the controller can bind all the flow entries matching the data packet to the switch through a message, so the switch sends the switch to the controller. All the flow entries matching the data packet can be obtained, and all the flow entries matching the data packet can be directly aggregated into the flow table entries of the hardware layer and configured into the flow table of the hardware layer. Compared with the prior art, the method for configuring a flow entry in the embodiment of the present invention shortens the configuration of the flow entry of the hardware layer because the flow entry matching the data packet is not found in the flow table of the software layer. Time, which in turn shortens the forwarding delay of the packet.
并且,由于软件层的处理能力有限(数据包的转发速度较慢),因此,当硬件层向软件层发送的数据包数量超出软件层的处理能力时,会丢弃一些数据包(例如,软件层每秒能转发5个数据包,而现在硬件层收到10个数据包,那么,硬件层在向软件层发送数据包时会丢弃5个数据包),在本实施例中,硬件层的流表项的配置时间缩短,这使得本来应该发送至软件层进行转发的数据包能够在硬件层实现转发,相比软件层,硬件层的处理能力较强(数据包的转发速度较快),因此,降低了数据包的丢包数量。Moreover, because the processing capability of the software layer is limited (the forwarding speed of data packets is slow), when the number of data packets sent by the hardware layer to the software layer exceeds the processing capability of the software layer, some data packets are discarded (for example, the software layer). 5 packets can be forwarded every second, but now the hardware layer receives 10 packets, then the hardware layer will discard 5 packets when sending packets to the software layer. In this embodiment, the hardware layer flows. The configuration time of the entry is shortened, which enables the data packet that should be sent to the software layer for forwarding to be forwarded at the hardware layer. Compared with the software layer, the hardware layer has a stronger processing capability (the packet forwarding speed is faster), so , reducing the number of packets lost.
请参阅图2,为本发明实施例提供的另一种配置流表项的方法的流程示意图,本实施例所述技术方案可具体应用于OpenFlow网络中,OpenFlow网络中的交换机和控制器之间通过OpenFlow协议进行通信,该方法可以包括:FIG. 2 is a schematic flowchart of another method for configuring a flow entry according to an embodiment of the present invention. The technical solution in this embodiment may be specifically applied to an OpenFlow network, between a switch and a controller in an OpenFlow network. Communicating through the OpenFlow protocol, the method can include:
步骤S201:交换机向控制器发送一个请求下发流表项的请求消息,请求消息中携带有待转发的数据包。Step S201: The switch sends a request message for requesting the delivery of the flow entry to the controller, where the request message carries the data packet to be forwarded.
交换机在接收到待转发的数据包之后,先在硬件层的流表中查找与待转发的数据包匹配的流表项,如果没有查找到与待转发的数据包匹配的流表 项,则接着在软件层的流表中查找与待转发的数据包匹配的流表项,如果在软件层的流表中也没有查找到与待转发的数据包匹配的流表项,则向控制器发送一个请求下发流表项的请求消息,请求消息中携带待转发的数据包。After receiving the data packet to be forwarded, the switch searches for the flow entry matching the data packet to be forwarded in the flow table of the hardware layer. If the flow table matching the data packet to be forwarded is not found, the flow table is not found. Then, the flow table entry matching the data packet to be forwarded is searched in the flow table of the software layer. If the flow table entry matching the data packet to be forwarded is not found in the flow table of the software layer, then The controller sends a request message for requesting the delivery of the flow entry, and the request message carries the data packet to be forwarded.
具体的,在OpenFlow网络中,请求下发流表项的请求消息可以为packet_in消息。Specifically, in the OpenFlow network, the request message for requesting the sending of the flow entry may be a packet_in message.
步骤S202:交换机接收控制器返回的一个响应消息。Step S202: The switch receives a response message returned by the controller.
其中,响应消息中携带有与待转发的数据包匹配的所有流表项。The response message carries all the flow entry items that match the data packet to be forwarded.
在本实施例中,控制器通过一个响应消息将与待转发的数据包匹配的所有流表项下发给交换机,即,与待转发的数据包匹配的所有流表项是绑定在一起通过一条消息下发下来的。In this embodiment, the controller sends all the flow entries matching the data packet to be forwarded to the switch through a response message, that is, all the flow entries matching the data packet to be forwarded are bound together. A message was sent down.
在一种可能的实现方式中,控制器返回的响应消息可以为扩展的ofp_flow_mod消息。In a possible implementation manner, the response message returned by the controller may be an extended ofp_flow_mod message.
扩展的ofp_flow_mod消息为在ofp_flow_mod消息中定义一个数组后所得到的消息,并且,扩展的fpt_flow_mod消息通过定义的数组可同时携带多个流表项。The extended ofp_flow_mod message is a message obtained after defining an array in the ofp_flow_mod message, and the extended fpt_flow_mod message can carry multiple flow table entries simultaneously through the defined array.
其中,ofp_flow_mod消息为现有技术中基于OpenFlow协议定义的消息,现有技术中的每个ofp_flow_mod消息只能携带一个流表项,即,如果OpenFlow控制器需要下发的流表项有多个,那么,其就需要下发多个ofp_flow_mod消息。The ofp_flow_mod message is a message defined by the OpenFlow protocol in the prior art. Each of the ofp_flow_mod messages in the prior art can only carry one flow entry, that is, if there are multiple flow entries to be delivered by the OpenFlow controller, Then, it needs to deliver multiple ofp_flow_mod messages.
在本实施例中,扩展的ofp_flow_mod消息除了携带有与数据包匹配的所有流表项外,还携带有消息类型标识以及流表项数量标识。其中,消息类型标识用于指示响应消息为扩展的ofp_flow_mod消息,流表项数量标识用于指示扩展的ofp_flow_mod消息中携带的流表项的数量。In this embodiment, the extended ofp_flow_mod message carries a message type identifier and a flow entry quantity identifier in addition to all the flow entry items that match the data packet. The message type identifier is used to indicate that the response message is an extended ofp_flow_mod message, and the number of flow entry entries is used to indicate the number of flow entry entries carried in the extended ofp_flow_mod message.
由于扩展的ofp_flow_mod消息携带的流表项有多个,因此,ofp_flow_mod消息可通过携带流表项数量标识指示扩展的ofp_flow_mod消息所携带的流表项的数量。The number of the flow table entries of the extended ofp_flow_mod message indicates that the number of flow entries that are carried by the extended ofp_flow_mod message is indicated by the number of the flow entry entries.
可以理解的是,实际应用中,交换机可能既需要支持现有技术中配置流表项的方式,又要支持本发明实施例提供的配置流表项的方式,即能够兼容两种配置流表项的方式。在这种情况下,交换机接收的响应消息就会有两种,一种为现有技术中的ofp_flow_mod消息,一种为本发明实施例提供的扩展的 ofp_flow_mod消息,为了区分这两种消息,可在扩展的ofp_flow_mod消息中携带消息类型标识,交换机在接收到扩展的ofp_flow_mod消息后,通过消息中携带的消息类型标识,就可知道接收的消息为携带有多个流表项的扩展的ofp_flow_mod消息。It can be understood that, in an actual application, the switch may need to support the configuration of the flow entry in the prior art, and support the configuration of the flow entry provided by the embodiment of the present invention. The way. In this case, there are two kinds of response messages received by the switch, one is the ofp_flow_mod message in the prior art, and the other is an extension provided by the embodiment of the present invention. The ofp_flow_mod message, in order to distinguish the two types of messages, may carry the message type identifier in the extended ofp_flow_mod message. After receiving the extended ofp_flow_mod message, the switch can know that the received message is carried by the message type identifier carried in the message. An extended ofp_flow_mod message for multiple flow entries.
扩展的ofp_flow_mod消息的结构体如下所示:The structure of the extended ofp_flow_mod message is as follows:
Figure PCTCN2014095230-appb-000001
Figure PCTCN2014095230-appb-000001
其中,number表示扩展的ofp_flow_mod消息中携带的流表项的数量,flow_mod包含与待转发的数据包匹配的所有流表项。The number indicates the number of flow entries carried in the extended ofp_flow_mod message, and the flow_mod contains all the flow entries matching the data packet to be forwarded.
步骤S203:交换机从响应消息中提取与待转发的数据包匹配的所有流表项。Step S203: The switch extracts, from the response message, all flow entries that match the data packet to be forwarded.
具体的,交换机从扩展的ofp_flow_mod消息中提取出与待转发的数据包匹配的所有流表项。进一步的,可通过流表项数量标识指示的流表项的数量对提取出的流表项的数量进行验证。Specifically, the switch extracts, from the extended ofp_flow_mod message, all flow entries that match the data packet to be forwarded. Further, the number of the flow entry to be extracted may be verified by the number of the flow entry indicated by the number of the flow entry.
步骤S204:交换机将提取出的所有流表项聚合为硬件层的流表项。Step S204: The switch aggregates all the extracted flow entries into the flow entry of the hardware layer.
其中,每个流表项均包括匹配域信息和转发动作信息。Each flow entry includes matching domain information and forwarding action information.
则交换机将所有流表项聚合为硬件层的流表项,具体为:将提取的所有流表项中的匹配域信息进行聚合,得到硬件层的流表项的匹配域信息,将提取的所有流表项中的转发动作信息进行聚合,得到硬件层的流表项的转发动作信息,硬件层的流表项的匹配域信息和硬件层的流表项的转发动作信息组成硬件层的流表项。The switch aggregates all the flow entries into the flow entries of the hardware layer. Specifically, the matching domain information of all the flow entries is aggregated, and the matching domain information of the flow entries of the hardware layer is obtained. The forwarding action information in the flow entry is aggregated to obtain the forwarding action information of the flow entry of the hardware layer. The matching domain information of the flow entry of the hardware layer and the forwarding action information of the flow entry of the hardware layer form a flow table of the hardware layer. item.
步骤S205:交换机判断自身是否支持硬件层的流表项,如果是,进入步骤S206a,否则,进入步骤S206b。Step S205: The switch determines whether it supports the flow entry of the hardware layer. If yes, the process goes to step S206a, otherwise, the process goes to step S206b.
在本实施例中,交换机判断自身是否支持硬件层的流表项具体为:交换机将聚合得到的流表项中的匹配域信息与硬件层的流表中的匹配域信息进 行比较,如果聚合得到的流表项中的匹配域信息与硬件层的流表中的匹配域信息相同,或者,硬件层的流表中的匹配域信息中包括聚合得到的流表项中的匹配域信息,则判定自身支持硬件层的流表项,否则,判定自身不支持硬件层的流表项。In this embodiment, the switch determines whether the flow entry of the hardware layer is supported by the switch: the matching domain information in the flow entry obtained by the switch and the matching domain information in the flow table of the hardware layer are In the row comparison, if the matching domain information in the flow entry obtained by the aggregation is the same as the matching domain information in the flow table of the hardware layer, or the matching domain information in the flow table of the hardware layer includes the flow entry obtained by the aggregation. Matching the domain information determines that it supports the flow entry of the hardware layer. Otherwise, it determines that it does not support the flow entry of the hardware layer.
示例性的,聚合得到的流表项中的匹配域信息包括三个匹配字段A、B、C,硬件层的流表中的匹配域信息同样包括三个匹配字段A、B、C,则判定交换机支持硬件层的流表项。Exemplarily, the matching domain information in the aggregated flow entry includes three matching fields A, B, and C. The matching domain information in the flow table of the hardware layer also includes three matching fields A, B, and C, and then The switch supports flow table entries at the hardware layer.
示例性的,聚合得到的流表项中的匹配域信息包括三个匹配字段A、B、C,硬件层的流表中的匹配信息包括五个匹配字段A、B、C、D、E,由于硬件层的流表中的匹配信息A、B、C、D、E中包括聚合得到的流表项中的匹配域信息A、B、C,因此,判定交换机支持硬件层的流表项。Exemplarily, the matching domain information in the aggregated flow entry includes three matching fields A, B, and C. The matching information in the flow table of the hardware layer includes five matching fields A, B, C, D, and E. Since the matching information A, B, C, D, and E in the flow table of the hardware layer includes the matching domain information A, B, and C in the aggregated flow entry, the determination switch supports the flow entry of the hardware layer.
示例性的,聚合得到的流表项中的匹配域信息包括三个匹配字段A、B、C,硬件层的流表中的匹配信息包括五个匹配字段A、B、D、E、F,由于硬件层的流表中的匹配信息中不包括匹配字段C,因此,判定交换机不支持硬件层的流表项。Exemplarily, the matching domain information in the aggregated flow entry includes three matching fields A, B, and C. The matching information in the flow table of the hardware layer includes five matching fields A, B, D, E, and F. Since the matching information in the matching information in the flow table of the hardware layer does not include the matching field C, it is determined that the switch does not support the flow entry of the hardware layer.
步骤S206a:当交换机自身支持硬件层的流表项时,将该硬件层的流表项配置到硬件层的流表中。Step S206a: When the switch itself supports the flow entry of the hardware layer, the flow entry of the hardware layer is configured into the flow table of the hardware layer.
由于从扩展的ofp_flow_mod消息中提取的流表项为与数据包匹配的所有流表项,因此,交换机可直接将提取出的所有流表项聚合成硬件层的流表项,在交换机支持该硬件层的流表项时,将该硬件层的流表项配置到硬件层的流表中,当交换机再接收到数据包后,就可以直接在硬件层的流表中查找匹配的流表项,并按照该匹配的流表项的数据包转发规则转发该数据包,而不用像现有技术那样,将接收的流表项保存到软件层,在软件层的流表中查找到与数据包匹配的所有流表项后,才能将所有的流表项聚合成硬件层的流表项。Since the flow entry extracted from the extended ofp_flow_mod message is all the flow entry matching the data packet, the switch can directly aggregate all the extracted flow entry into a hardware layer flow entry, and the switch supports the hardware. When the flow entry of the layer is configured, the flow entry of the hardware layer is configured in the flow table of the hardware layer. After the switch receives the data packet, the switch can directly find the matching flow entry in the flow table of the hardware layer. And forwarding the data packet according to the packet forwarding rule of the matched flow entry, instead of saving the received flow entry to the software layer as in the prior art, and finding the matching with the data packet in the flow table of the software layer After all the flow entries are added, all the flow entries can be aggregated into the flow entries of the hardware layer.
步骤S206b:当交换机自身不支持硬件层的流表项时,将提取出的所有流表项配置到软件层的流表中。Step S206b: When the switch does not support the flow entry of the hardware layer, all the extracted flow entries are configured in the flow table of the software layer.
在本发明实施例中,当交换机自身不支持硬件层的流表项时,表明当接收到同样的数据包时,无法在硬件层转发该数据包,为了能够实现数据包的 转发,将提取出的所有流表项配置到软件层的流表中,这样,在硬件层无法实现数据包的转发时,使软件层能实现数据包的转发。In the embodiment of the present invention, when the switch does not support the flow entry of the hardware layer, it indicates that when the same data packet is received, the data packet cannot be forwarded at the hardware layer, in order to implement the data packet. Forwarding, all the extracted flow entries are configured in the flow table of the software layer, so that when the hardware layer cannot forward the data packet, the software layer can implement the data packet forwarding.
需要说明的是,在本发明实施例中,当交换机自身不支持硬件层的流表项时,才会将提取出的所有流表项保存到软件层的流表中,在另一种可能的实现方式中,交换机在扩展的ofp_flow_mod消息中提取出所有流表项后,将提取的所有流表项保存到软件层的流表中,并将提取的所有流表项聚合成硬件层的流表项,在自身支持该硬件层的流表项时,将该硬件层的流表项配置到硬件层的流表中,在自身不支持该硬件层的流表项时,丢弃该硬件层的流表项,即,在这种实现方式中,交换机不管自身是否支持硬件层的流表项,都先将提取的所有流表项配置到软件层的流表中。It should be noted that, in the embodiment of the present invention, when the switch does not support the flow entry of the hardware layer, all the extracted flow entries are saved to the flow table of the software layer, and another possible In the implementation manner, after the switch extracts all the flow entries in the extended ofp_flow_mod message, the switch saves all the extracted flow entries to the flow table of the software layer, and aggregates all the extracted flow entries into a flow table of the hardware layer. When the flow entry of the hardware layer is supported by the hardware layer, the flow entry of the hardware layer is configured in the flow table of the hardware layer, and the flow of the hardware layer is discarded when the flow entry of the hardware layer is not supported by itself. The entry, that is, in this implementation manner, the switch first configures all the extracted flow entry items into the flow table of the software layer regardless of whether the switch supports the flow entry of the hardware layer.
本发明实施例提供的配置流表项的方法中,由于控制器可将与数据包匹配的所有流表项绑定在一起通过一条消息下发至交换机,因此,交换机在接收到控制器下发的消息时,可获取与数据包匹配的所有流表项,从而可以直接将与数据包匹配的所有流表项聚合为硬件层的流表项并配置到硬件层的流表中。本发明实施例提供的配置流表项的方法与现有技术相比,由于不用在软件层的流表中查找与数据包匹配的流表项,因此,缩短了硬件层的流表项配置到硬件层时间,进而缩短了数据包的转发时延。In the method for configuring a flow entry, the controller can bind all the flow entries matching the data packet to the switch through a message, so the switch sends the switch to the controller. All the flow entries matching the data packet can be obtained, and all the flow entries matching the data packet can be directly aggregated into the flow table entries of the hardware layer and configured into the flow table of the hardware layer. Compared with the prior art, the method for configuring a flow entry in the embodiment of the present invention shortens the configuration of the flow entry of the hardware layer by not searching for the flow entry matching the data packet in the flow table of the software layer. The hardware layer time, which in turn shortens the packet forwarding delay.
并且,由于软件层的处理能力有限(数据包的转发速度较慢),因此,当硬件层向软件层发送的数据包数量超出软件层的处理能力时,会丢弃一些数据包(例如,软件层每秒能转发5个数据包,而现在硬件层收到10个数据包,那么,硬件层在向软件层发送数据包时会丢弃5个数据包),在本实施例中,硬件层的流表项的配置时间缩短,这使得本来应该发送至软件层进行转发的数据包能够在硬件层实现转发,相比软件层,硬件层的处理能力较强(数据包的转发速度较快),因此,降低了数据包的丢包数量。Moreover, because the processing capability of the software layer is limited (the forwarding speed of data packets is slow), when the number of data packets sent by the hardware layer to the software layer exceeds the processing capability of the software layer, some data packets are discarded (for example, the software layer). 5 packets can be forwarded every second, but now the hardware layer receives 10 packets, then the hardware layer will discard 5 packets when sending packets to the software layer. In this embodiment, the hardware layer flows. The configuration time of the entry is shortened, which enables the data packet that should be sent to the software layer for forwarding to be forwarded at the hardware layer. Compared with the software layer, the hardware layer has a stronger processing capability (the packet forwarding speed is faster), so , reducing the number of packets lost.
上述任一实施例提供的配置流表项的方法还可以包括:在接收到控制器下发的响应消息后,将待转发的数据包转发出去。The method for configuring a flow entry provided by any one of the foregoing embodiments may further include: after receiving the response message sent by the controller, forwarding the data packet to be forwarded.
具体的,将待转发的数据包转发出去的实现方式有多种。在一种可能的实现方式中,可在接收到控制器下发的响应消息后,直接通过响应消息中携带的与待转发的数据包匹配的所有流表项将待转发的数据包转发出去,在另 一种可能的实现方式中,可在将响应消息中携带的与待转发的数据包匹配的所有流表项配置到软件层后,从软件层转发待转发的数据包,在又一种可能的实现方式中,可在将聚合得到的硬件层的流表项配置到硬件层后,从硬件层转发待转发的数据包。Specifically, there are multiple implementation manners for forwarding data packets to be forwarded. In a possible implementation, after receiving the response message sent by the controller, the data packet to be forwarded is directly forwarded through all the flow entries that are matched by the data packet to be forwarded in the response message. In another In a possible implementation, after all the flow entries matching the data packet to be forwarded carried in the response message are configured to the software layer, the data packet to be forwarded is forwarded from the software layer, and another possible In the implementation manner, after the flow entry of the hardware layer obtained by the aggregation is configured to the hardware layer, the data packet to be forwarded is forwarded from the hardware layer.
请参阅图3,为本发明实施例提供的一种下发流表项的方法的流程示意图,该方法可以包括:FIG. 3 is a schematic flowchart of a method for sending a flow entry according to an embodiment of the present disclosure, where the method may include:
步骤S301:控制器接收交换机发送的一个请求下发流表项的请求消息。Step S301: The controller receives a request message sent by the switch for requesting the sending of the flow entry.
其中,请求消息中携带有待转发的数据包。The request message carries a data packet to be forwarded.
步骤S302:控制器生成与待转发的数据包匹配的所有流表项。Step S302: The controller generates all flow entry items that match the data packet to be forwarded.
具体的,控制器通过待转发的数据包中的信息确定与待转发的该数据包匹配的流表项。Specifically, the controller determines, by using information in the data packet to be forwarded, a flow entry that matches the data packet to be forwarded.
示例性的,控制器在接收到Mpls_label为10,目的IP为192.168.0.6的数据包后,会产生如图4所示的T0_1流表项和T2_1流表项,然后通过一条消息将T0_1和T2_1两条流表项绑定到一起下发给交换机。具体的,控制器通过Mpls_label和目的IP可确定与数据包匹配的流表T0表和T1表,然后在T0表和T1表中确定出与数据包匹配的流表项T0_1和T2_1。需要说明的是,T0表中的Mpls_label为T0表支持的匹配字段,T1表中的Eth_type、Src_ip和Dst_ip为T2表支持的匹配字段,T0表和T1表中的action表示转发动作。Exemplarily, after receiving the data packet with the Mpls_label of 10 and the destination IP address of 192.168.0.6, the controller generates the T0_1 flow entry and the T2_1 flow entry as shown in FIG. 4, and then T0_1 and T2_1 through a message. The two flow entries are bound together and delivered to the switch. Specifically, the controller determines the flow table T0 table and the T1 table that match the data packet through the Mpls_label and the destination IP, and then determines the flow table entries T0_1 and T2_1 that match the data packet in the T0 table and the T1 table. It should be noted that the Mpls_label in the T0 table is a matching field supported by the T0 table, the Eth_type, Src_ip, and Dst_ip in the T1 table are matching fields supported by the T2 table, and the actions in the T0 table and the T1 table indicate forwarding actions.
步骤S303:控制器向交换机返回一个响应消息。Step S303: The controller returns a response message to the switch.
其中,响应消息中携带有与待转发的数据包匹配的所有流表项,其中,与待转发的数据包匹配的所有流表项用于聚合为硬件层的流表项,硬件层的流表项用于配置到交换机的硬件层的流表中。The response message carries all the flow entries that match the data packet to be forwarded, and all the flow entries that match the data packet to be forwarded are used to be aggregated into the flow table entry of the hardware layer, and the flow table of the hardware layer. The item is used to configure the flow table to the hardware layer of the switch.
在一种可能的实现方式中,响应消息为扩展的ofp_flow_mod消息,扩展的ofp_flow_mod消息为在ofp_flow_mod消息中定义一个数组后所得到的消息,并且,扩展的fpt_flow_mod消息通过定义的数组可同时携带多个流表项。In a possible implementation manner, the response message is an extended ofp_flow_mod message, the extended ofp_flow_mod message is a message obtained after defining an array in the ofp_flow_mod message, and the extended fpt_flow_mod message can carry multiple multiple times through the defined array. Flow entry.
其中,ofp_flow_mod消息为现有技术中基于OpenFlow协议定义的消息,现有技术中的每个ofp_flow_mod消息只能携带一个流表项,即,如果控制器需要下发的流表项有多个,那么,其就需要下发多个ofp_flow_mod消息。 The ofp_flow_mod message is a message defined by the OpenFlow protocol in the prior art. Each of the ofp_flow_mod messages in the prior art can only carry one flow entry, that is, if there are multiple flow entries to be delivered by the controller, It needs to issue multiple ofp_flow_mod messages.
在本实施例中,扩展的ofp_flow_mod消息除了携带有与待转发的数据包匹配的所有流表项外,还携带有消息类型标识以及流表项数量标识。其中,消息类型标识用于指示响应消息为扩展的ofp_flow_mod消息,流表项数量标识用于指示扩展的ofp_flow_mod消息中携带的流表项的数量。In this embodiment, the extended ofp_flow_mod message carries a message type identifier and a flow entry quantity identifier in addition to all the flow entry items that match the data packet to be forwarded. The message type identifier is used to indicate that the response message is an extended ofp_flow_mod message, and the number of flow entry entries is used to indicate the number of flow entry entries carried in the extended ofp_flow_mod message.
本发明实施例提供的下发流表项的方法中,控制器可将与数据包匹配的所有流表项绑定在一起通过一条消息下发至交换机,这使得交换机在接收到控制器下发的消息时,可获取与数据包匹配的所有流表项,从而可以直接将与数据包匹配的所有流表项聚合为硬件层的流表项并配置到硬件层的流表中。本发明实施例提供的下发流表项的方法使得交换机不用在软件层的流表中查找与数据包匹配的流表项,因此,使得交换机将硬件层的流表项配置到硬件层的流表的时间缩短,进而使交换机转发数据包的时延缩短。In the method for sending a flow entry, the controller can bind all the flow entries matching the data packet to the switch through a message, so that the switch sends the switch to the controller. All the flow entries matching the data packet can be obtained, and all the flow entries matching the data packet can be directly aggregated into the flow table entries of the hardware layer and configured into the flow table of the hardware layer. The method for sending a flow entry in the embodiment of the present invention does not need to find a flow entry matching the data packet in the flow table of the software layer, so that the switch configures the flow entry of the hardware layer to the flow of the hardware layer. The time of the table is shortened, which in turn reduces the delay for the switch to forward packets.
并且,由于软件层的处理能力有限(数据包的转发速度较慢),因此,当硬件层向软件层发送的数据包数量超出软件层的处理能力时,会丢弃一些数据包(例如,软件层每秒能转发5个数据包,而现在硬件层收到10个数据包,那么,硬件层在向软件层发送数据包时会丢弃5个数据包),在本实施例中,硬件层的流表项的配置时间缩短,这使得本来应该发送至软件层进行转发的数据包能够在硬件层实现转发,相比软件层,硬件层的处理能力较强(数据包的转发速度较快),因此,降低了数据包的丢包数量。Moreover, because the processing capability of the software layer is limited (the forwarding speed of data packets is slow), when the number of data packets sent by the hardware layer to the software layer exceeds the processing capability of the software layer, some data packets are discarded (for example, the software layer). 5 packets can be forwarded every second, but now the hardware layer receives 10 packets, then the hardware layer will discard 5 packets when sending packets to the software layer. In this embodiment, the hardware layer flows. The configuration time of the entry is shortened, which enables the data packet that should be sent to the software layer for forwarding to be forwarded at the hardware layer. Compared with the software layer, the hardware layer has a stronger processing capability (the packet forwarding speed is faster), so , reducing the number of packets lost.
请参阅图5,为本发明实施例提供的配置流表项的装置的结构示意图,该装置可以包括:发送模块501、接收模块502、提取模块503和硬件配置模块504。其中:FIG. 5 is a schematic structural diagram of an apparatus for configuring a flow entry according to an embodiment of the present invention. The apparatus may include: a sending module 501, a receiving module 502, an extracting module 503, and a hardware configuration module 504. among them:
发送模块501,用于向控制器发送一个请求下发流表项的请求消息。The sending module 501 is configured to send a request message for requesting the sending of the flow entry to the controller.
其中,请求消息中携带有待转发的数据包。The request message carries a data packet to be forwarded.
接收模块502,用于接收控制器返回的一个响应消息。The receiving module 502 is configured to receive a response message returned by the controller.
其中,响应消息中携带有与待转发的数据包匹配的所有流表项。The response message carries all the flow entry items that match the data packet to be forwarded.
提取模块503,用于从接收模块502接收的响应消息中提取与数据包匹配的所有流表项。 The extracting module 503 is configured to extract, from the response message received by the receiving module 502, all flow entries that match the data packet.
硬件配置模块504,用于将提取模块503提取出的所有流表项聚合为硬件层的流表项,并在交换机支持该硬件层的流表项时,将该硬件层的流表项配置到硬件层的流表中。The hardware configuration module 504 is configured to aggregate all the flow entries extracted by the extraction module 503 into the flow entry of the hardware layer, and configure the flow entry of the hardware layer to the flow entry of the hardware layer when the switch supports the flow entry of the hardware layer. In the flow table of the hardware layer.
本发明实施例提供的配置流表项的装置中,由于控制器可将与数据包匹配的所有流表项绑定在一起通过一条消息下发至交换机,因此,交换机在接收到控制器下发的消息时,可获取与数据包匹配的所有流表项,从而可以直接将与数据包匹配的所有流表项聚合为硬件层的流表项并配置到硬件层的流表中。本发明实施例提供的配置流表项的装置在配置流表项的过程中,由于不用在软件层的流表中查找与数据包匹配的流表项,因此,缩短了硬件层的流表项的配置时间,进而缩短了数据包的转发时延,并且。降低了数据包的丢包数量。In the device for configuring a flow entry, the controller can bind all the flow entries matching the data packet to the switch through a message, so the switch sends the switch to the controller. All the flow entries matching the data packet can be obtained, and all the flow entries matching the data packet can be directly aggregated into the flow table entries of the hardware layer and configured into the flow table of the hardware layer. In the process of configuring a flow entry, the device for configuring a flow entry in the embodiment of the present invention shortens the flow entry of the hardware layer by not searching for a flow entry matching the data packet in the flow table of the software layer. The configuration time, which in turn shortens the forwarding delay of the packet, and. Reduce the number of packets lost.
上述实施例提供的配置流表项的装置还可以包括:转发模块。The apparatus for configuring a flow entry provided by the foregoing embodiment may further include: a forwarding module.
转发模块,用于通过接收模块502接收的响应消息中携带的与待转发的数据包匹配的所有流表项转发待转发的数据包。The forwarding module is configured to forward the data packet to be forwarded by all the flow entry items that are matched by the data packet to be forwarded and carried in the response message received by the receiving module 502.
上述实施例提供的配置流表项的装置还可以包括:软件配置模块。The apparatus for configuring a flow entry provided by the foregoing embodiment may further include: a software configuration module.
软件配置模块,用于将提取模块503提取出的所有流表项配置到软件层的流表中。The software configuration module is configured to configure all flow entries extracted by the extraction module 503 into a flow table of the software layer.
在一种可能的实现方式中,上述实施例中接收模块502接收的响应消息为扩展的ofp_flow_mod消息。In a possible implementation manner, the response message received by the receiving module 502 in the foregoing embodiment is an extended ofp_flow_mod message.
扩展的ofp_flow_mod消息为在ofp_flow_mod消息中定义一个数组后所得到的消息,并且,扩展的fpt_flow_mod消息通过定义的数组可同时携带多个流表项。The extended ofp_flow_mod message is a message obtained after defining an array in the ofp_flow_mod message, and the extended fpt_flow_mod message can carry multiple flow table entries simultaneously through the defined array.
其中,ofp_flow_mod消息为现有技术中基于OpenFlow协议定义的消息,现有技术中的每个ofp_flow_mod消息只能携带一个流表项,即,如果控制器需要下发的流表项有多个,那么,其就需要下发多个ofp_flow_mod消息。 The ofp_flow_mod message is a message defined by the OpenFlow protocol in the prior art. Each of the ofp_flow_mod messages in the prior art can only carry one flow entry, that is, if there are multiple flow entries to be delivered by the controller, It needs to issue multiple ofp_flow_mod messages.
请参阅图6,为本发明实施例提供的一种下发流表项的装置的结构示意图,该装置可以包括:接收模块601、流表项生成模块602和发送模块603。其中:FIG. 6 is a schematic structural diagram of an apparatus for sending a flow entry according to an embodiment of the present disclosure. The device may include: a receiving module 601, a flow entry generating module 602, and a sending module 603. among them:
接收模块601,用于接收交换机发送的一个请求下发流表项的请求消息,请求消息中携带有待转发的数据包。The receiving module 601 is configured to receive a request message sent by the switch for requesting the sending of the flow entry, where the request message carries the data packet to be forwarded.
流表项生成模块602,用于生成与接收模块601接收的数据包匹配的所有流表项。The flow entry generation module 602 is configured to generate all flow entry items that match the data packet received by the receiving module 601.
发送模块603,用于向交换机返回一个响应消息,响应消息中携带有流表项生成模块602生成的与数据包匹配的所有流表项。The sending module 603 is configured to return a response message to the switch, where the response message carries all flow entries that are generated by the flow entry generation module 602 and that match the data packet.
其中,与数据包匹配的所有流表项用于聚合为硬件层的流表项,硬件层的流表项用于配置到交换机的硬件层的流表中。All the flow entries matching the data packet are used to be aggregated into the flow entry of the hardware layer, and the flow entry of the hardware layer is configured to be configured in the flow table of the hardware layer of the switch.
在一种可能的实现方式中,发送模块603向交换机返回的响应消息为一条扩展的ofp_flow_mod消息。In a possible implementation manner, the response message returned by the sending module 603 to the switch is an extended ofp_flow_mod message.
具体的,扩展的ofp_flow_mod消息为在ofp_flow_mod消息中定义一个数组后所得到的消息,并且,扩展的fpt_flow_mod消息通过定义的数组可同时携带多个流表项。Specifically, the extended ofp_flow_mod message is a message obtained after defining an array in the ofp_flow_mod message, and the extended fpt_flow_mod message can carry multiple flow entry items simultaneously through the defined array.
本发明实施例提供的下发流表项的装置,可将与数据包匹配的所有流表项绑定在一起通过一条消息下发至交换机,这使得交换机在接收到控制器下发的消息时,可获取与数据包匹配的所有流表项,从而可以直接将与数据包匹配的所有流表项聚合为硬件层的流表项并配置到硬件层的流表中。本发明实施例提供的下发流表项的方法使得交换机不用在软件层的流表中查找与数据包匹配的流表项,因此,使得交换机将硬件层的流表项配置到硬件层的流表中的时间缩短,进而使数据包的转发时延缩短,并且,降低了数据包的丢包数量。The device for sending a flow entry according to the embodiment of the present invention can bind all the flow entries matching the data packet to the switch through a message, so that the switch receives the message sent by the controller. All the flow entries matching the data packet can be obtained, and all the flow entries matching the data packet can be directly aggregated into the flow table entry of the hardware layer and configured into the flow table of the hardware layer. The method for sending a flow entry in the embodiment of the present invention does not need to find a flow entry matching the data packet in the flow table of the software layer, so that the switch configures the flow entry of the hardware layer to the flow of the hardware layer. The time in the table is shortened, which in turn shortens the forwarding delay of the data packet and reduces the packet loss amount of the data packet.
图5所示的配置流表项的装置,在实际应用中,具体应用于交换机中,部署如图5所示的配置流表项的装置的交换机,可以缩短硬件层的流表项的配置时间,进而缩短数据包的转发时延,并且,降低数据包的丢包数量。 The device for configuring the flow entry shown in FIG. 5 is applied to the switch in the switch, and the switch of the device configured with the flow entry shown in FIG. 5 is configured to shorten the configuration time of the flow entry of the hardware layer. , thereby shortening the forwarding delay of the data packet, and reducing the number of packet loss of the data packet.
请参见图7,为本发明实施例提供的一种交换机70的结构示意图,该交换机70至少可以包括存储器701和通过通信总线与存储器701连接的处理器702。FIG. 7 is a schematic structural diagram of a switch 70 according to an embodiment of the present invention. The switch 70 may include at least a memory 701 and a processor 702 connected to the memory 701 through a communication bus.
其中,存储器701,可用于存储软件程序以及模块,处理器702通过运行存储在存储器701中的软件程序以及模块,从而执行交换机70的各种功能应用以及数据处理。存储器701可主要包括存储程序区和存储数据区,其中,存储程序区可存储操作系统、至少一个功能所需的应用程序;存储数据区可存储根据交换机70的使用所创建的数据。此外,存储器701可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他易失性固态存储器件。The memory 701 can be used to store software programs and modules. The processor 702 executes various functional applications and data processing of the switch 70 by running software programs and modules stored in the memory 701. The memory 701 can mainly include a storage program area and a storage data area, wherein the storage program area can store an operating system, an application required for at least one function; and the storage data area can store data created according to the use of the switch 70. Further, the memory 701 may include a high speed random access memory, and may also include a nonvolatile memory such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device.
处理器702是交换机70的控制中心,利用各种接口和线路连接整个服务器的各个部分,通过运行或执行存储在存储器701内的软件程序和/或模块,以及调用存储在存储器701内的数据,执行交换机70的各种功能和处理数据,从而对交换机70进行整体监控。可选的,处理器702可包括一个或多个处理单元;优选的,处理器702可集成应用处理器和调制解调处理器,其中,应用处理器主要处理操作系统、用户界面和应用程序等,调制解调处理器主要处理无线通信。可以理解的是,上述调制解调处理器也可以不集成到处理器702中。The processor 702 is the control center of the switch 70, connecting various portions of the entire server using various interfaces and lines, by running or executing software programs and/or modules stored in the memory 701, and recalling data stored in the memory 701, The various functions and processing data of the switch 70 are performed to perform overall monitoring of the switch 70. Optionally, the processor 702 may include one or more processing units; preferably, the processor 702 may integrate an application processor and a modem processor, where the application processor mainly processes an operating system, a user interface, an application, and the like. The modem processor primarily handles wireless communications. It can be understood that the above modem processor may not be integrated into the processor 702.
在本发明实施例中,交换机70所包括的处理器7602具有以下功能:In the embodiment of the present invention, the processor 7602 included in the switch 70 has the following functions:
向控制器发送一个请求下发流表项的请求消息,请求消息中携带有待转发的数据包;接收控制器返回的一个响应消息,响应消息中携带有与待转发的数据包匹配的所有流表项;从响应消息中提取与待转发的数据包匹配的所有流表项;将提取出的所有流表项聚合为硬件层的流表项,并在交换机支持该硬件层的流表项时,将该硬件层的流表项配置到硬件层的流表中。Sending a request message to the controller for requesting the sending of the flow entry, the request message carrying the data packet to be forwarded; receiving a response message returned by the controller, the response message carrying all the flow tables matching the data packet to be forwarded All the flow entries that match the data packets to be forwarded are extracted from the response message; all the flow entries that are extracted are aggregated into the flow entry of the hardware layer, and when the switch supports the flow entry of the hardware layer, Configure the flow entry of the hardware layer to the flow table of the hardware layer.
图6所示的下发流表项的装置,在实际应用中,具体应用于控制器中,部署如图6所示的下发流表项的装置的控制器,可以使交换机配置硬件层的流表项的时间缩短,进而使交换机转发数据包的时延缩短,降低数据包的丢包数量。 The device for sending a flow entry shown in FIG. 6 is specifically applied to a controller, and a controller for deploying a device that sends a flow entry as shown in FIG. 6 can be configured to configure a hardware layer of the switch. The time of the flow entry is shortened, which shortens the delay of forwarding packets and reduces the number of packets lost.
请参见图8,为本发明实施例提供的一种控制器80的结构示意图,该交换机80至少可以包括存储器801和通过通信总线与存储器801连接的处理器802。FIG. 8 is a schematic structural diagram of a controller 80 according to an embodiment of the present invention. The switch 80 may include at least a memory 801 and a processor 802 connected to the memory 801 through a communication bus.
其中,存储器801,可用于存储软件程序以及模块,处理器802通过运行存储在存储器801中的软件程序以及模块,从而执行控制器80的各种功能应用以及数据处理。存储器801可主要包括存储程序区和存储数据区,其中,存储程序区可存储操作系统、至少一个功能所需的应用程序;存储数据区可存储根据控制器80的使用所创建的数据。此外,存储器801可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他易失性固态存储器件。Among them, the memory 801 can be used to store software programs and modules, and the processor 802 executes various functional applications and data processing of the controller 80 by running software programs and modules stored in the memory 801. The memory 801 may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application required for at least one function; and the storage data area may store data created according to the use of the controller 80. Further, the memory 801 may include a high speed random access memory, and may also include a nonvolatile memory such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device.
处理器802是控制器80的控制中心,利用各种接口和线路连接整个服务器的各个部分,通过运行或执行存储在存储器801内的软件程序和/或模块,以及调用存储在存储器801内的数据,执行控制器80的各种功能和处理数据,从而对控制器80进行整体监控。可选的,处理器802可包括一个或多个处理单元;优选的,处理器802可集成应用处理器和调制解调处理器,其中,应用处理器主要处理操作系统、用户界面和应用程序等,调制解调处理器主要处理无线通信。可以理解的是,上述调制解调处理器也可以不集成到处理器802中。 Processor 802 is the control center of controller 80, which connects various portions of the server with various interfaces and lines, by running or executing software programs and/or modules stored in memory 801, and recalling data stored in memory 801. The various functions and processing data of the controller 80 are executed to perform overall monitoring of the controller 80. Optionally, the processor 802 may include one or more processing units; preferably, the processor 802 may integrate an application processor and a modem processor, where the application processor mainly processes an operating system, a user interface, an application, and the like. The modem processor primarily handles wireless communications. It will be appreciated that the above described modem processor may also not be integrated into the processor 802.
在本发明实施例中,控制器80所包括的处理器802具有以下功能:In the embodiment of the present invention, the processor 802 included in the controller 80 has the following functions:
接收交换机发送的一个请求下发流表项的请求消息,请求消息中携带有待转发的数据包;生成与待转发的数据包匹配的所有流表项;向交换机返回一个响应消息,响应消息中携带有与待转发的数据包匹配的所有流表项,其中,与待转发的数据包匹配的所有流表项用于聚合为硬件层的流表项,硬件层的流表项用于配置到交换机硬件层的流表中。Receiving a request message sent by the switch to send a flow entry, the request message carrying the data packet to be forwarded; generating all flow entries matching the data packet to be forwarded; returning a response message to the switch, and carrying the response message All the flow entries matching the data packets to be forwarded, and all the flow entries matching the data packets to be forwarded are used to aggregate the flow entries of the hardware layer, and the flow entries of the hardware layer are configured to be configured to the switch. In the flow table of the hardware layer.
本说明书中各个实施例采用递进的方式描述,每个实施例重点说明的都是与其他实施例的不同之处,各个实施例之间相同相似部分互相参见即可。对于实施例公开的装置而言,由于其与实施例公开的方法相对应,所以描述的比较简单,相关之处参见方法部分说明即可。 The various embodiments in the present specification are described in a progressive manner, and each embodiment focuses on differences from other embodiments, and the same similar parts between the various embodiments may be referred to each other. For the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant parts can be referred to the method part.
在本申请所提供的几个实施例中,应该理解到,所揭露的方法、装置和设备,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,所述单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些通信接口,装置或单元的间接耦合或通信连接,可以是电性,机械或其它的形式。In the several embodiments provided by the present application, it should be understood that the disclosed methods, apparatus, and devices may be implemented in other manners. For example, the device embodiments described above are merely illustrative. For example, the division of the unit is only a logical function division. In actual implementation, there may be another division manner, for example, multiple units or components may be combined or Can be integrated into another system, or some features can be ignored or not executed. In addition, the mutual coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection through some communication interface, device or unit, and may be electrical, mechanical or otherwise.
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。The units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of the embodiment.
另外,在本发明各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
所述功能如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本发明的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本发明各个实施例所述方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、磁碟或者光盘等各种可以存储程序代码的介质。The functions may be stored in a computer readable storage medium if implemented in the form of a software functional unit and sold or used as a standalone product. Based on such understanding, the technical solution of the present invention, which is essential or contributes to the prior art, or a part of the technical solution, may be embodied in the form of a software product, which is stored in a storage medium, including The instructions are used to cause a computer device (which may be a personal computer, server, or network device, etc.) to perform all or part of the steps of the methods described in various embodiments of the present invention. The foregoing storage medium includes: a U disk, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk, and the like. .
对所公开的实施例的上述说明,使本领域专业技术人员能够实现或使用本发明。对这些实施例的多种修改对本领域的专业技术人员来说将是显而易见的,本文中所定义的一般原理可以在不脱离本发明的精神或范围的情况下,在其它实施例中实现。因此,本发明将不会被限制于本文所示的这些实施例,而是要符合与本文所公开的原理和新颖特点相一致的最宽的范围。 The above description of the disclosed embodiments enables those skilled in the art to make or use the invention. Various modifications to these embodiments are obvious to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the invention. Therefore, the present invention is not to be limited to the embodiments shown herein, but the scope of the invention is to be accorded

Claims (18)

  1. 一种配置流表项的方法,其特征在于,所述方法包括:A method for configuring a flow entry, the method comprising:
    交换机向控制器发送一个请求下发流表项的请求消息,所述请求消息中携带有待转发的数据包;The switch sends a request message to the controller for requesting the sending of the flow entry, where the request message carries the data packet to be forwarded;
    所述交换机接收所述控制器返回的一个响应消息,所述响应消息中携带有与所述待转发的数据包匹配的所有流表项;Receiving, by the switch, a response message returned by the controller, where the response message carries all flow entry items that match the data packet to be forwarded;
    所述交换机从所述响应消息中提取与所述待转发的数据包匹配的所有流表项;The switch extracts, from the response message, all flow entries that match the data packet to be forwarded;
    所述交换机将提取出的所有流表项聚合为硬件层的流表项,并在所述交换机支持所述硬件层的流表项时,将所述硬件层的流表项配置到硬件层的流表中。The switch aggregates all the extracted flow entries into the flow entry of the hardware layer, and configures the flow entry of the hardware layer to the hardware layer when the switch supports the flow entry of the hardware layer. In the flow table.
  2. 根据权利要求1所述的方法,其特征在于,所述方法还包括:The method of claim 1 further comprising:
    通过所述响应消息中携带的,与所述待转发的数据包匹配的所有流表项转发所述待转发的数据包。The data packet to be forwarded is forwarded by all the flow entry items that are carried in the response message and that match the data packet to be forwarded.
  3. 根据权利要求1或2所述的方法,其特征在于,所述交换机和所述控制器之间通过OpenFlow协议进行通信,所述请求消息和所述响应消息通过所述OpenFlow协议传输。The method according to claim 1 or 2, wherein the switch and the controller communicate through an OpenFlow protocol, and the request message and the response message are transmitted through the OpenFlow protocol.
  4. 根据权利要求3所述的方法,其特征在于,所述响应消息为扩展的ofp_flow_mod消息,所述扩展的ofp_flow_mod消息为在ofp_flow_mod消息中定义一个数组后所得到的消息,并且,所述扩展的ofp_flow_mod消息通过定义的数组可同时携带多个流表项。The method according to claim 3, wherein the response message is an extended ofp_flow_mod message, the extended ofp_flow_mod message is a message obtained after defining an array in the ofp_flow_mod message, and the extended ofp_flow_mod A message can carry multiple flow table entries at the same time through a defined array.
  5. 根据权利要求4所述的方法,其特征在于,所述响应消息还携带有消息类型标识以及流表项数量标识,所述消息类型标识用于指示所述响应消息为扩展的ofp_flow_mod消息,所述流表项数量标识用于指示所述扩展的ofp_flow_mod消息中携带的流表项的数量。The method according to claim 4, wherein the response message further carries a message type identifier and a flow entry quantity identifier, and the message type identifier is used to indicate that the response message is an extended ofp_flow_mod message, The number of flow entry entries is used to indicate the number of flow entry entries carried in the extended ofp_flow_mod message.
  6. 根据权利要求1~5中任意一项所述的方法,其特征在于,所述方法还包括:将提取出的所有流表项配置到软件层的流表中。The method according to any one of claims 1 to 5, wherein the method further comprises: configuring all the extracted flow entry items into a flow table of the software layer.
  7. 一种下发流表项的方法,其特征在于,所述方法包括:A method for sending a flow entry, the method comprising:
    控制器接收交换机发送的一个请求下发流表项的请求消息,所述请求消息中携带有待转发的数据包;The controller receives a request message sent by the switch for requesting the sending of the flow entry, where the request message carries the data packet to be forwarded;
    所述控制器生成与所述待转发的数据包匹配的所有流表项; The controller generates all flow entry items that match the data packet to be forwarded;
    所述控制器向所述交换机返回一个响应消息,所述响应消息中携带有与所述待转发的数据包匹配的所有流表项,其中,与所述数据包匹配的所有流表项用于聚合为硬件层的流表项,所述硬件层的流表项用于配置到所述交换机的硬件层的流表中。Returning, by the controller, a response message to the switch, where the response message carries all flow entries that match the data packet to be forwarded, where all flow entries matching the data packet are used. The flow table entry is aggregated into a hardware layer, and the flow entry of the hardware layer is used to be configured in a flow table of a hardware layer of the switch.
  8. 根据权利要求7所述的方法,其特征在于,所述控制器和所述交换机之间通过OpenFlow协议进行通信,所述请求消息和所述响应消息通过所述OpenFlow协议传输。The method according to claim 7, wherein the controller and the switch communicate through an OpenFlow protocol, and the request message and the response message are transmitted through the OpenFlow protocol.
  9. 根据权利要求8所述的方法,其特征在于,所述响应消息为扩展的ofp_flow_mod消息,所述扩展的ofp_flow_mod消息为在ofp_flow_mod消息中定义一个数组后所得到的消息,并且,所述扩展的ofp_flow_mod消息通过定义的数组可同时携带多个流表项。The method according to claim 8, wherein the response message is an extended ofp_flow_mod message, the extended ofp_flow_mod message is a message obtained after defining an array in the ofp_flow_mod message, and the extended ofp_flow_mod A message can carry multiple flow table entries at the same time through a defined array.
  10. 一种配置流表项的装置,其特征在于,所述装置包括:An apparatus for configuring a flow entry, characterized in that the device comprises:
    发送模块,用于向控制器发送一个请求下发流表项的请求消息,所述请求消息中携带有待转发的数据包;a sending module, configured to send, to the controller, a request message for requesting the sending of the flow entry, where the request message carries the data packet to be forwarded;
    接收模块,用于接收所述控制器返回的一个响应消息,所述响应消息中携带有与所述待转发的数据包匹配的所有流表项;a receiving module, configured to receive a response message returned by the controller, where the response message carries all flow entry items that match the data packet to be forwarded;
    提取模块,用于从所述接收模块接收的所述响应消息中提取与所述待转发的数据包匹配的所有流表项;An extracting module, configured to extract, from the response message received by the receiving module, all flow entry items that match the data packet to be forwarded;
    硬件层配置模块,用于将所述提取模块提取出的所有流表项聚合为硬件层的流表项,并在所述交换机支持所述硬件层的流表项时,将所述硬件层的流表项配置到硬件层的流表中。a hardware layer configuration module, configured to aggregate all flow entries extracted by the extraction module into flow entry entries of the hardware layer, and when the switch supports the flow entry of the hardware layer, the hardware layer The flow entry is configured in the flow table of the hardware layer.
  11. 根据权利要求10所述的装置,其特征在于,所述装置还包括:The device according to claim 10, wherein the device further comprises:
    转发模块,用于通过所述接收模块接收的所述响应消息中携带的与所述待转发的数据包匹配的所有流表项转发所述待转发的数据包。And a forwarding module, configured to forward the data packet to be forwarded by using all the flow entry that is matched by the data packet to be forwarded in the response message that is received by the receiving module.
  12. 根据权利要求10或11所述的装置,其特征在于,所述交换机和所述控制器之间通过OpenFlow协议进行通信,所述请求消息和所述响应消息通过所述OpenFlow协议传输。The device according to claim 10 or 11, wherein the switch and the controller communicate through an OpenFlow protocol, and the request message and the response message are transmitted through the OpenFlow protocol.
  13. 根据权利要求12所述的装置,其特征在于,所述响应消息为扩展的ofp_flow_mod消息,所述扩展的ofp_flow_mod消息为在ofp_flow_mod消息中 定义一个数组后所得到的消息,并且,所述扩展的ofp_flow_mod消息通过定义的数组可同时携带多个流表项。The apparatus according to claim 12, wherein the response message is an extended ofp_flow_mod message, and the extended ofp_flow_mod message is in an ofp_flow_mod message The message obtained after defining an array, and the extended ofp_flow_mod message can carry multiple flow table entries simultaneously through the defined array.
  14. 根据权利要求13所述的装置,其特征在于,所述响应消息还携带有消息类型标识以及流表项数量标识,所述消息类型标识用于指示所述响应消息为扩展的ofp_flow_mod消息,所述流表项数量标识用于指示所述扩展的ofp_flow_mod消息中携带的流表项的数量。The apparatus according to claim 13, wherein the response message further carries a message type identifier and a flow entry quantity identifier, and the message type identifier is used to indicate that the response message is an extended ofp_flow_mod message, The number of flow entry entries is used to indicate the number of flow entry entries carried in the extended ofp_flow_mod message.
  15. 根据权利要求10~14中任意一项所述的装置,其特征在于,所述装置还包括:The device according to any one of claims 10 to 14, wherein the device further comprises:
    软件层配置模块,用于将提取出的所有流表项配置到软件层的流表中。The software layer configuration module is configured to configure all the extracted flow entry items into the flow table of the software layer.
  16. 一种下发流表项的装置,其特征在于,所述装置包括:A device for sending a flow entry, characterized in that the device comprises:
    接收模块,用于接收交换机发送的一个请求下发流表项的请求消息,所述请求消息中携带有待转发的数据包;a receiving module, configured to receive, by the switch, a request message for requesting the sending of the flow entry, where the request message carries the data packet to be forwarded;
    流表项生成模块,用于生成与所述待转发的数据包匹配的所有流表项;a flow entry generation module, configured to generate all flow entry items that match the data packet to be forwarded;
    发送模块,用于向所述交换机返回一个响应消息,所述响应消息中携带有与所述待转发的数据包匹配的所有流表项,其中,与所述待转发的数据包匹配的所有流表项用于聚合为硬件层的流表项,所述硬件层的流表项用于配置到所述交换机的硬件层的流表中。a sending module, configured to return a response message to the switch, where the response message carries all flow entries that match the data packet to be forwarded, where all flows that match the data packet to be forwarded The entry is used to aggregate the flow entry of the hardware layer, and the flow entry of the hardware layer is used to be configured in the flow table of the hardware layer of the switch.
  17. 根据权利要求16所述的装置,其特征在于,所述控制器和所述交换机之间通过OpenFlow协议进行通信,所述请求消息和所述响应消息通过所述OpenFlow协议传输。The apparatus according to claim 16, wherein the controller and the switch communicate through an OpenFlow protocol, and the request message and the response message are transmitted through the OpenFlow protocol.
  18. 根据权利要求17所述的装置,其特征在于,所述响应消息为扩展的ofp_flow_mod消息,所述扩展的ofp_flow_mod消息为在ofp_flow_mod消息中定义一个数组后所得到的消息,并且,所述扩展的ofp_flow_mod消息通过定义的数组可同时携带多个流表项。 The apparatus according to claim 17, wherein the response message is an extended ofp_flow_mod message, the extended ofp_flow_mod message is a message obtained after defining an array in the ofp_flow_mod message, and the extended ofp_flow_mod A message can carry multiple flow table entries at the same time through a defined array.
PCT/CN2014/095230 2014-01-20 2014-12-27 Method and apparatus for configuring and delivering flow table entry WO2015106623A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201410025787.7 2014-01-20
CN201410025787.7A CN104796336B (en) 2014-01-20 2014-01-20 A kind of method and device for being configured, issuing flow table item

Publications (1)

Publication Number Publication Date
WO2015106623A1 true WO2015106623A1 (en) 2015-07-23

Family

ID=53542383

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2014/095230 WO2015106623A1 (en) 2014-01-20 2014-12-27 Method and apparatus for configuring and delivering flow table entry

Country Status (2)

Country Link
CN (1) CN104796336B (en)
WO (1) WO2015106623A1 (en)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106888165A (en) * 2015-12-15 2017-06-23 中国科学院沈阳自动化研究所 A kind of industrial SDN data transmission method and system for supporting Header compression
WO2018018567A1 (en) * 2016-07-29 2018-02-01 华为技术有限公司 Method and device for managing switch
WO2018103825A1 (en) * 2016-12-06 2018-06-14 Huawei Technologies Co., Ltd. System and method for low memory and low traffic overhead heavy-hitter detection
CN107124300B (en) * 2017-04-01 2020-03-17 西安交通大学 Switch migration method in software defined network
CN110300068B (en) * 2019-06-14 2023-04-07 杭州迪普科技股份有限公司 ARP resource management method and device and electronic equipment
CN110430138B (en) * 2019-07-26 2022-02-22 新华三技术有限公司合肥分公司 Data flow forwarding state recording method and network equipment

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1921442A (en) * 2006-08-15 2007-02-28 杭州华为三康技术有限公司 Method and device for ensuring message hardware transfer
CN103428094A (en) * 2013-08-12 2013-12-04 杭州华三通信技术有限公司 Method and device for packet transmitting in Open Flow system

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102301663B (en) * 2011-07-06 2013-11-06 华为技术有限公司 Message processing method and associated devices
KR101887581B1 (en) * 2011-12-26 2018-08-14 한국전자통신연구원 Flow-based packet transport device and packet management method thereof
CN103259728B (en) * 2013-05-24 2016-03-30 华为技术有限公司 A kind of OFS in-band communications method and OFS

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1921442A (en) * 2006-08-15 2007-02-28 杭州华为三康技术有限公司 Method and device for ensuring message hardware transfer
CN103428094A (en) * 2013-08-12 2013-12-04 杭州华三通信技术有限公司 Method and device for packet transmitting in Open Flow system

Also Published As

Publication number Publication date
CN104796336B (en) 2018-06-19
CN104796336A (en) 2015-07-22

Similar Documents

Publication Publication Date Title
US10659342B2 (en) Flow entry configuration method, apparatus, and system
WO2015106623A1 (en) Method and apparatus for configuring and delivering flow table entry
US10216853B2 (en) Method and system for implementing a VXLAN control plane
WO2020001393A1 (en) Method and network node for sending network performance parameter and calculating network performance
WO2015161780A1 (en) Forwarding data packets
WO2017113306A1 (en) Method for sending virtual extensible local area network packet, computer device, and readable medium
EP2955884A1 (en) Method, apparatus and system for configuring flow table in openflow network
CN107113241B (en) Route determining method, network configuration method and related device
US20160127181A1 (en) System and Method for Service Chaining with Tunnel Chains in Software Defined Network
WO2017156908A1 (en) Method and device for forwarding packet
EP3225014A1 (en) Source ip address transparency systems and methods
WO2015149343A1 (en) In-network message processing method, in-network message forwarding equipment and in-network message processing system
CN104079478A (en) Method and device of packet forwarding
US9331935B2 (en) Network device selection
CN106716870B (en) Local packet switching at satellite device
CN110768911B (en) Method, device, equipment, system and storage medium for efficient flow drainage
US10230647B2 (en) Data packet processing method and device
CN109672594B (en) IPoE message processing method and device and broadband remote access server
WO2015124015A1 (en) Data packet forwarding method and device
WO2016070332A1 (en) Flow entry processing method and apparatus
US9667540B2 (en) Fiber channel over ethernet (FCoE) frame forwarding system
WO2017206562A1 (en) Data table processing method, device, and system
US9853891B2 (en) System and method for facilitating communication
WO2022100511A1 (en) Method and device for processing forwarding entry
US20140050116A1 (en) Techniques for Generic Pruning in a Trill Network

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: 14878876

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: 14878876

Country of ref document: EP

Kind code of ref document: A1