WO2014079319A1 - 报文的转发方法及其路由设备、识别设备 - Google Patents
报文的转发方法及其路由设备、识别设备 Download PDFInfo
- Publication number
- WO2014079319A1 WO2014079319A1 PCT/CN2013/086565 CN2013086565W WO2014079319A1 WO 2014079319 A1 WO2014079319 A1 WO 2014079319A1 CN 2013086565 W CN2013086565 W CN 2013086565W WO 2014079319 A1 WO2014079319 A1 WO 2014079319A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- packet
- routing device
- module
- accelerated
- information
- Prior art date
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L45/00—Routing or path finding of packets in data switching networks
Definitions
- the application is submitted to the Chinese Patent Office on November 22, 2012, and the application number is 201210479132. 8.
- the invention name is "the forwarding method of the message and its routing device and identification device.
- the priority of the Chinese Patent Application the entire contents of which is incorporated herein by reference.
- the present invention relates to the field of message forwarding, and in particular, to a packet forwarding method, a routing device thereof, and an identification device.
- a technical solution of the WAN acceleration in the prior art is as follows: The CE router transmits the packet to the PE router, and the PE router sends the received packet to the corresponding acceleration device for acceleration and forwarding.
- the inventor of the present invention found in the long-term research and development that the acceleration scheme of the WAN packet forwarding in the prior art does not have the packet processing capability, that is, the capability of determining whether the packet needs to be accelerated, and the PE router is entered from an enterprise site. All the packets are directed to the acceleration device, and the packets that need to be accelerated are not directly directed to the acceleration device for acceleration processing, which increases the overhead of the packets that do not need to be accelerated, and reduces the overall transmission performance. Summary of the invention
- the technical problem to be solved by the embodiments of the present invention is to provide a packet forwarding method, a routing device, and a recognition device, which can reduce the overhead of packets that do not need to be accelerated, and improve the overall transmission performance of the packet.
- an aspect of the present invention is to provide a method for forwarding a packet, including: the routing device receives the first packet sent by the user; and the routing device encapsulates the user information corresponding to the first packet into the first
- the second message is obtained in a message; the routing device sends the second message to the identification device, and the identification device is configured to determine whether the second message needs to be accelerated; the routing device receives the control information sent by the identification device, and the control information And the flow device includes the flow information corresponding to the second packet with the same quintuple information; the routing device creates the flow entry corresponding to the second packet according to the control information, where the flow entry includes the quintuple information and the flow operation
- the routing device processes the third packet according to the flow operation information when the routing device receives the third packet, and when the third packet matches the flow entry.
- the routing device encapsulates the user information corresponding to the third packet into the third packet to obtain the fourth packet; the routing device sends
- the method further includes: determining that the first packet is a packet corresponding to the subscription user.
- the method further includes: determining that the destination address of the first packet is a preset destination address that needs to be accelerated.
- the method further includes: determining a protocol type of the first packet to be a preset protocol type that needs to be accelerated.
- another aspect of the present invention is: providing a routing device, including: a first receiving module, configured to receive a first packet sent by a user; and a packaging module, configured to correspond to the first packet
- the user information is encapsulated into the first packet to obtain the second packet.
- the first sending module is configured to send the second packet to the identifying device
- the second receiving module is configured to receive the control information sent by the identifying device.
- the control information includes flow operation information of the packet having the same quintuple information as the second packet.
- the first creation module is configured to create a flow entry corresponding to the second packet according to the control information, where the flow entry includes a quintuple information and a flow operation information; a matching module, configured to: when the first receiving module receives the third packet, determine whether the third packet matches the flow entry; and the processing module is configured to match the flow of the third packet The third packet is processed according to the flow operation information.
- the encapsulating module is further configured to: when the third packet does not match the flow entry, the user information corresponding to the third packet is encapsulated into the third packet to obtain the fourth packet; the first sending module is further configured to: The fourth message is sent to the identification device.
- the routing device further includes: a determining module, configured to: before the encapsulating module encapsulates the user information corresponding to the first packet into the first packet to obtain the second packet, determining that the first packet is the corresponding message of the subscribing user Text.
- the determining module is further configured to: before the encapsulating module encapsulates the user information corresponding to the first packet into the first packet to obtain the second packet, determining that the destination address of the first packet is preset and needs to be accelerated. Destination address.
- the determining module is further configured to: before the encapsulating module encapsulates the user information corresponding to the first packet into the first packet to obtain the second packet, determining that the protocol type of the first packet is preset and needs to be accelerated. agreement type.
- a further aspect of the present invention is: providing an identification device, comprising: a third receiving module, configured to receive a second packet sent by a routing device; and a determining module, configured to use the second packet
- the user information in the user is searched for the corresponding preset service configuration, and the second service packet needs to be accelerated according to the preset service configuration.
- the preset service configuration includes whether the second packet needs to be accelerated.
- the second creation module is configured to: after the determining module determines whether the second packet needs to be accelerated, create a control letter corresponding to the second packet
- the control information includes flow operation information of the message having the same quintuple information as the second message, and the second sending module is configured to send the control information to the routing device.
- the embodiment of the present invention receives the first packet sent by the user by using the routing device, and the routing device encapsulates the user information corresponding to the first packet into the first report.
- the second packet is obtained in the text, and the second packet is sent to the identification device to determine whether the second packet needs to be accelerated.
- the routing device creates a flow entry corresponding to the second packet according to the control information sent by the identification device.
- the routing device processes the third packet according to the flow operation information in the flow entry.
- FIG. 1 is a flowchart of a first embodiment of a method for forwarding a message according to the present invention
- FIG. 2 is a flowchart of a second embodiment of a method for forwarding a message according to the present invention
- FIG. 3 is a schematic block diagram of a first embodiment of a routing device of the present invention.
- FIG. 4 is a schematic block diagram of a second embodiment of a routing device of the present invention.
- FIG. 5 is a schematic block diagram of an embodiment of the identification device of the present invention.
- a first embodiment of a method for forwarding a packet according to the present invention includes: Step S101: Receive a first packet; and the routing device receives a first packet sent by a user.
- the routing device is a routing device such as an SR (Service Router).
- Step S102 Encapsulating the user information into the first packet to obtain the second packet. After receiving the first packet, the routing device encapsulates the user information corresponding to the first packet into the first packet to obtain the first packet. Two messages.
- the first packet is a data packet, and the user information corresponding to the data packet needs to include information such as an interface board, an interface, a sub-interface, and a tunnel that the user accesses to distinguish different users, and the routing device encapsulates the user information into the first
- a second message is obtained in a message, and the second message is a control message.
- Step S103 Send the second packet to the identification device.
- the routing device After obtaining the second packet, the routing device further sends the second packet to the identification device.
- the identification device is configured to determine whether the second packet needs to be accelerated. When the judgment result of the identification device is that the second packet needs to be accelerated, the routing device receives the second packet after the acceleration processing sent by the acceleration device, and the routing device further forwards the second packet after the acceleration processing; When the judgment result of the device is that the second packet does not need to be accelerated, the routing device receives the second packet sent by the identification device that does not need to be accelerated, and the routing device further forwards the second packet that does not need to be accelerated.
- Step S104 Receive control information; the routing device receives the control information sent by the identification device.
- the control information includes stream operation information of a message having the same quintuple information as the second message.
- the control information is created by the identification device searching for the corresponding preset service configuration according to the user information in the second packet, and determining whether the second packet needs to be accelerated according to the preset service configuration; The setting of the related judgment content including whether the second message needs to be accelerated; the quintuple information includes a source address, a destination address, a source port, a destination port, and a protocol match.
- Step S105 Create a flow entry; after receiving the control information, the routing device creates a flow entry corresponding to the second packet according to the control information.
- the flow entry includes the quintuple information of the second packet and the flow operation information.
- the flow operation information carries the flow operation information of the packets that are subsequently entered into the routing device to direct the flow of the packets that enter the routing device.
- the subsequent packets entering the routing device include the same quintuple information as the second packet.
- Step S106 Receive a third packet. After the flow entry corresponding to the second packet is created, the routing device receives the third packet sent by the user.
- Step S107 determining whether the third packet matches the flow entry; when the routing device receives the third packet, the routing device determines whether the quintuple information of the third packet is the same as the quintuple information of the second packet. It is determined whether the third packet matches the flow entry.
- Step S108a Processing the third packet.
- the routing device When determining that the third packet matches the flow entry, the routing device processes the third packet according to the flow operation information in the flow entry.
- the specific processing procedure is as follows: When the judgment result of the second packet in the identification device is that the acceleration processing is required, the flow operation information in the flow entry created by the routing device carries the routing device and the second packet quintuple information. The same subsequent packet is sent to the flow operation information of the acceleration device. The third packet at this time is the subsequent packet with the same information as the second packet quintuple. The routing device directly uses the third packet according to the flow operation information.
- the flow operation information in the flow entry created by the routing device carries the routing device and the second packet, when the result of the second packet in the identification device is that the acceleration processing is not required.
- Step S108b Encapsulating the user information into the third packet to obtain the fourth packet.
- the routing device encapsulates the user information corresponding to the third packet into the third packet.
- the fourth message is obtained in the text.
- Step S109 Send the fourth message to the identification device. After obtaining the fourth packet, the routing device further sends the fourth packet to the identifying device to determine whether the fourth packet needs to be accelerated.
- the routing device creates a flow entry corresponding to the fourth packet according to the control information sent by the identification device to guide subsequent entry of the same quintuple information with the fourth packet.
- the identification device may be built in the routing device, and the identification device may also be on the same server or SPU (Signal Processing Unit) board as the acceleration device, and the identification device and the acceleration device are also It can be used on the server or SPU board alone, and there are no restrictions here.
- the first embodiment of the packet forwarding method of the present invention receives the first packet sent by the user by using the routing device, and the routing device encapsulates the user information corresponding to the first packet into the first packet to obtain the second packet. And the second packet is sent to the identification device to determine whether the second packet needs to be accelerated.
- the routing device creates a flow entry corresponding to the second packet according to the control information sent by the identifier, when the routing device receives the When the third packet matches the flow entry, the routing device processes the third packet according to the flow operation information in the flow entry.
- a second implementation manner of the packet forwarding method of the present invention includes: Step S201: Receive a first packet; and the routing device receives the first packet sent by the user.
- Step S202a Determine that the first packet is a packet corresponding to the subscribing user. After receiving the first packet, the routing device determines that the first packet is a packet corresponding to the subscribing user.
- Step S202b determining that the destination address of the first packet is a preset destination address that needs to be accelerated; after receiving the first packet, the routing device determines that the destination address of the first packet is a preset destination that needs to be accelerated. address.
- the routing device directly forwards the first packet.
- Step S202c determining that the protocol type of the first packet is a preset protocol type that needs to be accelerated; after receiving the first packet, the routing device determines that the protocol type of the first packet is a preset protocol that needs to be accelerated. Types of.
- Step S203 Encapsulating the user information into the first packet to obtain the second packet; determining that the first packet is the packet corresponding to the subscription user, and the destination address of the first packet is preset and needs to be accelerated. After the address and the protocol type of the first packet are the preset types of the protocol to be accelerated, the routing device encapsulates the user information corresponding to the first packet into the first packet to obtain the second packet.
- the execution order of the step S202a, the step S202b, and the step S202c is not limited to the sequential execution sequence described in this embodiment.
- Step S204 Send the second packet to the identification device. After obtaining the second packet, the routing device further sends the second packet to the identification device.
- Step S205 Receive control information; the routing device receives the control information sent by the identification device. The control information includes stream operation information of a message having the same quintuple information as the second message.
- Step S206 Create a flow table entry. After receiving the control information, the routing device creates a flow entry corresponding to the second packet according to the control information.
- the flow entry includes the quintuple information of the second packet and the flow operation information.
- Step S207 Receive a third packet. After the flow entry corresponding to the second packet is created, the routing device receives the third packet sent by the user. Step S208: determining whether the third packet matches the flow entry; after the routing device receives the third packet, the routing device determines whether the quintuple information of the third packet is the same as the quintuple information of the second packet. It is determined whether the third packet matches the flow entry.
- Step S209a Processing the third packet. When determining that the third packet matches the flow entry, the routing device processes the third packet according to the flow operation information in the flow entry.
- Step S209b Encapsulating the user information into the third packet to obtain the fourth packet.
- the routing device encapsulates the user information corresponding to the third packet into the third packet.
- the fourth message is obtained in the text.
- Step S210 Send the fourth message to the identification device. After obtaining the fourth packet, the routing device further sends the fourth packet to the identifying device to determine whether the fourth packet needs to be accelerated.
- the second embodiment of the packet forwarding method of the present invention receives the first packet sent by the user by using the routing device, and the routing device determines that the first packet is the packet corresponding to the subscription user, and determines the destination address of the first packet. For the preset destination address that needs to be accelerated, and determining the protocol type of the first packet as a preset protocol type that needs to be accelerated, the routing device further encapsulates the user information into the determined first packet to obtain the first The second packet is sent to the identification device to determine whether the second packet needs to be accelerated.
- the routing device creates a flow entry corresponding to the second packet according to the control information sent by the identification device, and the routing device receives the When the third packet matches the flow entry, the routing device processes the third packet according to the flow operation information in the flow entry. In the foregoing manner, the initial filtering of the packet can be implemented. On the basis of the flow table entry, the subsequent packet with the same quintuple information of the flow entry is directly processed according to the flow entry. The overhead of the packets that do not need to be processed is reduced, and the overall transmission performance of the packets is improved.
- the first embodiment of the routing device of the present invention includes: a first receiving module 301, configured to receive a packet sent by a user.
- the packet received by the first receiving module 301 includes at least a first packet.
- the encapsulating module 302 is configured to encapsulate the corresponding user information of the first packet received by the first receiving module 301 into the first packet to obtain the second packet.
- the first sending module 303 is configured to send the second packet obtained by encapsulating the encapsulating module 302 to the identifying device.
- the identification device is configured to determine whether the second packet needs to be accelerated.
- the second receiving module 304 is configured to receive control information sent by the identification device.
- the control information includes flow operation information of the packet having the same quintuple information as the second packet.
- the second receiving module 304 is further configured to: when the determining result of the identifying device is that the second packet needs to be accelerated, receive the second packet after the acceleration processing sent by the acceleration device, and the forwarding module of the routing device further accelerates the processing.
- the second receiving module 304 is further configured to: when the determining result of the identifying device is that the second packet does not need to be accelerated, receiving the second packet sent by the identifying device that does not require acceleration processing, The forwarding module further forwards the second message that does not require acceleration processing.
- the first creating module 305 is configured to create a flow entry corresponding to the second packet according to the control information received by the second receiving module 304.
- the flow entry includes the quintuple information of the second packet and the flow operation information.
- the matching module 306 is configured to determine, when the first receiving module 301 receives the third packet sent by the user, whether the third packet matches the flow entry corresponding to the second packet created by the first creating module 305.
- the processing module 307 is configured to: when the matching module 306 determines that the third packet matches the flow entry, the third packet is processed according to the flow operation information in the flow entry.
- the specific processing procedure is: when the result of the second packet in the identification device is that the acceleration processing is required, the flow operation information in the flow entry created by the first creation module 305 is carried with the second packet quintuple.
- the subsequent packets with the same information are sent to the stream operation information of the acceleration device, and the processing module 307 controls the first sending module 303 to directly send the third packet to the acceleration device for acceleration processing according to the flow operation information; when the second packet is identified If the result of the device is that the acceleration process is not required, the flow operation information in the flow entry created by the first creation module 305 carries the flow operation information that directly forwards the subsequent packet with the same information as the second packet quintuple.
- the processing module 307 controls the forwarding module of the routing device to directly forward the third packet according to the flow operation information.
- the encapsulating module 302 is further configured to: when the matching module 306 determines that the third packet does not match the flow entry, the user information corresponding to the third packet is encapsulated into the third packet to obtain the fourth packet.
- the first sending module 303 is further configured to further send the fourth packet to the identifying device.
- the first receiving module 301 of the routing device receives the first packet sent by the user, and the encapsulating module 302 encapsulates the user information corresponding to the first packet into the first packet.
- the second sending module 303 further sends the second packet to the identifying device to determine whether the second packet needs to be accelerated.
- the first creating module 305 creates the first information according to the control information received by the second receiving module 304. For the flow entry corresponding to the second packet, when the matching module 306 determines that the third packet matches the flow entry, the processing module 307 processes the third packet according to the flow operation information in the flow entry.
- the second embodiment of the routing device of the present invention includes: a first receiving module 401, configured to receive a packet sent by a user.
- the first receiving module 401 receives at least the first packet.
- the determining module 402 is configured to: before the encapsulating module 403 encapsulates the user information corresponding to the first packet into the first packet to obtain the second packet, determining that the first packet received by the first receiving module 301 is a subscribing user Corresponding packets, determining a destination address of the first packet is a preset destination address that needs to be accelerated, and determining a protocol type of the first packet is a preset protocol type that needs to be accelerated.
- the encapsulating module 403 is configured to encapsulate the user information corresponding to the first packet into the first packet to obtain the second packet, after the determining module 402 performs the content determination as described above.
- the first sending module 404 is configured to send the second packet obtained by encapsulating the encapsulating module 403 to the identifying device.
- the second receiving module 405 is configured to receive control information sent by the identification device.
- the control information includes flow operation information of the packet having the same quintuple information as the second packet.
- the first creating module 406 is configured to create a flow entry corresponding to the second packet according to the control information received by the second receiving module 405.
- the flow entry includes the quintuple information of the second packet and the flow operation information.
- the matching module 407 is configured to: when the first receiving module 401 receives the third packet, determine whether the third packet matches the flow entry corresponding to the second packet created by the first creating module 406.
- the processing module 408 is configured to: when the matching module 407 determines that the third packet matches the flow entry, the third packet is processed according to the flow operation information in the flow entry. For a specific process, refer to the processing module 307 of the first embodiment of the routing device of the present invention, and details are not described herein again.
- the encapsulating module 403 is further configured to: when the matching module 407 determines that the third packet does not match the flow entry, the user information corresponding to the third packet is encapsulated into the third packet to obtain the fourth packet.
- the first sending module 404 is further configured to further send the fourth message to the identifying device.
- the second embodiment of the routing device of the present invention receives the first packet sent by the user by the first receiving module 401 of the routing device, and the determining module 402 determines that the first packet is the packet corresponding to the subscription user, and determines the first packet.
- the destination address of the text is a preset destination address that needs to be accelerated, and the protocol type of the first packet is determined to be a preset protocol type that needs to be accelerated.
- the encapsulation module 403 further encapsulates the user information into the determined first report.
- the second sending module 404 sends the second packet to the identifying device to determine whether the second packet needs to be accelerated.
- the first creating module 406 receives the control information according to the second receiving module 405.
- the flow table entry corresponding to the second packet is created.
- the processing module 408 processes the third packet according to the flow operation information in the flow entry. In the foregoing manner, the initial filtering of the packet can be implemented.
- the subsequent packet with the same quintuple information of the flow entry is directly processed according to the flow entry. The overhead of the packets that do not need to be processed is reduced, and the overall transmission performance of the packets is improved.
- an embodiment of the present invention includes: a third receiving module 501, configured to receive a second packet sent by a routing device.
- the second packet is obtained by the routing device receiving the user information corresponding to the first packet sent by the user.
- the determining module 502 is configured to search for a corresponding preset service configuration according to the user information in the second packet, and further determine, according to the preset service configuration, whether the second packet needs to be accelerated.
- the preset service configuration includes setting whether the second message needs to be accelerated to be related to the judgment content.
- the content of the judgment may include determining whether the destination address of the second packet is a destination address that is set by the user and needs to be accelerated. If the destination address of the second packet is a destination address that is set by the user and needs to be accelerated.
- the judgment result of the judging module 502 is that the second packet needs to be accelerated, otherwise the judging result is that the second packet does not need to be accelerated; the related judging content may further include determining whether the protocol type of the second packet is required for the user to be accelerated.
- the type of the protocol to be processed if the protocol type of the second packet is a protocol type that is set by the user and needs to be accelerated, the judgment result of the determining module 502 is that the second packet needs to be accelerated; the related judgment content may further include the second packet.
- the related judgment content may further include determining whether the content of the request of the second message includes the content of the format of jpeg, gif, exe, tar, etc., and the size of the compression capability depends on Due to the nature of the object being compressed, the compression algorithm has a good compression ratio for the content of the text format, and since the content of the format such as jpeg, gif, exe, tar has been compressed, the content compression efficiency of the compression algorithm on the above format is It is not high and the compression efficiency is related to whether the message needs to be accelerated.
- the second creating module 503 is configured to: after the determining module 502 determines whether the second packet needs to be accelerated, the control information corresponding to the second packet is created.
- the control information includes flow operation information of the packet having the same quintuple information as the second packet.
- the flow operation information when the judgment result of the determination module 502 is that the second message does not need to be accelerated, the flow operation information in the corresponding created control information carries the follow-up that the routing device will be the same as the second message quintuple information.
- the stream operation information that the packet directly forwards.
- the second sending module 504 is configured to send the control information to the routing device after the second creating module 503 creates the control information, so that the routing device further creates a flow entry corresponding to the second packet according to the control information.
- the second sending module 504 is further configured to: when the determining result of the determining module 502 is that the second packet needs to be accelerated, send the second packet that needs to be accelerated to the acceleration device to perform acceleration processing; and the second sending module 504 When the judgment result of the determining module 502 is that the second packet does not need to be accelerated, the second packet that does not need to be accelerated is sent to the routing device for forwarding.
- the third receiving module 501 is further configured to: when the routing device receives the third packet, and the third packet does not match the flow entry, and encapsulates the user information to obtain the fourth packet, receiving the fourth packet sent by the routing device. Text.
- the third receiving module 501 of the identifying device receives the second packet sent by the routing device, and the determining module 502 searches for the corresponding preset service configuration according to the user information in the second packet. And determining, according to the preset service configuration, whether the second packet needs to be accelerated, the second creating module 503 is configured to generate control information corresponding to the second packet, and the second sending module sends the control information to the routing device to create the second packet. Corresponding flow entry. In the above manner, it is possible to determine whether the packet needs to be accelerated, reduce the overhead of the packet that does not need to be accelerated, and improve the overall transmission performance of the packet. Referring to FIG.
- an implementation manner of a forwarding device of a packet according to the present invention includes:
- the processor 601 is electrically connected to the memory 602 and the input/output device 603, respectively, for when the service configuration of the message from the input/output device 603 is the same as the preset service configuration required to be accelerated in the memory 602.
- the message is an advertisement that needs to be accelerated, and the input message is accelerated, and the input/output device 603 is controlled to forward the accelerated message; or is used for the service configuration of the message from the input/output device 603.
- the control input/output device 603 directly forwards the message that does not need to be accelerated.
- the memory 602 is electrically connected to the processor 601 and configured to store a preset service configuration that needs to be accelerated.
- the input/output device 603 is electrically connected to the processor 601 for transmitting the message with the processor 601, and the input/output device 603 is further configured to forward the message.
- the input/output device 603 is an input/output device such as a routing device.
- the processor 601 controls the input/output device 603 to perform the acceleration processing on the packet that needs to be accelerated, or forward the packet that does not need to be accelerated.
- the packets that need to be accelerated are forwarded after being accelerated, and the packets that do not need to be processed are directly forwarded, which reduces the overhead of the packets that do not need to be processed, and improves the overall transmission performance of the packets.
- the disclosed apparatus and method may be implemented in other manners.
- the device implementations described above are only illustrative.
- the division of the modules is only a logical function division.
- each functional module in each embodiment of the present application may be integrated into one processing unit, or each functional module may exist physically separately, or two or more functional modules may be integrated into one unit.
- the above integrated unit can be implemented in the form of hardware or in the form of a software functional unit.
- the integrated unit if implemented in the form of a software functional unit and sold or used as a standalone product, may be stored in a computer readable storage medium.
- the technical solution of the present application in essence or the contribution to the prior art, or all or part of the technical solution may be embodied in the form of a software product stored in a storage medium. , including a number of instructions to enable a computer device (which may be a personal computer, a server, or a network device, etc.) or a processor All or part of the steps of the methods described in the various embodiments of the present application.
- the foregoing storage medium includes: u disk, mobile hard disk, read-only memory (ROM), random access memory (RAM), magnetic disk or optical disk, and the like, which can store program code. .
- ROM read-only memory
- RAM random access memory
- magnetic disk or optical disk and the like, which can store program code.
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
本发明实施方式公开了一种报文的转发方法,包括路由设备接收用户发来的第一报文;路由设备将第一报文对应的用户信息封装到第一报文中而得到第二报文;路由设备将第二报文发送至识别设备;路由设备接收识别设备发来的控制信息,控制信息包括对与第二报文有相同五元组信息的报文的流操作信息;路由设备根据控制信息创建第二报文对应的流表项,其中,流表项包括五元组信息和流操作信息;当路由设备接收到第三报文,且当第三报文匹配所述流表项时,路由设备根据流操作信息对第三报文进行处理。本发明实施方式还公开了一种路由设备、识别设备。通过上述方式,本发明能够减少不需要加速处理的报文的开销,提高报文整体的传输性能。
Description
报文的转发方法及其路由设备、 识别设备 本申请要求于 2012年 11月 22日提交中国专利局、 申请号为 201210479132. 8、 发 明名称为 "报文的转发方法及其路由设备、 识别设备"的中国专利申请的优先权, 其全 部内容通过引用结合在本申请中。 技术领域 本发明涉及报文转发领域, 特别是涉及报文的转发方法及其路由设备、 识别设备。 背景技术 随着全球化经济的发展, 越来越多的企业应用信息需要通过广域网进行传输。 目前 广域网传输存在低带宽、 高延迟的问题。 在此延迟的局限性的影响, 应用系统运行时遇 到了各种瓶颈, 包括性能降低、 服务质量下降以及各种潜在的安全性问题。
基于上述问题, 解决应用系统性能受广域网限制的技术应运而生。 现有技术中一种 广域网加速的技术方案为: CE路由器传输报文到 PE路由器, PE路由器将接收到的报文 送往相应的加速设备进行加速后转发。
本申请发明人在长期研发中发现,现有技术的广域网报文转发的加速方案中不具备 报文处理能力, 即不具备判断报文是否需要加速处理的能力, 导致从一个企业站点进入 PE路由器的全部报文都被导向加速设备,无法实现只把需要加速处理的报文导向到加速 设备进行加速处理 , 增加了不需要加速处理的报文的开销, 降低了整体的传输性能。 发明内容
本发明实施方式主要解决的技术问题是提供一种报文的转发方法及其路由设备、识 别设备, 能够减少不需要加速处理的报文的开销, 提高报文整体的传输性能。
为解决上述技术问题, 本发明的一方面是: 提供一种报文的转发方法, 包括: 路由 设备接收用户发来的第一报文; 路由设备将第一报文对应的用户信息封装到第一报文中 而得到第二报文; 路由设备将第二报文发送至识别设备, 识别设备用于判断第二报文是 否需要加速处理; 路由设备接收识别设备发来的控制信息, 控制信息包括对与第二报文 有相同五元组信息的报文的流操作信息; 路由设备根据控制信息创建第二报文对应的流 表项, 其中, 流表项包括五元组信息和流操作信息; 当路由设备接收到第三报文, 且当 第三报文匹配流表项时, 路由设备根据流操作信息对第三报文进行处理。
其中, 当第三报文不匹配流表项时, 路由设备将第三报文对应的用户信息封装到第 三报文中而得到第四报文; 路由设备将第四报文发送至识别设备。
其中,在路由设备将第一报文对应的用户信息封装到第一报文中而得到第二报文前 进一步包括: 确定第一报文为订阅用户对应的报文。
其中,在路由设备将第一报文对应的用户信息封装到第一报文中而得到第二报文前 进一步包括: 确定第一报文的目的地址为预设的需要加速处理的目的地址。
其中,在路由设备将第一报文对应的用户信息封装到第一报文中而得到第二报文前 进一步包括: 确定第一报文的协议类型为预设的需要加速处理的协议类型。
为解决上述技术问题, 本发明的另一方面是: 提供一种路由设备, 包括: 第一接收 模块, 用于接收用户发来的第一报文; 封装模块, 用于将第一报文对应的用户信息封装 到第一报文中而得到第二报文; 第一发送模块, 用于将第二报文发送至识别设备; 第二 接收模块, 用于接收识别设备发来的控制信息, 控制信息包括对与第二报文有相同五元 组信息的报文的流操作信息; 第一创建模块, 用于根据控制信息创建第二报文对应的流 表项, 其中, 流表项包括五元组信息和流操作信息; 匹配模块, 用于当第一接收模块接 收到第三报文时, 判断第三报文是否匹配流表项; 处理模块, 用于当第三报文匹配流表 项时, 根据流操作信息对第三报文进行处理。
其中, 封装模块还用于当第三报文不匹配流表项时, 将第三报文对应的用户信息封 装到第三报文中而得到第四报文; 第一发送模块还用于将第四报文发送至识别设备。
其中, 路由设备还包括: 确定模块, 用于在封装模块将第一报文对应的用户信息封 装到第一报文中而得到第二报文前, 确定第一报文为订阅用户对应的报文。
其中,确定模块还用于在封装模块将第一报文对应的用户信息封装到第一报文中而 得到第二报文前, 确定第一报文的目的地址为预设的需要加速处理的目的地址。
其中,确定模块还用于在封装模块将第一报文对应的用户信息封装到第一报文中而 得到第二报文前, 确定第一报文的协议类型为预设的需要加速处理的协议类型。
为解决上述技术问题, 本发明的又一方面是: 提供一种识别设备, 包括: 第三接收 模块, 用于接收路由设备发来的第二报文; 判断模块, 用于根据第二报文中的用户信息 查找对应的预设的业务配置, 根据预设的业务配置判断第二报文是否需要加速处理, 其 中, 预设的业务配置包括第二报文是否需要加速处理的相关判断内容的设定; 第二创建 模块, 用于在判断模块判断第二报文是否需要加速处理后, 创建第二报文对应的控制信
息, 其中, 控制信息包括对与第二报文有相同五元组信息的报文的流操作信息; 第二发 送模块, 用于将控制信息发送至路由设备。
本发明实施方式的有益效果是: 区别于现有技术的情况, 本发明实施方式通过路由 设备接收用户发来的第一报文,路由设备将第一报文对应的用户信息封装到第一报文中 而得到第二报文, 进一步将第二报文发送至识别设备以判断第二报文是否需要加速处 理; 路由设备根据识别设备发来的控制信息创建第二报文对应的流表项, 当路由设备接 收到第三报文且第三报文匹配流表项时,路由设备根据流表项中的流操作信息对第三报 文进行处理。 通过上述方式, 能够实现判断报文是否需要加速处理且根据流表项对与流 表项的五元组信息相同的后续报文直接进行处理, 减少不需要加速处理的报文的开销, 提高报文整体的传输性能。 附图说明 图 1是本发明报文的转发方法第一实施方式的流程图;
图 2是本发明报文的转发方法第二实施方式的流程图;
图 3是本发明路由设备第一实施方式的原理框图;
图 4是本发明路由设备第二实施方式的原理框图;
图 5是本发明识别设备一实施方式的原理框图;
图 6是本发明报文的转发装置一实施方式的原理框图。 具体实施方式 下面将结合本发明实施方式中的附图, 对本发明实施方式中的技术方案进行清楚、 完整地描述, 显然, 所描述的实施方式仅仅是本发明一部分实施方式, 而不是全部的实 施方式。 基于本发明中的实施方式, 本领域普通技术人员在没有做出创造性劳动前提下 所获得的所有其他实施方式, 均属于本发明保护的范围。 请参阅图 1, 本发明报文的转发方法第一实施方式包括: 步骤 S101 : 接收第一报文; 路由设备接收用户发来的第一报文。 其中, 路由设备为 SR ( Service Router, 业务 路由器) 等路由设备。
步骤 S102: 将用户信息封装到第一报文中而得到第二报文; 在接收到第一报文后,路由设备将第一报文对应的用户信息封装到第一报文中而得 到第二报文。 其中, 第一报文为数据报文, 数据报文对应的用户信息需包含用户接入的 接口板、 接口、 子接口、 隧道等信息以区分不同用户, 路由设备在将上述用户信息封装 到第一报文中而得到第二报文, 第二报文为控制报文。 步骤 S103: 将第二报文发送至识别设备; 在得到第二报文后, 路由设备进一步将第二报文发送至识别设备。 其中, 识别设备 用于判断第二报文是否需要加速处理。当识别设备的判断结果为第二报文需要加速处理 时, 路由设备接收加速设备发来的加速处理后的第二报文, 路由设备进一步将加速处理 后的第二报文进行转发; 当识别设备的判断结果为第二报文不需要加速处理时, 路由设 备接收识别设备发来的不需要加速处理的第二报文,路由设备进一步将不需要加速处理 的第二报文进行转发。 步骤 S104: 接收控制信息; 路由设备接收上述识别设备发来的控制信息。控制信息包括对与第二报文有相同五 元组信息的报文的流操作信息。 其中, 控制信息为识别设备根据第二报文中的用户信息 查找对应的预设的业务配置进而根据预设的业务配置判断第二报文是否需要加速处理 而创建得到的; 预设的业务配置包括第二报文是否需要加速处理的相关判断内容的设 定; 五元组信息包括源地址、 目的地址、 源端口、 目的端口以及协议匹配。 步骤 S105: 创建流表项; 在接收到控制信息后, 路由设备根据控制信息创建第二报文对应的流表项。 其中, 流表项包括第二报文的五元组信息以及流操作信息。流操作信息中承载有后续进入路由 设备的报文的流操作信息以指引后续进入路由设备的报文的流向,后续进入路由设备的 报文包括与第二报文相同的五元组信息。 步骤 S106: 接收第三报文; 在创建第二报文对应的流表项后, 路由设备接收用户发来的第三报文。 步骤 S107: 判断第三报文是否匹配流表项; 当路由设备接收到第三报文时,路由设备判断第三报文的五元组信息是否与第二报 文的五元组信息相同从而判断得到第三报文是否匹配上述流表项。
步骤 S108a: 对第三报文进行处理; 当判断得到第三报文匹配流表项时,路由设备根据流表项中的流操作信息对第三报 文进行处理。 具体的处理过程为: 当第二报文在识别设备中的判断结果为需要加速处理 时,路由设备创建的流表项中的流操作信息承载有路由设备将与第二报文五元组信息相 同的后续报文发送至加速设备的流操作信息,此时的第三报文即为与第二报文五元组信 息相同的后续报文,路由设备根据流操作信息将第三报文直接发送至加速设备以进行加 速处理; 当第二报文在识别设备中的判断结果为不需要加速处理时, 路由设备创建的流 表项中的流操作信息承载有路由设备将与第二报文五元组信息相同的后续报文直接进 行转发的流操作信息, 路由设备根据流操作信息将第三报文直接进行转发。 步骤 S108b: 将用户信息封装到第三报文中而得到第四报文; 当判断得到第三报文不匹配流表项时,路由设备将第三报文对应的用户信息封装到 第三报文中而得到第四报文。 步骤 S109: 将第四报文发送至识别设备。 在得到第四报文后,路由设备进一步将第四报文发送至识别设备以判断第四报文是 否需要加速处理。 同理, 在发送第四报文至识别设备后, 路由设备根据识别设备发来的 控制信息创建第四报文对应的流表项以指引与第四报文有相同五元组信息的后续进入 路由设备的报文的流向。 当路由设备接收到用户发来的第五报文后, 执行与上述步骤 S106之后一样的步骤流程, 此处不再赘述。 在其他实施方式中, 识别设备可内置于路由设备中, 识别设备也可与加速设备同在 一台服务器或 SPU ( Signal l ing Process Unit, 信令处理单元) 板上, 识别设备与加速 设备也可单独在服务器或 SPU板上, 此处不作过多限制。 可以理解,本发明报文的转发方法第一实施方式通过路由设备接收用户发来的第一 报文, 路由设备将第一报文对应的用户信息封装到第一报文中而得到第二报文, 进一步 将第二报文发送至识别设备以判断第二报文是否需要加速处理; 路由设备根据识别设备 发来的控制信息创建第二报文对应的流表项, 当路由设备接收到第三报文且第三报文匹 配流表项时,路由设备根据流表项中的流操作信息对第三报文进行处理。通过上述方式, 能够实现判断报文是否需要加速处理且根据流表项对与流表项的五元组信息相同的后 续报文直接进行处理, 减少不需要加速处理的报文的开销, 提高报文整体的传输性能。
请参阅图 2, 本发明报文的转发方法第二实施方式包括: 步骤 S201 : 接收第一报文; 路由设备接收用户发来的第一报文。 步骤 S202a: 确定第一报文为订阅用户对应的报文; 在接收到第一报文后, 路由设备确定第一报文为订阅用户对应的报文。 当第一报文 不为订阅用户对应的报文时, 路由设备将第一报文直接进行转发。 步骤 S202b : 确定第一报文的目的地址为预设的需要加速处理的目的地址; 在接收到第一报文后,路由设备确定第一报文的目的地址为预设的需要加速处理的 目的地址。 当第一报文的目的地址不为预设的需要加速处理的目的地址时, 路由设备将 第一报文直接进行转发。 步骤 S202c : 确定第一报文的协议类型为预设的需要加速处理的协议类型; 在接收到第一报文后,路由设备确定第一报文的协议类型为预设的需要加速处理的 协议类型。 当第一报文的协议类型不为预设的需要加速处理的协议类型时, 路由设备将 第一报文直接进行转发。 步骤 S203 : 将用户信息封装到第一报文中而得到第二报文; 在确定第一报文为订阅用户对应的报文、第一报文的目的地址为预设的需要加速处 理的目的地址以及第一报文的协议类型为预设的需要加速处理的协议类型后,路由设备 将第一报文对应的用户信息封装到第一报文中而得到第二报文。 其中, 步骤 S202a、 步 骤 S202b、 步骤 S202c的执行顺序并不限于本实施方式描述的先后执行顺序, 在其他实施 方式中, 可以任意调整步骤 S202a、 步骤 S202b、 步骤 S202c三个步骤间的先后执行顺序 或三个步骤同时执行, 在此不作过多限制。 步骤 S204: 将第二报文发送至识别设备; 在得到第二报文后, 路由设备进一步将第二报文发送至识别设备。 步骤 S205 : 接收控制信息; 路由设备接收上述识别设备发来的控制信息。控制信息包括对与第二报文有相同五 元组信息的报文的流操作信息。 步骤 S206 : 创建流表项;
在接收到控制信息后, 路由设备根据控制信息创建第二报文对应的流表项。 其中, 流表项包括第二报文的五元组信息以及流操作信息。 步骤 S207 : 接收第三报文; 在创建第二报文对应的流表项后, 路由设备接收用户发来的第三报文。 步骤 S208 : 判断第三报文是否匹配流表项; 当路由设备接收到第三报文后,路由设备判断第三报文的五元组信息是否与第二报 文的五元组信息相同从而判断得到第三报文是否匹配上述流表项。 步骤 S209a: 对第三报文进行处理; 当判断得到第三报文匹配流表项时,路由设备根据流表项中的流操作信息对第三报 文进行处理。具体的处理过程可参阅本发明报文的转发方法第一实施方式的步骤 S108a, 此处不再赘述。 步骤 S209b : 将用户信息封装到第三报文中而得到第四报文; 当判断得到第三报文不匹配流表项时,路由设备将第三报文对应的用户信息封装到 第三报文中而得到第四报文。 步骤 S210 : 将第四报文发送至识别设备。 在得到第四报文后,路由设备进一步将第四报文发送至识别设备以判断第四报文是 否需要加速处理。 可以理解,本发明报文的转发方法第二实施方式通过路由设备接收用户发来的第一 报文, 路由设备确定第一报文为订阅用户对应的报文、 确定第一报文的目的地址为预设 的需要加速处理的目的地址、确定第一报文的协议类型为预设的需要加速处理的协议类 型, 路由设备进一步将用户信息封装到经确定后的第一报文中而得到第二报文, 将第二 报文发送至识别设备以判断第二报文是否需要加速处理; 路由设备根据识别设备发来的 控制信息创建第二报文对应的流表项, 当路由设备接收到第三报文且第三报文匹配流表 项时, 路由设备根据流表项中的流操作信息对第三报文进行处理。 通过上述方式, 能够 实现对报文的初步过滤, 在此基础上, 进一步实现判断报文是否需要加速处理且根据流 表项对与流表项的五元组信息相同的后续报文直接进行处理,减少不需要加速处理的报 文的开销, 提高报文整体的传输性能。
请参阅图 3, 本发明路由设备第一实施方式包括: 第一接收模块 301, 用于接收用户发来的报文。 其中, 第一接收模块 301接收到的报 文中至少包括第一报文。 封装模块 302,用于将第一接收模块 301接收到的第一报文的对应的用户信息封装到 第一报文中而得到第二报文。 第一发送模块 303, 用于将封装模块 302封装后得到的第二报文发送至识别设备。 其 中, 识别设备用于判断第二报文是否需要加速处理。 第二接收模块 304, 用于接收识别设备发来的控制信息。 其中, 控制信息包括对与 第二报文有相同五元组信息的报文的流操作信息。 此外, 第二接收模块 304还用于当识 别设备的判断结果为第二报文需要加速处理时,接收加速设备发来的加速处理后的第二 报文,路由设备的转发模块进一步将加速处理后的第二报文进行转发;第二接收模块 304 还用于当识别设备的判断结果为第二报文不需要加速处理时,接收识别设备发来的不需 要加速处理的第二报文, 转发模块进一步将不需要加速处理的第二报文进行转发。 第一创建模块 305,用于根据第二接收模块 304接收到的控制信息创建第二报文对应 的流表项。 其中, 流表项包括第二报文的五元组信息以及上述流操作信息。 匹配模块 306, 用于当第一接收模块 301接收到用户发来的第三报文时, 判断第三报 文是否匹配第一创建模块 305创建的第二报文对应的流表项。 处理模块 307, 用于当匹配模块 306判断得到第三报文匹配流表项时, 根据流表项中 的流操作信息对第三报文进行处理。 具体的处理过程为: 当第二报文在识别设备中的判 断结果为需要加速处理时, 第一创建模块 305创建的流表项中的流操作信息承载有将与 第二报文五元组信息相同的后续报文发送至加速设备的流操作信息, 处理模块 307根据 流操作信息控制第一发送模块 303将第三报文直接发送至加速设备以进行加速处理; 当 第二报文在识别设备的判断结果为不需要加速处理时, 第一创建模块 305创建的流表项 中的流操作信息承载有将与第二报文五元组信息相同的后续报文直接进行转发的流操 作信息, 处理模块 307根据流操作信息控制路由设备的转发模块将第三报文直接进行转 发。
此外, 封装模块 302还用于当匹配模块 306判断得到第三报文不匹配流表项时, 将第 三报文对应的用户信息封装到第三报文中而得到第四报文。 第一发送模块 303还用于进 一步将第四报文发送至识别设备。
可以理解, 本发明路由设备第一实施方式通过路由设备的第一接收模块 301接收用 户发来的第一报文, 封装模块 302将第一报文对应的用户信息封装到第一报文中而得到 第二报文, 第一发送模块 303进一步将第二报文发送至识别设备以判断第二报文是否需 要加速处理; 第一创建模块 305根据第二接收模块 304接收到的控制信息创建第二报文对 应的流表项, 当匹配模块 306判断得到第三报文匹配流表项时, 处理模块 307根据流表项 中的流操作信息对第三报文进行处理。 通过上述方式, 能够实现判断报文是否需要加速 处理且根据流表项对与流表项的五元组信息相同的后续报文直接进行处理,减少不需要 加速处理的报文的开销, 提高报文整体的传输性能。 请参阅图 4, 本发明路由设备第二实施方式包括: 第一接收模块 401, 用于接收用户发来的报文。 其中, 第一接收模块 401接收到的报 文中至少包括第一报文。 确定模块 402,用于在封装模块 403将第一报文对应的用户信息封装到第一报文中而 得到第二报文前, 确定第一接收模块 301接收到的第一报文为订阅用户对应的报文、 确 定第一报文的目的地址为预设的需要加速处理的目的地址以及确定第一报文的协议类 型为预设的需要加速处理的协议类型。
封装模块 403, 用于在确定模块 402对第一报文进行如上述的内容确定后, 将第一报 文对应的用户信息封装到第一报文中而得到第二报文。 第一发送模块 404, 用于将封装模块 403封装后得到的第二报文发送至识别设备。 第二接收模块 405, 用于接收识别设备发来的控制信息。 其中, 控制信息包括对与 第二报文有相同五元组信息的报文的流操作信息。 第一创建模块 406,用于根据第二接收模块 405接收到的控制信息创建第二报文对应 的流表项。 其中, 流表项包括第二报文的五元组信息以及上述流操作信息。 匹配模块 407, 用于当第一接收模块 401接收到第三报文时, 判断第三报文是否匹配 第一创建模块 406创建的第二报文对应的流表项。
处理模块 408, 用于当匹配模块 407判断得到第三报文匹配流表项时, 根据流表项中 的流操作信息对第三报文进行处理。具体的处理过程可参阅本发明路由设备第一实施方 式的处理模块 307, 此处不再赘述。 此外, 封装模块 403还用于当匹配模块 407判断得到第三报文不匹配流表项时, 将第 三报文对应的用户信息封装到第三报文中而得到第四报文。 第一发送模块 404还用于进 一步将第四报文发送至识别设备。 可以理解, 本发明路由设备第二实施方式通过路由设备的第一接收模块 401接收用 户发来的第一报文, 确定模块 402确定第一报文为订阅用户对应的报文、 确定第一报文 的目的地址为预设的需要加速处理的目的地址、确定第一报文的协议类型为预设的需要 加速处理的协议类型, 封装模块 403进一步将用户信息封装到经确定后的第一报文中而 得到第二报文, 第一发送模块 404将第二报文发送至识别设备以判断第二报文是否需要 加速处理; 第一创建模块 406根据第二接收模块 405接收到的控制信息创建第二报文对应 的流表项, 当匹配模块 407判断得到第三报文匹配流表项时, 处理模块 408根据流表项中 的流操作信息对第三报文进行处理。 通过上述方式, 能够实现对报文的初步过滤, 在此 基础上,进一步实现判断报文是否需要加速处理且根据流表项对与流表项的五元组信息 相同的后续报文直接进行处理, 减少不需要加速处理的报文的开销, 提高报文整体的传 输性能。 请参阅图 5, 本发明识别设备一实施方式包括: 第三接收模块 501, 用于接收路由设备发来的第二报文。 其中, 第二报文为路由设 备接收用户发来的第一报文经封装对应的用户信息而得到的。 判断模块 502, 用于根据第二报文中的用户信息查找对应的预设的业务配置, 进一 步根据预设的业务配置判断第二报文是否需要加速处理。 其中, 预设的业务配置包括第 二报文是否需要加速处理的相关判断内容的设定。相关判断内容可包括判断第二报文的 目的地址是否为用户设定的远端需要加速处理的目的地址, 如果第二报文的目的地址为 用户设定的远端需要加速处理的目的地址则判断模块 502的判断结果为第二报文需要加 速处理, 否则判断结果为第二报文不需要加速处理; 相关判断内容还可包括判断第二报 文的协议类型是否为用户设定的需要加速处理的协议类型, 如果第二报文的协议类型为 用户设定的需要加速处理的协议类型则判断模块 502的判断结果为第二报文需要加速处 理; 相关判断内容还可包括第二报文的 HTTP请求内容是否合法, 如果 HTTP请求内容合法
则判断模块 502的判断结果为第二报文需要加速处理; 相关判断内容还可包括判断第二 报文的请求内容中是否含有 jpeg、 gif、 exe、 tar等格式的内容, 压缩能力的大小取决 于被压缩对象的性质,压缩算法对于文本格式的内容有较好的压缩率,而由于 jpeg、gif、 exe、 tar等格式的内容本身已经进行过压缩处理因而压缩算法对上述格式的内容压缩效 率不高且压缩效率的高低与报文是否需要加速处理相关, 因此当第二报文的请求内容中 含有 jpeg、 gif、 exe、 tar等格式的内容时, 判断模块 502的判断结果为第二报文不需要 加速处理。 第二创建模块 503, 用于在判断模块 502判断第二报文是否需要加速处理后, 创建第 二报文对应的控制信息。 其中, 控制信息包括对与第二报文有相同五元组信息的报文的 流操作信息。 当判断模块 502的判断结果为第二报文需要加速处理时, 对应创建的控制 信息中的流操作信息承载有路由设备将与第二报文五元组信息相同的后续报文发送至 加速设备的流操作信息; 当判断模块 502的判断结果为第二报文不需要加速处理时, 对 应创建的控制信息中的流操作信息承载有路由设备将与第二报文五元组信息相同的后 续报文直接进行转发的流操作信息。 第二发送模块 504, 用于在第二创建模块 503创建控制信息后, 将控制信息发送到路 由设备, 以使路由设备进一步根据控制信息创建第二报文对应的流表项。 此外, 第二发 送模块 504还用于当判断模块 502的判断结果为第二报文需要加速处理时,将需要加速处 理的第二报文发送至加速设备以进行加速处理; 第二发送模块 504还用于当判断模块 502 的判断结果为第二报文不需要加速处理时,将不需要加速处理的第二报文发送至路由设 备以进行转发。 此外, 第三接收模块 501还用于当路由设备接收到第三报文且第三报文不匹配流表 项而进行封装用户信息得到第四报文时, 接收路由设备发来的第四报文。 可以理解, 本发明识别设备一实施方式通过识别设备的第三接收模块 501接收路由 设备发来的第二报文, 判断模块 502根据第二报文中的用户信息查找对应的预设的业务 配置, 进一步根据预设的业务配置判断第二报文是否需要加速处理, 第二创建模块 503 创建第二报文对应的控制信息,第二发送模块将控制信息发送至路由设备以创建第二报 文对应的流表项。 通过上述方式, 能够实现判断报文是否需要加速处理, 减少不需要加 速处理的报文的开销, 提高报文整体的传输性能。 请参阅图 6, 本发明报文的转发装置一实施方式包括:
处理器 601, 分别与存储器 602、 输入输出设备 603电连接, 用于当来自输入输出设 备 603的报文的业务配置与存储器 602中存储的预设的需要加速处理的业务配置相同时, 即报文为需要加速处理的报文, 对输入的报文进行加速处理, 并控制输入输出设备 603 将加速处理后的报文进行转发; 或用于当来自输入输出设备 603的报文的业务配置与存 储器 602中存储的预设的需要加速处理的业务配置不相同时, 即报文为不需要加速处理 的报文, 控制输入输出设备 603将不需要加速处理的报文直接进行转发。 存储器 602, 与处理器 601电连接, 用于存储预设的需要加速处理的业务配置。 输入输出设备 603, 与处理器 601电连接, 用于与处理器 601之间进行报文的传输, 输入输出设备 603还用于向外转发报文。 输入输出设备 603为路由设备等输入输出设备。 可以理解,本发明报文的转发装置一实施方式通过处理器 601控制输入输出设备 603 将需要加速处理的报文经加速处理后进行转发或将不需要加速处理的报文直接进行转 发, 通过上述方式, 能够实现把需要加速处理的报文在进行加速处理后转发, 而不需要 加速处理的报文则直接进行转发, 减少不需要加速处理的报文的开销, 提高报文整体的 传输性能。 在本申请所提供的实施方式中, 应该理解到, 所揭露的设备和方法, 可以通过其它 的方式实现。 例如, 以上所描述的设备实施方式仅仅是示意性的, 例如, 所述模块的划 分, 仅仅为一种逻辑功能划分, 实际实现时可以有另外的划分方式, 例如多个模块可以 结合或者可以集成到另一个系统, 或一些特征可以忽略, 或不执行。 所述作为分离部件说明的功能模块可以是或者也可以不是物理上分开的, 即可以位 于一个地方, 或者也可以分布到多个网络模块上。 可以根据实际的需要选择其中的部分 或者全部模块来实现本实施方式方案的目的。 另外, 在本申请各个实施方式中的各功能模块可以集成在一个处理单元中, 也可以 是各个功能模块单独物理存在, 也可以两个或两个以上功能模块集成在一个单元中。 上 述集成的单元既可以采用硬件的形式实现, 也可以采用软件功能单元的形式实现。 所述集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时, 可以存储在一个计算机可读取存储介质中。 基于这样的理解, 本申请的技术方案本质上 或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形 式体现出来, 该计算机软件产品存储在一个存储介质中, 包括若干指令用以使得一台计 算机设备 (可以是个人计算机, 服务器, 或者网络设备等) 或处理器 (processor ) 执
行本申请各个实施方式所述方法的全部或部分步骤。 而前述的存储介质包括: u盘、 移 动硬盘、只读存储器 ( ROM, Read-Only Memory )、随机存取存储器 ( RAM, Random Access Memory) 、 磁碟或者光盘等各种可以存储程序代码的介质。 以上所述仅为本发明的实施方式, 并非因此限制本发明的专利范围, 凡是利用本发 明说明书及附图内容所作的等效结构或等效流程变换, 或直接或间接运用在其他相关的 技术领域, 均同理包括在本发明的专利保护范围内。
Claims
1.一种报文的转发方法, 其特征在于, 包括:
路由设备接收用户发来的第一报文;
所述路由设备将所述第一报文对应的用户信息封装到所述第一报文中而得到第二 报文;
所述路由设备将所述第二报文发送至识别设备,所述识别设备用于判断所述第二报 文是否需要加速处理;
所述路由设备接收所述识别设备发来的控制信息,所述控制信息包括对与所述第二 报文有相同五元组信息的报文的流操作信息;
所述路由设备根据所述控制信息创建所述第二报文对应的流表项, 其中, 所述流表 项包括所述五元组信息和所述流操作信息;
当所述路由设备接收到第三报文, 且当所述第三报文匹配所述流表项时, 所述路由 设备根据所述流操作信息对所述第三报文进行处理。
2.根据权利要求 1所述的方法, 其特征在于, 进一步包括:
当所述第三报文不匹配所述流表项时,所述路由设备将所述第三报文对应的用户信 息封装到所述第三报文中而得到第四报文;
所述路由设备将所述第四报文发送至所述识别设备。
3.根据权利要求 1所述的方法, 其特征在于,
在所述路由设备将所述第一报文对应的用户信息封装到所述第一报文中而得到第 二报文前进一步包括:
确定所述第一报文为订阅用户对应的报文。
4.根据权利要求 1所述的方法, 其特征在于,
在所述路由设备将所述第一报文对应的用户信息封装到所述第一报文中而得到第 二报文前进一步包括:
确定所述第一报文的目的地址为预设的需要加速处理的目的地址。
5.根据权利要求 1所述的方法, 其特征在于,
在所述路由设备将所述第一报文对应的用户信息封装到所述第一报文中而得到第 二报文前进一步包括:
确定所述第一报文的协议类型为预设的需要加速处理的协议类型。
6.—种路由设备, 其特征在于, 包括:
第一接收模块, 用于接收用户发来的第一报文;
封装模块,用于将所述第一报文对应的用户信息封装到所述第一报文中而得到第二 报文;
第一发送模块, 用于将所述第二报文发送至识别设备;
第二接收模块, 用于接收所述识别设备发来的控制信息, 所述控制信息包括对与所 述第二报文有相同五元组信息的报文的流操作信息;
第一创建模块, 用于根据所述控制信息创建所述第二报文对应的流表项, 其中, 所 述流表项包括所述五元组信息和所述流操作信息;
匹配模块, 用于当所述第一接收模块接收到第三报文时, 判断所述第三报文是否匹 配所述流表项;
处理模块, 用于当所述第三报文匹配所述流表项时, 根据所述流操作信息对所述第 三报文进行处理。
7.根据权利要求 6所述的路由设备, 其特征在于,
所述封装模块还用于当所述第三报文不匹配所述流表项时,将所述第三报文对应的 用户信息封装到所述第三报文中而得到第四报文;
所述第一发送模块还用于将所述第四报文发送至识别设备。
8.根据权利要求 6所述的路由设备, 其特征在于, 所述路由设备还包括: 确定模块,用于在所述封装模块将所述第一报文对应的用户信息封装到所述第一报 文中而得到第二报文前, 确定所述第一报文为订阅用户对应的报文。
9.根据权利要求 8所述的路由设备, 其特征在于,
所述确定模块还用于在所述封装模块将所述第一报文对应的用户信息封装到所述 第一报文中而得到第二报文前,确定所述第一报文的目的地址为预设的需要加速处理的 目的地址。
10.根据权利要求 8所述的路由设备, 其特征在于,
所述确定模块还用于在所述封装模块将所述第一报文对应的用户信息封装到所述 第一报文中而得到第二报文前,确定所述第一报文的协议类型为预设的需要加速处理的 协议类型。
11.一种识别设备, 其特征在于, 包括:
第三接收模块, 用于接收路由设备发来的第二报文;
判断模块, 用于根据所述第二报文中的用户信息查找对应的预设的业务配置, 根据 所述预设的业务配置判断所述第二报文是否需要加速处理, 其中, 所述预设的业务配置 包括所述第二报文是否需要加速处理的相关判断内容的设定;
第二创建模块, 用于在所述判断模块判断所述第二报文是否需要加速处理后, 创建 所述第二报文对应的控制信息, 其中, 所述控制信息包括对与所述第二报文有相同五元 组信息的报文的流操作信息;
第二发送模块, 用于将所述控制信息发送至所述路由设备。
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201210479132.8 | 2012-11-22 | ||
CN201210479132.8A CN102938733B (zh) | 2012-11-22 | 2012-11-22 | 报文的转发方法及其路由设备、识别设备 |
Publications (1)
Publication Number | Publication Date |
---|---|
WO2014079319A1 true WO2014079319A1 (zh) | 2014-05-30 |
Family
ID=47697603
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
PCT/CN2013/086565 WO2014079319A1 (zh) | 2012-11-22 | 2013-11-05 | 报文的转发方法及其路由设备、识别设备 |
Country Status (2)
Country | Link |
---|---|
CN (1) | CN102938733B (zh) |
WO (1) | WO2014079319A1 (zh) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2024016975A1 (zh) * | 2022-07-18 | 2024-01-25 | 华为技术有限公司 | 报文转发方法、装置、设备及芯片系统 |
Families Citing this family (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102938733B (zh) * | 2012-11-22 | 2016-01-13 | 华为技术有限公司 | 报文的转发方法及其路由设备、识别设备 |
CN103560958B (zh) * | 2013-10-18 | 2017-01-18 | 华为技术有限公司 | 一种数据包的规则匹配方法及装置 |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1708034A (zh) * | 2004-06-07 | 2005-12-14 | 杭州华为三康技术有限公司 | 基于路由器设备的多业务处理方法 |
CN102075439A (zh) * | 2011-02-22 | 2011-05-25 | 杭州华三通信技术有限公司 | 一种组播报文转发方法和路由设备 |
CN102938733A (zh) * | 2012-11-22 | 2013-02-20 | 华为技术有限公司 | 报文的转发方法及其路由设备、识别设备 |
Family Cites Families (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101494605B (zh) * | 2009-03-05 | 2011-08-24 | 中兴通讯股份有限公司 | 一种基于以太网驱动的数据转发方法和装置 |
CN102123082A (zh) * | 2011-01-14 | 2011-07-13 | 中兴通讯股份有限公司 | 数据包转发方法和设备 |
ES2565628T3 (es) * | 2011-07-06 | 2016-04-06 | Huawei Technologies Co., Ltd. | Procedimiento de procesamiento de mensajes y dispositivo relacionado |
CN102957600B (zh) * | 2011-08-19 | 2017-11-10 | 中兴通讯股份有限公司 | 一种数据报文转发方法及装置 |
-
2012
- 2012-11-22 CN CN201210479132.8A patent/CN102938733B/zh active Active
-
2013
- 2013-11-05 WO PCT/CN2013/086565 patent/WO2014079319A1/zh active Application Filing
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1708034A (zh) * | 2004-06-07 | 2005-12-14 | 杭州华为三康技术有限公司 | 基于路由器设备的多业务处理方法 |
CN102075439A (zh) * | 2011-02-22 | 2011-05-25 | 杭州华三通信技术有限公司 | 一种组播报文转发方法和路由设备 |
CN102938733A (zh) * | 2012-11-22 | 2013-02-20 | 华为技术有限公司 | 报文的转发方法及其路由设备、识别设备 |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2024016975A1 (zh) * | 2022-07-18 | 2024-01-25 | 华为技术有限公司 | 报文转发方法、装置、设备及芯片系统 |
Also Published As
Publication number | Publication date |
---|---|
CN102938733B (zh) | 2016-01-13 |
CN102938733A (zh) | 2013-02-20 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
KR102161681B1 (ko) | 패킷 기반 데이터 통신의 디바이스 식별자 의존적 오퍼레이션 프로세싱 | |
US10587544B2 (en) | Message processing method, processing server, terminal, and storage medium | |
US9203734B2 (en) | Optimized bi-directional communication in an information centric network | |
WO2015165296A1 (zh) | 协议类型的识别方法和装置 | |
US10148565B2 (en) | OPENFLOW communication method and system, controller, and service gateway | |
WO2017185719A1 (zh) | 一种udp协议加速方法和系统 | |
US9843514B2 (en) | Packet processing method and background server | |
US20150289301A1 (en) | Terminal matching method, terminal and system | |
US10057165B2 (en) | Packet forwarding method and device | |
KR101779917B1 (ko) | 미디어 리소스 피드백 방법, 장치, 프로그램 및 기록매체 | |
US11418951B2 (en) | Method for identifying encrypted data stream, device, storage medium and system | |
CN103391296A (zh) | 一种控制器、转发器及通道建立方法和系统 | |
CN108207012B (zh) | 一种流量控制方法、装置、终端及系统 | |
WO2013091534A1 (zh) | 一种木马检测的方法及装置 | |
KR20140144579A (ko) | 컨텐츠 중심 네트워크에서 컨텐츠를 엿듣는 노드의 통신 방법 및 그 노드 | |
CN107682267B (zh) | Linux设备的网络数据转发方法及系统 | |
WO2014079319A1 (zh) | 报文的转发方法及其路由设备、识别设备 | |
WO2017140095A1 (zh) | 一种无线通信方法及装置 | |
CN115038073B (zh) | 用户永久标识获取方法、装置、电子设备及存储介质 | |
WO2022100511A1 (zh) | 转发表项的处理方法和装置 | |
CN114793199B (zh) | 一种报文处理方法、装置及网络设备 | |
CN113453278B (zh) | 一种基于5g upf下的tcp包分段组包方法及终端 | |
CN114666846A (zh) | 一种通信方法及网关设备 | |
WO2011140801A1 (zh) | 一种发送彩信的方法,装置和系统 | |
WO2021093510A1 (zh) | 网络业务的处理方法、系统和网关设备 |
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: 13857032 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: 13857032 Country of ref document: EP Kind code of ref document: A1 |