Copyright notice © 2008 Raul Jimenez - -

Slides:



Advertisements
Similar presentations
Peer to Peer and Distributed Hash Tables
Advertisements

Session d2, 22 October 2008 eChallenges e-2008 Raul Jimenez and Björn Knutsson, KTH Copyright notice © 2008 Raul Jimenez - -
Kademlia: A Peer-to-peer Information System Based on the XOR Metric Petar Mayamounkov David Mazières A few slides are taken from the authors’ original.
Chapter 2 Application Layer Computer Networking: A Top Down Approach, 5 th edition. Jim Kurose, Keith Ross Addison-Wesley, April A note on the use.
NAT/Firewall Traversal April NAT revisited – “port-translating NAT”
STUN Date: Speaker: Hui-Hsiung Chung 1.
Voice over IP Skype.
DDoS Vulnerability Analysis of BitTorrent Protocol CS239 project Spring 2006.
1 Spring Semester 2007, Dept. of Computer Science, Technion Internet Networking recitation #12 LSNAT - Load Sharing NAT (RFC 2391)
1 IP Forwarding Relates to Lab 3. Covers the principles of end-to-end datagram delivery in IP networks.
The Bittorrent Protocol
P2P File Sharing Systems
INTRODUCTION TO PEER TO PEER NETWORKS Z.M. Joseph CSE 6392 – DB Exploration Spring 2006 CSE, UT Arlington.
1 Napster & Gnutella An Overview. 2 About Napster Distributed application allowing users to search and exchange MP3 files. Written by Shawn Fanning in.
Introduction Widespread unstructured P2P network
Network Layer (3). Node lookup in p2p networks Section in the textbook. In a p2p network, each node may provide some kind of service for other.
By Shobana Padmanabhan Sep 12, 2007 CSE 473 Class #4: P2P Section 2.6 of textbook (some pictures here are from the book)
PPSP Tracker Protocol draft-gu-ppsp-tracker-protocol PPSP WG IETF 82 Taipei Rui Cruz (presenter) Mário Nunes, Yingjie Gu, Jinwei Xia, David Bryan, João.
BitTorrent How it applies to networking. What is BitTorrent P2P file sharing protocol Allows users to distribute large amounts of data without placing.
Distributed Systems Concepts and Design Chapter 10: Peer-to-Peer Systems Bruce Hammer, Steve Wallis, Raymond Ho.
STUN - Simple Traversal of User Datagram Protocol (UDP) Through Network Address Translators (NATs) speaker : Wenping Zhang date :
Introduction of P2P systems
1 BitHoc: BitTorrent for wireless ad hoc networks Jointly with: Chadi Barakat Jayeoung Choi Anwar Al Hamra Thierry Turletti EPI PLANETE 28/02/2008 MAESTRO/PLANETE.
Chapter 2: Application layer
2: Application Layer1 Chapter 2: Application layer r 2.1 Principles of network applications r 2.2 Web and HTTP r 2.3 FTP r 2.4 Electronic Mail  SMTP,
 A P2P IRC Network Built on Top of the Kademlia Distributed Hash Table.
11/10/20151 A Standalone Content Sharing Application for Spontaneous Communities of Mobile Handhelds Authors: Amir Krifa –
Modifying a shareable resource: a demo for librarians. This is based on: Open Access and Free Collections in OutLook OnLine: A Demonstration, Open Medicine.
1 Distributed Hash Tables (DHTs) Lars Jørgen Lillehovde Jo Grimstad Bang Distributed Hash Tables (DHTs)
Hongil Kim E. Chan-Tin, P. Wang, J. Tyra, T. Malchow, D. Foo Kune, N. Hopper, Y. Kim, "Attacking the Kad Network - Real World Evaluation and High.
Network Computing Laboratory Scalable File Sharing System Using Distributed Hash Table Idea Proposal April 14, 2005 Presentation by Jaesun Han.
PPSP NAT traversal Lichun Li, Jun Wang, Wei Chen {li.lichun1, draft-li-ppsp-nat-traversal-02.
2: Application Layer1 Chapter 2: Application layer r 2.1 Principles of network applications  app architectures  app requirements r 2.2 Web and HTTP r.
Kaleidoscope – Adding Colors to Kademlia Gil Einziger, Roy Friedman, Eyal Kibbar Computer Science, Technion 1.
1 Peer-to-Peer Technologies Seminar by: Kunal Goswami (05IT6006) School of Information Technology Guided by: Prof. C.R.Mandal, School of Information Technology.
Experience Sharing in Mobile Peer Communities EPI Planete, INRIA International Consortium Meeting (Oulou) 10 June, 2009.
Open Access and Free Collections in OutLook OnLine: A Demonstration Open Medicine example Heather Morrison, BC ELN.
Peer to Peer Network Design Discovery and Routing algorithms
COS 420 Day 15. Agenda Finish Individualized Project Presentations on Thrusday Have Grading sheets to me by Friday Group Project Discussion Goals & Timelines.
Algorithms and Techniques in Structured Scalable Peer-to-Peer Networks
Click to edit Master title style Multi-Destination Routing and the Design of Peer-to-Peer Overlays Authors John Buford Panasonic Princeton Lab, USA. Alan.
CS Spring 2014 CS 414 – Multimedia Systems Design Lecture 37 – Introduction to P2P (Part 1) Klara Nahrstedt.
Bit Torrent Nirav A. Vasa. Topics What is BitTorrent? Related Terms How BitTorrent works Steps involved in the working Advantages and Disadvantages.
2-Hop TorrentSmell A distributed tracking algorithm name:Raynor Vliegendhart date:July 10, 2009 event:Tribler Dev Meeting.
INTERNET TECHNOLOGIES Week 10 Peer to Peer Paradigm 1.
CS 347Notes081 CS 347: Parallel and Distributed Data Management Notes 08: P2P Systems.
PEAR TO PEAR PROTOCOL. Pure P2P architecture no always-on server arbitrary end systems directly communicate peers are intermittently connected and change.
KYUNG-HWA KIM HENNING SCHULZRINNE 12/09/2008 INTERNET REAL-TIME LAB, COLUMBIA UNIVERSITY DYSWIS.
NGMAST Mobile DHT Energy1 Optimizing Energy Consumption of Mobile Nodes in Heterogeneous Kademlia-based Distributed Hash Tables Imre Kelényi Budapest.
Chapter 29 Peer-to-Peer Paradigm Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
CS Spring 2010 CS 414 – Multimedia Systems Design Lecture 24 – Introduction to Peer-to-Peer (P2P) Systems Klara Nahrstedt (presented by Long Vu)
Lecture XV: Real P2P Systems
NAT (Network Address Translation)
An example of peer-to-peer application
Decentralized peer discovery performance in swarm-protocols
Decentralized peer discovery performance in swarm-protocols
Copyright notice © 2008 Raul Jimenez - -
CHAPTER 3 Architectures for Distributed Systems
OneSwarm: Privacy Preserving P2P
Part 4: Peer to Peer - P2P Applications
TITLE PowerPoint project PowerPoint USA flag template.
Networking and Network Protocols (Part2)
IP Forwarding Relates to Lab 3.
DNSR: Domain Name Suffix-based Routing in Overlay Networks
Request for Comments(RFC) 3489
Consistent Hashing and Distributed Hash Table
Kademlia: A Peer-to-peer Information System Based on the XOR Metric
#02 Peer to Peer Networking
Presentation transcript:

Copyright notice © 2008 Raul Jimenez - rauljc@kth.se - http://tslab.ssvl.kth.se/raul/ This work is licensed under the Creative Commons Attribution 2.5 Sweden License. To view a copy of this license, visit http://creativecommons.org/licenses/by/2.5/se/deed.en or send a letter to Creative Commons, 171 Second Street, Suite 300, San Francisco, California, 94105, USA. Copy, distribution, and reuse of this work is permitted, so long as the redistributed copy displays a link to http://tslab.ssvl.kth.se/raul/. The logos displayed on the title page belong to KTH and the P2P-Next consortium, respectively. The snapshot displayed on slide 4 is part of the animation movie “elephants dream” (http://orange.blender.org/media-gallery) The figure displayed on slide 21 is part of the technical report referenced on slide 22. Although not mandatory, the author would be glad to hear from those who find this material useful. Of course, any comment which could complement and/or improve this work is very welcome.

Decentralized peer discovery performance in swarm-protocols Raul Jimenez KTH, Sweden rauljc@kth.se tslab.ssvl.kth.se/raul

Overview BitTorrent Content Discovery Data Exchange Peer Discovery Centralized Tracker Decentralized Tracker (DHT) Gossiping (PEX) DHT Issues NAT effects Experiments

Go to a search engine (e.g. legaltorrents.org) BitTorrent CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments BitTorrent Content Discovery Data Exchange Peer Discovery blender_foundation_-_ elephants_dream.torrent info_hash: c70bcf4657cac1253d12 acda95b04d1e4dcd23f4 Tracker (updated list of peers): http://tracker001.legaltorrents.com: 7070/announce 123.11.22.33 2223 234.22.11.22 3227 178.98.237.83 19033 231.187.99.123 6227 Go to a search engine (e.g. legaltorrents.org) Type “elephants dream” Download .torrent file

Decentralized Tracker (DHT) Gossiping (PEX) BitTorrent BitTorrent CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments Content Discovery Data Exchange Peer Discovery Centralized Tracker Decentralized Tracker (DHT) Gossiping (PEX) A tracker keeps track of every peer participating in the swarm Gossiping protocol Disconnected graphs Messages between peers Needs bootstrap Complements tracker

Centralized Tracker 1 P1 announces Tracker tracks P1 BitTorrent Centralized Tracker CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments 1 tracker.kth.se peers: 1 P1 announces Tracker tracks P1 Tracker returns list

Centralized Tracker 1 2 P2 announces Tracker tracks P2 BitTorrent Centralized Tracker CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments 1 tracker.kth.se 2 peers: 1 2 P2 announces Tracker tracks P2 Tracker returns list P2 contacts peers

Centralized Tracker 1 2 P3 announces Tracker tracks P3 3 BitTorrent Centralized Tracker CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments 1 tracker.kth.se 2 peers: 1 2 3 P3 announces Tracker tracks P3 3 Tracker returns list P3 contacts peers

Decentralized Tracker (DHT) Gossiping (PEX) BitTorrent BitTorrent CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments Content Discovery Data Exchange Peer Discovery Centralized Tracker Decentralized Tracker (DHT) Gossiping (PEX) DHT Issues NAT effects Experiments Lookup times Dead-end lookups NAT behavior NAT types Effects on the DHT Measuring reachability with different methods

Distributed Tracker Distributed Hash Table BitTorrent Distributed Tracker Distributed Hash Table CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments Kademlia DHT (Mainline implementation) Totally decentralized - bootstrap? O(Log(n)) routing table size O(Log(n)) hops to find the list of peers Iterative routing algorithm Tracks every peer in the BitTorrent swarm

Distributed Hash Table (DHT) BitTorrent Distributed Hash Table (DHT) CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments Simple demo 4-bits identifiers (24 = 16 identifiers) 1 node per bucket 10 nodes Real world 160-bit identifiers 8 nodes per bucket 1 million nodes ?

DHT: Routing Table Routing table Level 0 Level 1 Level 2 Level 3 BitTorrent DHT: Routing Table CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments Routing table Level 0 Level 1 Level 2 Level 3 MyNode 1001

DHT: Routing Table 1xxx 0xxx Routing table Level 0 0010 Level 1 BitTorrent DHT: Routing Table CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments 1xxx 0xxx Routing table Level 0 0010 Level 1 Level 2 Level 3 MyNode 1001

DHT: Routing Table 11xx 00xx Routing table 10xx 01xx Level 0 0010 BitTorrent DHT: Routing Table CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments 11xx 00xx Routing table 10xx 01xx Level 0 0010 Level 1 1111 Level 2 Level 3 MyNode 1001

DHT: Routing Table 111x 000x 110x 001x 101x 010x Routing table Level 0 BitTorrent DHT: Routing Table CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments 111x 000x 110x 001x 101x 010x Routing table Level 0 0010 Level 1 1111 100x 011x Level 2 1011 Level 3 MyNode 1001

DHT: Routing Table 111x 000x 110x 001x 101x 010x Routing table Level 0 BitTorrent DHT: Routing Table CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments 111x 000x 110x 001x 101x 010x Routing table Level 0 0010 Level 1 1111 1001 011x Level 2 1011 1000 Level 3 ------ MyNode 1001

DHT: Find Peers 1xxx 0xxx Level 0 0010 0101 torrentID Level 1 1111 BitTorrent DHT: Find Peers CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments 1xxx 0xxx Level 0 0010 0101 torrentID Level 1 1111 Level 2 1011 Level 3 MyNode 1001

DHT: Find Peers Level 0 1001 Level 1 0110 Level 2 0000 11xx 00xx BitTorrent DHT: Find Peers CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments Level 0 1001 Level 1 0110 Level 2 0000 11xx 00xx Level 3 0011 10xx 01xx 0101 torrentID MyNode 1001

DHT: Find Peers 111x 000x 110x 001x 101x 010x 0101 torrentID 100x 011x BitTorrent DHT: Find Peers CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments 111x 000x 110x 001x 101x 010x 0101 torrentID 100x 011x Level 0 1101 Level 1 0000 MyNode 1001 Level 2 0100 Level 3

DHT: Find Peers 111x 000x 110x 001x Level 0 1100 101x 010x Level 1 BitTorrent DHT: Find Peers CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments 111x 000x 110x 001x Level 0 1100 101x 010x Level 1 0011 Level 2 0110 Level 3 0101 0101 torrentID 100x 011x MyNode 1001

DHT Issues Long lookup times (around a minute) BitTorrent DHT Issues CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments Long lookup times (around a minute) Especially long at the end of the lookup

Reported causes 20% dead nodes in 95% of the lookups BitTorrent Reported causes CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments 20% dead nodes in 95% of the lookups Too many dead nodes in the routing table: Levels 0-15: 15% dead nodes Levels 15-18: 65% dead nodes 57% of the nodes suffer “infant mortality” Reference: Scott A Crosby and Dan S Wallach An Analysis of BitTorrent's Two Kademlia-Based DHTs Technical Report TR-07-04, Department of Computer Science, Rice University, June 2007

Are reachability issues (most likely caused by NAT boxes) BitTorrent CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments Are reachability issues (most likely caused by NAT boxes) the main cause of BitTorrent's poor DHT performance?

Network Address Translation (NAT) BitTorrent Network Address Translation (NAT) CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments NAT open partially open NAT temporarily open NAT timeout, or full table, or ...

NAT types Match IP and port (symmetric) IP2:2222 IP1:1111 IP1:9999 BitTorrent NAT types CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments Match IP and port (symmetric) IP2:2222 IP1:1111 IP1:9999 IP3:3333

NAT types Match IP and port (symmetric) BitTorrent NAT types CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments Match IP and port (symmetric) Match only IP (restricted cone) IP2:2222 IP1:1111 IP1:9999 IP3:3333

NAT types Match IP and port (symmetric) BitTorrent NAT types CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments Match IP and port (symmetric) Match only IP (restricted cone) Match any connection (full cone) IP2:2222 IP1:1111 IP1:9999 IP3:3333 Reference: RFC3489 STUN - Simple Traversal of User Datagram Protocol (UDP) Through Network Address Translators (NATs)

? NAT types Match IP and port Match only IP Match any connection ... BitTorrent NAT types CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments Match IP and port Match only IP Match any connection ... IP2:2222 IP1:1111 ? IP1:9999 IP3:3333

BitTorrent 1 Peer discovery No peers to contact tracker.kth.se peers: CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments 1 tracker.kth.se peers: 1 Peer discovery No peers to contact

BitTorrent 1 2 Peer discovery P2 contacts P1 tracker.kth.se peers: 1 2 CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments 1 tracker.kth.se 2 peers: 1 2 Peer discovery P2 contacts P1

BitTorrent 1 2 Peer discovery P3 contacts P1 3 P3 contacts P2 CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments 1 tracker.kth.se 2 peers: 1 2 3 Peer discovery P3 contacts P1 3 P3 contacts P2

BitTorrent 1 4 2 Peer discovery P4 contacts P1 3 P4 contacts P2 CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments 1 4 tracker.kth.se 2 peers: 1 2 3 4 Peer discovery P4 contacts P1 3 P4 contacts P2 P4 contacts P3

Temporal and partial reachability in DHT BitTorrent Temporal and partial reachability in DHT CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments Higher (apparent) churn Broken routes

Higher (apparent) churn BitTorrent Higher (apparent) churn CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments Churn rate: number of nodes joining and leaving the DHT during a given period. A new node joins Check reachability Level x N2 Add to the routing table 1 2 Dead node (remove) A new node joins ...

Broken routes Node 1 finds node 2 N1 checks N2's reachability BitTorrent Broken routes CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments Node 1 finds node 2 Level x N2 N1 checks N2's reachability N1 adds N2 to routing table 1 2 N3 sends message to N1 N2 is the next hop N2 is unreachable from N3 3

Experiments 3 PCs running DHT and local 1 PC running remote 129 496 nodes checked DHT local remote

Experiments Check candidate node's reachability BitTorrent Experiments CD PD DEX Tracker DHT PEX DHT Issues NAT Experiments Check candidate node's reachability from the DHT (same IP, same port) opening a new connection (same IP, different port) from another host (different IP) 33% U 61% U 63% U

What to do? Prevent my routing table from pollution Check for global reachability before adding a node Don't pollute others' routing tables When I'm aware of being partially reachable, tell others: “don't add me to your routing table” Free riders?

Thank you!