1 memory-efficient 5d packet classification at 40 gbps authors: ioannis papaefstathiou, and vassilis...

28
1 Memory-Efficient 5D Pa cket Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter: Yu-Tso Chen Date: July, 09, 2008

Post on 20-Dec-2015

213 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

1

Memory-Efficient 5D Packet Classification At 40 Gbps

Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou

Publisher: IEEE INFOCOM 2007

Presenter: Yu-Tso Chen

Date: July, 09, 2008

Page 2: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

2

Outline

• Introduction

• BSPC Design

• Simulation Results

Page 3: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

3

Introduction

• Should support the current state-of-art networking speeds – (i.e. OC-768 at 40Gpbs)– Should not be prohibitively expensive

• Decomposing multi-field classification rules into internal single-field rules– Combined using multi-level Bloom filters

• B2PC uses the BOS single field searching scheme[11]

Page 4: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

4

BSPC Design

• Observations– Filter sets’ sizes are small

• Ranging from tens of filters to less than 5000

– Protocol field is restricted to a small set of values• TCP, UDP, and commonly used wildcards (covering

more 95%)

– Filter specify a limited number of unique transport port range

Page 5: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

5

BSPC Design

• Observations (cont.)– The number of single field filters matching a given

packet is typically five or less– The number of single field values is significantly

less than the number of overall filters

Page 6: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

6

Overall Architecture of B2PC

TableII type

12bit flowID

BLH1-4

HSH_TBLindex

IP_BLH1-2

PR_BLH1-2

TreeBitmap 256-entry directly index

Page 7: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

7

Hash Function

BLH1 = (SIP>>4) xor REV(DIP>>2) xor (SPO<<4) xor(DPO>>3) xor (PRO<<3)BLH2 = SIP xor (DIP<<6) xor (SPO>>2) xor REV(DPO) xor PROBLH3 = (SIP<<3) xor REV(DIP) xor REV(SPO) xorDPO xor (PRO<<6)BLH4 = REV(SIP) xor (DIP<<3) xor (SPO>>3) xor(DPO<<1) xor (PRO>>2)

HSH_TBLindex = (BLH1,00) xor (00,BLH2>>4) xor(00,BLH3) xor (00,REV(BLH4))

IP_BLH1 = { SIP(6:11) xor DIP(0:5) , SIP(0:5) xor DIP(6:11) }IP_BLH2 = { SIP(0:5) xor DIP(6:11) , SIP(6:11) xor DIP(0:5) }PR_BLH1 = SPO xor (DPO<<2)PR_BLH2 = (SPO<<2) xor REV(DPO)

Page 8: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

8

Internally Represented Filters

• In order to reduce the memory we take advantage of the fact that many rules share the same field values.

• Side-effect of ID sharing scheme is that a certain internal-ID cannot be deleted unless all the rules employing it are deleted.– Keep a reference count for each internal ID– We need 4K 12-bit counters for each field– Total we need 5 x 4096 12-bit counters

Page 9: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

9

Example Filter Set

Page 10: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

10

Internal Representation of The Example Filter Set

Page 11: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

11

Combining Results

• Number of matching prefixes and the associated IDs– Prefix-based at most 33 matches each– Port fields may provide at most 17 matches– Protocol at most 2 matches

• Match on the value itself or the wildcard

Page 12: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

12

Incoming Packet Header Fields

Decreasing length order

Real-world less than five

Totalperm= 3*2*1*3*2 = 36

Page 13: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

13

Set Membership Queries with Bloom Filters

• How to identify that a permutation belongs to the given set of rules– Sequential access to the rule table is slow

– Efficiently represent a given ruleset and support quick set membership queries is need

• The main advantage of Bloom Filters– Easily be implemented in hardware while supporting set-m

embership queries at high rates

• Disadvantage of bloom filters– False-positive error

Page 14: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

14

Set Membership Queries with Bloom Filters (cont.)

• Parameters of bloom filters– Bit vector is 214 bits wide– The optimal number of hashing functions that set

this vector is 4– Theoretical false positive probability of 6.2%

• Efficiently support incremental updates– Counting Bloom Filters

Page 15: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

15

Flow ID Resolving

• A match in a set-membership query we should first determine whether it is a false positive

• To locate the FlowID we use HSH_TBL of 16k entries

• Have the FlowID we access the RULE_TBL, and compare the stored IDs with the IDs of the current permutation– All IDs match, we have found the final result

Page 16: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

16

Improving the Efficiency of Set Membership Query

• To avoid these useless queries we have used two additional Bloom Filters

• If they both provide a match then we query the “Main” Bloom Filter

Page 17: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

17

Parallel Bloom Filter Queries

Page 18: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

18

Number of References in Bloom Filters

Page 19: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

19

Observed False Positives Rate

Page 20: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

20

Hash Table Collisions (HSH_TBLindex)

Page 21: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

21

B2PC Components Memory Requirements

36-bit wide memory word

Page 22: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

22

Total Number of Average Memory Accesses in B2PC

Page 23: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

23

Worst Case Network Performance of B2PC (40 Bytes packets)

Page 24: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

24

Summary of Classification Schemes

Page 25: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

25

Bloom Filter

Page 26: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

26

Mask

Page 27: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

27

Number of Memory Access in P2BC Data Structures

Page 28: 1 Memory-Efficient 5D Packet Classification At 40 Gbps Authors: Ioannis Papaefstathiou, and Vassilis Papaefstathiou Publisher: IEEE INFOCOM 2007 Presenter:

28

B2PC Silicon Cost