bitvampire: p2p on-demand media streaming in the internet liu/bitvampire liu/bitvampire phd student:...

22
BitVampire: BitVampire: P2P P2P On-Demand On-Demand Media Media Streaming in the Internet Streaming in the Internet http:// www.cs.ubc.ca/~liu/bitvampire PhD Student: Xin Liu Supervisor: Dr. Son T. Vuong {liu, vuong}@cs.ubc.ca j Networking and Internet Computing (NICLab) University of British Columbia March 27, 2006

Post on 19-Dec-2015

217 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: BitVampire: P2P On-Demand Media Streaming in the Internet liu/bitvampire liu/bitvampire PhD Student: Xin Liu

BitVampire: BitVampire: P2PP2P On-Demand On-Demand MediaMedia Streaming in the InternetStreaming in the Internet

http://www.cs.ubc.ca/~liu/bitvampire

PhD Student: Xin LiuSupervisor: Dr. Son T. Vuong

{liu, vuong}@cs.ubc.caj

Networking and Internet Computing (NICLab)University of British Columbia

March 27, 2006

Page 2: BitVampire: P2P On-Demand Media Streaming in the Internet liu/bitvampire liu/bitvampire PhD Student: Xin Liu

2

Outline

1. Introduction

2. System Design

3. Simulation

4. Prototype Implementation

5. Future Work

Page 3: BitVampire: P2P On-Demand Media Streaming in the Internet liu/bitvampire liu/bitvampire PhD Student: Xin Liu

3

COOLSearch-BitVampire a novel technology for P2P content search and on-demand media streaming

On-Demand Media Streaming received intensive consideration due to the proliferation of high bandwidth networks.

Two main categories of existing on-demand media streaming systems: Server-based systems Proxy-based systems

The cost of deploy and maintain servers/proxies could be very expensive.

We propose a novel architecture that exploits the often under-utilized peers’ resources to support large-scale on-demand media streaming services.

1. Introduction – Motivation

Page 4: BitVampire: P2P On-Demand Media Streaming in the Internet liu/bitvampire liu/bitvampire PhD Student: Xin Liu

4

Basic Ideas/Contributions

1. Published video is split into segments and distributed to different peers (Media Segment Distribution MSD algorithm).

2. When watching a video, the requesting peer (receiver) searches the corresponding segments (COOLSearch), then

3. Aggregates bandwidths from multiple peers to stream the video (Multi-Source Scheduling MSS Algorithm).

Page 5: BitVampire: P2P On-Demand Media Streaming in the Internet liu/bitvampire liu/bitvampire PhD Student: Xin Liu

5

2. System Design

Example of watching a video

P1 (Seg #0)

P6 (Receiver)Playback bit rate: 500kbps

P2 (Seg #0)

P3 (Seg #0, #1)

P4 (Seg #1, #2)

P5 (Seg #2)250kbps

250kbps

200kbps

200kbps

100kbps

300kbps

200kbps

P6 wants to watch a video, it searches the Seg #0 and finds that P1, P2, P3 have Seg #0.

P6 aggregates bandwidths from P1, P2 and P3 to stream the Seg #0.

When streaming session of Seg #0 is almost over, P6 searches Seg #1.

P6 aggregates bandwidths from P3 and P4 to stream Seg #1.

When streaming session of Seg #1 is almost over, P6 searches Seg #2.

P6 aggregates bandwidths from P4 and P5 to stream Seg #2.

Page 6: BitVampire: P2P On-Demand Media Streaming in the Internet liu/bitvampire liu/bitvampire PhD Student: Xin Liu

6

COOLSearch (Category Overlay)

Clusters: C1, C2, C3

Category Overlay O1

Category Overlay O2

Category Overlay O3

N1

...N2

N3

(for Category Ca3)

(for Category Ca2)

(for Category Ca1)

Cluster C1 ClusterC2

Cluster C3 Ca1’s Agent NodeCa2’s Agent NodeCa3’s Agent Node

Clusters: C1, C2, C3

Category Overlay O1

Category Overlay O2

Category Overlay O3

Clusters: C1, C2, C3

Category Overlay O1

Category Overlay O2

Category Overlay O3

Category Overlay O1

Category Overlay O2

Category Overlay O3

N1

...N2

N3

(for Category Ca3)

(for Category Ca2)

(for Category Ca1)

Cluster C1 ClusterC2

Cluster C3 Ca1’s Agent NodeCa2’s Agent NodeCa3’s Agent Node

Page 7: BitVampire: P2P On-Demand Media Streaming in the Internet liu/bitvampire liu/bitvampire PhD Student: Xin Liu

7

A simple category overlay networkA simple category overlay network

Page 8: BitVampire: P2P On-Demand Media Streaming in the Internet liu/bitvampire liu/bitvampire PhD Student: Xin Liu

8

Overlay Networks - Three CategoriesOverlay Networks - Three Categories

Page 9: BitVampire: P2P On-Demand Media Streaming in the Internet liu/bitvampire liu/bitvampire PhD Student: Xin Liu

9

Large-Scale Large-Scale Category OverlayCategory Overlay Network Network

Page 10: BitVampire: P2P On-Demand Media Streaming in the Internet liu/bitvampire liu/bitvampire PhD Student: Xin Liu

10

Need An Efficient Scheduling Algorithm

To fully use the bandwidths from multiple supplying peers, we further divide (logically) each segment into equal sized blocks.

Given a set of supplying peers {P1, P2, …, PM} and the bandwidths from these peers {Bw1, Bw2, …, BwM}, the problem is how to assign blocks to these supplying peers to minimize the total downloading time, as well as to download the earlier blocks as soon as possible.

Possible solutions: Round Robin (RR) Bandwidth Proportional (BP): Assigning blocks to suppliers in proportion to

their contributed bandwidth

Page 11: BitVampire: P2P On-Demand Media Streaming in the Internet liu/bitvampire liu/bitvampire PhD Student: Xin Liu

11

Multiple-Source Scheduling (MSS) Algorithm

Scheduling:

1: for (i = 1; i ≤ num_suppliers; i++) 2: time[i] = 0; // time[i]: the earliest time for supplier[i] to start sending blocks;

3: curr_blk = 0; 4: while (curr_blk ≤ num_blks-1) { 5: for (i = 1; i ≤ num_suppliers; i++) 6: estimatedTime[i] = time[i] + blk_size / Bw[i];

7: select k, where estimatedTime[k] = Min{estimatedTime[i]}; 8: assign blocks[curr_blk] to supplier[k]; 9: time[k] = time[k] + blk_size / Bw[k]; 10: curr_blk ++;

11: if (curr_blk > num_blks-1) 12: break; 13: }

Page 12: BitVampire: P2P On-Demand Media Streaming in the Internet liu/bitvampire liu/bitvampire PhD Student: Xin Liu

12

Scheduling Algorithms Comparison

Example: Assign 8 blocks to 3 suppliers using RR, BP, MSS respectively.

The video bit rate: 512kbpsContributed bandwidth: P1: 320kbps P2: 128 kbps P3: 64kbps

6.4s

4.8s

Page 13: BitVampire: P2P On-Demand Media Streaming in the Internet liu/bitvampire liu/bitvampire PhD Student: Xin Liu

13

Streaming Session

Once schedule is generated, receiver sends it to suppliers. Then suppliers send the assigned blocks to receiver using UDP.

Receiver maintains a ring buffer, Once receiver receives a block, it writes this block to the right position of the ring buffer.

During the streaming session, supplier switching will happen if one supplier leaves/fails, or the incoming rate from a supplier is decreasing.

To absorb the transient effects of supplier switching, we require receiver to buffer at lease SinitBuff blocks before playback starts. The time to finish downloading these blocks is called initial buffering time.

Page 14: BitVampire: P2P On-Demand Media Streaming in the Internet liu/bitvampire liu/bitvampire PhD Student: Xin Liu

14

3. Simulation

Transit Domain

Stub Domain

Transit router

Stub router

End host

We conducted extensive simulation on large, Internet-like topologies. In average, the topologies consists of 2050 routers (generated by GT-ITM), and a total of 3010 end hosts (peers).

Page 15: BitVampire: P2P On-Demand Media Streaming in the Internet liu/bitvampire liu/bitvampire PhD Student: Xin Liu

15

Simulation Results

The simulation results demonstrate:

Based on the usual, low-cost PCs, our proposed architecture can support large-scale on-demand media streaming services in a dynamic heterogeneous Peer-to-Peer network.

Our segment distribution algorithm can achieve a fast system streaming capacity amplification, where system streaming capacity is defined as the number of media streaming sessions that can be served by the system concurrently.

The proposed scheduling algorithm can achieve small initial buffering time.

Page 16: BitVampire: P2P On-Demand Media Streaming in the Internet liu/bitvampire liu/bitvampire PhD Student: Xin Liu

16

4. Prototype Implementation

We implemented a functional prototype using Java and Java Media Framework (JMF). The prototype is totally platform independent.

In the prototype, control packets are sent using TCP, streaming packets are sent using UDP.

In total, the prototype implementation consists of 109 Java files, 21 packages, 133 classes, and more than 22,000 lines code (About 11,800 lines code in COOLSearch, and rest in BitVampire).

Page 17: BitVampire: P2P On-Demand Media Streaming in the Internet liu/bitvampire liu/bitvampire PhD Student: Xin Liu

17

Prototype System Architecture

Communication Component

Peers on Network

GUI

Controller

Service Abstraction Peer Abstraction

Peer Adaptor

Peer Clusters

Category TableContent Index Table

Neighbour Agents List

Category Overlay

Category Overlay Search Service

MediaService

Indexing Service

Streaming Receiver Streaming Supplier

Applicationlayer

Abstractionlayer

Servicelayer

Corelayer

Page 18: BitVampire: P2P On-Demand Media Streaming in the Internet liu/bitvampire liu/bitvampire PhD Student: Xin Liu

18

Prototype Snapshot

Page 19: BitVampire: P2P On-Demand Media Streaming in the Internet liu/bitvampire liu/bitvampire PhD Student: Xin Liu

19

Possible Business Model

Internet Cinema (or Internet DVD Player) users can register with the server of the Cinema Service Provider: Pay per view Pay monthly subscription fees Receive advertisements which can be made adaptive and

intelligent.

The deployment will be relatively simple, inexpensive, and incremental.

Page 20: BitVampire: P2P On-Demand Media Streaming in the Internet liu/bitvampire liu/bitvampire PhD Student: Xin Liu

20

5. Future Work

We plan to deploy our prototype on the PlanetLab (an Internet test-bed) in the near future.

Currently we deliver the video in full quality. Some adaptive streaming techniques (layer coding, priority drop, etc.) could be used to improve the quality of service.

An incentive mechanism to encourage peers to contribute their resources.

Page 21: BitVampire: P2P On-Demand Media Streaming in the Internet liu/bitvampire liu/bitvampire PhD Student: Xin Liu

21

Thesis Xin Liu, “BitVampire: A Cost-Effective Architecture for On-Demand Media

Streaming in Heterogeneous P2P Networks”, MSc Thesis, Computer Science, UBC, Nov. 2005.

Xin Liu, Son T. Vuong, “BitVampire: A Cost-Effective Peer-to-Peer Architecture for Large-Scale On-Demand Media Streaming”, invited paper for the Journal of Multimedia (JMM), to appear.

Xin Liu, Jun Wang, Son T. Vuong, “A Peer-to-Peer Framework for Cost-Effective On-Demand Media Streaming,” in the Proceedings of 3rd IEEE Consumer Communications and Networking Conference (CCNC’06), Las Vegas, NV, Jan. 2006.

Xin Liu, Son T. Vuong, “Supporting Low-Cost Video-on-Demand in Heterogeneous Peer-to-Peer Networks,” in the Proceedings of 7th IEEE International Symposium on Multimedia (ISM’05), Irvine, CA, Dec. 2005.

Xin Liu, Jun Wang and Son T. Vuong, “A Category Overlay Infrastructure for Peer-to-Peer Content Search,” in the Proceedings of APDCM'05 (in conjunction with IPDPS’05), Denver, CO, Apr. 2005.

Journal & Conference Papers

Patent In application process…

Page 22: BitVampire: P2P On-Demand Media Streaming in the Internet liu/bitvampire liu/bitvampire PhD Student: Xin Liu

22

http://www.cs.ubc.ca/~liu/bitvampire

Thanks!