1 / 21

Class #4: P2P Section 2.6 of textbook (some pictures here are from the book)

By Shobana Padmanabhan Sep 12, 2007 CSE 473. Class #4: P2P Section 2.6 of textbook (some pictures here are from the book). Recap. Links Packet switched networks Store-and-forward routing Delays d prop = distance/ propagation speed d tran = L /R = packet size/ capacity d q d proc

Download Presentation

Class #4: P2P Section 2.6 of textbook (some pictures here are from the book)

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. By Shobana Padmanabhan Sep 12, 2007 CSE 473 Class #4: P2PSection 2.6 of textbook (some pictures here are from the book)

  2. Recap • Links • Packet switched networks • Store-and-forward routing • Delays • dprop = distance/ propagation speed • dtran = L /R = packet size/ capacity • dq • dproc • IPv4 address: 32 bits • 172.16.2.15 (roach.int.cec.wustl.edu) • 172.16.2.8 (butterfly.int.cec.wustl.edu) • 10101100 00010000 00000010 00001000 • Subnet mask • 172.16.2.8/24 • First 24 bits constitute “prefix”

  3. Longest-prefix matching

  4. Today’s lecture • Application layer • Applications don’t see links • Client-server or P2P • Today, we focus on P2P

  5. Applications Gmail request response Internet request response New mail: “Watch Federer video. Tell Cathy, Denis, Ed, and Frank also.”

  6. Applications Gmail • Server sends 5 copies • If 50 requests, 50 copies; 5 million requests, 5 million copies! request response Internet request response

  7. Client-server • Suppose • File is F bits • N users • Upload rate of server’s access link is us • Upload rate of useri’s access link is ui • Download rate of useri’s access link is di • Time to distribute a copy to all users • NF/us a • A user may have very low download rate • Max {NF/us, F/dmin} where dmin= min {d1,d2,…dN }

  8. Client-server • Other problems • Significant reliance on always-on servers • Multiple copies, along with other traffic, can cause congestion on links • Longest-prefix matching is not sensitive to traffic load • Queuing delays at routers • Potential dropping of packets (i.e.) data loss • Peer-to-peer architecture addresses these…

  9. Peer-to-peer (P2P) • Pairs of computers, called peers, communicate directly. Source: wikipedia.org • Server sends file once. • Peers redistribute file chunks using their upload capacity. • Max {F/us, F/dmin, NF/(us+u1+u2+…+uN)}

  10. Client-server vs. P2P

  11. BitTorrent • P2p protocol for file distribution

  12. BitTorrent • When a peer (Alice) joins a torrent, she registers with a tracker. • Periodically, informs tracker of its presence. • Tracker sends Alice IP addresses of n random participating peers. • Alice tries to establish connection with them all. • All connected peers are neighboring peers. • These peers may leave and others may join over time. • Periodically, Alice asks each neighbor for their list of chunks • Alice then requests chunks that she wants. • Important decisions Alice makes are: • Request “rarest first” chunks • “Trading algo” to determine neighbors to whom to send • Eliminates “free-riding”

  13. BitTorrent • Estimated BitTorrent traffic is 18 - 35% • BitTorrent does not offer users anonymity • obtaining IP addresses exposes users with insecure systems to attacks • Peers may leave selfishly after downloading a file • Users with low upload capacity may see slower download speeds until they upload more • Some trackers exempt dial-up users Source: wikipedia.org

  14. Indexing • Map info to locations • Centralized index • Query flooding • Hierarchical overlay • DHTs (Distributed Hash Table)

  15. 1. Centralized index

  16. 2. Query flooding index • Limited-scope query flooding • Handling of peers joining and leaving overlay • Bootstrap, maybe with a tracker • The new peer tries to setup TCP connections • “Ping”, “pong”

  17. 3. Hierarchical overlay index • “Super” peers maintain index for files of their children • Super peers interconnect themselves

  18. 4. DHT index • A fully decentralized index • Allows users to determine all locations of a file • Without generating excessive traffic

  19. Skype • P2P Internet telephony • P2P techniques for also user location • Proprietary protocol; all packet transmissions encrypted • Nodes organized into hierarchical overlay net • Each peer classified as super or ordinary • Index to map username to current IP address • Distributed over super peers

  20. Backup

  21. Longest-prefix matching // insert sorted if (new_mask == curr_mask) { if (new_destAddr == curr_destAddr) { //entry already exists return 0; } return (new_destAddr > curr_destAddr) ? 1 : -1; } return (new_mask > curr_mask) ? 1 : -1; // if return value > 0, insert above current entry

More Related