SkipNet Christian Schmidt-Madsen, csm@itu.dk Peter Tiedemann, petert@itu.dk

Preview:

Citation preview

SkipNet

Christian Schmidt-Madsen, csm@itu.dkPeter Tiedemann, petert@itu.dk

SkipNet structure overviewDual ID-space:

Name ID

Numeric ID (similar to Chord,Pastry etc)

•Node names are the reverse DNS name of the host (example: dk.itu.mycomputer)• Name ID Objects are stored at the lexicographic predecessor node. ( example: dk.itu.mycomputer/index.html will be stored at

dk.itu.mycomputer )*•Numeric ID objects are stored at the numerically closest node*: assuming ”/” is less than other

symbols

The SkipList datastructure

Probabilistic:

Deterministic:

Node at level h with probability 1/2h

Pointer at level h skips over 2h elements

SkipList -> SkipNet

Basic principle of SkipNet:

•A probalistic skiplist where every node is a head.

•The keys are just the names of the nodes

•The ordering is lexicographic

Problems with SkipList:

•Efficient search only possible from head

•Some nodes more likely to be in routing path

SkipNet structure illustrated

A Level: L = 0

L = 1

L = 3

L = 2

Root Ring

Ring 0 Ring 1

Ring 00 Ring 01 Ring 10 Ring 11

Ring000

Ring001

Ring010

Ring011

Ring100

Ring101

Ring110

Ring111

D M OT

VXZ

O

ZA T

M

X

DV

A T

M

X

D

VZ

O

O

ZA T

M

X

D

V

Numeric Numeric ID of AID of A

: skiplist with head = A

SkipNet Global View – Routing table

Level: L = 0

L = 1

L = 2Ring 00 Ring 01 Ring 10 Ring 11

Ring000

Ring001

Ring010

Ring011

Ring100

Ring101

Ring110

Ring111

A Root RingD M O

TVXZ

Ring 0A

M

T

X

Ring 1D

Z V

O

OZA T

M

X

D

V

A TM

X

DV Z

O L = 3

Node A’sRoutingTable

Routing by Name ID to node

Level: L = 0

L = 1

L = 2

Example: route from A to V Simple Rule: Forward the message to node that is

closest to dest, without going too far.

Ring 00 Ring 01 Ring 10 Ring 11

Ring000

Ring001

Ring010

Ring011

Ring100

Ring101

Ring110

Ring111

A Root RingD M O

TVXZ

Ring 0A

M

T

X

Ring 1D

Z V

O

OZA T

M

X

D

V

A TM

X

DV Z

O L = 3

Routing by Name ID to node

Level: L = 0

L = 1

L = 2

Example: route from A to V Simple Rule: Forward the message to node that is

closest to dest, without going too far.

Ring 00 Ring 01 Ring 10 Ring 11

Ring000

Ring001

Ring010

Ring011

Ring100

Ring101

Ring110

Ring111

A Root RingD M O

TVXZ

Ring 0A

M

T

X

Ring 1D

Z V

O

OZA T

M

X

D

V

A TM

X

DV Z

O L = 3

Node T’sRoutingTable

Routing by Name ID to node

Level: L = 0

L = 1

L = 2

Example: route from A to V Simple Rule: Forward the message to node that is

closest to dest, without going too far.

Ring 00 Ring 01 Ring 10 Ring 11

Ring000

Ring001

Ring010

Ring011

Ring100

Ring101

Ring110

Ring111

A Root RingD M O

TVXZ

Ring 0A

M

T

X

Ring 1D

Z V

O

OZA T

M

X

DV

A TM

X

DV Z

O L = 3

Routing by Name ID to object

Level: L = 0

L = 1

L = 2

Example: route from A to F -> Terminates at E Simple Rule: Forward the message to node that is

closest to dest, without going too far.

Ring 00 Ring 01 Ring 10 Ring 11

Ring000

Ring001

Ring010

Ring011

Ring100

Ring101

Ring110

Ring111

A Root RingD E O

VXZ

Ring 0A

E

T

X

Ring 1D

Z V

O

OZA T

E

X

DV

A TE

X

DV Z

O L = 3

T

How fast is routing by name?

In expectation a level h pointer will point past 2h nodes

This enables us to at least half the distance on the root ring to the destination giving O(logn) steps

Worst case is O(n) in the case were everybody else is on the same rings as us

Node joins

Join(node v) algorithm: Decide on a numeric ID(position in the

SkipNet) either randomly or by hashing DNS name.

Route to the top level ring for that numeric ID

Find neighbors on level below Continue recursively until we reach the

root ring Illustration on next slide !

Node join illustrated

Ring P0 Ring P1

Ring P

Only a few in expectation

Joining node

Node departure

Notifies neighbours of departure

Node failureLeaf Set :Each node has L/2 pointers in each direction

on theroot ring, providing protection from

independent failure. However the leaf set for a node are most

likely close in the underlying network too!

Background repair 1/2

Local ring repairs Periodically contact neighbours in each ring

and tell them that you think you are neighbors.

If neighbor accepts -> no response else neighbour responds with neighbor Reconcilliation based on this info( no details

in article)

Upper ring repair For each ring, route a message a short

distance around the ring, checking encountered nodes against higher level pointers

Background repair 2/2

Ring P

Ring PxThis is closer than red node and in ring Px !

Routing by numeric IDRouteTo( numID ): Current ring = root ring Move around the current ring until you meet

a node which is in the same next higher ring as numID

Continue recursively until a top ring is reached

Routing by numeric ID

Level: L = 0

L = 1

L = 2

Example: route from A to 110 -> ends at node OLog(N) rings to visit In expectation only 2 nodes visited before

encountering one belonging to correct ring

Ring 00 Ring 01 Ring 10 Ring 11

Ring000

Ring001

Ring010

Ring011

Ring100

Ring101

Ring110

Ring111

A Root Ring

D OT

VX

Ring 0A

B

T Ring 1D

V

O

OA

B

X

DV

A TB

X

DV

O L = 3

X

T

B

Content and path locality

Organizations correspond to contiguous SkipNet segments Internal routing by nameID remains internal Objects are stored according to nameID

com.sun

edu.ucbgov.irs

com.microsoft

com.microsoft.researchmicrosoft.com/pwlist.txt

Constrained load balancing DHT over a limited domain We combine the two id spaces Calling a file <CLB Domain>!<CLB Suffix> will

store the file on the node beginning with <CLB Domain> and having the closest numeric ID to hash(<CLB Suffix>)

CLB Domain CLB Suffix

microsoft.com!skipnet.htmlNumeric RoutingName Routing

CLB example

To get object “microsoft.com!skipnet.html” Route by nameID to “microsoft.com” Route by numericID to Hash(“skipnet.html”)

within the “microsoft.com” constraint

edu.ucbgov.irs

com.microsoft

skipnet.html

com.sun

CLB options

For a domain DOM and an objectID OID three options for storing the object exists:

1. Controlled placement (no DHT): DOMOID(!)

2. Global DHT: !DOMOID3. CLB: DOM!OID

Organizational disconnect

• Common failure• Forming an internal SkipNet• Re-joining the global SkipNet or,

equivalently• Merge of two SkipNet segments

Root ring connection

Proximity-aware routing

Proximity-aware routing of nameId (P-table)Use slightly shorter or longer jumps than the ”normally”; distance at lvl h expected to be 2h

Proximity-aware routing of numericId (C-table)Use a scheme similar to Pastry, where the node with lowest latency is chosen as an entry in the C-table

Modifying the routing table 1/2

Increase the base k of the numericID Ring ”fanout” increases to k Fewer pointers in R-table, O(logk n) More routing hops, O(k logk n)

Example: k = 3

h = 2

h = 1

h = 0

Modifying the routing table 2/2

Store k-1 additional pointers in each direction at each

level of the routing table Increased complexity of join (2k-2 in each

member ring) Fewer routing hops

Chord Basic SkipNet

Full SkipNet

Pastry

16.3 41.7 102.2 63.2Average number of unique routing entries per node in an overlay

with 216 nodes.

Discussion

DNS as the basis of nameIds (NAT’ed hosts)

Choice of numericId (random/secure hash)

Variation: Deterministic SkipNet (~ balanced tree)

End of slide show, PgDn to continue

Routing by nameID

Routing by numericID

Recommended