CS 414 - Spring 2012 CS 414 – Multimedia Systems Design Lecture 31 – Media Server (Part 1) Klara Nahrstedt Spring 2012.

Slides:



Advertisements
Similar presentations
Disk Storage SystemsCSCE430/830 Disk Storage Systems CSCE430/830 Computer Architecture Lecturer: Prof. Hong Jiang Courtesy of Yifeng Zhu (U. Maine) Fall,
Advertisements

CS 414 – Multimedia Systems Design Lecture 26 – Media Server (Part 2)
I/O Management and Disk Scheduling Chapter 11. I/O Driver OS module which controls an I/O device hides the device specifics from the above layers in the.
Operating Systems ECE344 Ashvin Goel ECE University of Toronto Disks and RAID.
CS Spring 2009 CS 414 – Multimedia Systems Design Lecture 28 – Media Server (Part 3) Klara Nahrstedt Spring 2009.
Continuous Media 1 Differs significantly from textual and numeric data because of two fundamental characteristics: –Real-time storage and retrieval –High.
CS Spring 2012 CS 414 – Multimedia Systems Design Lecture 14 – Introduction to Multimedia Resource Management Klara Nahrstedt Spring 2012.
Chapter 20: Multimedia Systems Silberschatz, Galvin and Gagne ©2005 Operating System Concepts Chapter 20: Multimedia Systems What is Multimedia.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition Chapter 20: Multimedia Systems.
CSE506: Operating Systems Disk Scheduling. CSE506: Operating Systems Key to Disk Performance Don’t access the disk – Whenever possible Cache contents.
CS Spring 2012 CS 414 – Multimedia Systems Design Lecture 35 – Media Server (Part 4) Klara Nahrstedt Spring 2012.
CS Spring 2011 CS 414 – Multimedia Systems Design Lecture 27 – Media Server (Part 3) Klara Nahrstedt Spring 2011.
CS Spring 2012 CS 414 – Multimedia Systems Design Lecture 15 –QoS Admission, QoS Negotiation, and Establishment of AV Connections Klara Nahrstedt.
CS-3013 & CS-502, Summer 2006 Multimedia topics (continued)1 Multimedia Topics (continued) CS-3013 & CS-502 Operating Systems.
Lecture 17 I/O Optimization. Disk Organization Tracks: concentric rings around disk surface Sectors: arc of track, minimum unit of transfer Cylinder:
Disk Drivers May 10, 2000 Instructor: Gary Kimura.
CS 104 Introduction to Computer Science and Graphics Problems Operating Systems (4) File Management & Input/Out Systems 10/14/2008 Yang Song (Prepared.
A Server-less Architecture for Building Scalable, Reliable, and Cost-Effective Video-on-demand Systems Presented by: Raymond Leung Wai Tak Supervisor:
CS Spring 2012 CS 414 – Multimedia Systems Design Lecture 34 – Media Server (Part 3) Klara Nahrstedt Spring 2012.
Disk and I/O Management
MM File Management Karrie Karahlaios and Brian P. Bailey Spring 2007.
CS Spring 2012 CS 414 – Multimedia Systems Design Lecture 32 – Media Server (Part 2) Klara Nahrstedt Spring 2012.
CS Spring 2011 CS 414 – Multimedia Systems Design Lecture 28 – Media Server (Part 4) Klara Nahrstedt Spring 2011.
CS4432: Database Systems II Data Storage (Better Block Organization) 1.
CS 346 – Chapter 10 Mass storage –Advantages? –Disk features –Disk scheduling –Disk formatting –Managing swap space –RAID.
B. Prabhakaran1 Multimedia Storage & Retrieval Large sizes as well as real-time requirements of multimedia objects influence their storage and retrieval.
E0262 MIS - Multimedia Playback Systems Anandi Giridharan Electrical Communication Engineering, Indian Institute of Science, Bangalore – , India.
Topic: Disks – file system devices. Rotational Media Sector Track Cylinder Head Platter Arm Access time = seek time + rotational delay + transfer time.
Page 15/25/2016 CSE 40373/60373: Multimedia Systems QoS Classes  Guaranteed Service Class  QoS guarantees are provided based on deterministic and statistical.
Disk Structure Disk drives are addressed as large one- dimensional arrays of logical blocks, where the logical block is the smallest unit of transfer.
CS Spring 2012 CS 414 – Multimedia Systems Design Lecture 28 – Final Comments on DASH and Client-Server Buffer Management Klara Nahrstedt Spring.
XE33OSA Chapter 20: Multimedia Systems. 20.2XE33OSA Silberschatz, Galvin and Gagne ©2005 Chapter 20: Multimedia Systems What is Multimedia Compression.
CS Spring 2012 CS 414 – Multimedia Systems Design Lecture 29 – Buffer Management (Part 2) Klara Nahrstedt Spring 2012.
CS Spring 2011 CS 414 – Multimedia Systems Design Lecture 30 – Media Server (Part 6) Klara Nahrstedt Spring 2011.
CE Operating Systems Lecture 20 Disk I/O. Overview of lecture In this lecture we will look at: Disk Structure Disk Scheduling Disk Management Swap-Space.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition, Multimedia Systems.
CS Spring 2011 CS 414 – Multimedia Systems Design Lecture 25 – Media Server (Part 1) Klara Nahrstedt Spring 2011.
Practice 8 Chapter Ten. 1. Is disk scheduling, other than FCFS scheduling, useful in a single-user environment? Explain your answer. Answer: In a single-user.
Lecture 3 Page 1 CS 111 Online Disk Drives An especially important and complex form of I/O device Still the primary method of providing stable storage.
CS Spring 2014 CS 414 – Multimedia Systems Design Lecture 18 – Multimedia Transport (Part 1) Klara Nahrstedt Spring 2014.
CS Spring 2009 CS 414 – Multimedia Systems Design Lecture 30 – Media Server (Part 5) Klara Nahrstedt Spring 2009.
Storing and Serving Multimedia. What is a Media Server? A scalable storage manager Allocates multimedia data optimally among disk resources Performs memory.
Operating System concerns for Multimedia Multimedia File Systems -Jaydeep Punde.
CS Spring 2014 CS 414 – Multimedia Systems Design Lecture 30 – Final Comments on DASH and Client-Server Buffer Management Klara Nahrstedt Spring.
NUS.SOC.CS5248 Ooi Wei Tsang 1 Course Matters. NUS.SOC.CS5248 Ooi Wei Tsang 2 Make-Up Lecture This Saturday, 23 October TR7, 1-3pm Topic: “CPU scheduling”
Multimedia Retrieval Architecture Electrical Communication Engineering, Indian Institute of Science, Bangalore – , India Multimedia Retrieval Architecture.
Introduction to Quality of Service Klara Nahrstedt CS 538.
CS Spring 2009 CS 414 – Multimedia Systems Design Lecture 27 – Media Server (Part 2) Klara Nahrstedt Spring 2009.
CS Spring 2014 CS 414 – Multimedia Systems Design Lecture 17 – QoS Classes and Setup Operations Klara Nahrstedt Spring 2014.
Chapter 20: Multimedia Systems
Multimedia Systems Operating System Presentation On
CS 414 – Multimedia Systems Design Lecture 31 – Media Server (Part 5)
Chapter 20: Multimedia Systems
Klara Nahrstedt Spring 2009
Klara Nahrstedt Spring 2009
Klara Nahrstedt Spring 2012
Disks and RAID.
Operating System I/O System Monday, August 11, 2008.
Klara Nahrstedt Spring 2010
Lecture 45 Syed Mansoor Sarwar
Chapter 20: Multimedia Systems
Data Orgnization Frequently accessed data on the same storage device?
Disks and scheduling algorithms
Persistence: hard disk drive
Chapter 11 I/O Management and Disk Scheduling
Chapter 20: Multimedia Systems
CSE451 File System Introduction and Disk Drivers Autumn 2002
Chapter 20: Multimedia Systems
Chapter 20: Multimedia Systems
Presentation transcript:

CS Spring 2012 CS 414 – Multimedia Systems Design Lecture 31 – Media Server (Part 1) Klara Nahrstedt Spring 2012

Administrative MP2 posted MP2 Deadline – April 7, Saturday, 5pm. CS Spring 2012

Covered Aspects of Multimedia Image/Video Capture Media Server Storage Transmission Compression Processing Audio/Video Presentation Playback Audio/Video Perception/ Playback Audio Information Representation Transmission Audio Capture A/V Playback Image/Video Information Representation CS Spring 2012

Outline Media Server Requirements Media Server Layered Architecture CS Spring 2012

Client/Server Video-on-Demand System CS Spring 2012

Video-on-Demand Systems must be designed with goals: Avoid starvation Minimize buffer space requirement Minimize initiation latency (video startup time) Optimize cost CS Spring 2012

Media Server Requirements Real-time storage and retrieval  Media quanta must be presented using the same timing sequence with which they were captured High-Data Transfer Rate and Large Storage Space  HDTV quality: 1280x720 pixels/frame; 24 bits/pixel -> 81 Mbytes per second  NTCS quality: 640x480 pixels/frame; 24 bits/pixel ->27MBytes per seconds CS Spring 2012

YouTube Video Server (2010) utube-at-5-years-old-2-billion-served-per- day/ utube-at-5-years-old-2-billion-served-per- day/ May 2010, 2 Billion videos served per day More than 24 hours of video uploaded every minute Videos usually less than 10 minutes long CS Spring 2012

YouTube Video Server (2011) Over 4 B videos are viewed a day 60 hours of video are uploaded every minute Over 800 million unique users visit YouTube each month 70% of YouTube traffic comes from outside US In 2011, YouTube had more than 1 trillion views (140 views for every person on Earth) CS Spring 2012 Source:

Video Playback Issues Single Stream Playback  Possible approach – buffer the whole stream Problem:??  Possible approach – prefetch just short video part Problem:  Prevent starvation  Minimize buffer space requirement  Minimize initiation latency Multiple Streams Playback  Possible approach – dedicate a disk to each stream Problem: ??  Possible approach – multiple streams per disk Problems: ?? CS Spring 2012

Media Server Architecture CS Spring 2012 Storage device Disk control - scheduling Storage management File System Memory Management Content Directory/Distribution Network Attachment Incoming request Delivered data

Storage Device- Disk Layout CS Spring 2012 Track Sector Zoned Disk (ZBR – Zone Bit Recording) Traditional Random Access Disk Layout Advantage: Easy mapping of location Information to head movement and disk rotation Problem: loss of storage space Advantage: Sector size same Rotation speed constant; efficient Usage of space

Storage/Disk Management Optimal placement of MM data blocks  Single disk  multiple disks Timely disk scheduling algorithms and sufficient buffers to avoid jitter Possible Admission control CS Spring 2012

Storage Management Storage access time to read/write disk block is determined by 3 components  Seek Time Time required for the movement of read/write head  Rotational Time (Latency Time) Time during which transfer cannot proceed until the right block or sector rotates under read/write head  Data Transfer Time Time needed for data to copy from disk into main memory CS Spring 2012

Impact of Access Time Metrics If data blocks are arbitrarily placed If requests are served on FCFC basis Then effort for locating data place may cost time period in order of magnitude 10ms This performance degrades disk efficiency Need techniques to reduce seek, rotation and transmission times !!! CS Spring 2012

MM Data Placement on Single Disk CS Spring 2012 Continuous PlacementNon-contiguous Placement Simple to implement, but subject to fragmentation Avoids fragmentation Enormous copying overhead during insert/delete to maintain continuity Avoid copying overhead When reading file, only one seek required to position the disk head at the start of data When reading file, seek operation incurs for each block, hence intrafile seek

Intra-file Seek Time Intra-file seek – can be avoided in non- contiguous layout if the amount read from a stream always evenly divides block Solution: select sufficient large block and read one block in each round  If more than one block is required to prevent starvation prior to next read, deal with intra- file seek Solution: constrained placement or log- structure placement CS Spring 2012

Non-continuous Placement CS Spring 2012

Constrained Placement Approach: separation between successive file blocks is bounded  Bound on separation – not enforced for each pair of successive blocks, but only on average over finite sequence of blocks  Attractive for small block sizes  Implementation – expensive For constrained latency to yield full benefit, scheduling algorithm must retrieve immediately all blocks for a given stream before switching to another stream CS Spring 2012

Log-Structure Placement This approach writes modified blocks sequentially in a large contiguous space, instead of requiring seek for each block in stream when writing (recording)  Reduction of disk seeks  Large performance improvements during recording, editing video and audio Problem: bad performance during playback Implementation: complex CS Spring 2012

MM Data Placement at Multiple Disks CS Spring 2012 Data Interleaving On Multiple Disks (Disks are not Synchronized) Striping data across Multiple disks Data Interleaving On single disk (consecutive blocks are placed on The same cylinder But in interleaved way

Disk Scheduling Policies Goal of Scheduling in Traditional Disk Management  Reduce cost of seek time  Achieve high throughput  Provide fair disk access Goal of Scheduling in Multimedia Disk Management  Meet deadline of all time-critical tasks  Keep necessary buffer requirements low  Serve many streams concurrently  Find balance between time constraints and efficiency CS Spring 2012

Disk Scheduling Framework Must support multiple QoS levels and requests CS Spring 2012 Source: Reddy et al, “Disk Scheduling in a Multimedia I/O System”, ACM TOMCCAP 2005

EDF (Earliest Deadline First) Disk Scheduling Each disk block request is tagged with deadline  Very good scheduling policy for periodic requests Policy:  Schedule disk block request with earliest deadline  Excessive seek time – high overhead  Pure EDF must be adapted or combined with file system strategies CS Spring 2012

EDF Example CS Spring 2012 Note: Consider that block number Implicitly encapsulates the disk track number

SCAN-EDF Scheduling Algorithm Combination of SCAN and EDF algorithms Each disk block request tagged with augmented deadline  Add to each deadline perturbation Policy:  SCAN-EDF chooses the earliest deadline  If requests with same deadline, then choose request according to scan direction CS Spring 2012

Implementation of SCAN-EDF Notation:  D i be deadline of disk block request ‘i’  N i be track (block) position on disk  N max be maximum number of disk tracks Deadline Modification:  D i + f(N i )  f(N i ) converts track number of ‘i’ into a small perturbation of deadline  Perturbation small enough so that D i + f(N i ) ≤ D j + f(N j ) for D i ≤ D j Possible f(N i ) = N i /N max CS Spring 2012

SCAN EDF Example (N max = 100) CS Spring 2012

Enhanced SCAN-EDF (1) Use more accurate perturbation of deadline Consider  Actual track position of disk head ‘N’  N max – max number of disk tracks  N i – next track to be considered CS Spring 2012 Head Moves Upwards

Enhanced SCAN-EDF (2) Algorithm:  If head moves upwards (towards N max ), then  (a)  (b) CS Spring 2012

Enhanced SCAN-EDF (3) If head moves downwards (towards 1), then (a) (b) CS Spring 2012

Group Sweeping Algorithms Policy:  Each Request consists of (Deadline, Block Number )  Disk Block Requests served in cycles  In one cycle, requests divided into groups according to similar deadlines  Within group use SCAN  As we retrieve blocks, we may need smoothing buffers to ensure continuity CS Spring 2012

Group Sweeping Example CS Spring 2012

Mixed Scheduling (uses SSTF – Shortest Seek Time First) CS Spring 2012 Example of SSTF

Mixed Scheduling CS Spring 2012 SSTF (Shortest Seek Time First) + Balanced Strategy

Conclusion Media Server Architecture Storage Management  Data/file placement on single disk  Data/file placement on multiple disks Disk Scheduling – important component in the timely delivery of streams Admission should be done if one cares not to over subscribe CS Spring 2012