support mobile and distributed applications with …...support mobile and distributed applications...

57
Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of California, Los Angeles CA, 90095 [email protected] May 22, 2013 Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 1 / 52

Upload: others

Post on 30-Aug-2020

6 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Support Mobile and Distributed Applications withNamed Data Networking

Zhenkai Zhu

Computer Science DepartmentUniversity of California, Los Angeles

CA, [email protected]

May 22, 2013

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 1 / 52

Page 2: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Research Overview

Supporting mobility in the global Internetthoroughly studied existing IP mobility solutionsdeveloped solution for the scalability problem in Global HA to HAprotocolprovided a new perspective of mobility support

Exploring new design patterns for distributed applications over NDNexplored naming conventions in application designproposed a general-purpose dataset synchronization protocol that hasthe potential of supporting a wide range of distributed applicationsdeveloped security solutions for distributed applications using NDN’sdata-centric approach

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 2 / 52

Page 3: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Motivation

Today’s Internet is increasingly mobileIP’s host-to-host communication model is increasing challenged byemerging communication patterns

Despite years of IP mobility support research, few solutions enjoyedwide adoption

it is time to rethink what is mobility support and how to align mobilitysupport with the applications’ need

NDN aims to accommodate emerging communication patterns bytaking fundamental changes to today’s IP Internet architecture

we must learn how to design applications to fully exploit the benefits ofsuch an architectural shift by trying out new applications

This work is to push forward this new front of networking research

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 3 / 52

Page 4: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Supporting mobility in the global Internet

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 4 / 52

Page 5: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

The IP mobility problems

How to find a mobile after it moves?

How to minimize the interruption to the communications?

How to make sure one is talking to the right host?

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 5 / 52

Page 6: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Solution space

One can reach a mobile by the same IP address regardless of whetherit moves or not

e.g. broadcast the mobile’s location via routing

One can find the mobile’s location based on a stable piece ofinformation

e.g. home address, DNS nameneed to maintain an up-to-date mapping

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 6 / 52

Page 7: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Three basic components of IP mobility support

Stable identifiersender’s knowledge about the mobile that does not change due tomobility

Locatoran IP address for the mobile’s current location

Mapping between the twokept in dedicated network entitiesor by the routing system

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 7 / 52

Page 8: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

IP mobility solutions

I conducted a complete and systematic survey of IP mobility solutions thathave been proposed in order to gain a good understanding of the solutionspace and shed light on future efforts.

Protocol Year Protocol Year

Columbia 1991 TIMIP 2001

Virtual IP 1991 M-SCTP 2002

LSR 1993 HIP 2003

Mobile IP 1996 Connexion 2004

MSM-IP 1997 ILNPv6 2005

Cellular IP 1998 Global HAHA 2006

HMIP 1998 PMIP 2006

FMIP 1998 BTMM 2007

HAWAII 1999 WINMO 2008

NEMO 2000 LISP-Mobility 2009

E2E 2000

Table 3.1: IP mobility solutions studied, listed roughly in chronicle order

which the Columbia protocol [IDM91], Virtual IP [TYT91], and a protocol based

on IP Loose source routing (LSR) [BP93] are representative.

3.1.1.1 Columbia Protocol

This protocol was designed to provide mobility support on a campus. A router

named Mobile Support Station (MSS) is set up in each wireless cell and serves as

the default access router for all mobile nodes in that cell. Each MSS also knows

how to reach other MSSs (e.g., all MSSs could be in one multicast group, or a list

of IP addresses of all MSSs could be statically configured).

A mobile node obtains an IP address from a special IP prefix, and the mobile

node uses this IP address regardless of the cell to which it belongs. Each MSS

keeps a tracking list of mobile nodes that are currently in its cell by periodically

broadcasting beacons. When receiving beacons, the mobile replies to the MSS

11

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 8 / 52

Page 9: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Host Route

Cellular IP

TIMIP

HAWAII

Columbia

MSM-IP

Global Routing

ConnexionWINMOHome Agent

Virtual IP

LSRMobile IP

NEMO

Global HAHA

HMIP FMIP

PMIP

DNS

E2E

M-SCTP

HIP

ILNPv6

BTMM

LISP-Mobility

Mapping Routing

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 9 / 52

Page 10: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Host Route

Cellular IP

TIMIP

HAWAII

Columbia

MSM-IP

Global Routing

ConnexionWINMOHome Agent

Virtual IP

LSRMobile IP

NEMO

Global HAHA

HMIP FMIP

PMIP

DNS

E2E

M-SCTP

HIP

ILNPv6

BTMM

LISP-Mobility

Mapping Routing

Local Mobility

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 9 / 52

Page 11: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Summary of IP mobility solution space

Mobility support essentially involves three basic componentsa stable identifier, a locator and the mapping between the two

Broadcast (routing) based approach is simplest, most robust, andwork well in small networks, but raises scaling concerns when appliedto large networks

Mapping based approach (home agent, DNS, etc.) can scale well withlarge network, but introduces dependency on a 3rd party.

Managing local movements local helps improve the performance andscalability

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 10 / 52

Page 12: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Limitations of IP mobility support

Security is tied to IP addressesoften weak and need frequent updates during the movequite a few proposals didn’t even mention about security

Incomplete solution: only considers cases when mobiles are connectedto the infrastructure

yet mobility can easily lead to intermittent connectivity or ad hocconnectivity among a set of mobilesad hoc mobility and DTN becomes separate branches in networkingresearch with their own solutions

Because IP is for point-to-point delivery, so far mobility solutions alsofocus only on maintaining point-to-point sessions

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 11 / 52

Page 13: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

A new perspective on mobility support

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 12 / 52

Page 14: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

What NDN brings

Data-centric securityevery piece of data is namedand signedwhere the data is obtaineddoesn’t matter

Receiver-driven communications

must send Interest for datadata follows the reverse pathback to requester

Intelligent data planeper-packet state at routers

Name

Selectors

Nonce

Name

Content

Signed Info

Signature

Interest Data

Producer

C

C

C Cdata packetinterest packet

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 13 / 52

Page 15: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Security done right

Security has always been a big challenge for IP mobility solutionsNDN secures data

decouples trust in data from trust in host

Bob Alice

Adversary

Communication channel hijacked

Location updatefrom "Alice" that passesReturn Routability test

(a) IP

Bob Alice

Adversary

Data signed by Alice

Alice's public key

(b) NDN

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 14 / 52

Page 16: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Enhanced performance with network caching

Data can be easily cached anywhere1 fast recovery for packet drops at last (wireless) hop2 smooth handoff without special optimization3 always fetch popular content from nearest cache or repository

1

2

3

4

/photo/1

/photo/1

registration

move move

(1) last hop recovery (2.a) optimization for handoff in IP (2.b) handoff in NDN

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 15 / 52

Page 17: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Naturally support DTN and ad hoc networks

NDN already provides two basic building blocks for DTN and ad hocnetworks

a way to identify data → every piece of data is nameda way to carry data around → data is secured and can be cachedanywhere

Furthermore, NDN fully utilizes the broadcast nature of wirelesscommunications

Interest can be broadcasted and whoever has the data can replyOverheard data can be cached

/I5/traffic

/I5/traffic

drive/I5/traffic

/I5/traffic

DSRC

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 16 / 52

Page 18: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Naturally support mobile consumers

IP is about connectivityhas to acquire IP address and reportIP address changes so that the otherend can “push” data

In NDN, data flows back along thereverse path of the Interest

no need to acquire namesno need to report location changes

Producer

move

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 17 / 52

Page 19: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Support for mobile producers

The network needs to route Interests based on data namesproducers whose names are not on FIB must have a way for Intereststo reach them

The lessons we learned from IP mobility research can be appliedstable identifier: the name space assigned to a producer

e.g. /ndn/ucla.edu/cs/foolocator: the name prefix that hints the location of a producer

e.g. /ndn/stanford.edumapping:

broadcast: simplest and robust, and takes advantage of broadcastnature of wireless communicationsDNS: one can do DNS lookup to find the mobile

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 18 / 52

Page 20: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

An example of DNS based support for mobile producer

Stanford

DNS

Producer

Consumer

DNS Update/twitter/foo : /stanford

DNS Query/twitter/foo

DNS Reply/twitter/foo : /stanford

Interest/twitter/foo/tweets/95

fowarding-hint = /stanford

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 19 / 52

Page 21: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Flexible data fetching

NDN’s forwarding strategy provides the much desired flexibility infetching mobile producer’s data

enabled by packet statistics and loop-free Interest forwardingalso take into considerations of each face’s properties (e.g. broadcastinterface, traffic cost) and namespace

WiFi

4G

RTT=400msCost=0

RTT=100msCost=$15/MB

(a) utilizing multipleinterfaces

Consumer

Peer user

Mobile producer's location(may be outdated)

Designated storage for mobile producer

(b) exploring alternative path

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 20 / 52

Page 22: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Publications on mobility support

Supporting mobility in the global Internet (ACM MobiCom MICNET Workshop ’09)

Supporting mobility for Internet cars (IEEE Communications Magazine 2011)

SAIL: A scalable approach for wide-area IP mobility (IEEE Infocom MobiWorld

Workshop ’11)

Home as you go: an engineering approach to mobility-capableextended home networks (AINTEC ’11)

A survey of mobility support in the Internet (IETF RFC 6301)

Understanding Apple’s back to my mac service (IETF RFC 6281)

A new perspective on mobility support under submission to MobiArch ’13

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 21 / 52

Page 23: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Exploring new design patterns for distributedapplications over NDN

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 22 / 52

Page 24: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Why new design patterns

NDN uses application defined names for data deliveryso apps can now use names to achieve new functions that they wereunable to do before

Exactly how to design apps to take such advantages is yet to beexplored

NDN research has been taking on an app-driven approach to get theanswer

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 23 / 52

Page 25: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Distributed applications in today’s Internet

Centralized designscentralized controlsingle point of failureinefficient data distribution

Peer-to-peer designsefficient data distribution maynot be the goalmis-matching between P2Poverlay and underlyingtopology

BD

C E

A

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 24 / 52

Page 26: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Distributed applications over NDN: Goals

Robust, fully decentralized

Efficient data distribution

Mobile friendly

Secure

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 25 / 52

Page 27: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

A simple distributed application: group text chat

Alice

Bob

Ted

Hello, guys.Do you guys need coffee?

Hello, Alice.

Yup.

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 26 / 52

Page 28: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

A simple distributed application: group text chat

Alice

Bob

Ted

Name Content

... ...

/ca/alice/15 Hello, guys

/ca/alice/16 Do you guys need coffee?

Name Content

... ...

/ca/ted/3 Hello, Alice.

Name Content

... ...

/ca/bob/31 Yup.

The problem is really synchronizing the chat dataset among the three.

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 26 / 52

Page 29: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Decentralized dataset synchronization

The need is ubiquitous in distributed applicationsretrieving all messages to a chatroomcollecting a list of conferences and speakers in audio conferencingcollecting all revisions in collaborative editing

The problems:synchronizing a dataset produced by multiple parties in anunpredictable patternno pre-knowledge about parties

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 27 / 52

Page 30: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

The role of naming

Naming is an important aspect of NDN application design

Names determine how Interests are forwarded in the networkand also identifies the application process if it reaches the producer

Proper naming can often simplify application designs

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 28 / 52

Page 31: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Naming in dataset synchronization

Use broadcast namespace for rendezvousInterest carrying broadcast name will be broadcasted in a domainreaches all potential data producers

/ndn/broadcast/chronos/lunch-talk/4b01...

(1) (2) (3)

Use routable namespace for actual data itemsuse broadcast names for all data would be prohibitively expensive

/wonderland/alice/chronos/lunch-talk/791

(1) (2) (3)

Simplify the knowledge about a producer’s datae.g., name the data of a producer sequentially

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 29 / 52

Page 32: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

ChronoSync: decentralized dataset state synchronization

Maintain knowledge of a dataset by tracking what each producer hasproduced so far

Chat room dataset

…Ted: 37

Dave: 5Alice: 19

Bob: 11

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 30 / 52

Page 33: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

ChronoSync: decentralized dataset state synchronization

Maintain knowledge of a dataset by tracking what each producer hasproduced so far

Compactly represent a user’s knowledge of the dataset in a hash, orstate digest

Chat room dataset

…Ted: 37

Dave: 5Alice: 19

Bob: 11

4b01...

State Digest

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 30 / 52

Page 34: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

ChronoSync: decentralized dataset state synchronization

Maintain knowledge of a dataset by tracking what each producer hasproduced so farCompactly represent a user’s knowledge of the dataset in a hash, orstate digestExchange state digests among all users using broadcast (sync)Interests

Alice

Bob

Ted

4b01...

4b01...

4b01...

4b01...

4b01...

4b01...

/ndn/broadcast/chronos/lunch-talk/4b01...

(1) (2) (3)

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 30 / 52

Page 35: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Tracking dataset state: digest-tree

State Digest

Alice's Digest Bob's Digest Ted's Digest

Name PrefixMax Seq-No

Name PrefixMax Seq-No

Name PrefixMax Seq-No

Chat room dataset

…Ted: 37

Alice: 19Bob: 11

Each child node maintains the knowledge of a producersorted according to the name prefix of each producer

Hash children nodes in order to produce state digest

When a producer’s state changes, update the branch and re-calculatestate digest

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 31 / 52

Page 36: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Tracking dataset state: digest-log

/wonderland/alice/chronos/lunch-talk/791

(1) (2) (3)

(a) An example of chat data name

/ndn/broadcast/chronos/lunch-talk/a1324asd9...

(1) (2) (3)

(b) An example of sync data name

Fig. 3: Naming rules of ChronoSync

by the Internet provider. For example, part (1) of the chat dataname in Fig. 3a is such a prefix. The purpose of the part (2),which includes the application name and the chatroom name,is to demultiplex the interest once it reaches the data source:it identifies the process that is responsible for handling suchinterests.

The data generated by a user is named sequentially. Forexample, in ChronoChat, the initial message from a user tothe chatroom has sequence number zero and whenever a newmessage is generated, be it a chat message or user presencemessage, the sequence number is incremented by one. As aresult, the complete knowledge of the user can be compactlyrepresented by just one name. Assume the name shown inFig. 3a is the latest chat data name used by Alice. We caninfer from the naming rules that Alice has produced 792 piecesof chat data to this chatroom, with sequence numbers rangingfrom 0 to 791.

Similarly, the name for sync data (Fig. 3b) also consists ofthree parts. Part (1) is the prefix in the broadcast namespacefor a given broadcast domain. A broadcast prefix ensures thatthe sync interests are properly forwarded to all participants ofa group, as it is often impossible to predict who will cause thenext change to the dataset state. Part (2) serves the purpose ofdemultiplexing (similar to that of the application data name),and the last part carries the latest state digest of the interestsender.

C. Maintaining dataset state

The application dataset can be represented as the union ofthe subsets of data generated by all producers.

Since the knowledge of a data producer can be solelyrepresented by its name prefix and the latest sequence number,ChronoSync tracks the latest application data name of eachproducer in order to maintain up-to-date knowledge of thedataset. For the sake of simplicity in writing, we refer tothe latest application data name of a producer as its producerstatus.

Inspired by the idea of Merkle trees [6], ChronoSync usesa digest tree to quickly and deterministically compress knowl-edge about the dataset into a crypto digest, as illustrated inFig. 4. 3 Each child node of the tree root holds a cryptographicdigest calculated by applying, for example, SHA-256 hash

3While we use an one-level hash tree here, a more canonical form of hashtrees can be used if the applications demand different naming rules.

State Digest

Alice's Digest Bob's Digest Ted's Digest

Name PrefixMax Seq-No

Name PrefixMax Seq-No

Name PrefixMax Seq-No

Fig. 4: An example of digest tree used in ChronoChat

State Digest Changes0000... Null9w35... [Alice’s prefix, 1]

... ...23ab... [Bob’s prefix, 31], [Alice’s prefix, 19]05t1... [Bob’s prefix, 32]

TABLE I: An example of digest log

function over a user’s producer status. Recursively applyingthe same hash function to all child nodes of the root resultsin the digest that represents state of the whole dataset, whichwe refer to as the state digest. To ensure that every participantcalculates the same state digest when observing the same set ofproducer statuses, the child nodes are kept in the lexicographicorder according to their application data name prefixes.

The digest tree is always kept up-to-date to accurately reflectthe current state of the dataset. Whenever a ChronoChat usersends a new chat message or learns about the name of a newmessage from another participant, the corresponding branch ofthe digest tree is updated and the state digest is re-calculated.

As an optimization, each party keeps a digest log along withthe digest tree. This log is a list of key-value pairs arranged inchronological order, where the key is the state digest and thevalue field contains the producer statuses that caused the statechange. An example of digest log is illustrated in Table I.The log is useful in recognizing outdated state digests. Forexample, when a user resumes from a temporary disconnectionand sends out a sync interest with an outdated state digest,other parties, if recognizing the old digest, can quickly inferthe differences between the dataset states and promptly replythe sender with missing data names.

Although the digest log facilitates the process of statedifference discovery in many cases, it is not essential ensurethe correctness of the ChronoSync design. Depending on theavailable resources, applications can set an upper bound onthe size of the digest log, purging old items when necessary.

D. Propagating dataset changes

To detect dataset changes as soon as possible, every partykeeps an outstanding sync interest with the current state digest.When all parties have the same knowledge about the dataset,the system is in a stable state, and sync interest from eachparty carries an identical state digest, resulting in efficientinterest collapsing in NDN routers [4]. Fig. 5a shows anexample of a system in stable state, where there is no ongoingconversation in a chatroom.

Maintaining the history of state digest changesuseful when old state digest is received, e.g. from a user who justrecovers from a temp disconnection

Not essential for the correctness of ChronoSyncapplication can set an upper bound of log size

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 32 / 52

Page 37: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Stable state

A B

C

Alice Bob

Ted

0

12

Interest Name/sync-prefix/04b1...

Interfaces0, 1, 2

04b1.. 04b1..

04b1..

Everyone has the same knowledge of a dataset

Sync Interests carry an identical state digestregardless of number of users in a group, at most one sync Interest sentover a link in one direction

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 33 / 52

Page 38: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Disseminate knowledge of new data

A B

C

Alice Bob

Ted

0

12

/sync-prefix/04b1…/alice2f18...

04b1...

04b1...

After producing new data, a producer observes different state digestreply the pending sync Interest with the new data info

Others update their state digest once receiving the replyproducing the same new state digest

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 34 / 52

Page 39: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Disseminate knowledge of new data

A B

C

Alice Bob

Ted

0

12

Interest Name/sync-prefix/2f18...

Interfaces0, 1, 2

2f18.. 2f18..

2f18..

After producing new data, a producer observes different state digestreply the pending sync Interest with the new data info

Others update their state digest once receiving the replyproducing the same new state digest

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 34 / 52

Page 40: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Handle simultaneous data generation

A B

C

Alice Bob

Ted

0

12

/sync-prefix/ceb2.../alice /sync-prefix/ceb2.../bobee65... 7db5...

7db5...

.../ceb2…/alice .../ceb2.../���

Problem: one sync Interest can only retrieve one sync datausers are partitioned into groups with different knowledge about thedataset

Optimization: use exclude filterneed to exclude at most (N − 1) known sync data if N producersgenerated data simultaneously

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 35 / 52

Page 41: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Problem: network partitions

A B

C

Alice Bob

Ted

D

John

State Digest Changes... ...

9w35... [Alice’s prefix, 1]23ab... [Bob’s prefix, 31]07t1... [Alice’s prefix, 2]ks23... [Alice’s prefix, 3]

Alice and Bob’s view

State Digest Changes... ...

9w35... [Alice’s prefix, 1]ux53... [Ted’s prefix, 9]ik29... [John’s prefix, 0]990s... [John’s prefix, 2]

John and Ted’s viewZhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 36 / 52

Page 42: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Handling network partitions

Any set reconciliation algorithm can be used

A simple recovery method is used as defaultexplicitly asking for information from the users who produced theunknown state digestrecovery data contains the whole snapshot of the dataset state (i.e.information about each data producer)

/ndn/broadcast/chronos/lunch-talk/recovery/ks23...

(1) (2) (3) (4)

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 37 / 52

Page 43: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Overview of ChronoSync

ChronoSync

Digest/Tree

Digest/Log/(op4onal)

Sync/Interests

Sync/Data

App:specific/communica4on

Recovery/Interests

No4fica4ons/about/changes/of/dataset/state

ChronoSync-based application

App-specific logic and state storage (chat messages, file revisions, etc.)

Recovery/Data

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 38 / 52

Page 44: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

ChronoShare: distributed file sharing with ChronoSync

Starting from an empty shared folder, the state of the folder is alteredwhenever an action from a participant is appliedThe state of the folder can be determined by applying all actions fromall participants in a deterministic wayChronoSync can be used track the actions

Root digest

...

Implied actions from /alice

action seq number 3 from /alice

/alice 3

action seq number 2 from /alice

action seq number 1 from /alice

/ted 7/bob 5

ChronoSync Digest Tree

/alice/action/1

delete /doc/tmp.txt

/alice/action/2update /photo/

garden.jpg

/alice/file/photo/garden.jpg/02/00

bytes

/alice/file/photo/garden.jpg/02/01

bytes

/alice/file/photo/garden.jpg/02/99

bytes

...

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 39 / 52

Page 45: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Evaluation

Goals: to confirmChronoSync synchronize dataset state quickly and efficientlyChronoSync is robust again network partitions, link failures and packetlosses

Methodologysimulation in ndnSIM module of NS-3evaluate performance of ChronoChat, a group text chat appimplemented based on ChronoSyncuse central server based TCP/IP implementation of IRC as baseline

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 40 / 52

Page 46: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Evaluation setup

Topology: 52 nodes, 84 links [1]

100 Mbps bandwidth for eachlink

Traffic: 1000 messages followingexponential distribution withmean of 5 seconds [2]All nodes participate in onechatroom

[1] N. Spring et al., Measuring ISP topologies with Rocketfuel.[2] C. Dewes et al., An analysis of Internet chat systems.

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 41 / 52

Page 47: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Metrics

Synchronization delay: the time needed for the last user to learn anew data piece after its generation

Communication pairs: the pairs of users that are still able to chat inface of network failures

Traffic pattern: how is the traffic distributed over the links

Total overhead: how many packets are transmitted

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 42 / 52

Page 48: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Synchronization delay

0

100k(10%)

200k(20%)

300k(30%)

400k(40%)

0ms 40ms 80ms 120ms 160ms 200ms 240msDelay of message delivery

Num

ber o

f mes

sage

deliv

erie

s (20

runs

) IRC

ChronoChat

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 43 / 52

Page 49: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Synchronization delay under lossy environment

●●●●●●●●●●●●●●●●●●●●●●●●

●●●●●●●●●●●●●●●

●●●●

●●●●●●●●●●●

●●●●●●●●●●●●

●●●●●

●●●●●●●●●●●●●

●●

●●

●●●

●●

●●●

●●●●●●●●●●●●●●●●●●●●●●●●●●●

IRC ChronoChat

0%20%40%

60%

80%

100%

4ms 16ms 62ms 0.2s 1s 4s 16s 4ms 16ms 62ms 0.2s 1s 4s 16sDelay

CD

F

Random loss● 0%

1%

5%

10%

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 44 / 52

Page 50: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Resilience to network failures

0%

20%

40%

60%

80%

● ●

10 20 30 40 50Number of failed links

Perc

ent o

f com

mun

icat

ing

pairs

(265

2 pa

irs to

tal)

IRC

ChronoChat

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 45 / 52

Page 51: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Traffic pattern

0

2.5k

10k

22.5k

40k

62.5k

90k●

●●

●●●●●●●●●●●●●●●●●●●●●●●

●●●●●●●●●●●●●●●●

Different links

Tota

l num

ber o

f pac

kets

(sqr

t sca

le)

● IRC

ChronoChat

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 46 / 52

Page 52: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Total overhead

100k

200k

300k

400k

●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●

20 40 60 80Number of links counted in total

Tota

l num

ber o

f pac

kets

● IRC

ChronoChat

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 47 / 52

Page 53: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Discussion: broadcast in large networks

Broadcast directly in large networks is costlyA broadcast overlay can dramatically reduce the cost

5/2/12" 42"

A"

B"

C"

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 48 / 52

Page 54: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Publications

ACT: an audio conference tool over Named Data Networking ACM

SIGCOMM ICN Workshop ’11

A new approach of securing audio conference tools AINTEC ’11

Chronos: serverless multi-user chat over NDN NDN Tech-Report 0008, 2012

Let’s ChronoSync: decentralized dataset state synchronization inNamed Data Networking under submission

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 49 / 52

Page 55: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Software

ACT: multiple party audio conference toolXMPP-MUC: multi-user text chatChronoChat: Chronosync based multi-user text chatChronoShare: ChronoSync based file sharing applicationpeets: WebRTC based audio/video conferencingChronoSync: C++ librarypy-chronos: python API for ChronoSyncNDN.cxx: C++ API for NDNndndump: packet analyzer for NDN

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 50 / 52

Page 56: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Concluding thoughts

The Internet needs changes to accommodate billions of mobiledevices and dramatically changed communication patterns.

By aligning mobile communications with application’s data-centricnature, we provided a completely different perspective on mobilitysupport

ChronoSync leverages NDN’s naming and data multicast capability toachieve efficient and robust dataset state synchronization

effectively names the state of a dataset by its given digest at a giventimeremoves single point of failure and traffic concentration problemsprovides useful building blocks in supporting distributed applications

Look forward, we hope this work can help stimulate more discussionson the design space of mobile and distributed applications over NDN

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 51 / 52

Page 57: Support Mobile and Distributed Applications with …...Support Mobile and Distributed Applications with Named Data Networking Zhenkai Zhu Computer Science Department University of

Acknowledge

Alexander Afanasyev made significant contribution to the design andimplementation of ChronoSync. He is also a collaborator onChronoShare and NDN.cxx.

Chaoyi Bian made significant contribution to XMPP-MUC

Zhenkai Zhu (UCLA) Ph.D Final Defense May 22, 2013 52 / 52