CA2303261A1 - A lookup device and a method for classification and forwarding of packets in packet-switched networks - Google Patents

A lookup device and a method for classification and forwarding of packets in packet-switched networks Download PDF

Info

Publication number
CA2303261A1
CA2303261A1 CA002303261A CA2303261A CA2303261A1 CA 2303261 A1 CA2303261 A1 CA 2303261A1 CA 002303261 A CA002303261 A CA 002303261A CA 2303261 A CA2303261 A CA 2303261A CA 2303261 A1 CA2303261 A1 CA 2303261A1
Authority
CA
Canada
Prior art keywords
packet
packet identifier
hash
memory
index
Prior art date
Legal status (The legal status 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 status listed.)
Abandoned
Application number
CA002303261A
Other languages
French (fr)
Inventor
Peter Sjodin
Andreas Moestedt
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
SICS SWEDISH INSTITUTE OF COMPUTER SCIENCE AB
Original Assignee
Individual
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 Individual filed Critical Individual
Publication of CA2303261A1 publication Critical patent/CA2303261A1/en
Abandoned legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04QSELECTING
    • H04Q11/00Selecting arrangements for multiplex systems
    • H04Q11/04Selecting arrangements for multiplex systems for time-division multiplexing
    • H04Q11/0428Integrated services digital network, i.e. systems for transmission of different types of digitised signals, e.g. speech, data, telecentral, television signals
    • H04Q11/0478Provisions for broadband connections
    • 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/745Address table lookup; Address filtering
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L49/00Packet switching elements
    • H04L49/25Routing or path finding in a switch fabric
    • H04L49/256Routing or path finding in ATM switching fabrics
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L49/00Packet switching elements
    • H04L49/30Peripheral units, e.g. input or output ports
    • H04L49/3081ATM peripheral units, e.g. policing, insertion or extraction
    • H04L49/309Header conversion, routing tables or routing tags
    • 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/745Address table lookup; Address filtering
    • H04L45/7452Multiple parallel or consecutive lookup operations
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L49/00Packet switching elements
    • H04L49/20Support for services
    • H04L49/205Quality of Service based
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L49/00Packet switching elements
    • H04L49/35Switches specially adapted for specific applications
    • H04L49/351Switches specially adapted for specific applications for local area network [LAN], e.g. Ethernet switches

Landscapes

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

Abstract

The present invention relates to a lookup device and a method for classification and forwarding of packets in packet-switched networks, wherein each packet comprises a packet header comprising a number of fields, wherein several fields in the packet header together form a packet identifier. The lookup device (30) comprises n parallel hashing units (321, 322, ... 32n), wherein n is an integer and n2, for computing, for each packet, a first index by hashing the packet identifier, and in dependence of the first index either directly or indirectly obtaining a packet identifier and forwarding information for the destination for said packet from one of at least n memories . The n hashing units (321, 322, ... 32n) are processing the same packet identifier at a time. The lookup device (30) also comprises a comparator (42) connected either directly or indirectly to at least one of said memories and to an input to said n hashing units (321, 322, ... 32n) for comparing the packet identifier input to the n hashing (321, 322, ... 32n) and the packet identifier output from said memory. When the compared packet identifiers match, the forwarding information for the packet is obtained from said memory.

Description

A LOOKUP DEVICE ANO A METHOD FOR CLASSIFICATION AIVO FORWARDING
OF PACKETS IN PACKET-SWITCHED NETWORKS
Technical field of the invention The present invention relates to a lookup device for classification and forwarding of packets in packet-switched networks. The present invention also relates to a method for classification and forwarding of packets in packet-siaitched networks.
Description of related art The growth of the Internet has led to a situation where bandwidth is becoming a scarce resource. One reason for this is that the IP routers - the packet switches in the Internet - are not powerful enough to handle the traffic that aggregates a~ the switching points. The current trend for dealing with this problem is to relieve routers from some cf the burden of switching traffic, and instead use switches of different kinds, such as FDDI
switches, ATM switches, and Ethernet switches. This turns out to be a more cost effective solution, since the price for switching capacity is much lower than the price for routing capacity.
2C One of the main limiting factors for performance in an IP router, compared to a switch is often claimed to be the processing of incoming packets. When an IP packet arrives at an inpu' port ef a router, the packet needs to be examined and classified, and based on the classifi-cation the packet is forwarded to an output port. The packet classification operation consists of analysing information in the packe~ header (at least the destination address needs to be examined), and performing a lookup operation to obtain the information required to forward the packet to its next hop. In principle, the same kind of classification needs to be performed by a switch, but the operation is generally thought to be more complicated for an IP packet than for an ATM cell or an Ethernet frame. A
common lookup method is to use a hashing scheme.
In the article "A Comparison of Hashing Schemes for Address Lookup in Computer Networks", by R. Jain, IEEE
Transactions on Communication, vol. 90, No. 10, pp. 1570--SU8ST1TUTE SHEET (RULE 26) 1573, 1992, is disclosed different hashing methods. The described hashing methods are:
1) hashing using address bits, 2) hashing using CRC polynomials, - 5 3) hashing using Fletcher checksum, 4) hashing using another checksum, and 5) hashing using XOR folding.
The article "Large-scale and High-speed Inter-connection of Multiple FDDIs using ATM-based Backbone LAN", by T. Tsukakoshi, 0. Takada, T. Murakami, M. Terada, M. Yamaga, IEEE INFOCOM '92, vol. 3, pp. 2290-2298, May 1992, describes a solution to the problem that a hash function can map several identifiers into the same table location. The hashing mechanism according to this solution puts all entries in the same memory, and calculates the hash value a variable number of times until no collision occurs.
Typically hash tables are implemented as a table of lists, where each table entry is a list of identifiers that share that index. The disadvantage with such an organisation is that it requires repetitive accesses to memory in order to do a lookup, lowering performance.
Furthermore, many such schemes rely on only one hash function, so rehashing has to be performed if the distribution gets too skewed.
Summary of the. invention The object of the present invention is to solve the above mentioned problems and to provide a lookup device for classification and forwarding of packets, wherein each packet comprises a packet header comprising a number of fields, wherein several fields in the packet header together form a packet identifier. This object is achieved by providing the lookup device defined in the introductory part of Claim 1 with the advantageous features of the characterizing part of said Claim.
The lookup device according to the present invention comprises n parallel hashing units, wherein n is an integer and n>_2, for computing for each packet, a firs index by hashing the packet identifier, and in dependence of the first index either directly or indirectly obtaining a packet identifier and forwarding information for the - 5 destination for said packet from one of at least n memories, wherein the n hashing units are processing the same packet identifier at a time. The lookup device also comprises a comparator connected either directly or indirectly to at least one of said memories and to an input to said n hashing units for comparing the packet identifier input to the n hashing units and the packet identifier output from said memory. When the compared packet identifiers match the forwarding information for the packet is obtained from said memory. The main advantage with this design is that a new packet identifies can be looked up in each memory cycle time. Another advantage with this design is that it allows several table lookups to be performed in one memory cycle time, since the lookups are performed in parallel.
Advantageously, each hashing unit comprises a hash function means for computing said first index, and a hash memory connected to said hash function means.
Preferably, the lookup device makes use of n different hash functions, one hash function for each hash function means. Hereby is achieved that the need of rehashing is effectively decreased, and hopefully eliminated since the identifiers are spread by several independent hash functions.
Preferably, the n hashing units are ordered by priority, wherein the first hashing unit has the highest priority, and the n:th hashing unit has the lowest priority.
Advantageously, the first hash memory, representinc the highest level in the lookup device, has the largest memory size, and the n:th hash memory, representing the lowest level in the lookup device, has the smallest memory size.
Preferably, the memory sizes for the n hash memories are decreasing substantially lineary. Hereby is achieved the most efficient memory usage.
Advantageously, all the memories are Static Random - 5 Access Memories (SRAM's) and/or Dynamic Random Access Memories (DRAM's).
Preferably, said first index function as an input to said hash memory giving a packet identifier and forwarding information for the destination and a hit flag as outputs.
The lookup device also comprises a selecting means connected to the hit flag outputs of all n hash memories, a multiplexer connected to the packet identifier and forwarding information outputs of all n hash memories, wherein said comparator is connected to said multiplexer.
A set hit flag indicates that there was an entry in the hash memory with the first index obtained by hashing the packet identifier, and the packet identifier from the hash memory with the highest priority with the hit flag set, if any, is used as input to said comparator via said multiplexer, whereby said comparator compares the packet identifier input to said hash function means and the packet identifier output from said multiplexer, and when the compared packet identifiers match, the forwarding information for the packet is obtained from the hash memory with the highest priority with the hit flag set.
According to another embodiment of the present invention said first index function as an input to said hash memory giving a second index and a hit flag as outputs. The lookup device also comprises a selecting means connected to the hit flag outputs of all n hash memories, a multiplexer connected to the second index outputs of all n hash memories, an address memory, storing all packet identifiers together with the forwarding information for the destination, connected to said multiplexer, wherein said comparator is connected to said address memory. A set hit flag indicates that there was an entry in the hash memory with the first index obtained when hashing the packet identifier, and the second index from the hash memory with the highest priority with the hit flag set, if any, is used as input to said address memory, giving a packet identifier and the forwarding information as outputs. The comparator compares the packet - 5 identifier input to said hash function means and the packet identifier output from said address memory, and when the. compared packet identifiers match, the forwarding information for the packet is obtained from said address memory.
Another object of the invention is to provide a method for classification and forwarding of packets, wherein each packet comprises a packet header comprising a number of fields, wherein several fields in the packet header together forms a packet identifier. The method comprises the following steps:
- to compute, for each packet, a first index by hashing the input packet identifier in n different, parallel paths, wherein n is an integer and n>_2;
- and in dependence of the first index either directly or indirectly obtaining a packet identifier and forwarding information for the destination for said packet from one of at least n memories;
- to compare the input packet identifier and the packet identifier output from the memory; and - if the compared packet identifiers match to make use of the forwarding information obtained from said memory.
The main advantage with this method is that a new packet identifier can be looked up in each memory cycle time. Another advantage with this method is that it allows several table lookups to be performed in one memory cycle time, since the lookups are performed in parallel.
Advantageously, the computing step comprises the steps:
- to compute the first index by using different hash functions, one hash function for each path; and to use the first index as an input to a table, one of n different tables. Hereby is achieved that the need of rehashing is effectively decreased, and hopefully eliminated since the identifiers are spread by several - 5 independent hash functions.
Preferably, the n.paths are ordered by priority, wherein the first path has the highest priority and the n:th path has the lowest priority.
Preferably, the first table, representing the highest level, has the largest size, and the n:th table, representing the lowest level, has the smallest size.
Advantageously, the sizes of the n tables are decreasing substantially lineary. Hereby is achieved the most efficient table usage.
Preferably, each table stores packet identifiers and forwarding information for the destination, and wherein each table outputs a hit flag, wherein a set hit flag indicates that there was an entry in the table with the first index obtained by hashing the packet identifier, and the packet identifier from the table with the highest priority with the hit flag set, if any, is used as input to said comparing step.
According to another embodiment of the method according to the present invention, said first index functions as an input to said table giving a second index and a hit flag as outputs. A set hit flag indicates that there was an entry in the table with the first index obtained when hashing the packet identifier, and the second index from the fable with the highest priority with the hit flag set, if any, is used as input to an address memory giving a packet identifier as output, and said packet identifier is used as input to said comparing step.
Preferably, if a new packet identifier is to be added, it is initially hashed into the first path, and if a collision occurs, i.e. there is already a packet identifier with that first index in the first table, the two colliding packet identifiers are hashed into the second path, and if a collision occurs in the i:th path, the colliding packet identifiers are hashed into the (i+1):th path, wherein 15i<_n-1. Hereby is achieved that only one comparison is needed for a full identifier - 5 lookup.
Advantageously, the method terminates for said packet identifier if the compared packet identifiers not match.
Preferably, the method terminates for said packet identifier if none of the n tables outputs a set hit flag.
Embodiments of the invention will now be described with a reference to the accompanying drawings, in which:
Brief description of the Drawings Figure 1 shows a schematic diagram of the fields in an IP
packet header;
Figure 2 shows a schematic diagram of the hashing concept;
Figure 3 shows a block diagram of a lookup device according to the present invention; and Figure 4 is a flow chart of the method according to the present invention.
Detailed description of Embodiments In figure 1 there is disclosed a schematic diagram of the fields in an IP packet header. The IP packet header comprises 12 different fields. As is disclosed in figure 1 these fields are: Version, IP Header Length, Type of Service, Total Length, Identification, Flags, Fragment Offset, Time to Live, Protocol, Header Checksum, Source Address, and Destination Address. It can also contain an Options field.
There are in principle two different types of IP
packet classification: IP address lookup, which is used for forwarding of unicast packets based on their destination address, and identifier lookup, which is intended to be used for, for example, forwarding of multicast packets and flows of packets. IP multicast addresses are not organized in a hierarchical structure.
Identifier lookup is used when several fields in the packet header together form a packet identifier. Such an identifier has no hierarchical structure to it, and the - 5 identifier space is potentially very large. Therefore techniques such as hashing or CAM (Content Addressable Memory) are required for the lookup. The present invention is based on identifier lookup.
In the articla "A Comparison of Hashing Schemes for Address Lookup in Computer Networks", by R. Jain, IEEE
Transactions on Communication, vol. 40, No. 10, pp. 1570-1573, referred to above, is disclosed the basic theory underlying the hashing concept. Below and in reference to figure 2 will be given a small selection from this article.
In figure 2 there is disclosed a schematic diagram of the hashing concept. Basically, hashing allows us to chop up a big table into several small subtables so that we can quickly find the information once we have determined the subtable to search for. This determination is made by using a mathematical function, which maps the given key to hash cell i, as shown in figure 2. The cell i could then point us to the subtable of size ni. Given a trace of R frames with N distinct addresses and a hash table of M cells, the goal is to minimize the average number of lookups required per frame.
If we perform a regular binary search through all N
addresses, we need to perform 1 + log2(N) or log2(2N) lookup per frame. Given an address that hashes to i:th cell, we have to search through a subtable of ni entries, which requires only log (2ni) lookups. The total number of lookups saved is S:
S = ~ri[log2(2N)-log2(2ni)]
i where ri is the number of frames that hash to the i:th cell, Sri = R. The net saving per frame is F:
F = ~ - ri log2(n') = E - q~ log2(P~) R N
- Here, qi = ri denotes the fraction of frames that R
hash to i:th cell, and p; - ni is the fraction of N
addresses that hash to i:th cell. The goal of a hashing function is to maximize the quantity ~-qilog2(Pi).
In figure 3 there is disclosed a block diagram of a lookup device according to the present invention. The lookup device 30 is for classification and forwarding of packets in packet-switched networks, wherein each packet comprises a packet header (see figure 1) comprising a number of fields, wherein several fields in the packet header together forms a packet identifier. The lookup device 30 comprises n parallel hashing units 321, 322, ...
32", wherein n is an integer and n>_2. Each hashing unit 321, 322, ... 32~ comprises a hash function means 341; 342, ... 34n, and a hash memory 361, 362, ... 36n connected to said hash function means 341, 392, ... 39n. Each hash function means 341, 342, ... 34n computes a first index by hashing the packet identifier. This first index is used as an input to said hash memory, giving a second index and a hit flag as outputs. A set hit flag indicates that there was an entry in a hash memory 361, 362, ... 36~ with the first index obtained when hashing the packet identifier.
The lookup device 30 according to the present invention makes use of n different hash functions, one hash function for each hash function means 341, 342, ... 34n. This means that the lookup device 30 according to the present invention comprises several (n) parallel hash paths. All hashing units 321, 322, ... 32n process the same packet identifier. Therefore a lookup for a given identifier will succeed in at most one of the paths, and therefore all paths can be searched in parallel. The lookup device 30 also comprises a selecting means 38 connected to the hit flag outputs of all n hash memories 361, 362, ... 36n, and a multiplexer 39 connected to the second index outputs of all n hash memories 36t, 362, ... 36~. The output from the selecting means 38 is connected to said multiplexer 39.
- 5 The lookup device 30 also comprises an address memory 90, storing all the packet identifiers together with the forwarding information for the destination. Each second index input to said address memory 40 will give a packet identifier and the forwarding information for the destination as output. The lookup device 30 also comprises a comparator 42 connected to said address memory 40. The comparator 92 has also another input, supplied with the identifier input to all the n hash function means 391, 342, ... 34n. The comparator 42 compares the packet identifier input to the n hash function means 391, 342, ... 39n, and the packet identifier output from the address memory 40. If the compared packet identifiers match, the forwarding informaton for the packet is obtained from said address memory 40, via a line 44. If they do not match it was a false hit, indicating that the packet identifier was not present in the address memory 90. The hash calculation, the memory lookup, the table lookup and the comparison are all independent operations and can work in parallel, thus the lookup can easily be pipelined to increase the throughput.
Another embodiment of the lookup device according to the present invention does not comprise an address memory and does not make use of any second index. Instead the hash memories 361, 362, ... 36n comprise the packet identifiers and the forwarding information. The packet identifier output from the hash memory with the highest priority with the hit flag set, if any, is used as input to said comparator. This embodiment is not disclosed in any figure. This embodiment comprises all the elements disclosed in figure 3, except the address memory 90.
The embodiment disclosed in figure 3 is preferred for large identifiers, because it saves memory to use a second level memory. What method is best depends on how the design is used (i.e. size of identifiers, memory organization, etc.)..
The advantages with these designs are twofold:
first, it allows several table lookups to be performed in - 5 one memory cycle time, since the lookups are performed in parallel. Second, there are several hash functions, which effectively decrease, and hopefully eliminate, the need of rehashing since the identifiers are spread by several independent hash functions.
When an identifier is added to the lookup device 30 it is initially hashed into the first path. If a collision occurs, i.e. there is already an identifier with that index in the hash memory, the two colliding identifiers are hashed into the second path. The index in the first path where the collision occurred cannot be used for another identifier. If a collision occurs also in the second path the same procedure is repeated with the colliding identifiers moved to the third path, and so on.
There is a reason why a hash entry where a collision has occurred is not used any more. If a lookup hits in more than one path, then it is sufficient to only consider the hit in the path with the highest priority. So with this scheme, only one comparison with~the real identifier has to be performed.
If a collision occurs in the last of paths, the lookup table will overflow. The larger the hash memories in the hash paths, the lower the probability that identifiers will collide.
The most efficient memory usage is obtained when the memory is divided into several hash paths. The hash paths should be organised hierarchically with the largest hash memory at the highest level and the smallest hash memory at the lowest level, preferably with the hash memory sizes for the n hash memories decreasing substantially lineary.
The lookup device 30 is preferably implemented using Static Random Access Memories (SRAMs) and/or Dynamic Random Access Memories (DRAMs) as memories.

The hash function means 341, 342, ... 34~ can be implemented using xor folding, which is probably preferred, being very simple and easy to vary.
In figure 4 there is disclosed a flow chart of the - 5 method according to the present invention. The method for classification and forwarding of packets, wherein each packet comprises a packet header (see figure 1) comprising a number of fields, wherein several fields in the packet header together form a packet identifier, begins at block 50. Thereafter, at block 52, the method continues to compute, for each packet, a first index by hashing the input packet identifier in n different, parallel paths, wherein n is an integer and n>_2. Thereafter, at block 54, the method continues by, in dependence of the first index, either directly or indirectly obtaining a packet identifier and forwarding information for the destination for said packet from one of_ at least n memories. Then, at block 56, the method continues by comparing the input packet identifier and the packet identifier output from the memory. Then, at block 58, the method continues, if the compared packet identifiers match, by making use of the forwarding information obtained from said memory.
Then, at block 60, the method is completed.
The method according to the present invention can e.g. be implemented with a lookup device of the type disclosed in figure 3.
The invention is not limited to the embodiment described in the foregoing. It will be obvious that many different modifications are possible within the scope of the following Claims.

Claims (19)

Claims
1. A lookup device (30) for classification and forwarding of packets, wherein each packet comprises a packet header comprising a number of fields, wherein several fields in the packet header together form a packet identifier, characterized in that the lookup device (30) comprises n parallel hashing units (32 1, 32 2, ... 32 n), wherein n is an integer and n~2, for computing, for each packet, a first index by hashing the packet identifier, and in dependence of the first index either directly or indirectly obtaining a packet identifier and forwarding information for the destination for said packet from one of at least n memories, wherein the n hashing units (32 1, 32 2, ... 32 n) are processing the same packet identifier at a time, and a comparator (42) connected either directly or indirectly to at least one of said memories and to an input to said n hashing units (32 1, 32 2, ... 32 n) for comparing the packet identifier input to the n hashing units (32 1, 32 2, ... 32 n) and the packet identifier output from said memory, and when the compared packet identifiers match, the forwarding information for the packet is obtained from said memory.
2. A lookup device (30) according to Claim 1, characterized in that each hashing unit (32 1, 32 2, ... 32 n) comprises a hash function means (34 1, 34 2, ... 34 n) for computing said first index, and a hash memory (36 1, 36 2, ... 36 n) connected to said hash function means (34 1, 34 2, ... 34 n).
3. A lookup device (30) according to Claim 2, characterized in that the lookup device (30) makes use of n different hash functions, one hash function for each hash functions means (34 1, 34 2, ... 34 n).
4. A lookup device (30) according to any one of Claims 1-3, characterized in that the n hashing units (32 1, 32 2, ... 32 n) are ordered by priority, wherein the first hashing unit (32 1) has the highest priority, and the n:th hashing unit (32 n) has the lowest priority.
5. A lookup device (30) according to Claim 4, characterized in that the first hash memory (36 1), representing the highest level in the lookup device (30), has the largest memory size, and the n:th hash memory (36 n), representing the lowest level in the lookup device, has the smallest memory size.
6. A lookup device (30) according to Claim 5, characterized in that the memory sizes for the n hash memories (36 1, 36 2, ... 36 n) are decreasing substantially lineary.
7. A lookup device (30) according to any one of Claims 1 - 6, characterized in that all the memories (36 1, 36 2, ... 36 n, 40; 36 1, 36 2, ... 36 n) are Static Random Access Memories (SRAMs) and/or Dynamic Random Access Memories (DRAMs).
8. A lookup device (30) according to any one of Claims 2 - 7, characterized in that said first index function as an input to said hash memory (36 1, 36 2, ... 36 n) giving a packet identifier and forwarding information for the destination and a hit flag as outputs, and in that said lookup device (30) also comprises a selecting means (38) connected to the hit flag outputs of all n hash memories (36 1, 36 2, . . . 36 n) , a multiplexer (39) connected to the packet identifier and forwarding information outputs of all n hash memories (36 1, 36 2, ... 36 n), wherein said comparator (42) is connected to said multiplexer (39), wherein a set hit flag indicates that there was an entry in the hash memory (36 1, 36 2, ... 36 n) with the first index obtained by hashing the packet identifier, and the packet identifier from the hash memory (36 1, 36 2, ... 36 n) with the highest priority with the hit flag set, if any, is used as input to said comparator (42), via said multiplexer (39), whereby said comparator (42) compares the packet identifier input to said hash function means (34 1, 34 2, ... 34 n) and the packet identifier output from said multiplexer (39), and when the compared packet identifiers match, the forwarding information for the packet is obtained from the hash memory (36 1, 36 2, ... 36 n) with the highest priority with the hit flag set.
9. A lookup device (30) according to any one of Claims 2 - 7, characterized in that said first index function as an input to said hash memory (36 1, 36 2, ... 36 n) giving a second index and a hit flag as outputs, and in that said lookup device (30) also comprises a selecting means (38) connected to the hit flag outputs of all n hash memories (36 1, 36 2, ... 36 n) , a multiplexer (39) connected to the second index outputs of ail n hash memories (36 1, 36 2, ...
36 n), an address memory (40), storing all packet identifiers tohgether with the forwarding information for the destination, connected to said multiplexer (39), wherein said comparator (42) is connected to said address memory (40), wherein a set hit flag indicates that there was an entry in the hash memory (36 1, 36 2, ... 36 n) with the first index obtained when hashing the packet identifier, and the second index from the hash memory (36 1, 36 2, ... 36 n) with the highest priority with the hit flag set, if any, is used as input to said address memory (40) giving a packet identifier and the forwarding information as outputs, whereby said comparator (42) compares the packet identifier input to the said hash function means (34 1, 34 2, ... 34 n) and the packet identifier output from said address memory (40), and when the compared packet identifiers match, the forwarding information for the packet is obtained from said address memory (40).
10. A method for classification and forwarding of packets, wherein each packet comprises a packet header comprising a number of fields, wherein several fields in the packet header together form a packet identifier, wherein the method is characterized by the following steps:
- to compute, for each packet, a first index by hashing the input packet identifier in n different, parallel paths, wherein n is an integer and n~2;
- and in dependence of the first index either directly or indirectly obtaining a packet identifier and forwarding information for the destination for said packet from one of at least n memories;
- to compare the input packet identifier and the packet identifier output from the memory; and - if the compared packet identifiers match to make use of the forwarding information obtained from said memory.
11. A method according to Claim 10, characterized in that the computing step comprises the steps:
- to compute the first index by using n different hash functions, one hash function for each path; and - to use the first index as an input to a table, one of n different tables.
12. A method according to any one of Claims 10 - 11, characterized in that the n paths are ordered by priority, wherein the first path has the highest priority, and the n:th path has the lowest priority.
13. A method according to Claim 12, characterized in that the first table, representing the highest level, has the largest size, and the n:th table, representing the lowest level, has the smallest size.
14. A method according to Claim 13, characterized in that the sizes of the n tables are decreasing substantially lineary.
15. A method according to any one of Claims 10 - 14, characterized in that each table stores packet identifiers and forwarding information for the destination, and wherein each table outputs a hit flag, wherein a set hit flag indicates that there was an entry in a table with the first index obtained by hashing the packet identifier, and the packet identifier from the table with the highest priority with the hit flag set, if any, is used as input to said comparing step.
16. A method according to any one of Claims 10 - 14, characterized in that said first index function as an input to said table giving a second index and a hit flag as outputs, wherein a set hit flag indicates that there was an entry in a table with the first index obtained when hashing the packet identifier, and the second index from the table with the highest priority with the hit flag set, if any, is used as input to an address memory giving a packet identifier as output, and said packet identifier is used as input to said comparing step.
17. A method according to any one of Claims 10 - 16, characterized in that, if a new packet identifier is to be added, it is initially hashed into the first path, and if a collision occurs, i.e. there is already a packet identifier with that first index in the first table, the two colliding packet identifiers are hashed into the second path, and if a collision occurs in the i:th path, the colliding packet identifiers are hashed into the (i+1):th path, wherein 1~i~n-1.
18. A method according to any one of Claims 10 - 17, characterized in that, if the compared packet identifiers not match, the method terminates for said packet identifier.
19. A method according to any one of Claims 15 - 16, characterized in that, if none of the n tables outputs a set hit flag, the method terminates for said packet identifier.
CA002303261A 1997-09-09 1998-09-07 A lookup device and a method for classification and forwarding of packets in packet-switched networks Abandoned CA2303261A1 (en)

Applications Claiming Priority (3)

Application Number Priority Date Filing Date Title
SE9703293-4 1997-09-09
SE9703293A SE511971C2 (en) 1997-09-09 1997-09-09 A lookup device and a method for classifying and forwarding data packets in data packet switching networks
PCT/SE1998/001585 WO1999013620A2 (en) 1997-09-09 1998-09-07 A lookup device and a method for classification and forwarding of packets in packet-switched networks

Publications (1)

Publication Number Publication Date
CA2303261A1 true CA2303261A1 (en) 1999-03-18

Family

ID=20408225

Family Applications (1)

Application Number Title Priority Date Filing Date
CA002303261A Abandoned CA2303261A1 (en) 1997-09-09 1998-09-07 A lookup device and a method for classification and forwarding of packets in packet-switched networks

Country Status (5)

Country Link
EP (1) EP1020053A2 (en)
AU (1) AU9192698A (en)
CA (1) CA2303261A1 (en)
SE (1) SE511971C2 (en)
WO (1) WO1999013620A2 (en)

Families Citing this family (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6765909B1 (en) 1999-04-22 2004-07-20 Nortel Networks Limited Method and apparatus for providing support for multiple QoS levels within a third generation packet data session
WO2001078309A2 (en) * 2000-04-11 2001-10-18 P-Cube Ltd. A method and apparatus for wire-speed application layer classification of data packets
GB2399199B (en) * 2000-04-11 2004-10-27 Cube Ltd P A method and apparatus for wire-speed application layer classification of data packets
DE50106624D1 (en) * 2001-01-12 2005-08-04 Vector Informatik Gmbh Method and device for checking the relevance of an identifier
US7031314B2 (en) 2001-05-16 2006-04-18 Bytemobile, Inc. Systems and methods for providing differentiated services within a network communication system
EP1564960B1 (en) * 2001-05-16 2007-03-28 Bytemobile, Inc. System and methods for providing differentiated services within a network communication system
US7027446B2 (en) * 2001-07-18 2006-04-11 P-Cube Ltd. Method and apparatus for set intersection rule matching
ATE314768T1 (en) 2001-10-08 2006-01-15 Cit Alcatel METHOD FOR DISTRIBUTING LOAD BETWEEN SEVERAL COMMON EQUIPMENT IN A COMMUNICATIONS NETWORK AND NETWORK FOR APPLYING THE METHOD
US20030120932A1 (en) * 2001-12-21 2003-06-26 Koninklijke Philips Electronics N.V. Synchronizing source and destination systems via parallel hash value determinations
FR2838590B1 (en) * 2002-04-16 2005-12-30 St Microelectronics Sa ROUTING METHOD FOR A TELECOMMUNICATION NETWORK AND ROUTER FOR IMPLEMENTING SAID METHOD
US20060041734A1 (en) * 2002-07-01 2006-02-23 Lim Swee H Associating mac addresses with addresses in a look-up table
US7298740B2 (en) * 2002-07-11 2007-11-20 Sprint Communications Company L.P. Centralized service control for a telecommunication system
US7877504B2 (en) 2002-08-29 2011-01-25 Intel Corporation Techniques for entry lookups

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5206856A (en) * 1989-12-27 1993-04-27 Bell Communications Research, Inc. Routing of network traffic
US5365520A (en) * 1992-03-27 1994-11-15 Motorola, Inc. Dynamic signal routing

Also Published As

Publication number Publication date
EP1020053A2 (en) 2000-07-19
WO1999013620A3 (en) 1999-06-03
SE9703293D0 (en) 1997-09-09
WO1999013620A2 (en) 1999-03-18
SE9703293L (en) 1999-03-10
AU9192698A (en) 1999-03-29
SE511971C2 (en) 2000-01-10

Similar Documents

Publication Publication Date Title
US7079537B1 (en) Layer 3 switching logic architecture in an integrated network switch
US6052683A (en) Address lookup in packet data communication networks
US6674769B1 (en) Simultaneous searching of layer 3 policy filter and policy cache in a network switch port
Lakshman et al. High-speed policy-based packet forwarding using efficient multi-dimensional range matching
US20150023351A1 (en) Method and apparatus for performing link aggregation
Panigrahy et al. Reducing TCAM power consumption and increasing throughput
US9704574B1 (en) Method and apparatus for pattern matching
US7327727B2 (en) Atomic lookup rule set transition
US20050171937A1 (en) Memory efficient hashing algorithm
US20010056417A1 (en) Method and apparatus for performing a binary search on an expanded tree
Huang et al. Design of multi-field IPv6 packet classifiers using ternary CAMs
US6343078B1 (en) Compression of forwarding decisions in a network device
CA2303261A1 (en) A lookup device and a method for classification and forwarding of packets in packet-switched networks
US8798066B2 (en) Method for IPv6 longest prefix match
Moestedt et al. IP address lookup in hardware for high-speed routing
WO2020144655A1 (en) Exact match and ternary content addressable memory (tcam) hybrid lookup for network device
Veeramani et al. Minimization of flow table for TCAM based openflow switches by virtual compression approach
US6591317B1 (en) Queue incorporating a duplicate counter per entry
US20050114393A1 (en) Dynamic forwarding method using binary search
CA2302744A1 (en) A lookup device and a method for classification and forwarding of packets
Perez et al. Memory cost analysis for OpenFlow multiple table lookup
Liu IP Lookup in IPv6 Networks
Sun et al. A highly deterministic hashing scheme using bitmap filter for high speed networking
Lim et al. High-speed IP address lookup using balanced multi-way trees
Ke et al. The analysis and design of fast route lookup algorithms for high performance router

Legal Events

Date Code Title Description
FZDE Discontinued