packet classification using tuple space search author: v. srinivasan, s. suri, g. vargheset...
TRANSCRIPT
Packet Classification using Tuple Space Search
Author: V. Srinivasan, S. Suri, G. VarghesetPublisher: ACM SIGCOMM 1999Presenter: Sih-An PanDate: 2013/11/27
Tuple Space Search Our scheme is motivated by the observation that
while filter databases contain many different prefixes or ranges, the number of distinct prefix lengths tends to be small.
Suppose we have a filter database FD with N filters, and these filters result in m distinct tuples.
Since m tends to be much smaller than N in practice, even a linear search through the tuple set is likely to greatly outperform the linear search through the filter database.
Tuple Space Search We can define a tuple for each combination of
field length, and call the resulting set tuple space. By concatenating these bits in order we can
create a hash key, which can then be used to map filters of that tuple into a hash table.
Rule Specification Tuple
R1 (00*,001*) (2,3)
R2 (0000,0*) (4,1)
R3 (*,1111) (0,4)
R4 (0000,0111) (4,4)
R5 (111*,11*) (3,2)
R6 (*,*) (0,0)
R7 (011*,01*) (3,2)
Tuple Hash Table Entries
(0,0) {R6}
(0,4) {R3}
(2,3) {R1}
(3,2) {R5,R7}
(4,1) {R2}
(4,4) {R4}
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
0
0 1
0 1 2 3
Tuple Space Search The port numbers, however, are often specified
using ranges, and the number of bits specified is not clear.
To get around this, we define the length of a port range to be its nesting level.
Rule Specification Tuple
R1 (00*,001*,[0,15]) (2,3,0)
R2 (0000,0*,[6,7]) (4,1,2)
R3 (*,1111,[8,8]) (0,4,2)
R4 (0000,0111,[0,7]) (4,4,1)
R5 (111*,11*,[10,13]) (3,2,2)
R6 (*,*,[8,16]) (0,0,1)
R7 (011*,01*,[4,4]) (3,2,2)
RangeIDLevel
0
1
2
Tuple Pruning Algorithm
[0,0][0,4]
[2,3]
[3,2] [3,2]
[4,1][4,4]
[0,0]
[2,3]
[3,2] [3,2]
[4,1]
[4,4] [0,4]
Packet = {0000, 01*}
Source Trie Destination Trie
Source Tuple List = {[0,0], [0,4], [2,3], [4,1], [4,4]}Destination Tuple List = {[0,0], [4,1], [3,2]}Intersected Tuple List = {[0,0], [4,1]}
Tuple Pruning Algorithm
Markers and Precomputation Consider a tuple = [, , . . . , ]. = [, , . . . , ] belongs to set Short () if and only if
,for all = ,and = [, , . . . , ] belongs to set Long () if and only
if ,for all = ,and A tuple , where , that is neither in Short()nor in
Long() belongs to the incomparable set IC().
Markers and Precomputation
Source IP Length
Des
tinati
on IP
Len
gth T
Short(T)
Long(T)
IC(T)
The main idea is that a probe into a tuple can be used to eliminate a subset of the tuple space.
Markers
Des
tinatio
n IP
Len
gth
Source IP Length
R5(111*,11*) M5(111*,1*) M5(111*,*)
R1(00*,001*) M1(00*,00*) M1(00*,0*) M1(00*,*)
Precomputation
Des
tinat
ion
IP L
engt
h
Source IP Length
R5(111*,11*) M5(111*,1*) M5(111*,*,R6)
R6(*,*)
Rectangle Search The search terminates when the we reach therightmost column or the first row. Since there are Wrows and W columns, the number of probes needed is at most 2W - 1
Rectangle Search
Des
tinat
ion
IP L
engt
h
Source IP Length
R2(0000,0*) M4(0000,0*)
R4(0000,0111) M4(0000,01*) M4(0000,011*) M2(0000,*,R6) M4(0000,*,R6)
R5(111*,11*) M5(111*,1*) M5(111*,*,R6)
M1(00*,0*) M1(00*,*,R6)
M3(*,1*) M3(*,11*) R6(*,*) M3(*,*)
M3(*,111*) R3(*,1111)
M1(00*,00*) R1(00*,001*)
P(0000,0000)
Storage Efficiency
Throughput (Worst Case)
Throughput (Avg. Case)