Counter Braids: A novel counter architecture
Joint work with:
Counter Braids: A novel counter architecture Balaji Prabhakar - - PowerPoint PPT Presentation
Counter Braids: A novel counter architecture Balaji Prabhakar Balaji Prabhakar Stanford University Joint work with: Yi Lu, Andrea Montanari , Sarang Dharmapurikar and Abdul Kabbani Overview Counter Braids Background: current
Joint work with:
2
3
– Accounting/billing, traffic engineering, security/forensics – Several products in this area; notably, Cisco’s NetFlow, Juniper’s cflowd, Huawei’s NetStream
– In databases: number and count of distinct items in streams – Web server logs
– 500,000+ active flows, packets arrive once every 10 ns on 40 Gbps line – We need fast and large memories for implementing counters: v.expensive
– Exact, per-flow accounting: Use hybrid SRAM-DRAM architecture – Approximate, large-flow accounting: Use heavy-tailed nature of flow size distribution
4
F1 F2 Fn 43 4 15 LSB MSB 44 4 15 LSB MSB
5
– LSBs in SRAM: high-speed updates, on-chip – MSBs in DRAM: less frequent updates; can use slower speed, off-chip DRAMs F1 Fl2 Fn 35 4 15 SRAM DRAM Interconnect
Counter Mgmt Algorithm
– Line speed = SRAM speed = L; Interconnect speed = DRAM speed = L/S – Adversarial packet arrival process
1. The counter management algorithm Longest Counter First is optimal 2.
6
SRAM DRAM Interconnect
CMA
SRAM FIFO F1 Fl2 Fn
7
Packets off of the wire Yes No Counter Array
8
9
– By “braiding” the counters
– By using multiple hash functions and a “decoder”
1 2 35 3 1 LSBs Shared MSBs
10
1 2 35 4 2 1 2 35 3 2 1 2 35 4 2 1 2 35 4 2 1 2 35 4 2 1 2 35 4 2
11
12
1 2 35 3 3 40 3 1 5 1 2 35 3 2 6 36 3 45 5
13
14
1 2 35 3 2 6 36 3 45 5
15
messages from flow’s other than i
messages from counters other than a
16
17
Flow index Flow size
18
19
20
21
second stage; an “overflow” status bit
counter has overflowed to the second stage
resets and counts again; second stage counters track most significant bits
22
23
Entropy
24
25
Medium: 1.090% Small: 43.87%
26
Stanford University
Cisco Systems
28
29
30