Professional Documents
Culture Documents
Outline
Survey
Self-organizing overlay network
File system on top of P2P network
CS 461
Background
Distribution
Decentralized control
Self-organization
Symmetric communication
Spring 2000
CS 461
Examples
Pioneers
Napster, Gnutella, FreeNet
Academic Prototypes
Pastry, Chord, CAN,
Spring 2000
CS 461
Common Issues
Organize, maintain overlay network
node arrivals
node failures
CS 461
Architecture
Event
notification
Network
storage
P2P Substrate
TCP/IP
Spring 2000
Internet
CS 461
Object Distribution
Consistent hashing
[Karger et al. 97]
2128 1 0
objid
nodeids
Spring 2000
CS 461
Object Insertion/Lookup
2128 - 1 O
Route(X)
Spring 2000
CS 461
Routing
d471f1
d46a1c
d467c4
d462ba
d4213f
d13da3
Properties
log16 N steps
O(log N) state
65a1fc
locate(d46a1c)
Spring 2000
CS 461
Leaf Sets
CS 461
Routing Procedure
if (destination is within range of our leaf set)
forward to numerically closest member
else
let l = length of shared prefix
let d = value of l-th digit in Ds address
if (Rld exists)
forward to Rld
else
forward to a known node that
(a) shares at least as long a prefix
(b) is numerically closer than this node
Spring 2000
CS 461
11
Routing
Integrity of overlay:
guaranteed unless L/2 simultaneous failures of
nodes with adjacent nodeIds
Number of routing hops:
No failures: < log16 N expected, 128/b + 1 max
During failure recovery:
O(N) worst case, average case much better
Spring 2000
CS 461
12
Node Addition
d471f1
d46a1c
d467c4
d462ba
d4213f
addnode(d46a1c)
d13da3
65a1fc
Spring 2000
CS 461
13
Spring 2000
CS 461
14
API
route(M, X): route message M to node with nodeId
numerically closest to X
deliver(M): deliver message M to application
forwarding(M, X): message M is being forwarded
towards key X
newLeaf(L): report change in leaf set L to
application
Spring 2000
CS 461
15
Spring 2000
CS 461
PAST API
Insert - store replica of a file at k diverse storage
nodes
Lookup - retrieve file from a nearby live storage
node that holds a copy
Reclaim - free storage associated with a file
Files are immutable
Spring 2000
CS 461
17
fileId
Insert fileId
Spring 2000
CS 461
18
fileId
Storage Invariant:
File replicas are
stored on k nodes
with nodeIds
closest to fileId
Insert fileId
(k is bounded by the
leaf set size)
Spring 2000
CS 461
19
k replicas
Lookup
fileId
Spring 2000
CS 461
20