1 Statistical Modeling and Analysis of P2P Replication to Support Vod Service zyp Infocom, 2011,...

Preview:

Citation preview

1

Statistical Modeling and Analysis of P2P Replication to

Support Vod Service

zyp

Infocom, 2011, Shanghai

2

Background

• VoD: Video-on-Demand– http://www.xunlei.com/– http://movie.youku.com/

• Traditional VoD and P2P VoD– First one,client-server approach– Second one,P2P assisted VoD

3

Outline

• Introduction• Model• Replication algorithm• Analysis• Adaptive Algorithm• Simulation• Conclusion

4

Introduction

• P2P VoD– Storage to replicate content– Upload bandwidth

• P2P replication is a central design issue in P2P VoD system

5

• For a P2P VoD system– Average server bandwidth utilization(B)– Average number of movie copies(M)– Peers(N),movies(K)

• Each peer:– Upload capacity(Ui)– movies stored(L)– movie set stored on peer i(Qi)– average requests received by peer i(λi)

• Each movie:– relative popularity of movie j(ηj)– peer set replicating movie j(Sj)

Model

K

jj

1

1

6

Model

• Assumed:– movies are of the same size– have the same playback rate equal to

1(same as the average upload capacity)– Perfect Fair-Sharing Model

• How a peer select a movie:– Deterministic Demand– Stationary(random)

7

• Stationary(random):– transition matrix -> stationary state– in stationary state,any peer watch movie j is

a Binomial distribution with ηj

– average number requests for peer i

• Objective of the P2P VoD system• This paper try to do: minimize B

Model

iQj ji N

8

• Random with Load Balancing Assignment1. for j=1 to K do2. Bj=03. end for4. for i=1 to N do 5. Peer i randomly select L movies from the movie set

and puts the id of each movie into Qi;6. 7. for do8. Bj=Bj+Ui/λi,for homogeneous,Ui=19. if Bj≥1 then10. Never select movie j any more11. end if12. end for13.end for

Replication Algorithm

iQj ji N

jQj

9

Replication Algorithm

• In this algorithm Bj meaning the expected received bandwidth for peers watching movie j.

• For Homogeneous peer,their uplink capacity U=1.

• This algorithm wants to make the most movie's B≥1

10

Analysis

iQj jip

ii

ki

i pNek

kq i ,!

)(RePr

Stationary Demand and Homogeneous(同类的 ) Peers

• Requests at any peer i is a random variable of Binomial distribution( )– For large N:

• Bandwidth form provider i allocated to a peer watching movie j( )– EQ.1

jj SiiX ),(

3

1)]([,

1)]([

ij

ij iXVariXE

11

Analysis

• EQ.1:

322

0

0

1

0

1)])([(])([)]([

11

111

!

!1!1

1)]([

ijjj

iiik

ki

i

k

ki

ik

ki

j

iXEiXEiXVar

eee

k

e

k

e

k

e

kiXE

ii

ii

ii

12

Analysis

)(iXXjSi jj

• Aggregate bandwidth that peers watching movie j get from other peers:

• We need variance of Xj to describe B:– EQ.2

)1),(1.()1

(

),(2)]([])([

2

2

3

,,,,

2

kir

kiriXVariXVar

jSi

i

kiSkijkjij

Sij

Sijj

j

jjj

13

Analysis

)),(2)]([(,,

,,11

2

kiSki

jkjijSi

j

K

jj

K

jjj

jj

kiriXVar

1)]([ jSi

j iXE

• Weighted average variance of all movies:– EQ.3

• Constraints to restrict the allocation:– EQ.4

– EQ.5

– The RLB algorithm satisfying both conditions.

L

KN

i i

1

1

14

Analysis• EQ.5:

– Each peer stores exactly L movies,means 1/λi appears exactly L times.

L

K

KiXE

N

i i

K

j Si i

K

j Sij

jj

1

11

1

1)]([

15

Analysis

NL

KK

jjj

1

2

• The performance of RLB algorithm is given by EQ.3

• Correlation rj(i,k) is complicating factor.– rj(i,k)=1

• EQ.3 becomes EQ.6

– rj(i,k)=0• EQ.3 becomes EQ.7

2

12

1

2 )()1

(1

NL

K

N

N

i i

K

jjj

16

Analysis• EQ.6:

– rj(i,k)=1,means peers who store movie j have the same movie set,then λi=λk.

– From EQ.4 we can get |sj|=λi.

NL

K

SS

NSS

S

iXSVariXVar

LK

i j

Qj jK

j j

jK

jjj

Qjjij

ji

j

jjSi

jj

i

i

j

/

111

2

3

2

2

||||

||,||

1||

)](|[|])([

17

Analysis

M

N

L

NKXXB j

N

i

K

j Xjj

j2

1

2

1)Pr(1

2

1

1 1

M

N

L

NKB

2

1

2

1

• The sever load with eq.4 and eq.5:– EQ.8

• The worst case rj(i,k)=1– EQ.9

• The best case rj(i,k)=0– EQ.10 M

N

L

KB

2

1

2

1

18

Analysis• EQ.8:

M

N

L

NKN

XXX

XXX

XXB

K

jjj

N

i

K

jjjj

K

j Xjj

jj

N

i

K

j Xjjj

j

N

i

K

j Xjj

j

j

j

2

1

2

1

2

1

)Pr()1()Pr(2

1

)Pr()Pr(12

1

)Pr(12

1

1

2

1 1

2

1

1 1

1 1

19

AnalysisStationary demand and heterogeneous peers• The upload capacity of peer i be Ui.

– EQ.1 is rewritten as EQ.11:

• Proposition 1:They share same lower bound• Proposition 2:They share same upper bound

3

2

)]([,)]([i

ij

i

ij

UiXVar

UiXE

20

Adaptive Algorithm• RLB is a centralized algorithm.• ARLB is a distributed one

– Do movie replication based on the watched movies.

• ARLB algorithm:– x+=x if x>0,else 0.

– GAP means weighted gap between Bj and required playback rate(1).

21

Adaptive Algorithm• Step1-3:Check i's

storage.• Step4-5:Check movie j's

bandwidth .• Step7:Find out which

movie to be replaced.• Step8-19:Calculate the

GAP before and after replace

• Step20-22:Decision.

22

Simulation• A.Stationary demand and static replicati

on assignment– Model validation under homogeneous setti

ngs:• Evenly distributed movie popularity(ηj=1/K).• Homogeneous peer uplink capacity(Ui=1).• Simulation duration 1500 timeslots,viewing

duration [20,40].• N=10000,each peer make independently

selection.• K/L=50,keep the bounds unchanged.

23

Simulation• Sever load

decreases when L is increased.

• Server load of RLB is strictly bounded.

• L=1 achieved lower-bound.

Fig.1

24

Simulation– Sensitivity analysis on configuration parameters:

25

Simulation• Fig.2 shows that all the six cases that

RLB performs much better and RLB is strictly bounded.– (a) changing the popularity– (b) changing the peer uplink capacity– (c) changing N– (d) changing K– (e) changing L with N,K fixed– (f) changing L with K/L fixed

26

Simulation• B.Evaluate adaptive replication algorithms

– The simulation configuration parameters is similar to A.

– Compare with four replacement algorithms.– Also, these simulations show that ARLB

performs much better then others,and ARLB still bounded by upper- and lower-bounds.

27

Simulation

28

Conclusion• This paper propose a service model

and a stationary statistical demand model for P2P VoD.

• Design a replication algorithm(RLB) and give an adaptive version(ARLB).

• Simulation

29

Thank you!