Building Low-maintenance Expressways for P2P Systems - PowerPoint PPT Presentation

About This Presentation
Title:

Building Low-maintenance Expressways for P2P Systems

Description:

Building Low-maintenance Expressways for P2P Systems Zhichen Xu and Zheng Zhang Presented By Swetha Boinepally – PowerPoint PPT presentation

Number of Views:55
Avg rating:3.0/5.0
Slides: 39
Provided by: dev1150
Learn more at: http://cecs.wright.edu
Category:

less

Transcript and Presenter's Notes

Title: Building Low-maintenance Expressways for P2P Systems


1
Building Low-maintenance Expressways for P2P
Systems
  • Zhichen Xu and Zheng Zhang
  • Presented By
  • Swetha Boinepally

2
Overview
  • What are Expressways ?
  • CAN
  • CAN construction
  • Routing in CAN
  • Overview of Expressway
  • Building Expressway
  • Routing with Expressways
  • Tuning towards load balance
  • On demand maintenance
  • Analysis of routing
  • Tuning towards best performance
  • Conclusion

3
Introduction
  • Expressway is an auxiliary mechanism to
    deliver high routing performance.
  • Expressways are auxiliary data structures.

4
Real Life Expressways Vs. Expressways in P2P
Systems
  • Expressways in P2P systems are analogous to the
    real world expressways.
  • Attributes of expressways
  • - Auxiliary mechanisms. Not a wholesale
    replacement of local
  • routes.
  • - Greater span per hop.
  • - High bandwidth.
  • Difference between real life expressways and
    expressways in P2P systems
  • Expressways in P2P systems are
  • - Self organized.
  • - Self maintained.
  • - Adaptive to changing network.

5
Why CAN ?
  • CAN has performance of O(N1/d)
  • Expressways improves the routing performance to
    O(log N)
  • Highly scalable
  • Simple routing algorithm
  • Low maintenance cost

6
Content Addressable Network(CAN)
  • CAN is a distributed infrastructure which
    provides hash table like functionality.
  • CAN organizes the logical space as a
    d-dimensional Cartesian coordinate space.
  • Entire coordinate space is partitioned among all
    the nodes.
  • Each node owns its individual zone within overall
    space.

7
CAN construction
  • All nodes are represented in the coordinate
    space.
  • When a new node joins, it joins a node that is
    close to it in IP distance.
  • The existing node will split its allocated zone
    into half.
  • The neighbors of the split zone must be notified.
  • When a node leaves the network, its zone should
    be taken over by one of its neighboring nodes .

8
Example
9
Routing in CAN
  • CAN node maintains a coordinate routing table
    that holds the IP address and the virtual
    coordinates of each of its neighboring zones.
  • A CAN message includes the destination
    coordinates. Using its neighbor coordinate set, a
    node routes a message towards its destination by
    simply forwarding to the neighbor with
    coordinates closest to the destination
    coordinates.

10
Example
  • We consider a 2-d Cartesian space with 16 equal
    zones.
  • Each node has maximum of 4 neighbors.
  • Maximum routing path length is 3 hops.

11
D-dimensional Space
  • For a d-dimensional space which is partitioned
    into n equal zones
  • The average routing path length is
  • (d/4)(n(1/d)) hops.
  • of neighbors for an individual node is
  • 2d.

12
Scaling Results
  • The previous results show that for a
    d-dimensional space, we can grow the number of
    nodes(zones) without increasing the per node
    state.
  • The average routing path length grows in
    proportion to (n(1/d)).
  • Thus the routing performance in CAN is
  • O(n(1/d)).

13
Overview of Expressways
  • Expressways of CANs have routing tables of
    increasing span.
  • The entire space is partitioned into zones of
    different spans with smallest zones correspond to
    the CAN zones and any other zones are called
    Expressway zones.
  • Each node owns a CAN zone and is also a resident
    of the Expressway zone that encloses its CAN
    zone.
  • Expressway zones and CAN zones are recorded in
    each node in data structure called Total routing
    table.

14
Contd
  • In this example, CAN zones are at level 3, four
    of neighboring CAN zones make one level 2
    expressway and four such level 2 zones make a
    level 1 zone.
  • Total routing table of node 1 consists of the
    default routing table of CAN(plain arcs) and
    expressway routing tables(thick and long arcs)

15
Contd
  • Total routing table RT
  • RT lt R0, R1, R2, . . . ., RLgt where RL
    corresponds to the nodes default routing table
    that CAN already builds.
  • Ri(i0 to L-1) is called an Expressway routing
    table that has larger span. Smaller the i larger
    the span.
  • For each neighboring expressway zone, the
    expressway routing table keeps the address of one
    or more nodes in that zone.
  • In the previous figure, CAN zones are at level 3
    and each CAN zone is 1/64 th of entire Cartesian
    space.

16
Building Expressways
  • The algorithm for building expressway is
    Evolving snapshot.
  • According to the algorithm, at regular intervals
    of system growth, snapshots of current routing
    table are taken.
  • Each node takes the snapshot independently by
    observing its zone size, with which it may infer
    to what stage the system has grown.
  • For node x, suppose the current zone size is
    x.R.Z and the target size is x.R(L-1).Z/K. if the
    xs current size shrinks to its target size then
    it takes a new snapshot by incrementing L. where
    K is the span of the expressway.

17
Notations Used
18
Procedure for New Node Join
  • When a node y splits with x, it inherits all
    entries of xs total routing table other than xs
    current routing table.
  • Procedure when a node y joins node x
  • y.RT ltx.R0,x.R1,,x.RL-1,y.RLgt
  • repeat the procedure for testing for a new
    snap shot
  • Both nodes test to see if its current zone has
    shrunken to 1/K th of its last snapshot.

19
Algorithm to Test a New Snapshot
  • Procedure for testing for new snapshot
  • //executed by both x and y
  • If (RL.Z lt RL-1.Z/K)
  • RL1 RL
  • RTltR0,R1,..,RL,RL1gt
  • LL1

20
Expressway Tree
  • CAN can be thought as building a binary tree
    since each new node splits a random existing
    node.
  • Total routing table can be found by walking down
    the tree from the root towards the node picking
    up the snapshot routing tables.
  • Tree rooted by x when it joined system is called
    xs expressway tree.

21
Routing
  • If the destination point is within the current
    zone (RL.Z) then we can route it using the CANs
    default routing table.
  • If the node is in some other zone, it iterates
    through the total routing table, starting from
    the one with largest span.
  • It iterates until it finds a routing table whose
    space does not cover the destination.
  • Suppose Ri is the routing table whose space does
    not cover the destination, then Ri is selected
    and the message will be routed according to Ri to
    one of Ris expressway neighbors.

22
Pseudo-code for Routing With Expressway
  • Route with Expressway
  • If(pt?RL.Z)
  • Return
  • For(i0iltLi)
  • If(pt?(Ri.Z))
  • Route using Ri
  • Route with Ri
  • for(j0jltdj)
  • if(ptltRi.Z.Lj ptgtRi.Z.Uj)
  • Route to x?Ri.Nj that is close to pt
  • Break

23
Tuning Towards Load Balance
  • Achieving load balance requires that a node z
    that routes to x in expressway routing, to have
    the option for replacing x with any node inside
    the xs expressway tree.
  • Let Z.Ri be the routing table used to route to x
    and X be the xs expressway zone, then we pick a
    point pt in X and route to it. Whoever owns that
    zone now replaces x in Z.Ri. Here the point pt is
    selected randomly.
  • of nodes that replace x is proportional to the
    size of xs Expressway tree and therefore is
    proportional to the of residents inside xs
    Expressway tree.
  • Thus the algorithm will automatically balance the
    load among Expressways.

24
Default Vs. Random Algorithms
  • This figure show the simulation results reporting
    number of messages each node has to forward with
    default routing table and the routing table
    constructed using random selection.
  • We see that with random selection, more of
    messages are forwarded

25
On-demand Maintenance
  • When a new node joins the network, it updates its
    expressway neighbors for the EW zones recorded in
    its total routing table. Such maintenance is
    proportional to the total levels of expressways,
    which is O(logkN).
  • When a node departs, one of its neighbors will
    take over departed nodes responsibilities.
    However the departed node can be the expressway
    neighbor of multiple nodes and its EW functions
    need to be maintained by some other nodes.

26
Contd
  • Suppose node x departs from the network, and node
    y attempts to route to node x, then the request
    will timeout and node y tries to use the EW with
    smaller reach.
  • Now node y picks up a point pt in the space of x
    recorded in the failed routing table, and route
    to it. If node z owns the zone in which the point
    pt lies then node z is now replacement of x to
    repair ys snapshot.
  • On average the total of nodes that will update
    their routing table entries is the product of the
    total of expressway levels and the of
    neighbors in each level, which is O(d.logkN).

27
Storage
  • Let m be the of levels of EWs and mlogkN. The
    total routing table depth is m and as a result
    the storage for routing table increases m-folds.
  • For example, if K4 and N220 (million nodes),
    then m is 10 and it takes only few hundred bytes
    to store the routing table. Therefore storage is
    not a concern.

28
Routing with expressways
  • Routing expressways involves at most m levels of
    CAN like routing.
  • Routing algorithm will iterate through the table
    to get down to the level where the expressway
    zone doesn't cover the destination. It will the
    follow the CAN routing to reach an expressway
    zone that covers the destination.

29
Analysis
  • The average routing hops in any level are
    (d/3)K(1/d) hops and number of levels the
    routing will travel are logkN levels. Thus there
    are (logkN)(d/3)K(1/d) hops in the worst case.
  • The bigger the K, the less levels of expressways
    there are and routing at each level is more
    expensive, so we need to find the optimal K.

30
Contd
  • Let f(x)(d/3).(x1/d).logxN
  • Taking the derivative and equating it to zero
  • f(x) 0 gt
  • (d/3).(1/d.x(1/d-1).lnN/lnx
    x(1/d-1).lnN/(lnx)2
  • on simplification we get 1/d1/lnx
  • gt xed
  • Thus the optimal K is ed and the optimal routing
    performance is
  • f(x)(d/3).((ed)1/d).log(ed)N
    d/3.e.lnN/d e/3 lnN
  • Thus the routing performance of CAN using
    expressways is O(lnN). And it is independent of
    choice of d.

31
Expressway Performance Compared With Theoretical
Values
  • In the figure, theoretical performance using EW
    is compared with results obtained using
    simulation.
  • There are small deviations in these values.

32
Expressway Performance Compared With CAN With
Different D
  • In this graph, we can see that the EW performance
    with d1 outperforms the basic CAN with d5.

33
Tuning Towards Best Performance
  • Tuning towards network conditions
  • Locating closest nodes using coordinate maps
  • Route around congested node
  • Tuning according to application needs

34
Locating Closest Nodes
  • Build maps of network coordinates, and utilizing
    the archival capacity of P2P system itself to
    store and maintain the maps in various zones in
    CAN.
  • Any node can find a resident close to it in a
    given expressway zone Z by consulting the
    appropriate map.
  • There is one map for each expressway zone in the
    system.

35
Route Around Congested Node
  • In Internet like dynamic environment, the traffic
    flow is unpredictable and the common problem to
    deal with is congestion.
  • Congestion can be avoided by detecting the
    congested node, reporting and finding the
    alternate route.
  • To find the appropriate expressway neighbor, each
    node will periodically update its map with the
    information about its load.

36
Tuning According to Application Needs
  • Reducing the per hop distance may not necessarily
    reduce the total delay.
  • To account for the communicating patterns of
    application, the total routing table of node
    keeps the addresses of multiple nodes, instead of
    keeping the address of the node that is
    physically closest to it.
  • While routing to a destination, we attempt to
    balance the per hop distance and the total number
    of logical hops to achieve overall small latency.
  • Routing performance can be further improved by
    allocating some storage at each node to cache
    routes based on runtime behavior.

37
Summary
  • Using expressways the performance of routing in
    CAN is improved from O(N1/d) to O(ln N).
  • The important attributes of P2P systems are to
    reduce maintenance cost, and to provide venues to
    tune the system to suit the application needs and
    the underlying network conditions. Such that it
    beats O(ln N) in practice.

38
Thank You
Write a Comment
User Comments (0)
About PowerShow.com