Transcript Downloading

Peer-to-Peer Streaming
Systems
Kan-Leung CHENG
CMSC 818Z, Spring 2007
Department of Computer Science
University of Maryland
24th April, 2007
1
Outline

Introduction

Streaming Approaches



Application Layer Multicast
Content Distribution Networks
Peer-to-Peer Streaming

Metrics

Current Issues
2
What is a Communication Network?
(End system view)

Network offers a service:


What distinguish different types of networks?


move information
The services they provide
What distinguish the services?






Latency
Bandwidth
Loss rate
Number of end systems
Service interface (how to invoke?)
Other details

Reliability, unicast vs. multicast, real-time,
message vs. byte ...
3
The Internet


Global scale, general purpose,
heterogeneous-technologies, public,
computer network
Internet Protocol



Open standard: Internet Engineering Task
Force (IETF) as standard body
Technical basis for other types of networks
 Intranet: enterprise IP network
Developed by the research community
4
Peer-to-peer

Advent of multimedia technology and broadband
surge lead to excessive usage of P2P application that
includes:



Sharing of large files over the internet

Video-on-Demand (VoD) applications

P2P media streaming applications
BitTorrent like P2P models suitable for bulk file
transfer
P2P file sharing has no issues like QoS:

No need to playback the media in real time

Downloading takes long time, many users do it overnight
5
P2P Media Streaming

Media streaming extremely expensive

1 hour of video encoded at 300Kbps = 128.7 MB

Serving 1000 users would require 125.68 GB

Media Server cannot serve everybody in swarm

In P2P Streaming:



Peers form an overlay of nodes on top of www internet
Nodes in the overlay connected by direct paths (virtual or logical
links), in reality, connected by many physical links in the
underlying network
Nodes offer their uplink bandwidth while downloading and viewing
the media content

Takes load off the server

Scalable
6
P2P media streaming is non trivial

Need to playback the media in real time


Procure future media stream packets


Needs robust network topology to overcome churn
Internet dynamics and congestion in the interior of the
network


Needs reliable neighbors and effective management
High “churn” rate – Users join and leave in between


Quality of Service
Degrades QoS
Fairness policies extremely difficult to apply like tit-for-tat

High bandwidth users have no incentive to contribute
7
Major Approaches

Client Server Model


Application Layer Multicast


Alternate to IP Multicast
Content Distribution Networks like Akamai


Not scalable
Expensive  Only large infrastructure can afford
Peer-to-Peer Based



Most viable and simple to use and deploy
No setup cost
Scalable
8
IP Multicast




Relies on network routers
Pros
 Bandwidth efficiency
Cons
 Lack of scalable inter-domain multicast routing
protocols
 Require global deployment of multicast-capable
routers
 Lack of practical pricing models
Examples:

DVMRP/PIM-DM, CBT, PIM-SM, MOSPF, PIM-SSM, …
9
Multi-unicast vs. IP Multicast
Unicast
IP Multicast
10
Application Layer Multicast (ALM)


IP Multicast is not globally deployed.
Application Layer/Level Multicast (or Overlay
Multicast) is hence proposed.


Multicasting implemented at end hosts instead of
network routers
Nodes form unicast channels or tunnels between
them
S
E1
Unicast
Unicast
E2
R1
R2
Unicast
E3
11
Multicast
12
ALM - Benefits

Easy to deploy


No change to network infrastructure
Programmable end-hosts


Overlay construction algorithms at end
hosts can be easily applied
Application-specific customizations
13
ALM Methodologies

Tree Based


Content flows from server to nodes in a tree like fashion, every
node forwards the content to its children, which in turn forward to
their children

One point of failure for a complete subtree

High recovery time

Notes Tree Base Approaches: NICE, SpreadIT, Zigzag
Mesh Based

Overcomes tree based flaws

Nodes maintain state information of many nodes

High control overhead

Notes Mesh Based approaches include Narada and ESM from CMU.
14
Tree Based ALM
15
Mesh Based ALM
16
Content Distribution Networks (CDNs)





CDN nodes deployed in multiple locations, often
over multiple backbones
These nodes cooperate with each other to satisfy an
end user’s request
User request is sent to nearest CDN node, which
has a cached copy
QoS improves as end user receives best possible
connection
Yahoo mail uses Akamai
17
Peer-to-Peer Streaming Models


Media content is broken down in small pieces and
disseminated in the swarm
Neighboring nodes use Gossip protocol to exchange buffer
information

Nodes trade unavailable pieces

Robust and scalable, but more delay

Most noted approach in recent years: CoolStreaming

PPLive, SOPCast, Fiedian, TV Ants are derivates of
CoolStreaming

Proprietary and working philosophy not published

Reverse Engineered and measurement studies released
18
P2P Based Streaming Model
…
1
…
Server
3
2
…
…
…
5
…
4
…
…
3
1
19
CoolStreaming


Files is chopped by server and disseminated in
the swarm
Node upon arrival obtain a peerlist of 40 nodes
from the server

Nodes contact these nodes for media content

In steady state, every node has typically 4-8
neighbors, it periodically shares it buffer content
map with neighbors

Nodes exchange the unavailable content

Real world deployed and highly successful system
20
ALM and P2P
Media Streaming
Application Layer
Multicast
Peer-to-Peer
[CoolStreaming, PPLive,
SOPCast,TV Ants, Feidian]
Tree Based
[NICE, ZigZag, SpreadIT]
Mesh Based
[ESM, Narada]
21
Metrics
22
Metrics

Quality of Service




Network efficiency
Uplink utilization



Churn, Node failure or departure should not affect QoS
Scalability
Fairness



High uplink throughput leads to scalable P2P systems
Robustness and Reliability


Jitter less transmission
Low end to end latency
Determined in terms of content served (Share Ratio)
No user should be forced to upload much more than what it has
downloaded
Security

Implicitly affects above metrics
23
Quality of Service






Most important metric
Jitter: Unavailability of stream content at play time
causes jitter
Jitter less transmission ensures good media playback
Continuous supply of stream content ensures no jitters
Latency: Difference in time between playback at
server and user
Lower latency keeps users interested


A live event viz. Soccer match would lose importance in crucial
moments if the transmission is delayed
Reducing hop count reduces latency
24
Network efficiency


The delay between the source and receivers is
small
At the same time, the number of redundant
packets on any physical link should be low
CMU
Stan2
Stan1
Berk1
Berk2
High latency
Stan2
CMU
Stan2
Stan1
Gatech
Berk1
CMU
Stan1
Gatech
Berk2
High degree (unicast)
Berk1
Gatech
Berk2
“Efficient” overlay
25
Physical Link Stress (PLS)



The number of identical copies of a packet
that traverse a physical link.
Indicates the bandwidth inefficiency
Example:


S
E1
PLS for link S-R1 is 2.
Average PLS is 7/5.
R1
E2
R2
E3
26
Relative Delay Penalty (RDP)



The ratio of the delay in the overlay with
the delay in the direct unicast path.
Indicates the delay inefficiency
Example:



S
Overlay delay for the path
from S to E3 is 60 ms.
Unicast delay is 40 ms.
Therefore, the RDP for E3
is 1.5 ( = 60 ms / 40 ms).
E1
10 ms
10 ms
R1
R2
20 ms
10 ms
10 ms
E2
E3
27
Uplink Utilization





Uplink is the most sparse and important
resource in swarm
Summation of uplinks of all nodes is the load
taken off the server
Utilization = Uplink used / Uplink Available
Needs effective node organization and
topology to maximize uplink utilization
High uplink throughput means more bandwidth
in the swarm and hence it leads to scalable P2P
systems
28
Robustness and Reliability

A Robust and Reliable P2P system should be
able to support with an acceptable levels of
QoS under following conditions:

High churn

Node failure

Congestion in the interior of the network

Affects QoS

Efficient peering techniques and node
topology ensures robust and reliable P2P
networks
29
Scalability



Serve as many users as possible with an
acceptable level of QoS
Increasing number of nodes should not
degrade QoS
An effective overlay node topology and high
uplink throughput ensures scalable systems
30
Fairness

Measured in terms of content served to the swarm


Randomness in swarm causes severe disparity





Share Ratio = Uploaded Volume / Downloaded Volume
Many nodes upload huge volume of content
Many nodes get a free ride with no or very less
contribution
Must have an incentive for an end user to contribute
P2P file sharing system like BitTorrent use tit-for-tat
policy to stop free riding
Not easy to use it in Streaming as nodes procure
pieces in real time and applying tit-for-tat can cause
delays
31
Security


Implicitly affects other P2P Streaming metrics
Mainly 4 types of attacks:





Malicious garbled Payload insertion
Free rider – Selfish used only downloads with no
uploads
Whitewasher – After being kicked out, comes again
with new identity. Such nodes use IP spoofing
DDoS attack – One or more nodes collectively
launch a DoS attack on media server to crack the
system down
Lot of attack on P2P file sharing system but
very few on Streaming

Possibility cannot be denied
32
Current Issues
33
Current Issues

High buffering time for P2P streaming


Half a minute for popular streaming channels and around 2
minutes for less popular
Some nodes lag with their peers by more than 2 minutes in
playback time.

Better Peering Strategy needed

Uneven distribution of uplink bandwidths (Unfairness)

Huge volumes of cross ISP traffic


ISPs use bandwidth throttling to limit bandwidth usage

Degrade QoS perceived at used end
Sub Optimal uplink utilization
34
Current Issues - Service differentiation

Different peers may have different
privileges.


A user who pays more or is more important
should receive better quality of service (e.g.
shorter delay, lower loss rate, less jitter, etc).
Previous overlay protocols have not
sufficiently considered service
differentiation based on user privilege and
requirement.
35
Service differentiation– example
(distance learning)
Lecturer
(Source node)
Student
(More important node)
Auditor
(Less important node)
Note: Euclidean distance
is proportional to network
distance
Traditional
Importantstreaming
nodes
will
system
receive
doesn’t
better
quality
consider
of service
the
difference
(e.g. shorter
of user’s
delay
in requirement.
this example).
36
Q&A
37
References



X. Zhang, J. Liu, B. Li, and T.-S. Peter Yum,
“CoolStreaming/DONet: A data-driven overlay network for
efficient live media streaming,” in Proc. IEEE INFOCOM’ 05,
March 2005.
Y. Chu, S. G. Rao, and H. Zhang, “A case for end system
multicast,” ACM SIGMETRICS’00, June 2000.
Kan-Leung Cheng, Xing Jin and S.-H. Gary Chan, "Offering
Differentiated Services in Peer-to-Peer Multimedia Multicast," in
Proceedings of IEEE International Conference on Multimedia &
Expo (ICME), Toronto, Canada, 9-12 July 2006.

http://en.wikipedia.org/wiki/Akamai_Technologies

http://www.cs.ucf.edu/courses/cis3360/QoS_P2P_Streaming.ppt
38