WO2016188058A1 - 一种缓存管理方法、本端设备及存储介质 - Google Patents

一种缓存管理方法、本端设备及存储介质 Download PDF

Info

Publication number
WO2016188058A1
WO2016188058A1 PCT/CN2015/095019 CN2015095019W WO2016188058A1 WO 2016188058 A1 WO2016188058 A1 WO 2016188058A1 CN 2015095019 W CN2015095019 W CN 2015095019W WO 2016188058 A1 WO2016188058 A1 WO 2016188058A1
Authority
WO
WIPO (PCT)
Prior art keywords
data packet
routing information
local device
information corresponding
determination result
Prior art date
Application number
PCT/CN2015/095019
Other languages
English (en)
French (fr)
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 WO2016188058A1 publication Critical patent/WO2016188058A1/zh

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/10Flow control; Congestion control
    • H04L47/32Flow control; Congestion control by discarding or delaying data units, e.g. packets or frames
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/74Address processing for routing
    • H04L45/742Route cache; Operation thereof

Definitions

  • the present invention relates to the field of data communications, and in particular, to a cache management method, a local device, and a storage medium.
  • a data exchange architecture in a router or a switch is mainly composed of a line card and a switch fabric.
  • an interface module (Interface Module) is mainly disposed in the line card.
  • the packet processing module (Switch Processor) and the switch access module (Switch Access), wherein the interface module may be implemented by using an SDH framer or an Ethernet physical layer plus a link layer chip; the packet processing module may specifically pass Network processor (NP) or FPGA-based packet processor implementation.
  • NP Network processor
  • a switching access module and a switching module of multiple routers or switches form a switching network.
  • a high-speed serial link is used between the switching access module and the switching module to implement interconnection. Therefore, the switching network is robust when there is an exchange. When the access module is unplugged or reinserted, it cannot affect other traffic.
  • the switching access module classifies and stores the data packet according to the service type, the priority, and the like, and pulls out the destination switching access module corresponding to the stored data packet.
  • the destination line card corresponding to the data packet is pulled out, the data packet to the destination switching access module is not routed. At this time, such a non-routed data packet is usually discarded, but because Such a packet with no route has already completed the processing of the packet processing module before being discarded, but cannot be sent to the destination switching access module, but is directly discarded.
  • the embodiment of the present invention provides a cache management method, a local device, and a storage medium, which can enable the local device to cache data packets in a targeted manner, thereby laying a foundation for avoiding traffic fluctuations.
  • the embodiment of the invention provides a cache management method, and the method includes:
  • the first preset rule is used to indicate that the local device can be based on the first routing information Transmitting the first data packet to a destination device corresponding to the first data packet;
  • the determining, according to the obtained first judgment result, whether to cache the first data packet includes:
  • the determining, according to the obtained first judgment result, whether to cache the first data packet includes:
  • the first data packet is discarded.
  • the method further includes:
  • the method further includes:
  • the preset rule is configured to obtain a third determination result, where the third preset rule is used to indicate that the local device cannot send the second data packet to the destination device corresponding to the second data packet according to the second routing information;
  • the method further includes:
  • the acquiring the first routing information corresponding to the first data packet includes:
  • the embodiment of the invention further discloses a local device, where the local device includes:
  • a receiving unit configured to receive the first data packet
  • An acquiring unit configured to acquire first routing information corresponding to the first data packet
  • a first determining unit configured to determine whether the first routing information corresponding to the first data packet is Satisfying the first preset rule, and acquiring the first determination result; the first preset rule is used to indicate that the local device can send the first data packet to the first data packet according to the first routing information.
  • Corresponding destination device configured to determine whether the first routing information corresponding to the first data packet is Satisfying the first preset rule, and acquiring the first determination result; the first preset rule is used to indicate that the local device can send the first data packet to the first data packet according to the first routing information.
  • the first processing unit is configured to determine whether to cache the first data packet according to the obtained first determination result.
  • the first processing unit is further configured to: when the obtained first judgment result indicates that the first routing information corresponding to the first data packet meets the first preset rule, a first data packet and performing data processing on the first data packet.
  • the first processing unit is further configured to: when the obtained first judgment result indicates that the first routing information corresponding to the first data packet does not satisfy the first preset rule, discard the Said the first data packet.
  • the local device further includes:
  • the second determining unit is configured to determine whether the second routing information corresponding to the second data packet in the at least one second data packet that is currently stored is located in the local device, and obtain a second determination result;
  • a second processing unit configured to: when the second determination result indicates that the second routing information corresponding to the second data packet in the currently stored at least one second data packet does not exist in the local device, a second data packet in the at least one second data packet.
  • the local device further includes:
  • a third determining unit configured to: when the second determining result indicates that the second routing information corresponding to the second data packet in the currently stored at least one second data packet exists in the local device, If the routing information meets the third preset rule, the third determination result is obtained; the third preset rule is used to indicate that the local device cannot send the second data packet to the second data according to the second routing information.
  • the destination device corresponding to the package;
  • the third processing unit is further configured to: when the third determination result indicates that the second routing information is satisfied And deleting, by the third preset rule, the second data packet in the at least one second data packet.
  • the local device further includes:
  • a data generating unit configured to generate a routing table according to routing state information between the local device and at least one destination device
  • the acquiring unit is configured to acquire first routing information corresponding to the first data packet according to the routing table.
  • the cache management method, the local device, and the storage medium by receiving the first data packet, acquiring the first routing information corresponding to the first data packet, and determining that the first data packet corresponds to the first Whether the routing information meets the first preset rule, obtains the first determination result, and further determines whether to cache the first data packet according to the obtained first determination result, so that the local device can cache the data in a targeted manner.
  • the package in turn, lays the foundation for avoiding traffic fluctuations.
  • FIG. 1 is a first schematic structural diagram 1 of a local line card according to an embodiment of the present invention.
  • FIG. 2 is a second schematic structural diagram of a local line card according to an embodiment of the present invention.
  • FIG. 3 is a schematic flowchart of an implementation process of a cache management method according to an embodiment of the present invention.
  • FIG. 4 is a schematic structural diagram of a local device according to a logical function division according to an embodiment of the present invention.
  • the local device that is, the local line card receives the first data packet, obtains the first routing information corresponding to the first data packet, and determines whether the first routing information corresponding to the first data packet is satisfied.
  • the first preset rule is configured to obtain a first judgment result, where the first preset rule is used to indicate that the local device can send the first data packet to correspond to the first data packet according to the first routing information.
  • the destination device determines whether to cache the first data packet according to the obtained first determination result.
  • the interface module discards the wrong data packet in the data packet, and transmits the correct data packet to the packet processing module.
  • the packet processing module analyzes and processes the data packet according to the destination address of the data packet, such as the destination MAC address or the destination IP address, the service type, the priority, and the like, and determines the destination end line card to which the data packet is sent.
  • the switching access module that is, the destination switching access module, and the stream number of the data packet are determined, and then the data packet is sent to the switching access module in the local line card.
  • the switching access module in the local line card caches data according to the destination address of the data packet, and waits for scheduling of the destination switching access module.
  • the The switching access module in the local line card sends the data packet to the destination switching access module through the switching module according to the obtained routing information, where the switching access module of the local line card stores itself to at least Routing information of a switching access module of a destination end line card.
  • the packet processing module includes an inbound processing submodule and a packet processing submodule;
  • the switching access module includes an outbound processing submodule; wherein the inbound processing submodule is configured to receive the sending by the interface module.
  • a data packet the packet processing sub-module is configured to perform data processing on the data packet, for example, analyzing and processing the data packet according to information such as a destination address, a service type, a priority, and the like of the data packet;
  • the module is configured to store routing information of the local end line to the switching access module of the at least one destination end line card, that is, the routing table is stored.
  • FIG. 3 is a schematic flowchart of an implementation of a cache management method according to an embodiment of the present invention; the method is applied to a local device, and specifically, the local device may be a line card, that is, a local line card; as shown in FIG.
  • the methods include:
  • Step 301 Receive a first data packet.
  • the interface module in the local line card receives the first data packet, and sends the first data packet to a packet processing module in the local line card. .
  • Step 302 Acquire first routing information corresponding to the first data packet.
  • the packet processing module in the local line card after receiving the first data packet, acquires first routing information corresponding to the first data packet, where the local line card is in the local line card.
  • the packet processing module acquires the first routing information corresponding to the first data packet to the switching access module in the local line card.
  • the method further includes: according to the routing state between the local device and the at least one destination device, in the embodiment of the present invention, in order to enable the packet processing module to obtain the first routing information corresponding to the first data packet.
  • the information is generated, and the routing information is generated.
  • the acquiring the first routing information corresponding to the first data packet includes: acquiring the first routing information corresponding to the first data packet according to the routing table.
  • the switching access module in the local line card is configured according to the routing state information between the local line card and the switching access module in the at least one destination line card, that is, the switching network topology.
  • a routing table is generated.
  • the routing table includes routing information of the local line card to each destination line card, that is, routing information of the switching access module in the local line card to the switching access module of each destination line card.
  • the routing state information includes an reachable state and an unreachable state.
  • the local line card can send the data packet to the switching access module of the destination line card corresponding to the data packet according to the routing information.
  • the routing state is an reachable state.
  • the local line card cannot send the data packet to the switching access module of the destination line card corresponding to the data packet according to the routing information.
  • the routing state is an unreachable state.
  • the local device when the destination device, for example, the plugging and unplugging state of the destination line card is changed, or the link is broken, the local device, that is, the local line card can update the routing table, that is, the original The switch access module in the end line card can update the routing table in real time.
  • the routing table is updated.
  • the packet processing module in the local line card can obtain the updated routing table, and then The updated routing table determines whether the first routing information of the received first data packet exists in the updated routing table, so that the first data packet is cached in a targeted manner, for example, in the local line card.
  • the packet processing module can only send the first routing information of the first data packet in the updated routing table, and can send the first data packet to the first according to the first routing information.
  • the packet processing module in the local line card caches the first data packet, thereby effectively avoiding The problem that the routing data is stored in the local device wastes the storage space, and the bandwidth of the cache read data is reduced due to the lack of routing data.
  • Step 303 Determine whether the first routing information corresponding to the first data packet meets the first preset rule, and obtain a first determination result.
  • the first preset rule is used to indicate that the local device can be based on the first route. Transmitting the first data packet to a destination device corresponding to the first data packet;
  • the packet processing module in the local line card determines whether the first routing information corresponding to the first data packet meets a first preset rule, specifically, packet processing in the local line card. The module determines whether the first data packet can be sent to the destination line card corresponding to the first data packet according to the first routing information, and further determines whether the first one is determined according to the obtained first determination result. The packet is cached.
  • the obtained first judgment result indicates that the local line card can send the first data packet to the destination line card corresponding to the first data packet according to the first routing information.
  • the packet processing module in the local line card buffers the first data packet, and performs data processing on the first data packet;
  • Step 304 Determine whether to cache the first data packet according to the obtained first determination result.
  • the determining, according to the obtained first judgment result, whether to cache the first data packet includes:
  • the determining, according to the obtained first judgment result, whether to cache the first data packet includes:
  • the first data packet is discarded.
  • the method further includes:
  • the data packet will not be dispatched to the switching module, if the cached data packet has been stored for a long time. If the data is not scheduled, the aging mode can be used to discard the data packets that remain unscheduled for a long time.
  • the packet processing module of the local line card determines whether the data packet scheduled from the cache is discarded according to the destination address of the scheduled data packet, that is, according to the corresponding data packet.
  • the routing information of the switching access module of the destination line card determines whether it is discarded. If the routing information of the switching access module of the corresponding destination line card of the scheduled data packet is in an unreachable state, then the scheduled Before the data packet is analyzed and processed, and the scheduled data packet is discarded before being sent to the switching access module of the local line card, the buffer space of the local line card is saved, the buffer read bandwidth is released, and the operation is reduced. The amount improves the performance of the local line card.
  • the method further includes:
  • the preset rule is configured to obtain a third determination result, where the third preset rule is used to indicate that the local device cannot send the second data packet to the destination device corresponding to the second data packet according to the second routing information;
  • the local end line card and the destination end line card are both line cards, and there is no difference in structure.
  • the "local end” and the “destination end” are only suitable for distinguishing the sending direction of the data packet. Therefore, the local device in the embodiment of the present invention may be a local end line card or a destination end line card.
  • the embodiment of the present invention further provides a computer readable storage medium, the storage medium comprising a set of instructions, and the instructions are used to execute the cache management method according to the first embodiment.
  • the embodiment of the present invention further provides a local device.
  • the local device may be a line card, that is, a local line card.
  • the local device includes:
  • the receiving unit 41 is configured to receive the first data packet
  • the obtaining unit 42 is configured to acquire first routing information corresponding to the first data packet
  • the first determining unit 43 is configured to determine whether the first routing information corresponding to the first data packet meets the first preset rule, and obtain the first determination result; the first preset rule is used to indicate that the local device can be based on Transmitting, by the first routing information, the first data packet to a destination device corresponding to the first data packet;
  • the first processing unit 44 is configured to determine whether to cache the first data packet according to the obtained first determination result.
  • the first processing unit 44 is further configured to: when the obtained first judgment result indicates that the first routing information corresponding to the first data packet meets the first preset rule, Caching the first data packet and performing data processing on the first data packet.
  • the first processing unit 44 is further configured to: when the obtained first judgment result indicates that the first routing information corresponding to the first data packet does not satisfy the first preset rule Discarding the first data packet.
  • the local device further includes:
  • the second determining unit 45 is configured to determine whether there is second routing information corresponding to the second data packet in the at least one second data packet that is currently stored in the local device, and obtain a second determination result;
  • the second processing unit 46 is configured to: when the second determining result indicates that the second routing information corresponding to the second data packet in the currently stored at least one second data packet does not exist in the local device, Discarding the second data packet in the at least one second data packet.
  • the local device further includes:
  • the third determining unit 47 is configured to: when the second determining result indicates that the second routing information corresponding to the second data packet in the currently stored at least one second data packet exists in the local device, Whether the second routing information meets the third preset rule, and obtains a third determination result;
  • the third preset rule is used to indicate that the local device cannot send the second data packet to the destination device corresponding to the second data packet according to the second routing information;
  • the third processing unit 48 is further configured to discard the second data packet in the at least one second data packet when the third determination result indicates that the second routing information meets the third preset rule.
  • the local device further includes:
  • the data generating unit 49 is configured to generate a routing table according to routing state information between the local device and the at least one destination device;
  • the obtaining unit 42 is configured to acquire first routing information corresponding to the first data packet according to the routing table.
  • the unit 48 can be integrated into the local device, that is, the packet processing module of the local line card, that is, the receiving unit 41, the obtaining unit 42, the first determining unit 43, the first processing unit 44, and the The second determining unit 45, the second processing unit 46, the third determining unit 47, and the third processing unit 48 are all implemented by a packet processing module in the local line card; the data generating unit 49 can be exchanged in the local line card. Access module implementation.
  • the data generating unit 49 can be implemented by a central processing unit (CPU), or a digital signal processing (DSP), or a Field Programmable Gate Array (FPGA);
  • CPU central processing unit
  • DSP digital signal processing
  • FPGA Field Programmable Gate Array
  • the cache management method and the local device obtain the first routing information corresponding to the first data packet by receiving the first data packet, and determine whether the first routing information corresponding to the first data packet is Satisfy the first preset rule, obtain the first judgment result, and then obtain the The first determination result determines whether to cache the first data packet, so that the local device can cache the data packet in a targeted manner, thereby laying a foundation for avoiding traffic fluctuations, and effectively solving the traffic stability problem.
  • the functions of the processing units in the local device of the embodiment of the present invention can be understood by referring to the related description of the foregoing cache management method.
  • the device embodiments described above are only schematic, for example, The division of the unit is only a logical function division, and the actual implementation may have another division manner, for example, multiple units or components may be combined, or may be integrated into another system, or some features may be ignored, or Not executed.
  • the coupling, or direct coupling, or communication connection of the components shown or discussed may be indirect coupling or communication connection through some interfaces, devices or units, and may be electrical, mechanical or other forms. of.
  • the embodiment of the present invention provides a local line card based on a cache management method, where the local line card includes: an interface module, a packet processing module, and a switching access module; wherein the packet processing module includes an inbound processing module.
  • the packet processing module receives the first data packet, acquires the first routing information corresponding to the first data packet, and determines whether the first routing information corresponding to the first data packet meets the first preset.
  • the first pre-determined result is obtained by the first preset rule, and the first preset rule is configured to send, by the local device, the first data packet to the destination device corresponding to the first data packet according to the first routing information. Determining whether to cache the first data packet according to the obtained first judgment result;
  • the packet processing module is further configured to: when the obtained first judgment result indicates that the first routing information corresponding to the first data packet meets the first preset rule, And storing the first data packet, and performing data processing on the first data packet;
  • the first data packet is also discarded when the obtained first judgment result indicates that the first routing information corresponding to the first data packet does not satisfy the first preset rule.
  • the packet processing module is further configured to determine, by the local device, whether there is second routing information corresponding to the second data packet in the at least one second data packet that is currently stored, and obtain a second determination. result;
  • the packet processing module is further configured to: when the second determining result indicates that the local device has a second data packet corresponding to the currently stored at least one second data packet.
  • the routing information is two
  • the second routing information is determined to meet the third preset rule, and the third determining result is obtained.
  • the third preset rule is used to indicate that the local device cannot use the second routing information according to the second routing information. Sending the packet to the destination device corresponding to the second data packet;
  • the switching access module is further configured to generate a routing table according to routing state information between the local device and at least one destination device;
  • the packet processing module is further configured to acquire, according to the routing table, first routing information corresponding to the first data packet.
  • the outbound processing submodule is configured to send a data packet to the switching module, and the specific format may be a packet format or a packet cut into a packet; wherein the outgoing processing submodule is further configured as a storage device.
  • the routing table of the switching access module, the routing table is indexed by the destination switching access module, and the storage is a reachability indication according to a high-speed serial link. If a high-speed serial link is reachable, the corresponding The bit will be set. Further, the routing information corresponding to the routing table At any time, according to the network topology update, the control information is exchanged between the two ends of the sending and receiving; wherein the two ends refer to the local line card and the destination end line card. After the switching access module of a destination end line card is removed, the link of the switching access module of the destination line card to the local line card switching access module is disconnected, so that the routing table can be updated according to the link information. Bit reset.
  • the link of the switching access module of the destination line card to the local line card switching access module becomes reachable, that is, the routing information can be reached, so that the local line card is
  • the outbound processing sub-module in the switch access module updates the routing table according to the updated network structure.
  • the inbound processing submodule internally includes an admission control subunit configured to distinguish whether the routing information corresponding to the data packet is reachable, and the routing table of the outgoing processing submodule
  • the update information is sent to the inbound processing sub-module, for example, the updated routing table is sent to the inbound processing sub-module, and the in-direction processing sub-module is internally obtained by the secondary look-up table.
  • the inbound processing sub-module maps an internal queue number according to the service and the priority, and then obtains the information of the destination switching access module corresponding to the data packet by the internal queue number lookup table, and then according to the information
  • the destination exchange access module obtains reachable information, that is, routing information.
  • the routing-based cache management takes a certain time to update the routing table in the incoming processing sub-module. During the routing table update time, some unreachable data packets may enter the cache. For this part of the data packet, since there is no destination, that is, there is no routing information, it can be discarded by the aging method.
  • embodiments of the present invention can be provided as a method, system, or computer program product. Accordingly, the present invention can take the form of a hardware embodiment, a software embodiment, or a combination of software and hardware. Moreover, the invention may be employed in one or more of its A computer program product embodied on a computer usable storage medium (including but not limited to disk storage and optical storage, etc.) containing computer usable program code.
  • a computer usable storage medium including but not limited to disk storage and optical storage, etc.
  • the computer program instructions can also be stored in a computer readable memory that can direct a computer or other programmable data processing device to operate in a particular manner, such that the instructions stored in the computer readable memory produce an article of manufacture comprising the instruction device.
  • the apparatus implements the functions specified in one or more blocks of a flow or a flow and/or block diagram of the flowchart.
  • These computer program instructions can also be loaded onto a computer or other programmable data processing device such that a series of operational steps are performed on a computer or other programmable device to produce computer-implemented processing for execution on a computer or other programmable device.
  • the instructions provide steps for implementing the functions specified in one or more of the flow or in a block or blocks of a flow diagram.
  • the embodiment of the present invention obtains the first routing information corresponding to the first data packet by receiving the first data packet, and determines whether the first routing information corresponding to the first data packet meets the first preset rule. Obtaining a first determination result, and determining whether to cache the first data packet according to the obtained first determination result, so that the local device can cache the data packet in a targeted manner, thereby laying a foundation for avoiding traffic fluctuation The foundation.

Landscapes

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

Abstract

本发明实施例公开了一种缓存管理方法,包括:接收第一数据包;获取所述第一数据包对应的第一路由信息;判断所述第一数据包对应的第一路由信息是否满足第一预设规则,获取第一判断结果;所述第一预设规则用于表征本端设备能够依据所述第一路由信息将所述第一数据包发送至与所述第一数据包对应的目的端设备;依据获取到的所述第一判断结果确定是否缓存所述第一数据包。本发明实施例还公开了一种本端设备及存储介质。

Description

一种缓存管理方法、本端设备及存储介质 技术领域
本发明涉及数据通信领域,尤其涉及一种缓存管理方法、本端设备及存储介质。
背景技术
在网络系统中,路由器或者交换机中数据交换架构主要由线卡(Line Card)与交换模块(Switch Fabric)构成,如图1所示,所述线卡中主要设置有接口模块(Interface Module)、包处理模块(Packet Processor)和交换接入模块(Switch Access),其中,所述接口模块可以具体通过SDH成帧器或者以太网物理层加链路层芯片实现;所述包处理模块可以具体通过网络处理器(NP)或者基于FPGA的包处理器实现。
多个路由器或者交换机的交换接入模块和交换模块组成了交换网,通常交换接入模块与交换模块之间使用高速串行链路实现互联,因此,交换网具有健壮性,当有某个交换接入模块被拔出或者重新插入时,不能影响其他流量。
现有交换网中,交换接入模块在存储数据包时,会根据业务类型、优先级等信息对数据包进行分类并存储,当与存储的所述数据包对应的目的交换接入模块拔出时,也即与该数据包对应的目的端线卡拔出时,使得通往所述目的交换接入模块的数据包没有路由,此时,通常将此类没有路由的数据包丢弃,但是,由于此类没有路由的数据包在丢弃之前已经完成了所述包处理模块的处理过程,但又不能发送至目的交换接入模块,而是被直接丢弃,因此,此类没有路由的数据包占用了本端线卡的内存,减慢了本端线卡的处理速度;进一步地即使此类没有路由的数据包被全部缓存, 并发送至交互模块,则当目的交换接入模块重新插入时,且当缓存中存有大量发往该目的交换接入模块的数据包时,这些数据包会重新获得路由,并发送至该目的交换接入模块,导致出向流量发生突变,即突然增大,进而导致交换模块流量波动。随着交换网络的规模提高以及交换处理能力的提高,插拔交换接入模块引起的流量波动越来越不可忽视,现有技术又难以解决此问题。
发明内容
为解决现有存在的技术问题,本发明实施例提供了一种缓存管理方法、本端设备及存储介质,能够使本端设备有针对性的缓存数据包,为避免流量波动奠定了基础。
本发明实施例的技术方案是这样实现的:
本发明实施例提供了一种缓存管理方法,所述方法包括:
接收第一数据包;
获取所述第一数据包对应的第一路由信息;
判断所述第一数据包对应的第一路由信息是否满足第一预设规则,获取第一判断结果;所述第一预设规则用于表征本端设备能够依据所述第一路由信息将所述第一数据包发送至与所述第一数据包对应的目的端设备;
依据获取到的所述第一判断结果确定是否缓存所述第一数据包。
上述方案中,所述依据获取到的所述第一判断结果确定是否缓存所述第一数据包,包括:
当获取到的所述第一判断结果表征所述第一数据包对应的第一路由信息满足所述第一预设规则时,缓存所述第一数据包,并对所述第一数据包进行数据处理。
上述方案中,所述依据获取到的所述第一判断结果确定是否缓存所述第一数据包,包括:
当获取到的所述第一判断结果表征所述第一数据包对应的第一路由信息不满足所述第一预设规则时,丢弃所述第一数据包。
上述方案中,所述方法还包括:
判断所述本端设备中是否存在与当前存储的至少一个第二数据包中的第二数据包对应的第二路由信息,获取第二判断结果;
当所述第二判断结果表征所述本端设备中不存在与所述当前存储的至少一个第二数据包中的第二数据包对应的第二路由信息时,丢弃所述至少一个第二数据包中的第二数据包。
上述方案中,所述方法还包括:
当所述第二判断结果表征所述本端设备中存在与所述当前存储的至少一个第二数据包中的第二数据包对应的第二路由信息时,判断第二路由信息是否满足第三预设规则,获取第三判断结果;所述第三预设规则用于表征所述本端设备不能够依据第二路由信息将第二数据包发送至与第二数据包对应的目的端设备;
当所述第三判断结果表征第二路由信息满足所述第三预设规则时,丢弃所述至少一个第二数据包中的第二数据包。
上述方案中,所述方法还包括:
依据所述本端设备至至少一个目的端设备之间的路由状态信息,生成路由表;
对应地,所述获取所述第一数据包对应的第一路由信息,包括:
依据所述路由表,获取所述第一数据包对应的第一路由信息。
本发明实施例还公开了一种本端设备,所述本端设备包括:
接收单元,配置为接收第一数据包;
获取单元,配置为获取所述第一数据包对应的第一路由信息;
第一判断单元,配置为判断所述第一数据包对应的第一路由信息是否 满足第一预设规则,获取第一判断结果;所述第一预设规则用于表征本端设备能够依据所述第一路由信息将所述第一数据包发送至与所述第一数据包对应的目的端设备;
第一处理单元,配置为依据获取到的所述第一判断结果确定是否缓存所述第一数据包。
上述方案中,所述第一处理单元,还配置为当获取到的所述第一判断结果表征所述第一数据包对应的第一路由信息满足所述第一预设规则时,缓存所述第一数据包,并对所述第一数据包进行数据处理。
上述方案中,所述第一处理单元,还配置为当获取到的所述第一判断结果表征所述第一数据包对应的第一路由信息不满足所述第一预设规则时,丢弃所述第一数据包。
上述方案中,所述本端设备还包括:
第二判断单元,配置为判断所述本端设备中是否存在与当前存储的至少一个第二数据包中的第二数据包对应的第二路由信息,获取第二判断结果;
第二处理单元,配置为当所述第二判断结果表征所述本端设备中不存在与所述当前存储的至少一个第二数据包中的第二数据包对应的第二路由信息时,丢弃所述至少一个第二数据包中的第二数据包。
上述方案中,所述本端设备还包括:
第三判断单元,配置为当所述第二判断结果表征所述本端设备中存在与所述当前存储的至少一个第二数据包中的第二数据包对应的第二路由信息时,判断第二路由信息是否满足第三预设规则,获取第三判断结果;所述第三预设规则用于表征所述本端设备不能够依据第二路由信息将第二数据包发送至与第二数据包对应的目的端设备;
第三处理单元,还配置为当所述第三判断结果表征第二路由信息满足 所述第三预设规则时,丢弃所述至少一个第二数据包中的第二数据包。
上述方案中,所述本端设备还包括:
数据生成单元,配置为依据所述本端设备至至少一个目的端设备之间的路由状态信息,生成路由表;
对应地,所述获取单元,配置为依据所述路由表,获取所述第一数据包对应的第一路由信息。
本发明实施例所述的缓存管理方法、本端设备及存储介质,通过接收第一数据包,获取所述第一数据包对应的第一路由信息,判断所述第一数据包对应的第一路由信息是否满足第一预设规则,获取第一判断结果,进而依据获取到的所述第一判断结果确定是否缓存所述第一数据包,如此,使得本端设备能够有针对性的缓存数据包,进而为避免流量波动奠定了基础。
附图说明
图1为本发明实施例本端线卡的具体结构示意图一;
图2为本发明实施例本端线卡的具体结构示意图二;
图3为本发明实施例缓存管理方法的实现流程示意图;
图4为本发明实施例本端设备基于逻辑功能划分的结构示意图。
具体实施方式
本发明实施例中:本端设备,也即本端线卡接收第一数据包;获取所述第一数据包对应的第一路由信息;判断所述第一数据包对应的第一路由信息是否满足第一预设规则,获取第一判断结果;所述第一预设规则用于表征本端设备能够依据所述第一路由信息将所述第一数据包发送至与所述第一数据包对应的目的端设备;依据获取到的所述第一判断结果确定是否缓存所述第一数据包。
在数据包传输过程中,如图1所示,数据包从接口模块进入到本端线卡后,接口模块将所述数据包中错误的数据包丢弃,并将正确的数据包传递给包处理模块进行处理,所述包处理模块根据数据包的目的地址,例如目的MAC地址或者目的IP地址、业务类型、优先级等信息对数据包进行分析处理,确定出数据包所发往的目的端线卡中的交换接入模块,也即目的交换接入模块,以及确定出数据包的流编号,然后将数据包发送至本端线卡中的交换接入模块。所述本端线卡中的交换接入模块根据数据包的目的地址缓存数据,并等待所述目的交换接入模块的调度,当所述目的交换接入模块允许数据包发往自身时,所述本端线卡中的交换接入模块依据获取到的路由信息,将所述数据包通过交换模块发送至所述目的交换接入模块;其中,本端线卡的交换接入模块中存储有自身至至少一个目的端线卡的交换接入模块的路由信息。
进一步地,如图2所示,包处理模块包括入向处理子模块和包处理子模块;交换接入模块包括出向处理子模块;其中,所述入向处理子模块用于接收接口模块发送的数据包;所述包处理子模块用于对数据包进行数据处理,例如,根据所述数据包的目的地址、业务类型、优先级等信息对所述数据包进行分析处理;所述出向处理子模块用于存储本端线至至少一个目的端线卡的交换接入模块的路由信息,即存储有路由表。
以下结合图1和图2所示的本端线卡的具体结构对本发明实施例做进一步详细说明;这里,所附附图仅供参考说明之用,并非用来限定本发明。
实施例一
图3为本发明实施例缓存管理方法的实现流程示意图;所述方法应用于本端设备,具体地,所述本端设备可以为线卡,也即本端线卡;如图3所示,所述方法包括:
步骤301:接收第一数据包;
在一具体实施例中,如图1所示,所述本端线卡中的接口模块接收所述第一数据包,并将所述第一数据包发送至所述本端线卡中的包处理模块。
步骤302:获取所述第一数据包对应的第一路由信息;
在一具体实施例中,所述本端线卡中的包处理模块接收到所述第一数据包后,获取所述第一数据包对应的第一路由信息,这里,所述本端线卡中的包处理模块向本端线卡中的交换接入模块获取所述第一数据包对应的第一路由信息。
为使包处理模块能够获取到所述第一数据包对应的第一路由信息,本发明实施例中,所述方法还包括:依据所述本端设备至至少一个目的端设备之间的路由状态信息,生成路由表;对应地,所述获取所述第一数据包对应的第一路由信息,包括:依据所述路由表,获取所述第一数据包对应的第一路由信息。
在一具体实施例中,所述本端线卡中的交换接入模块依据所述本端线卡至至少一个目的端线卡中的交换接入模块之间的路由状态信息,也即交换网拓扑结构,生成路由表;所述路由表中包含有本端线卡通往各个目的端线卡的路由信息,也即本端线卡中的交换接入模块通往各个目的端线卡的交换接入模块的路由信息。
这里,所述路由状态信息包括可到达状态和不可到达状态,例如,所述本端线卡能够依据路由信息将数据包发送至与数据包对应的目的端线卡的交换接入模块中,此时,路由状态为可到达状态;相反地,所述本端线卡不能够依据路由信息将数据包发送至与数据包对应的目的端线卡的交换接入模块中,此时,路由状态为不可到达状态。
另外,在实际应用中,当目的端设备,例如目的端线卡插拔状态发生变化,或者倒换断链时,所述本端设备即本端线卡能够即时更新所述路由表,也即所述本端线卡中的交换接入模块能够即时更新所述路由表。例如, 当加入新的目的端线卡,即加入新的目的端线卡的交换接入模块时,路由表将被更新,此时,本端线卡中的包处理模块能够获取到更新后的路由表,进而依据更新后的路由表判断是否在更新后的路由表中存在有接收到的所述第一数据包的第一路由信息,如此,有针对性的缓存第一数据包,例如,本端线卡中的包处理模块只有在确定出更新后的路由表中存在有所述第一数据包的第一路由信息,且能够依据所述第一路由信息将所述第一数据包发送至与所述第一数据包对应的目的端线卡,也即所述第一路由信息处于可到达状态时,所述本端线卡中的包处理模块才会对所述第一数据包进行缓存处理,因此,有效避免了无路由数据存入本端设备而浪费存储空间的问题,以及避免了由于无路由数据而导致的缓存读出数据带宽降低的问题。
步骤303:判断所述第一数据包对应的第一路由信息是否满足第一预设规则,获取第一判断结果;所述第一预设规则用于表征本端设备能够依据所述第一路由信息将所述第一数据包发送至与所述第一数据包对应的目的端设备;
在一具体实施例中,所述本端线卡中的包处理模块判断所述第一数据包对应的第一路由信息是否满足第一预设规则,具体地,所述本端线卡中的包处理模块判断是否能够依据所述第一路由信息将所述第一数据包发送至与所述第一数据包对应的目的端线卡中,进而依据获取到的第一判断结果确定是否对所述第一数据包进行缓存处理。
在一具体实施例中,当获取到的所述第一判断结果表征本端线卡能够依据所述第一路由信息将所述第一数据包发送至与所述第一数据包对应的目的端线卡中,此时,所述本端线卡中的包处理模块缓存所述第一数据包,并对所述第一数据包进行数据处理;
当获取到的所述第一判断结果表征本端线卡不能够依据所述第一路由信息将所述第一数据包发送至与所述第一数据包对应的目的端线卡中,此 时,丢弃所述第一数据包。
步骤304:依据获取到的所述第一判断结果确定是否缓存所述第一数据包。
本实施例中,所述依据获取到的所述第一判断结果确定是否缓存所述第一数据包,包括:
当获取到的所述第一判断结果表征所述第一数据包对应的第一路由信息满足所述第一预设规则时,缓存所述第一数据包,并对所述第一数据包进行数据处理。
本实施例中,所述依据获取到的所述第一判断结果确定是否缓存所述第一数据包,包括:
当获取到的所述第一判断结果表征所述第一数据包对应的第一路由信息不满足所述第一预设规则时,丢弃所述第一数据包。
为进一步确定缓存在本端线卡的包处理模块中的数据包是否存在路由信息,或者即使本端线卡的包处理模块中的数据包存储有与之对应的路由信息时,还需要进一步确定存储的路由信息是否处于可到达状态,如此,以便于有针对性的丢弃没有路由信息的数据包,以及丢弃路由信息处于不可到达状态的数据包,进而释放存储空间,为降低本端线卡的包处理模块的运算量奠定基础,因此,本实施例中,所述方法还包括:
判断所述本端设备中是否存在与当前存储的至少一个第二数据包中的第二数据包对应的第二路由信息,获取第二判断结果;
当所述第二判断结果表征所述本端设备中不存在与所述当前存储的至少一个第二数据包中的第二数据包对应的第二路由信息时,丢弃所述至少一个第二数据包中的第二数据包。
在一具体实施例中,对于已经存入缓存的数据包,如果没有路由信息,则数据包将不会被调度送往交换模块,如果已经存入缓存的数据包长时间 保持不被调度,则可以采用老化方式丢弃该长时间保持不被调度的数据包。
在实际应用中,本端线卡的包处理模块对于每一个从缓存中调度出的数据包,均会根据调度出的数据包的目的地址确定是否被丢弃,也即根据调度出的数据包的对应的目的端线卡的交换接入模块的路由信息确定是否被丢弃,若调度出的数据包的对应的目的端线卡的交换接入模块的路由信息处于不可到达状态,则在对所述调度出的数据包进行分析处理之前,以及在发送至本端线卡的交换接入模块之前丢弃该调度出的数据包,如此,节省了本端线卡的缓存空间,释放了缓存读出带宽,同时降低了运算量,提升了本端线卡的性能。
本实施例中,所述方法还包括:
当所述第二判断结果表征所述本端设备中存在与所述当前存储的至少一个第二数据包中的第二数据包对应的第二路由信息时,判断第二路由信息是否满足第三预设规则,获取第三判断结果;所述第三预设规则用于表征所述本端设备不能够依据第二路由信息将第二数据包发送至与第二数据包对应的目的端设备;
当所述第三判断结果表征第二路由信息满足所述第三预设规则时,丢弃所述至少一个第二数据包中的第二数据包。
这里,值得注意的是,所述本端线卡与所述目的端线卡均为线卡,在结构上不存在区别,其中“本端”及“目的端”仅适用于区别数据包的发送方向,因此,本发明实施例所述的本端设备既可以为本端线卡,又可以为目的端线卡。
本发明实施例还提出一种计算机可读存储介质,该存储介质包括一组指令,所述指令用于执行以上实施例一所述的缓存管理方法。
为实现上述方法,本发明实施例还提供了一种本端设备,具体地,所述本端设备可以为线卡,也即本端线卡;如图4所示,所述本端设备包括:
接收单元41,配置为接收第一数据包;
获取单元42,配置为获取所述第一数据包对应的第一路由信息;
第一判断单元43,配置为判断所述第一数据包对应的第一路由信息是否满足第一预设规则,获取第一判断结果;所述第一预设规则用于表征本端设备能够依据所述第一路由信息将所述第一数据包发送至与所述第一数据包对应的目的端设备;
第一处理单元44,配置为依据获取到的所述第一判断结果确定是否缓存所述第一数据包。
本发明实施例中,所述第一处理单元44,还配置为当获取到的所述第一判断结果表征所述第一数据包对应的第一路由信息满足所述第一预设规则时,缓存所述第一数据包,并对所述第一数据包进行数据处理。
本发明实施例中,所述第一处理单元44,还配置为当获取到的所述第一判断结果表征所述第一数据包对应的第一路由信息不满足所述第一预设规则时,丢弃所述第一数据包。
本发明实施例中,所述本端设备还包括:
第二判断单元45,配置为判断所述本端设备中是否存在与当前存储的至少一个第二数据包中的第二数据包对应的第二路由信息,获取第二判断结果;
第二处理单元46,配置为当所述第二判断结果表征所述本端设备中不存在与所述当前存储的至少一个第二数据包中的第二数据包对应的第二路由信息时,丢弃所述至少一个第二数据包中的第二数据包。
本发明实施例中,所述本端设备还包括:
第三判断单元47,配置为当所述第二判断结果表征所述本端设备中存在与所述当前存储的至少一个第二数据包中的第二数据包对应的第二路由信息时,判断第二路由信息是否满足第三预设规则,获取第三判断结果; 所述第三预设规则用于表征所述本端设备不能够依据第二路由信息将第二数据包发送至与第二数据包对应的目的端设备;
第三处理单元48,还配置为当所述第三判断结果表征第二路由信息满足所述第三预设规则时,丢弃所述至少一个第二数据包中的第二数据包。
本发明实施例中,所述本端设备还包括:
数据生成单元49,配置为依据所述本端设备至至少一个目的端设备之间的路由状态信息,生成路由表;
对应地,所述获取单元42,配置为依据所述路由表,获取所述第一数据包对应的第一路由信息。
在实际应用中,所述接收单元41、获取单元42、第一判断单元43、第一处理单元44、第二判断单元45、第二处理单元46、第三判断单元47以及所述第三处理单元48均可以集成于所述本端设备,也即本端线卡的包处理模块中,也就是说,所述收单元41、获取单元42、第一判断单元43、第一处理单元44、第二判断单元45、第二处理单元46、第三判断单元47以及所述第三处理单元48均通过本端线卡中的包处理模块实现;所述数据生成单元49可通过本端线卡中的交换接入模块实现。
在实际应用中,所述接收单元41、获取单元42、第一判断单元43、第一处理单元44、第二判断单元45、第二处理单元46、第三判断单元47、第三处理单元48以及数据生成单元49均可由中央处理单元(CPU,Central Processing Unit)、或数字信号处理(DSP,Digital Signal Processor)、或现场可编程门阵列(FPGA,Field Programmable Gate Array)等来实现;所述CPU、DSP、FPGA均可内置于本端设备中。
本发明实施例所述的缓存管理方法及本端设备,通过接收第一数据包,获取所述第一数据包对应的第一路由信息,判断所述第一数据包对应的第一路由信息是否满足第一预设规则,获取第一判断结果,进而依据获取到 的所述第一判断结果确定是否缓存所述第一数据包,如此,使得本端设备能够有针对性的缓存数据包,进而为避免流量波动奠定了基础,有效解决了流量稳定性问题。
本领域技术人员应当理解,本发明实施例的本端设备中各处理单元的功能,可参照前述缓存管理方法的相关描述而理解;而且,以上所描述的设备实施例仅仅是示意性的,例如,所述单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,如:多个单元或组件可以结合,或可以集成到另一个系统,或一些特征可以忽略,或不执行。另外,所显示或讨论的各组成部分相互之间的耦合、或直接耦合、或通信连接可以是通过一些接口,设备或单元的间接耦合或通信连接,可以是电性的、机械的或其它形式的。
实施例二
本发明实施例提供了一种基于缓存管理方法的本端线卡,其中,所述本端线卡包括:接口模块、包处理模块以及交换接入模块;其中,所述包处理模块包括入向处理子模块和包处理子模块;所述交换接入模块包括出向处理子模块;所述本端线卡通过所述交换接入模块中的出向处理子模块与交换模块连接。
本实施例中,所述包处理模块,接收第一数据包;获取所述第一数据包对应的第一路由信息;判断所述第一数据包对应的第一路由信息是否满足第一预设规则,获取第一判断结果;所述第一预设规则用于表征本端设备能够依据所述第一路由信息将所述第一数据包发送至与所述第一数据包对应的目的端设备;依据获取到的所述第一判断结果确定是否缓存所述第一数据包;
本实施例中,所述包处理模块,还配置为当获取到的所述第一判断结果表征所述第一数据包对应的第一路由信息满足所述第一预设规则时,缓 存所述第一数据包,并对所述第一数据包进行数据处理;
还配置为当获取到的所述第一判断结果表征所述第一数据包对应的第一路由信息不满足所述第一预设规则时,丢弃所述第一数据包。
本实施例中,所述包处理模块,还配置为判断所述本端设备中是否存在与当前存储的至少一个第二数据包中的第二数据包对应的第二路由信息,获取第二判断结果;
当所述第二判断结果表征所述本端设备中不存在与所述当前存储的至少一个第二数据包中的第二数据包对应的第二路由信息时,丢弃所述至少一个第二数据包中的第二数据包。
本实施例中,所述包处理模块,还配置为当所述第二判断结果表征所述本端设备中存在与所述当前存储的至少一个第二数据包中的第二数据包对应的第二路由信息时,判断第二路由信息是否满足第三预设规则,获取第三判断结果;所述第三预设规则用于表征所述本端设备不能够依据第二路由信息将第二数据包发送至与第二数据包对应的目的端设备;
还配置为当所述第三判断结果表征第二路由信息满足所述第三预设规则时,丢弃所述至少一个第二数据包中的第二数据包。
本实施例中,所述交换接入模块,还配置为依据所述本端设备至至少一个目的端设备之间的路由状态信息,生成路由表;
对应地,所述包处理模块,还配置为依据所述路由表,获取所述第一数据包对应的第一路由信息。
本实施例中,所述出向处理子模块,配置为向交换模块发送数据包,具体的格式可以是包格式或者是包切割成的信元;其中,所述出向处理子模块还配置为存储所述交换接入模块的路由表,该路由表由目的交换接入模块作索引,存储的是按照高速串行链路表示的可达性指示,如果某个高速串行链路可达,则相应bit会被置位。进一步地,路由表对应的路由信息 随时根据网络拓扑更新,通过收发两端交换控制信息完成;其中,所述两端指的本端线卡与目的端线卡。在拔出某个目的端线卡的交换接入模块后,目的端线卡的交换接入模块到达本端线卡交换接入模块的链路将断开,这样可以根据链路信息更新路由表,将对应bit复位。
当新的目的端线卡的交换接入模块被插入,则目的端线卡的交换接入模块到达本端线卡交换接入模块的链路变为可到达,即路由信息可到达,这样本端线卡的交换接入模块中的出向处理子模块会根据更新的网络结构更新路由表。
进一步地,所述入向处理子模块内部包含一个准入控制子单元,所述准入控制子单元配置为分辨数据包对应的路由信息是否可达,所述出向处理子模块的路由表每次发生更新,就会将更新信息发送至所述入向处理子模块,例如,将更新后的路由表发送至入向处理子模块,所述入向处理子模块内部用二级查表方式获得可达信息,进一步地,所述入向处理子模块会根据业务及优先级映射出一个内部队列号,再由内部队列号查表获得与数据包对应的目的交换接入模块的信息,然后再根据目的交换接入模块的信息获得可达信息,也即路由信息。
在目的交换接入模块可到达时,也即数据包对应的路由信息可到达时,该数据包才被允许写入缓存,如果不可到达,则在写入缓存前即被丢弃,不占用宝贵的缓存及带宽资源。由于路由表存储于出向处理子模块,基于路由的缓存管理在入向处理子模块,路由表更新需要一定的时间,在路由表更新的时间里,可能会有部分不可到达的数据包进入缓存,对于这部分数据包,由于没有目的地,即没有路由信息,可采用老化方法丢弃。
本领域内的技术人员应明白,本发明的实施例可提供为方法、系统、或计算机程序产品。因此,本发明可采用硬件实施例、软件实施例、或结合软件和硬件方面的实施例的形式。而且,本发明可采用在一个或多个其 中包含有计算机可用程序代码的计算机可用存储介质(包括但不限于磁盘存储器和光学存储器等)上实施的计算机程序产品的形式。
本发明是参照根据本发明实施例的方法、设备(系统)、和计算机程序产品的流程图和/或方框图来描述的。应理解可由计算机程序指令实现流程图和/或方框图中的每一流程和/或方框、以及流程图和/或方框图中的流程和/或方框的结合。可提供这些计算机程序指令到通用计算机、专用计算机、嵌入式处理机或其他可编程数据处理设备的处理器以产生一个机器,使得通过计算机或其他可编程数据处理设备的处理器执行的指令产生用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的装置。
这些计算机程序指令也可存储在能引导计算机或其他可编程数据处理设备以特定方式工作的计算机可读存储器中,使得存储在该计算机可读存储器中的指令产生包括指令装置的制造品,该指令装置实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能。
这些计算机程序指令也可装载到计算机或其他可编程数据处理设备上,使得在计算机或其他可编程设备上执行一系列操作步骤以产生计算机实现的处理,从而在计算机或其他可编程设备上执行的指令提供用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的步骤。
以上所述仅是本发明实施例的实施方式,应当指出,对于本技术领域的普通技术人员来说,在不脱离本发明实施例原理的前提下,还可以作出若干改进和润饰,这些改进和润饰也应视为本发明实施例的保护范围。
工业实用性
本发明实施例通过接收第一数据包,获取所述第一数据包对应的第一路由信息,判断所述第一数据包对应的第一路由信息是否满足第一预设规 则,获取第一判断结果,进而依据获取到的所述第一判断结果确定是否缓存所述第一数据包,如此,使得本端设备能够有针对性的缓存数据包,进而为避免流量波动奠定了基础。

Claims (13)

  1. 一种缓存管理方法,包括:
    接收第一数据包;
    获取所述第一数据包对应的第一路由信息;
    判断所述第一数据包对应的第一路由信息是否满足第一预设规则,获取第一判断结果;所述第一预设规则用于表征本端设备能够依据所述第一路由信息将所述第一数据包发送至与所述第一数据包对应的目的端设备;
    依据获取到的所述第一判断结果确定是否缓存所述第一数据包。
  2. 根据权利要求1所述的方法,其中,所述依据获取到的所述第一判断结果确定是否缓存所述第一数据包,包括:
    当获取到的所述第一判断结果表征所述第一数据包对应的第一路由信息满足所述第一预设规则时,缓存所述第一数据包,并对所述第一数据包进行数据处理。
  3. 根据权利要求1所述的方法,其中,所述依据获取到的所述第一判断结果确定是否缓存所述第一数据包,包括:
    当获取到的所述第一判断结果表征所述第一数据包对应的第一路由信息不满足所述第一预设规则时,丢弃所述第一数据包。
  4. 根据权利要求1所述的方法,其中,所述方法还包括:
    判断所述本端设备中是否存在与当前存储的至少一个第二数据包中的第二数据包对应的第二路由信息,获取第二判断结果;
    当所述第二判断结果表征所述本端设备中不存在与所述当前存储的至少一个第二数据包中的第二数据包对应的第二路由信息时,丢弃所述至少一个第二数据包中的第二数据包。
  5. 根据权利要求4所述的方法,其中,所述方法还包括:
    当所述第二判断结果表征所述本端设备中存在与所述当前存储的至少 一个第二数据包中的第二数据包对应的第二路由信息时,判断第二路由信息是否满足第三预设规则,获取第三判断结果;所述第三预设规则用于表征所述本端设备不能够依据第二路由信息将第二数据包发送至与第二数据包对应的目的端设备;
    当所述第三判断结果表征第二路由信息满足所述第三预设规则时,丢弃所述至少一个第二数据包中的第二数据包。
  6. 根据权利要求1所述的方法,其中,所述方法还包括:
    依据所述本端设备至至少一个目的端设备之间的路由状态信息,生成路由表;
    对应地,所述获取所述第一数据包对应的第一路由信息,包括:
    依据所述路由表,获取所述第一数据包对应的第一路由信息。
  7. 一种本端设备,包括:
    接收单元,配置为接收第一数据包;
    获取单元,配置为获取所述第一数据包对应的第一路由信息;
    第一判断单元,配置为判断所述第一数据包对应的第一路由信息是否满足第一预设规则,获取第一判断结果;所述第一预设规则用于表征本端设备能够依据所述第一路由信息将所述第一数据包发送至与所述第一数据包对应的目的端设备;
    第一处理单元,配置为依据获取到的所述第一判断结果确定是否缓存所述第一数据包。
  8. 根据权利要求7所述的本端设备,其中,所述第一处理单元,还配置为当获取到的所述第一判断结果表征所述第一数据包对应的第一路由信息满足所述第一预设规则时,缓存所述第一数据包,并对所述第一数据包进行数据处理。
  9. 根据权利要求7所述的本端设备,其中,所述第一处理单元,还配 置为当获取到的所述第一判断结果表征所述第一数据包对应的第一路由信息不满足所述第一预设规则时,丢弃所述第一数据包。
  10. 根据权利要求7所述的本端设备,其中,所述本端设备还包括:
    第二判断单元,配置为判断所述本端设备中是否存在与当前存储的至少一个第二数据包中的第二数据包对应的第二路由信息,获取第二判断结果;
    第二处理单元,配置为当所述第二判断结果表征所述本端设备中不存在与所述当前存储的至少一个第二数据包中的第二数据包对应的第二路由信息时,丢弃所述至少一个第二数据包中的第二数据包。
  11. 根据权利要求10所述的本端设备,其中,所述本端设备还包括:
    第三判断单元,配置为当所述第二判断结果表征所述本端设备中存在与所述当前存储的至少一个第二数据包中的第二数据包对应的第二路由信息时,判断第二路由信息是否满足第三预设规则,获取第三判断结果;所述第三预设规则用于表征所述本端设备不能够依据第二路由信息将第二数据包发送至与第二数据包对应的目的端设备;
    第三处理单元,还配置为当所述第三判断结果表征第二路由信息满足所述第三预设规则时,丢弃所述至少一个第二数据包中的第二数据包。
  12. 根据权利要求7所述的本端设备,其中,所述本端设备还包括:
    数据生成单元,配置为依据所述本端设备至至少一个目的端设备之间的路由状态信息,生成路由表;
    对应地,所述获取单元,配置为依据所述路由表,获取所述第一数据包对应的第一路由信息。
  13. 一种计算机可读存储介质,该存储介质包括一组指令,所述指令用于执行权利要求1至6任一项所述的缓存管理方法。
PCT/CN2015/095019 2015-05-25 2015-11-19 一种缓存管理方法、本端设备及存储介质 WO2016188058A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201510270283.6 2015-05-25
CN201510270283.6A CN106302232A (zh) 2015-05-25 2015-05-25 一种缓存管理方法及本端设备

Publications (1)

Publication Number Publication Date
WO2016188058A1 true WO2016188058A1 (zh) 2016-12-01

Family

ID=57393621

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2015/095019 WO2016188058A1 (zh) 2015-05-25 2015-11-19 一种缓存管理方法、本端设备及存储介质

Country Status (2)

Country Link
CN (1) CN106302232A (zh)
WO (1) WO2016188058A1 (zh)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH11127184A (ja) * 1997-10-20 1999-05-11 Oki Electric Ind Co Ltd ルーティング方法及びルータ
CN102006226A (zh) * 2010-11-19 2011-04-06 福建星网锐捷网络有限公司 报文缓存管理方法、装置及网络设备
CN103312614A (zh) * 2013-07-02 2013-09-18 福建星网锐捷网络有限公司 一种组播报文处理方法、线卡及通信设备
CN103856407A (zh) * 2014-03-25 2014-06-11 重庆邮电大学 一种基于NetFPGA可编程虚拟路由器的数据包加速转发方法及装置
CN104092632A (zh) * 2014-07-14 2014-10-08 杭州华三通信技术有限公司 一种网络设备
CN104243323A (zh) * 2013-06-06 2014-12-24 中兴通讯股份有限公司 交换网多播路由方法及系统

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101483883B (zh) * 2008-12-17 2011-09-14 上海华为技术有限公司 一种数据处理方法、装置和通信系统
CN103780507B (zh) * 2014-02-17 2017-03-15 杭州华三通信技术有限公司 缓存资源的管理方法及装置
CN104394081B (zh) * 2014-12-05 2017-10-03 迈普通信技术股份有限公司 一种数据处理方法及装置

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH11127184A (ja) * 1997-10-20 1999-05-11 Oki Electric Ind Co Ltd ルーティング方法及びルータ
CN102006226A (zh) * 2010-11-19 2011-04-06 福建星网锐捷网络有限公司 报文缓存管理方法、装置及网络设备
CN104243323A (zh) * 2013-06-06 2014-12-24 中兴通讯股份有限公司 交换网多播路由方法及系统
CN103312614A (zh) * 2013-07-02 2013-09-18 福建星网锐捷网络有限公司 一种组播报文处理方法、线卡及通信设备
CN103856407A (zh) * 2014-03-25 2014-06-11 重庆邮电大学 一种基于NetFPGA可编程虚拟路由器的数据包加速转发方法及装置
CN104092632A (zh) * 2014-07-14 2014-10-08 杭州华三通信技术有限公司 一种网络设备

Also Published As

Publication number Publication date
CN106302232A (zh) 2017-01-04

Similar Documents

Publication Publication Date Title
US11792046B2 (en) Method for generating forwarding information, controller, and service forwarding entity
US7653056B1 (en) Virtual switching using a provisional identifier to conceal a user identifier
CN110943924B (zh) 网络中分段源路由的方法及存储介质
CN108462646B (zh) 一种报文处理方法及装置
JP5534481B2 (ja) 通信品質監視システム、通信品質監視方法、及び記憶媒体
US7760723B1 (en) Relaying a data stream from a data device to a network tunnel
US20030161319A1 (en) Packet communications system and transfer device
US10050906B2 (en) Virtual node having separate control and data planes
WO2018036173A1 (zh) 一种网络负载均衡方法、设备及系统
CN111371634B (zh) 一种通信方法、装置及系统
US8838782B2 (en) Network protocol processing system and network protocol processing method
US11070386B2 (en) Controlling an aggregate number of unique PIM joins in one or more PIM join/prune messages received from a PIM neighbor
US20100157818A1 (en) Network system, server, quality degradation point estimating method, and program
KR20180025944A (ko) Sdn 기반의 arp 구현 방법 및 장치
EP3534571A1 (en) Service packet transmission method, and node apparatus
JP5413452B2 (ja) ネットワーク通信システム、通信装置、ネットワーク連携方法及びプログラム
CN111026324A (zh) 转发表项的更新方法及装置
WO2016188058A1 (zh) 一种缓存管理方法、本端设备及存储介质
JP2004088658A (ja) パケット転送装置及びパケット処理方法
US8091136B2 (en) Packet transfer device, packet transfer method, and program
WO2023231438A1 (zh) 报文发送的方法、网络设备及系统
WO2024065481A1 (zh) 一种数据处理方法、装置、网络设备及存储介质
JP2006060346A (ja) データ伝送システム及び方法並びにデータ伝送用プログラム
JP5069276B2 (ja) 機能分散型パケット転送システム及びメッセージ処理方法
JP2017204785A (ja) 通信装置、通信システム、及び通信装置のパケット転送方法

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

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

Country of ref document: EP

Kind code of ref document: A1