INF3190 Data Communication. Application Layer

Similar documents
INF3190 Data Communication. Application Layer

INF3190 Data Communication. Multimedia Protocols

Multimedia Protocols. Foreleser: Carsten Griwodz Mai INF-3190: Multimedia Protocols

INF5071 Performance in Distributed Systems. October 01, 2010

INF5071 Performance in distributed systems: Distribution Part III

Advanced Networking Technologies

Popular protocols for serving media

INF5070 media storage and distribution systems. to-peer Systems 10/

4 rd class Department of Network College of IT- University of Babylon

Content Overlays (continued) Nick Feamster CS 7260 March 26, 2007

Overview Computer Networking Lecture 16: Delivering Content: Peer to Peer and CDNs Peter Steenkiste

Kommunikationssysteme [KS]

CS519: Computer Networks. Lecture 9: May 03, 2004 Media over Internet

Mohammad Hossein Manshaei 1393

Multimedia Networking

Multimedia Applications. Classification of Applications. Transport and Network Layer

Internet Streaming Media. Reji Mathew NICTA & CSE UNSW COMP9519 Multimedia Systems S2 2006

Overview. Slide. Special Module on Media Processing and Communication

Lecture 14: Multimedia Communications

Video Streaming and Media Session Protocols

Digital Asset Management 5. Streaming multimedia

VoIP. ALLPPT.com _ Free PowerPoint Templates, Diagrams and Charts

Multimedia networking: outline

Multimedia Networking

EDA095 Audio and Video Streaming

RTP: A Transport Protocol for Real-Time Applications

Networked Multimedia and Internet Video. Colin Perkins

Outline. QoS routing in ad-hoc networks. Real-time traffic support. Classification of QoS approaches. QoS design choices

Overlay and P2P Networks. Introduction and unstructured networks. Prof. Sasu Tarkoma

Computer Networks. Wenzhong Li. Nanjing University

CS555: Distributed Systems [Fall 2017] Dept. Of Computer Science, Colorado State University

Networking Applications

Multimedia! 23/03/18. Part 3: Lecture 3! Content and multimedia! Internet traffic!

Part 3: Lecture 3! Content and multimedia!

Chapter 28. Multimedia

Application Layer Chapter 7

CSCD 433/533 Advanced Networks Fall Lecture 14 RTSP and Transport Protocols/ RTP

Real-Time Control Protocol (RTCP)

Internet Streaming Media. Reji Mathew NICTA & CSE UNSW COMP9519 Multimedia Systems S2 2007

DISTRIBUTED COMPUTER SYSTEMS ARCHITECTURES

The Frozen Mountain irtc White Paper Series

Multimedia Communications

Service/company landscape include 1-1

ETSF10 Internet Protocols Transport Layer Protocols

Higher layer protocols

ITTC Communication Networks The University of Kansas EECS 780 Multimedia and Session Control

Achieving Low-Latency Streaming At Scale

RECOMMENDATION ITU-R BT.1720 *

IMPROVING LIVE PERFORMANCE IN HTTP ADAPTIVE STREAMING SYSTEMS

Internet Video Delivery. Professor Hui Zhang

Content Overlays. Nick Feamster CS 7260 March 12, 2007

416 Distributed Systems. March 23, 2018 CDNs

IxLoad Data Streaming (RTSP, RTP)

CS 43: Computer Networks. 14: DHTs and CDNs October 3, 2018

Recommended Readings

Internet Streaming Media

Week-12 (Multimedia Networking)

CS 43: Computer Networks BitTorrent & Content Distribution. Kevin Webb Swarthmore College September 28, 2017

MITIGATING THE EFFECT OF PACKET LOSSES ON REAL-TIME VIDEO STREAMING USING PSNR AS VIDEO QUALITY ASSESSMENT METRIC ABSTRACT

Multimedia Networking

CMPE 80N: Introduction to Networking and the Internet

Introduction & Motivation

Cobalt Digital Inc Galen Drive Champaign, IL USA

Overview of the Session Initiation Protocol

irtc: Live Broadcasting

Internet Protocol Stack! Principles of Network Applications! Some Network Apps" (and Their Protocols)! Application-Layer Protocols! Our goals:!

Media server and QoS (so far)

Spotify Behind the Scenes

Streaming (Multi)media

Multimedia in the Internet

Streaming Video over the Internet. Dr. Dapeng Wu University of Florida Department of Electrical and Computer Engineering

Internet Content Distribution

OSI Layer OSI Name Units Implementation Description 7 Application Data PCs Network services such as file, print,

Overlay Networks in ScaleNet

Lecture 8: Application Layer P2P Applications and DHTs

CompSci 356: Computer Network Architectures Lecture 21: Overlay Networks Chap 9.4. Xiaowei Yang

Telematics Chapter 9: Peer-to-Peer Networks

EDA095 Audio and Video Streaming

For layered video encoding, video sequence is encoded into a base layer bitstream and one (or more) enhancement layer bit-stream(s).

Reliable Transport I: Concepts and TCP Protocol

TSIN02 - Internetworking

Media Communications Internet Telephony and Teleconference

P2P Network Structured Networks: Distributed Hash Tables. Pedro García López Universitat Rovira I Virgili

Outline Overview Multimedia Applications Signaling Protocols (SIP/SDP, SAP, H.323, MGCP) Streaming Protocols (RTP, RTSP, HTTP, etc.) QoS (RSVP, Diff-S

Part 5: Link Layer Technologies. CSE 3461: Introduction to Computer Networking Reading: Chapter 5, Kurose and Ross

Introduction to LAN/WAN. Application Layer 4

Uncompressed HD Video Streaming with Congestion Control

EDA095 Audio and Video Streaming

internet technologies and standards

P2PSIP, ICE, and RTCWeb

Ch 4: Multimedia. Fig.4.1 Internet Audio/Video

Page 1. Outline / Computer Networking : 1 st Generation Commercial PC/Packet Video Technologies

DISTRIBUTED SYSTEMS CSCI 4963/ /4/2015

ITEC310 Computer Networks II

Master Course Computer Networks IN2097

Peer to Peer Systems and Probabilistic Protocols

RTP Transport & Extensions

Troubleshooting VoWLAN using OmniPeek

Real-Time Transport Protocol (RTP)

Peer-to-Peer Architectures and Signaling. Agenda

Transcription:

Application Layer Carsten Griwodz Email: griff@ifi.uio.no

Real-time Transport Protocol (RTP) Real-time Transport Protocol (RTP) NOT real-time NOT a transport protocol Two Components: RTP & RTCP Provides end-to-end transport functions No premise on underlying resources Integrated with applications RTP follows principles of Application Level Framing and Integrated Layer Processing ATM TCP Application media encapsulation RTP UDP IPv4/6 Ethernet RTCP ST-2 AAL5 ATM

Signalling Protocols: RTSP & SIP

Signaling Protocols Applications differ Media delivery controlled by sender or receiver Sender and receiver meet before media delivery Signaling should reflect different needs Media-on-demand Receiver controlled delivery of content Explicit session setup Internet broadcast Sender announces multicast stream No explicit session setup Internet telephony and conferences: Bi-directional data flow, live sources (mostly) explicit session setup, mostly persons at both ends Real-Time Streaming Protocol (RTSP) Session Initiation Protocol (SIP)

Real-Time Streaming Protocol (RTSP) Rough synchronization Media description in DESCRIBE response Timing description in SETUP response Fine-grained through RTP sender reports Aggregate and separate control of streams possible Combine several data (RTP) servers Load balancing by REDIRECT at connect time Caching Much more difficult than web caching interpret RTSP but cache several RTP flows Cache must act as an RTP translator otherwise it cannot guarantee to receive packets

RTSP Integration HTTP server HTTP GET RTSP server RTSP SETUP RTSP OK RTSP PLAY RTSP OK RTSP TEARDOWN RTSP OK RTSP plug-in data source media server RTP VIDEO RTP AUDIO AV subsystem web browser

Session Initiation Protocol (SIP) Lightweight generic signaling protocol Internet telephony and conferencing call: association between number of participants signaling association as signaling state at endpoints (no network resources) Several services needed Name translation User location Feature negotiation Call control Changing features

SIP Operation Proxy Mode Location server 2. Where? 3. user@host Site A User with symbolic name calls another 1. INVITE u@domain 7. OK 8. ACK u@domain 11. OK 4. INVITE user@host 6. OK 9. ACK user@host 10. OK Site B 5. RING Proxy forwards requests possibly in parallel to several hosts cannot accept or reject call useful to hide location of callee

SIP Operation Redirect Mode 2. Where? Location server 3. user@domain2 Site A 5. ACK u@domain1 User with symbolic name calls another 6. INVITE user@domain2 8. OK 9. ACK user@domain2 Site B 7. RING

Co-existing with TCP Adapt audiovisual quality to your bandwidth share

RTP Quality Adaptation Application Application Encoding Decoding Encoding Decoding RTP RTCP RTCP RTP UDP UDP Application level framing idea application knows best how to adapt protocol (i.e. RTP) provides information about the network Application can evaluate sender and receiver reports modify encoding schemes and parameters adapt its transmission rates

Loss-Delay Adjustment Algorithm LDA An algorithm to stream with RTP in a TCP-friendly way use RTCP receiver reports (RR) RTCP sends RR periodically Application Application Encoding Decoding Encoding Decoding RTP RTCP RTCP RTP UDP UDP The Loss-Delay Based Adjustment Algorithm: A TCP- Friendly Adaptation Scheme, D. Sisalem, H. Schulzrinne, NOSSDAV 1998

Loss-Delay Adjustment Algorithm LDA An algorithm to stream with RTP in a TCP-friendly way use RTCP receiver reports (RR) RTCP sends RR periodically works like TCP's AIMD but RRs are rare can't adapt every time step one: find the bottleneck bandwidth b Sender use packet size and gap sizes b = 1 n n i=1 packetsize(i) time(i +1) time(i) Receiver

Loss-Delay Adjustment Algorithm LDA An algorithm to stream with RTP in a TCP-friendly way use RTCP receiver reports (RR) RTCP sends RR periodically works like TCP's AIMD but RRs are rare can't adapt every time no loss: use "AIR" additive increase rate but never more than 1 packet/rtt loss: RTCP counts losses, l is fraction of lost packets guess 3 of those losses in one RTT current rate " AIR t = AIR * 1 r t $ # b r t+1 = r t + AIR t newrate r t+1 = r t *(1 l *3) % ' &

Coding for adaptation Adapt audiovisual quality to your bandwidth share

Coding for Adaptive Streaming: MPEG-1 Frames can be dropped In a controlled manner Frame dropping does not violate dependancies Example: B-frame dropping in MPEG-1

Coding...: H.264 SVC extensions H.264: most common codec for MPEG-4 SVC: Scalable Video Codec Simplified representation of H.264/SVC the H.264 motion vectors of a frame can point to 16 different frames motion vectors in H.264 can cross I-frames...

Coding...: H.264 SVC extensions Simplified representation of H.264/SVC the H.264 motion vectors of a frame can point to 16 different frames motion vectors in H.264 can cross I-frames...

How to change quality?

The BAD CHOICE: PSNR Peak Signal-to-Noise Ratio you find it everywhere but it is really, really bad Example from Prof. Touradj Ebrahimi, ACM MM'09 keynote PSNR = 24.9 db Reference PSNR = 24.9 db PSNR = 24.9 db

Coding...: hierarchical layer coding

Coding...: perception study Encoding Layers High Frequency Frames over Time Low Frequency Amplitude Frequency Field study mobile devices, free seating, resolution 480x320@30fps, no sunlight, lounge chairs

Blurriness, noise and motion flicker change of H.264 compression strength change of resolution change of frame rate Mean Acceptance Score 2 1 0 1 2 HQ 6f 10f 30f 60f 90f 180f LQ Period QP 28 QP 32 QP 36 QP 40

Blurriness, noise and motion flicker Three influential factors Amplitude Most dominant effect Flicker is almost undetectable for amplitudes with H.264 quantization factors <8 almost always detectable for larger amplitudes Content Minor effect within the class But content can influence flicker perception; low interaction for noise flicker and stronger for blur flicker Frequency Major effect Acceptance thresholds compared to constant low quality video: worse when above 1 Hz, often better when below 0.5 Hz Remember for later: change at most once a second, better every two seconds

Dynamic Adaptive Streaming over HTTP The State-of-the-Art

Dynamic Adaptive Streaming over HTTP Divide video into segments at recording time or convert later Complete little movies Choose the segment duration playout time Choose the number of layers Choose the adaptation strategy quality Typical segment lengths: 2-10 seconds (2-hour movie à 3600++ small, indexed videos)

Dynamic Adaptive Streaming over HTTP UDP-based streaming resists packets loss random loss Applications IPTV DVB-H 4G telephony video conferencing classical RTSP/RTP servers DASH & similar scales to available bandwidth congestion loss Applications Commercial VoD: Netflix, Akamai, Microsoft, Apple, Comoyo,... MPEG DASH Free VoD: Youtube, Metacafe, Dailymotion, Vimeo, Revver, Flixya... Internet Client WLAN Server

Dynamic Adaptive Streaming over HTTP UDP-based streaming DASH & similar Challenges to be addressed Resilience to packet loss Possibly resilience to bit errors Possibly active adaptation (server-side decision) Resilience to buffer underruns Active adaptation (client-side decision) Works with web caches Internet Client WLAN Server

Fluctuating Bandwidth Problem

Adaptive Delivery: Tested Systems Adobe Strobe Media Playback (v1.6.328 for Flash 10.1) using HTTP Dynamic Streaming Format Apple s native ipad player (ios v4.3.3) using native HLS format Microsoft Silverlight/IIS Smooth (v4.0.60531.0 on Win7) using native Smooth format and default desktop scheduler Netview Media Client (v2011-10-10) using Apple HLS format (worst case) and Netview 3G scheduler

Comparison of Existing Quality Schedulers Bus: Ferry: Metro:

Distribution Architectures

Client-Server Traditional distributed computing Successful architecture, and will continue to be so (adding proxy servers) Tremendous engineering necessary to make server farms scalable and robust backbone network local distribution network local distribution network local distribution network

Distribution with proxies Hierarchical distribution system E.g. proxy caches that consider popularity completeness of available content root servers Popular data replicated more frequently and kept close to clients regional servers Unpopular ones close to the root servers local servers è Where to keep copies? end-systems

Zipf distribution and features Popularity Estimate the popularity of movies (or any kind of product) 1 x t y b a b ro p e v t a re probability Frequently used: Zipf distribution z(i) = C i ς 0.16 0.08 N 1 C =1/ n ς n=1 100,000 req 1,000,000 req Zipf 0 0 20 40 60 80 100 Objects movie sorted rank (out by of 500) popularity Danger Zipf-distribution of a process can only be applied while popularity doesn t change is only an observed property a subset of a Zipf-distributed dataset is no longer Zipfdistributed

0 0 0 0 0 1.1.01.01 Access probability distributions Times accessed 10 5 10 4 10 3 10 2 10 Zipf, alpha=1.3 Actual number of hits Zipf-distribution often used to assign popularities to simulated files Frequently observed Popularity over an entire log does not match a Zipf distribution 1 1 10 100 1000 All files in system Why? Zipf-distribution models a snapshot in time Popularity of news changes daily Must not model according to Zipfdistribution with access counts for more than one interval of popularity change Access frequency 100% 10% 1% 0.1% Actual popularity Zipf, alpha=1.2 1 10 100 Files ordered by daily popularity

Peer-to-Peer (P2P) Really an old idea - a distributed system architecture - No centralized control - Nodes are symmetric in function Typically, many nodes, but unreliable and heterogeneous backbone network local distribution network local distribution network local distribution network

P2P Many aspects similar to proxy caches Nodes act as clients and servers Distributed storage Bring content closer to clients Storage limitation of each node Number of copies often related to content popularity Necessary to make replication and de-replication decisions Redirection But No distinguished roles No generic hierarchical relationship: at most hierarchy per data item Clients do not know where the content is May need a discovery protocol All clients may act as roots (origin servers) Members of the P2P network come and go (churn)

P2P BitTorrent

BitTorrent Distributed download system Content is distributed in segments Tracker One central download server per content Approach to fairness (tit-for-tat) per content No approach for finding the tracker No content transfer protocol included

BitTorrent Segment download operation Ø Tracker tells peer source and number of segment to get Ø Peer retrieves content in pull mode Ø Peer reports availability of new segment to tracker Tracker

BitTorrent No second input stream: not contributed enough Tracker Rarest first strategy

BitTorrent No second input stream: not contributed enough All nodes: max 2 concurrent streams in and out Tracker

BitTorrent Tracker

BitTorrent Tracker

BitTorrent Tracker

P2P Distributed Hash Tables (DHTs)

Challenge: Fast, efficient lookups The BitTorrent tracker is a single point of failure How to distribute tracker functions to many (all) machines? è Distributed Hash Tables (DHTs) use a more structured key based routing

Lookup Based on Hash Tables hash table lookup(key) data Insert(key, data) 0 1 y z 2 key hash function pos 3...... Hash bucket N

Distributed Hash Tables (DHTs) Insert(key, data) Distributed application Lookup (key) Distributed hash tables data node node node. node Key identifies data uniquely Nodes are the hash buckets The keyspace is partitioned usually a node with ID = X has elements with keys close to X must define a useful key nearness metric DHT should balances keys and data across nodes Keep the hop count small Keep the routing tables right size Stay robust despite rapid changes in membership

Distributed Hash Tables Chord

Chord Approach taken Only concerned with efficient indexing Distributed index - decentralized lookup service Inspired by consistent hashing: SHA-1 hash Content handling is an external problem entirely No relation to content No included replication or caching P2P aspects Every node must maintain keys Adaptive to membership changes Client nodes act also as file servers

Chord IDs & Consistent Hashing m-bit identifier space for both keys and nodes Key identifier = SHA-1(key) Key= LetItBe SHA-1 ID=54 Node identifier = SHA-1(IP address) IP= 198.10.10.1 SHA-1 ID=123 Both keys and identifiers are uniformly distributed in the space of m-bit numbers Identifiers ordered in a circle modulo 2 m A key is mapped to the first node whose node ID key ID

Routing: Finger Tables Every node knows nodes that represent m other IDs in the ring Increase distances between these IDs exponentially Finger i points to successor of n+2 i

Routing: Finger Tables Every node knows nodes that represent m other IDs in the ring Increase distances between these IDs exponentially Finger i points to successor of n+2 i Lookup jumps to that node in its lookup table with largest ID where hash(search term) >= ID

Chord Assessment Large distributed index Scalability, fairness, load balancing Space complexity: routing tables are size O(log(#nodes)) Logarithmic insert effort Network topology is not accounted for Quick lookup in large systems, low variation in lookup costs Content location Run-time complexity: O(log(#nodes)) lookup steps Search by hash key: limited ways to formulate queries No failure resilience in basic approach Easy fix Successor lists allow use of neighbors to failed nodes create several index with different has functions (O(1))

Summary 1. Signaling protocols: RTSP and SIP 2. Adaptation with RTP: Loss Delay Adjustment Algorithm (LDA) 3. How to adapt video quality? 4. Dynamic Adaptive Streaming over HTTP (DASH) and related techniques 5. Distribution Architectures 6. P2P using the Zipf distribution DHTs Chord