IP Routing Lookups Scalable High Speed IP Routing Lookups.

Slides:



Advertisements
Similar presentations
February 12, 2007 WALCOM '2007 1/22 DiskTrie: An Efficient Data Structure Using Flash Memory for Mobile Devices N. M. Mosharaf Kabir Chowdhury Md. Mostofa.
Advertisements

A Search Memory Substrate for High Throughput and Low Power Packet Processing Sangyeun Cho, Michel Hanna and Rami Melhem Dept. of Computer Science University.
August 17, 2000 Hot Interconnects 8 Devavrat Shah and Pankaj Gupta
Router/Classifier/Firewall Tables Set of rules—(F,A)  F is a filter Source and destination addresses. Port number and protocol. Time of day.  A is an.
Internet Routers
Spring 2006CS 685 Network Algorithmics1 Longest Prefix Matching Trie-based Techniques CS 685 Network Algorithmics Spring 2006.
1 IP-Lookup and Packet Classification Advanced Algorithms & Data Structures Lecture Theme 08 – Part I Prof. Dr. Th. Ottmann Summer Semester 2006.
A Scalable and Reconfigurable Search Memory Substrate for High Throughput Packet Processing Sangyeun Cho and Rami Melhem Dept. of Computer Science University.
Network Algorithms, Lecture 4: Longest Matching Prefix Lookups George Varghese.
An On-Chip IP Address Lookup Algorithm Author: Xuehong Sun and Yiqiang Q. Zhao Publisher: IEEE TRANSACTIONS ON COMPUTERS, 2005 Presenter: Yu Hao, Tseng.
1 An Efficient, Hardware-based Multi-Hash Scheme for High Speed IP Lookup Hot Interconnects 2008 Socrates Demetriades, Michel Hanna, Sangyeun Cho and Rami.
Fast Firewall Implementation for Software and Hardware-based Routers Lili Qiu, Microsoft Research George Varghese, UCSD Subhash Suri, UCSB 9 th International.
Bio Michel Hanna M.S. in E.E., Cairo University, Egypt B.S. in E.E., Cairo University at Fayoum, Egypt Currently is a Ph.D. Student in Computer Engineering.
M. Waldvogel, G. Varghese, J. Turner, B. Plattner Presenter: Shulin You UNIVERSITY OF MASSACHUSETTS, AMHERST – Department of Electrical and Computer Engineering.
Data Compressor---Huffman Encoding and Decoding. Huffman Encoding Compression Typically, in files and messages, Each character requires 1 byte or 8 bits.
Tries Standard Tries Compressed Tries Suffix Tries.
Digital Search Trees & Binary Tries Analog of radix sort to searching. Keys are binary bit strings.  Fixed length – 0110, 0010, 1010,  Variable.
1 Author: Ioannis Sourdis, Sri Harsha Katamaneni Publisher: IEEE ASAP,2011 Presenter: Jia-Wei Yo Date: 2011/11/16 Longest prefix Match and Updates in Range.
A supernetwork.
IP Address Lookup for Internet Routers Using Balanced Binary Search with Prefix Vector Author: Hyesook Lim, Hyeong-gee Kim, Changhoon Publisher: IEEE TRANSACTIONS.
Higher Order Tries Key = Social Security Number.   9 decimal digits. 10-way trie (order 10 trie) Height
1 A Tree Based Router Search Engine Architecture With Single Port Memories Author: Baboescu, F.Baboescu, F. Tullsen, D.M. Rosu, G. Singh, S. Tullsen, D.M.Rosu,
Power Efficient IP Lookup with Supernode Caching Lu Peng, Wencheng Lu*, and Lide Duan Dept. of Electrical & Computer Engineering Louisiana State University.
Digital Search Trees & Binary Tries Analog of radix sort to searching. Keys are binary bit strings.  Fixed length – 0110, 0010, 1010,  Variable.
CS 268: Lectures 13/14 (Route Lookup and Packet Classification) Ion Stoica April 1/3, 2002.
Study of IP address lookup Schemes
1 A Fast IP Lookup Scheme for Longest-Matching Prefix Authors: Lih-Chyau Wuu, Shou-Yu Pin Reporter: Chen-Nien Tsai.
CS 268: Route Lookup and Packet Classification
Univ. of TehranAdv. topics in Computer Network1 Advanced topics in Computer Networks University of Tehran Dept. of EE and Computer Engineering By: Dr.
Fast binary and multiway prefix searches for pachet forwarding Author: Yeim-Kuan Chang Publisher: COMPUTER NETWORKS, Volume 51, Issue 3, pp , February.
Address Lookup in IP Routers. 2 Routing Table Lookup Routing Decision Forwarding Decision Forwarding Decision Routing Table Routing Table Routing Table.
Fast IP Address Lookup Algorithms 정 성 권 서울대학교 컴퓨터공학과
1 Efficient packet classification using TCAMs Authors: Derek Pao, Yiu Keung Li and Peng Zhou Publisher: Computer Networks 2006 Present: Chen-Yu Lin Date:
1 Route Table Partitioning and Load Balancing for Parallel Searching with TCAMs Department of Computer Science and Information Engineering National Cheng.
Indexing. Goals: Store large files Support multiple search keys Support efficient insert, delete, and range queries.
1 Routing with a clue Anat Bremler-Barr Joint work with Yehuda Afek & Sariel Har-Peled Tel-Aviv University.
PARALLEL TABLE LOOKUP FOR NEXT GENERATION INTERNET
IP Address Lookup Masoud Sabaei Assistant professor
LayeredTrees: Most Specific Prefix based Pipelined Design for On-Chip IP Address Lookups Author: Yeim-Kuau Chang, Fang-Chen Kuo, Han-Jhen Guo and Cheng-Chien.
Higher Order Tries Key = Social Security Number.   9 decimal digits. 10-way trie (order 10 trie) Height
IP Address Lookup Masoud Sabaei Assistant professor
1 Fast packet classification for two-dimensional conflict-free filters Department of Computer Science and Information Engineering National Cheng Kung University,
Scalable High Speed IP Routing Lookups Scalable High Speed IP Routing Lookups Authors: M. Waldvogel, G. Varghese, J. Turner, B. Plattner Presenter: Zhqi.
A Small IP Forwarding Table Using Hashing Yeim-Kuan Chang and Wen-Hsin Cheng Dept. of Computer Science and Information Engineering National Cheng Kung.
Efficient Cache Structures of IP Routers to Provide Policy-Based Services Graduate School of Engineering Osaka City University
Sets of Digital Data CSCI 2720 Fall 2005 Kraemer.
Memory-Efficient IPv4/v6 Lookup on FPGAs Using Distance-Bounded Path Compression Author: Hoang Le, Weirong Jiang and Viktor K. Prasanna Publisher: IEEE.
CS 740: Advanced Computer Networks IP Lookup and classification Supplemental material 02/05/2007.
Author: Haoyu Song, Murali Kodialam, Fang Hao and T.V. Lakshman Publisher/Conf. : IEEE International Conference on Network Protocols (ICNP), 2009 Speaker:
Lecture 9COMPSCI.220.FS.T Lower Bound for Sorting Complexity Each algorithm that sorts by comparing only pairs of elements must use at least 
Dynamic Pipelining: Making IP-Lookup Truly Scalable Jahangir Hasan T. N. Vijaykumar Presented by Sailesh Kumar.
Evaluating and Optimizing IP Lookup on Many Core Processors Author: Peng He, Hongtao Guan, Gaogang Xie and Kav´e Salamatian Publisher: International Conference.
DESIGN AND IMPLEMENTATION OF DYNAMIC ROUTING TABLES Author: Yeim-Kuan Chang and Dung-Jiun Lin Publisher/Conf.: The graduation paper of CIAL master student,
Ofir Luzon Supervisor: Prof. Michael Segal Longest Prefix Match For IP Lookup.
IP Address Lookup Masoud Sabaei Assistant professor Computer Engineering and Information Technology Department, Amirkabir University of Technology.
Behrouz A. Forouzan TCP/IP Protocol Suite, 3rd Ed.
Higher Order Tries Key = Social Security Number.
IP Routers – internal view
AN ON-CHIP IP ADDRESS LOOKUP ALGORITHM
Mark Redekopp David Kempe
Multiway range trees: scalable IP lookup with fast updates
Digital Search Trees & Binary Tries
Tree data structure.
Statistical Optimal Hash-based Longest Prefix Match
Tree data structure.
Indexing and Hashing Basic Concepts Ordered Indices
Digital Search Trees & Binary Tries
Packet Classification Using Coarse-Grained Tuple Spaces
Higher Order Tries Key = Social Security Number.
A Small and Fast IP Forwarding Table Using Hashing
Presentation transcript:

IP Routing Lookups Scalable High Speed IP Routing Lookups. Based on a paper by: Marcel Waldvogel, George Vaghese, Jon Turner, Bernhard Plattner.

Background and Motivation Rapidly growing Internet increases demands for high performance routing. Routing table lookup for a destination address is one of the key components of packet forwarding. Given IP address, find out the output link that is the best choice to reach this IP. Hierarchial IP address structure. BMP – Best matching prefix problem.

The Address Lookup Problem Address in a packet is compared to the stored prefixes starting from the left most bit. The longest prefix found is the desired match. The packet is forwarded to the specific next hop. Next hop field changes – topology, traffic. Set of prefixes changes rarely – inserting/removing network or host.

Address lookup using Tries 1 1 1 Existing prefixes: 000, 001, 010, 011, 100, 101, 11, 111 1 1 1 1 Prefixes stored in a binary trie Black nodes denote terminal nodes for prefixes. Remember the most recent black node. The search ends either in leaf or because of no matching branch to follow. Time Complexity W (= 32 for IPv4 and 128 for IPv6) memory accesses.

Liner Search of Hash Tables Organize prefixes into the hash tables by length. Start searching from the longest prefix size. W hash function computations in the worst case. W = maximal prefix length, 32 for IPv4.

Binary Search of Hash Tables. (Basic Scheme) Organize prefixes into the hash tables by length. Introduce markers. Remember the last found BMP to avoid backtracking. log2w hash function computations.

Binary Search of Hash Tables. Hash tables with markers Prefix length 1 P1=0 2 P1=00 11 00 3 P3=111 111 - Prefix 00 - Marker 11

Binary Search of Hash Tables. (Code) Binary_Search(D) // Search for address D Initialize search range R to cover the whole array L; Initialize BMP found so far to NULL; While R is not empty { Let i correspond to the middle level in range R; Extract the first L[i].length() bits of D into D’; M = Search(D’,L[i].hash); // search hash for D’ if (M == NULL) R = Upper half of R; // Not found else if (M is a prefix and not a marker) { BMP = M.bmp; break;} else { // M is a pure marker or a marker and a prefix BMP = M.bmp; // update the best matching prefix so far R = lower half of R; } End;

Mutating Binary Search Every match in the binary search with some marker X means that we need only search among the set of prefixes for which X is a prefix. BS mutates (changes) the levels on which it searches dynamically (in a way that always reduces the level to be searched) as it gets more match information. Average number of memory lookups is 2 for IPv4 (32 bit) Root New Trie on failure m = median length among all prefix lengths in trie X New Trie on match (first m bits of Prefix = X)

Mutating Binary Search (example:) Prefix length Mutating search trees Hash Tables 16 E: …, Tree2 17 18 19 F: ...111, Tree3 H: ...101, Tree4 20 J: …1010, End 21 G: …11100, End H: ...101, Tree4 22 23 24 Hash entry structure: Node_Name: Prefix(… stands for E), Tree to use from now on

Mutating Binary Search: Advantages / Disadvantages Faster average lookup time. Disadvantages: Increased new prefix insertion time. Increased storage requirements for optimal binary search trees family.

Mutating Binary Search: How to reduce the storage needed? On match we use the new tree On miss we use only the upper part of the current tree We never use more then a single rope like branch from any specific tree. So we can store ropes instead of binary trees

Ropes of a sub tree – the sequence of levels which binary search will follow on repeated failures. Example: Prefix length Mutating search trees Hash Tables 16 E: …, Tree2 17 18 19 F: ...111, Tree3 H: ...101, Tree4 20 J: …1010, End 21 G: …11100, End H: ...101, Tree4 22 23 24

Rope Variation of Mutating Binary Search Search for address D: Rope Search(D) { R default search sequence BMP NULL While R is not empty { i first pointer found in R D’ first L[i].length() bits of D M Search(D’,L[i].hash) // search hash for D’ if (M != NULL) { BMP M.bmp //update the best matching prefix so far R M.rope //get the new Rope, possibly empty }

Possible variations Arrays usage instead of hash tables for the initial prefix lookup. Space time tradeoff : wo prefix length for which array is used (wo=16) 2Wo space used (216) Hardware implementations. Rope search algorithm is simple Can be pipelined

Mutating Binary Search: Implementation: Precomputations – building the rope search data structure optimized for a given prefix set. Insertions/deletions result in performance degradation

Conclusions: Simple Binary search algorithm reduce number of memory accesses from W to log 2W. Where w = number of bits in the IP address. (5 = log 232 hash computations for IPv4) Mutating Binary search algorithm further reduce the average case hash computations number to 2. The DS initialization takes O(sum of prefix lengths)

Practical Measurements: Practical measurements made on 200 MHz Pentium Pro, C using compiler max. optimizations on table with 33,000 entries about 80ns for IPv4 about 150-200ns for IPv6

Generalized Level Compressed Tries. Definition – Tries with n levels compressed into the hash tables. Time complexity optimization problem under memory constrains. To be presented the next lecture.