p2p live streaming

62
1 Peer-to-Peer Live Streaming, 16 th Nov. 2007 P2P Live Streaming Amir H. Payberah [email protected] Fatemeh Rahimian [email protected]

Upload: others

Post on 12-Sep-2021

11 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: P2P Live Streaming

1Peer-to-Peer Live Streaming, 16th Nov. 2007

P2P Live Streaming

Amir H. [email protected]

Fatemeh Rahimian [email protected]

Page 2: P2P Live Streaming

2Peer-to-Peer Live Streaming, 16th Nov. 2007

Outline

• Introduction• Related Works• ForestCast• Simulation• Summary

Page 3: P2P Live Streaming

3Peer-to-Peer Live Streaming, 16th Nov. 2007

Outline

• Introduction• Related Works• ForestCast• Simulation• Summary

Page 4: P2P Live Streaming

4Peer-to-Peer Live Streaming, 16th Nov. 2007

What is the Problem?

• Growing interest in networked multimedia streaming application.

• Simplest solution: Allocate server and network resources for each client request. Does not scale well.

• Better solution: Peer-to-Peer technologies

Page 5: P2P Live Streaming

5Peer-to-Peer Live Streaming, 16th Nov. 2007

Peer-to-Peer Technology

• A type of network in which each peer has equivalent capabilities and responsibilities.

• Popular for many scalable applications

Multicasting

File sharing

Page 6: P2P Live Streaming

6Peer-to-Peer Live Streaming, 16th Nov. 2007

P2P Media Streaming

• The peers who have all or part of the requested media can forward the data to requesting peers.

• The requesting peers can become supplying for other requesting peers.

• Each peer contributes its own resources. The capacity of whole system becomes much more than the

client-server model.

Page 7: P2P Live Streaming

7Peer-to-Peer Live Streaming, 16th Nov. 2007

P2P Media Streaming Challenges

• Dynamic uptime

• Limited and dynamic bandwidth

Page 8: P2P Live Streaming

8Peer-to-Peer Live Streaming, 16th Nov. 2007

Outline

• Introduction• Related Works• ForestCast• Simulation• Summary

Page 9: P2P Live Streaming

9Peer-to-Peer Live Streaming, 16th Nov. 2007

Two Main Questions

• How to find supplying peers?

• How to maintain content delivery paths?

Page 10: P2P Live Streaming

10Peer-to-Peer Live Streaming, 16th Nov. 2007

Locating Supplying Peers

Page 11: P2P Live Streaming

11Peer-to-Peer Live Streaming, 16th Nov. 2007

Locating Supplying Peers

• Centralized directory• Hierarchical overlay structure• DHT-based approach• Controlled flooding

• Gossip-based approach

Page 12: P2P Live Streaming

12Peer-to-Peer Live Streaming, 16th Nov. 2007

Centralized Directory

Page 13: P2P Live Streaming

13Peer-to-Peer Live Streaming, 16th Nov. 2007

Hierarchical Overlay Structure

Page 14: P2P Live Streaming

14Peer-to-Peer Live Streaming, 16th Nov. 2007

DHT-based Approach

Page 15: P2P Live Streaming

15Peer-to-Peer Live Streaming, 16th Nov. 2007

Controlled Flooding

Page 16: P2P Live Streaming

16Peer-to-Peer Live Streaming, 16th Nov. 2007

Gossip-based Approach

Page 17: P2P Live Streaming

17Peer-to-Peer Live Streaming, 16th Nov. 2007

Locating Supplying Peers(Comparison)

Page 18: P2P Live Streaming

18Peer-to-Peer Live Streaming, 16th Nov. 2007

Maintaining ContentDelivery Path

Page 19: P2P Live Streaming

19Peer-to-Peer Live Streaming, 16th Nov. 2007

Maintaining Content Delivery Path

• Push based Single tree Multiple trees

• Pull based

Page 20: P2P Live Streaming

20Peer-to-Peer Live Streaming, 16th Nov. 2007

Push-base

Single tree

Multiple trees

Page 21: P2P Live Streaming

21Peer-to-Peer Live Streaming, 16th Nov. 2007

Pull-based

Page 22: P2P Live Streaming

22Peer-to-Peer Live Streaming, 16th Nov. 2007

Maintaining Content Delivery Path(Comparison)

Page 23: P2P Live Streaming

23Peer-to-Peer Live Streaming, 16th Nov. 2007

Related Works

• SplitStream DHT based Push model (multiple tree)

• ZigZag Hierarchical overlay structure Push model (single tree)

• CoolStream Gossip based Pull model

• Pulsar DHT based Mixed (pull and push)

• Orchard Gossip based Push model (multiple tree)

• PULSE Gossip based Pull model

Page 24: P2P Live Streaming

24Peer-to-Peer Live Streaming, 16th Nov. 2007

Outline

• Introduction• Related Works• ForestCast• Simulation• Summary

Page 25: P2P Live Streaming

25Peer-to-Peer Live Streaming, 16th Nov. 2007

What is ForestCast?

• A solution to heuristically build multicast trees for live video streaming.

• What are we looking for? Maximize the total utilization of upload bandwidth Maximize continuity Minimize latency Minimize start up delay

Page 26: P2P Live Streaming

26Peer-to-Peer Live Streaming, 16th Nov. 2007

The Answer of Two Questions

• Centralized directory Locating supplying peers

• Push-based (Multiple trees) Maintaining content delivery paths

Page 27: P2P Live Streaming

27Peer-to-Peer Live Streaming, 16th Nov. 2007

Multicast Trees

• The stream is split into some stripes.

• One multicast tree for each stripe. rooted at source.

Page 28: P2P Live Streaming

28Peer-to-Peer Live Streaming, 16th Nov. 2007

How to Approach the Problem

• What are the things that influence our goals? Bandwidth of peers Fair distribution of different stripes Having distinct parents Position of a peer in different trees

• How they affect the efficiency of system? Needs appropriate heuristics Evaluation

Page 29: P2P Live Streaming

29Peer-to-Peer Live Streaming, 16th Nov. 2007

Peer roles

• Server Central server that constructs the tree

• Source The node which has the video to be streamed

• Peer A node which downloads/uploads the stream

Page 30: P2P Live Streaming

30Peer-to-Peer Live Streaming, 16th Nov. 2007

Definition of Some Terms

• Open node A node which its available upload bandwidth is more than the

stripe rate.

• Head of buffer The largest segment number a node has in its buffer.

• Head to play latency The difference between head of buffer of a node and its

playback point.

Page 31: P2P Live Streaming

31Peer-to-Peer Live Streaming, 16th Nov. 2007

Join Procedure

Page 32: P2P Live Streaming

32Peer-to-Peer Live Streaming, 16th Nov. 2007

Join Procedure

• Server receives the join request from a peer.

• It decides from which node a joining peer should receive its live stream.

• The decision will be based on The existing trees The properties of the joining node

• e.g. its available bandwidth

Page 33: P2P Live Streaming

33Peer-to-Peer Live Streaming, 16th Nov. 2007

Join Procedure (Step 1)

• Collect a number of open nodes for each stripe. How many open nodes should be selected?

Where to start picking the nodes?• Root?• Leaves?• ...

In what order?• BFS?• DFS?• ...

Page 34: P2P Live Streaming

34Peer-to-Peer Live Streaming, 16th Nov. 2007

Join Procedure (Step 2)

• Prioritize the collected nodes for being selected as a parent. Number of existing children Available upload bandwidth Source-to-end latency Any other parameter?

Page 35: P2P Live Streaming

35Peer-to-Peer Live Streaming, 16th Nov. 2007

Join Procedure (Step 3)

• Select the best parents Who is the best parent? Distinct parents

• To increase the resiliency to failure Which stripe?

• Rarest?• ...

Any other parameter?

Page 36: P2P Live Streaming

36Peer-to-Peer Live Streaming, 16th Nov. 2007

Join Procedure (Step 4)

• Decide from which segment number the media should be forwarded to the joining node. This segment number determines a specific time of the media

that joining node will start to play.

Different parents have different segments at their head of buffer.

So from which segment?• Minimum of head of buffer of all parents?• Start somewhere earlier?

Page 37: P2P Live Streaming

37Peer-to-Peer Live Streaming, 16th Nov. 2007

Join Procedure (Step 5)

• Decide about the playback time of the joining node. There is a trade-off between playback latency and continuity.

• Asks the selected parents to forward data to the new node from the decided segment on.

• Asks the new node to start playback where its head-to-play is the decided length.

Page 38: P2P Live Streaming

38Peer-to-Peer Live Streaming, 16th Nov. 2007

Each Peer After Joining

• Sends its profile periodically to server: Latency to its parent for each stripe First segment of each stripe Last segment of each stripe ...

Page 39: P2P Live Streaming

39Peer-to-Peer Live Streaming, 16th Nov. 2007

Leave Procedure

Page 40: P2P Live Streaming

40Peer-to-Peer Live Streaming, 16th Nov. 2007

Leave Procedure

• Server receives the leave request from a peer. The request consists of the last segment number which the

leaving node has sent to its children.

• It finds the substitute parents for the leaving peer.

• The decision will be based on The existing trees The properties of the orphan nodes

• e.g. what is the last segment which they will receive from the leaving node

Page 41: P2P Live Streaming

41Peer-to-Peer Live Streaming, 16th Nov. 2007

Leave Procedure (Step 1)

• Find substitute parents for the children of the leaving node.

The same as finding parent for joining node, but some more constraints

• It should consider the last segment which the children have received.

• The new parent should have from that segment on.

Page 42: P2P Live Streaming

42Peer-to-Peer Live Streaming, 16th Nov. 2007

Leave Procedure (Step 2)

• In case of finding new parent

Server asks the leaving node to stop forwarding any more data to that child.

Server also sends order to the new parents to start forwarding data to their new children.

Page 43: P2P Live Streaming

43Peer-to-Peer Live Streaming, 16th Nov. 2007

Leave Procedure (Step 3)

• In case of not finding new parent

The server repeats step 1 until it finds a new parent.

The leaving node continues sending stream to its children.

Page 44: P2P Live Streaming

44Peer-to-Peer Live Streaming, 16th Nov. 2007

Leave Procedure (Step 4)

• After finding new parent for all children

The server asks the parent of leaving node to stop sending data to it.

Server grants the node to leave.

The node leaves the system upon receiving server’s message.

Page 45: P2P Live Streaming

45Peer-to-Peer Live Streaming, 16th Nov. 2007

Failure Handling

Page 46: P2P Live Streaming

46Peer-to-Peer Live Streaming, 16th Nov. 2007

Failure Handling

• Server receives the failure notification from the failed node's children. The message consists of the last segment number which the

children have in their buffer.

• It finds the substitute parents for the orphaned peers.

• The decision will be based on The existing trees The properties of the orphan nodes

• e.g. what is the last segment which they will receive from the leaving node

Page 47: P2P Live Streaming

47Peer-to-Peer Live Streaming, 16th Nov. 2007

Failure Handling (Step 1)

• Find substitute parents for the children of the failed node.

The same as finding parent for joining node, but some more constraints

• It should consider the last segment which the children have received.

• The new parent should have from that segment on.

Page 48: P2P Live Streaming

48Peer-to-Peer Live Streaming, 16th Nov. 2007

Failure Handling (Step 2)

• In case of finding new parent, Server sends order to the new parents to start forwarding data

to their new children.

• Otherwise Find a parent who causes the least disruption.

Page 49: P2P Live Streaming

49Peer-to-Peer Live Streaming, 16th Nov. 2007

Outline

• Introduction• Related Works• ForestCast• Simulation• Summary

Page 50: P2P Live Streaming

50Peer-to-Peer Live Streaming, 16th Nov. 2007

Simulation

• Discrete-event modelling A common method of simulating networks

• The operation of a system is represented as a sequence of events in time order.

• Each event occurs at an instant in time and makes a change of state in the system.

• Traditional modelling Packet level modelling

Page 51: P2P Live Streaming

51Peer-to-Peer Live Streaming, 16th Nov. 2007

Improving Scalability

• Improving computational power Using faster and more powerful machines

• Improving simulation technology Using better algorithms

• Changing simulation model Using simpler and higher abstraction model

Page 52: P2P Live Streaming

52Peer-to-Peer Live Streaming, 16th Nov. 2007

Packet-level vs. Fluid-level

• Packet level modelling For each packet departures or arrivals one event will be

generated.

• Fluid level modelling The events are generated only when the rate of flows changes.

Page 53: P2P Live Streaming

53Peer-to-Peer Live Streaming, 16th Nov. 2007

Packet-level modelling

• Advantages High accuracy

• Because of considering the detail information of individual packets

• Disadvantages Low scalability

• In case of growing the network size and links bandwidth • Huge number of events and cost of processing them

Page 54: P2P Live Streaming

54Peer-to-Peer Live Streaming, 16th Nov. 2007

Fluid-level modelling

• Advantages High scalability High performance

• In case of low changes in flow rates

• Disadvantages Low accuracy

• Because of ignoring the details of modelling Ripple effect

• Reduces the performance advantage of fluid-level modelling

Page 55: P2P Live Streaming

55Peer-to-Peer Live Streaming, 16th Nov. 2007

Our modelling (SicsSim-II)

• We use fluid-based modelling. To have a scalable simulator

• We partly consider the effects of underlying layer as well. Network congestion

Page 56: P2P Live Streaming

56Peer-to-Peer Live Streaming, 16th Nov. 2007

SicsSim-II Overall Structure

Page 57: P2P Live Streaming

57Peer-to-Peer Live Streaming, 16th Nov. 2007

Internal Structure of SicsSim-II

• FEL (Future Event List) A global queue which contains all the events of the system.

• Event scheduler Lets the simulator to handle the control messages in a

chronological order.

• The simulation loop proceeds by selecting the next event in queue, executing it and inserting new generated events in queue in simulation time order.

Page 58: P2P Live Streaming

58Peer-to-Peer Live Streaming, 16th Nov. 2007

Control and Data Messages

• Control messages The control messages are considered to have a very small size

which would use 0 bandwidth. To handle them we put them in future event list.

• Data messages Data messages carry the real data. We don’t transfer real data in the simulator. We just assume there is a flow of data from nodes to nodes

with a rate.

Page 59: P2P Live Streaming

59Peer-to-Peer Live Streaming, 16th Nov. 2007

Outline

• Introduction• Related Works• ForestCast• Simulation• Summary

Page 60: P2P Live Streaming

60Peer-to-Peer Live Streaming, 16th Nov. 2007

Future Work

• Evaluating the algorithm

• Improving the model

• Investigate the same approach for decentralized model

Page 61: P2P Live Streaming

61Peer-to-Peer Live Streaming, 16th Nov. 2007

Summary

• P2P live streaming

• Different algorithms Locating supplying peers Maintaining content delivery path

• ForestCast Centralized Multiple trees

• SicsSim-II Discrete event modelling Fluid based

Page 62: P2P Live Streaming

62Peer-to-Peer Live Streaming, 16th Nov. 2007

Questions?

&

Comments!