Question: Principal Architectural Similarities

Real-time and multimedia operating systems are in some ways similar. What are the principal architectural similarities and differences? What distinctive requirements does each have?
What operating systems are typically used with each?

I am taking course Operating system concepts by textbook of Silberschatz, 9th edition.
please check my textbook here:

https://drive.google.com/file/d/0B8zfGJ22TlnjVmFlc0pyaEJIbjg/edit?usp=sharing

A special purpose operating system is a system designed to execute a particular type of application, to solve a specific type of problem, or to execute in a highly constrained environment. Real-time and multimedia operating systems are examples of special purpose systems. Real-time systems are systems designed to solve a specific type of problem, and when they are embedded configurations they are designed to execute in a highly constrained environment. Multimedia operating systems are systems designed to serve a particular range of applications. This lecture provides an overview of these two types of special purpose operating systems. Considering these two types of special purpose systems in conjunction with one another is illuminating, for, as will be discussed, multimedia systems fall into a category of real-time systems known as soft real-time systems. To this extent, an appreciation of how multimedia systems work will support an enhanced understanding of real-time systems.

Real-Time Operating Systems With real-time systems, timing is crucial. This is not merely a matter of being fast, although that is often a challenge. Real-time systems are associated with three distinguishing attributes: determinism, hardness, and jitter (National Instruments, 2011; Silberschatz, Galvin, & Gagne, 2009). To the extent that the system is deterministic, processing must take place within fixed time constraints—not too soon and not too late, but on time. For example, in an automated assembly line, robots must perform their tasks at precise intervals. If a robotic welder applies a weld at the wrong time, of if the welding process itself does not adhere to a precise timeline, the weld may be faulty, resulting in a defective product. Hardness refers to the absoluteness of the determinism. A system is said to exhibit hard real time if it absolutely guarantees adherence to its time constraints. A soft real time guarantees that it will meet its time constraints most, but not all, of the time. A multimedia operating system is an example of a soft real-time system. The softer the system, the more prone to jitter it is. Jitter is a measure of the consistency with which the system meets its deadlines. Real-time operating systems are designed to minimize jitter. Real-time systems are typically deployed to perform a single, well-defined

activity. Some familiar examples are the cruise control systems and antilock brake systems installed in automobiles. Consequently, these systems do not need many of the features supported in general purpose operating systems. For example, they do not need to support a wide range of devices, and they do not usually need elaborate security and protection mechanisms (Silberschatz et al., 2009). They may not even have a user interface, or the interface may be very simple, as in the case of a cruise control system. If the system is a single tasking system, it will not need an elaborate memory management subsystem. Indeed, virtual addressing may be avoided even in multiprocessing real-time operating systems, as this reduces system complexity and context-switching performance. Instead, the operating system may use real-addressing mode, which lacks memory protection and requires programmers to specify fixed memory locations for their applications in advance (Silberschatz et al., 2009). Real-time systems make special demands on their schedulers and on interrupt handling. The scheduler must be priority-based, always guaranteeing that the highest process will be running. In some systems, the processes may run in kernel mode, so the scheduler must be designed to support preemption within the kernel (Silberschatz et al., 2009). In their survey of real-time scheduling, Ramamritham and Stankovic (1994) identify four paradigms underlying the scheduling approaches. Static table-driven schedulers can be used for mission-critical processes that can be statically pre-allocated to guarantee that their deadlines will be met even under worst-case conditions. This is most suitable when the characteristics of the process are simple, lending themselves to the use of earliest-deadlinefirst (EDF) shortest-period-first techniques. Static priority preemptive scheduling is frequently used in time-sharing systems. For use in real-time systems, assignment of process priority is set relative to time constraints associated with the process; this may be static or dynamic. For example, the rate monotonic scheduling algorithm is a static algorithm that assigns priorities to equate with their rate requirements, so that the highest rate requirement always receives the highest priority (Liu & Layland, 1973). Dynamic planning-based scheduling constructs a plan for process execution where each process meets its timing constraints. The plan incorporates assumptions about each process’s performance, including expected worst-case execution time and resource needs, system faults, timing constraints, and other factors. So long as the assumptions are met, each process is guaranteed to meet its deadlines and rates. Dynamic best effort scheduling is perhaps the most-used deployed real-time scheduling approach. Each process is assigned a priority based on its characteristics, and the process is scheduled based on its priority. Simulations are typically used to refine and adjust the schedule and to build confidence in the system. Some algorithms based on dynamic best-effort scheduling include highest-

priority-first-scheduling, earliest deadline first, least laxity first, shortest processing time first, and first come first served. In addition to special scheduling considerations, real-time operating systems must manage interrupt and dispatch latency. Interrupt latency is the time required to service an interrupt once the interrupt request is received. Interrupt latency must be precisely specifiable. Acceptable latency will vary depending on the application—for example, antilock brake systems must respond within 3 to 5 milliseconds, whereas a radar-controlling system can respond within several seconds (Silberschatz et al., 2009)—but whatever the tolerable limit is, it must be guaranteed. Dispatch latency refers to the time required to perform context switching from one process to another. In general purpose operating systems, a switch from one process to another, or back to a process following an interrupt, involves a significant amount of overhead sometimes requiring hundreds of milliseconds. Real-time operating systems must minimize these latencies. In some cases the real-time system may be stripped down to the point that it consists of a set of libraries that the application links with (Tanenbaum, 2008). The eCos real-time operating system for embedded applications is an example of this (eCos, n.d.). This open source product provides a real-time kernel, interrupt handling, a choice of schedulers, thread support, synchronization primitives, a choice of memory managers, and other features. Although many currently deployed monitoring and control systems, such as the supervisory control and data acquisition (SCADA) systems used in power generation, include little or no security or protection mechanisms, these types of systems are becoming increasingly vulnerable (Mahboob & Zubairi, 2010; Mills, 2009). This is because they are more frequently integrated using the internet, and they are more likely to be deployed on platforms with standard interfaces, such as USB. For example, the famous Stuxnet worm spread using a combination of both USB flash drives and RPC (Matrosov, Rodionov, Harley, & Malcho, 2010).

Multimedia Operating Systems The term multimedia usually refers to various file formats and applications that incorporate the use of video and audio. A multimedia operating system is an operating system designed to accommodate the special requirements of these media. For example, large file systems are required to accommodate the size of the media, which may be multiple terabytes, and

file I/O imposes particular timing requirements to achieve acceptable playback or streaming rates, which may be implemented using progressive download techniques or real-time streaming across the internet. Data are frequently compressed for more efficient storage and transmission and are decoded on the fly when accessed. Consequently, multimedia applications make significant demands of the operating system, and these have implications for operating system design, in particular for the scheduler, the file system, and networking. As mentioned earlier, a multimedia operating system is a soft real-time system, and while this is generally true, there is a range of hardness possible, and one of the ways a multimedia server can be differentiated from others is in terms of its ability to meet specific rate and deadline requirements. The extent to which an operating system is able to do so is defined in terms of its quality of service (QoS) parameters. These parameters include average bandwidth, peak bandwidth, minimum and maximum delay, and bit-loss probability (Tanenbaum, 2008). There are three levels of QoS: best effort, soft QoS, and hard QoS (Silberschatz et al., 2009). These can be viewed as metrics for the hardness of the systems with respect to real-time requirements. Multimedia servers use resource reservation schemes and admission control algorithms to determine whether they can meet a guaranteed QoS level (Tanenbaum, 2008). A variety of admission control algorithms have been developed, including bandwidth utilization estimation (Jiang & Mohapatra, 1999); statistical variation in disk access times and variation in client load (H. Vin, P. Goyal, & A. Goyal, 1994a); observation-based admission control (H. Vin, P. Goyal, & A. Goyal, 1994b); and cost-based admission control (Chen & Verma, 2003). The operating system scheduler uses such algorithms to determine whether it can meet the rate and deadline requirements of a client and rejects the request if it cannot. Real-time scheduling algorithms must be designed to meet the rate and deadline requirements of competing processes. QoS requirements must be met in an environment in which processing demands change unpredictably as clients come and go, frame sizes vary, and video resolutions vary depending on the format of the particular video file. This makes the work of the scheduler more difficult. In order for the scheduler to enable processes to maintain their rates and meet their deadlines, it must have information about each process’s requirements (Tanenbaum, 2008). Under such circumstances, a process that is at risk of missing a deadline must be able to interrupt other processes and gain access to the CPU. Several algorithms have been devised to handle this. For example, the rate monotonic scheduling algorithm mentioned earlier assigns priorities to equate with their rate requirements, so that the highest rate requirement always receives the highest priority (Liu & Layland, 1973). Another popular

algorithm, earliest deadline first is a dynamic scheduling algorithm. It keeps track of the deadlines of each process, and as the name of the algorithm suggests, it gives priority to the process with the closest deadline. The deadline list is updated whenever a process becomes ready to run. Multimedia systems also use specialized networking methods for delivering media. With the unicasting scheme, the server transmits a dedicated stream to each client. For busy systems, the transmission load can increase rapidly. However, this is the method most frequently used. Other methods include broadcasting and multicasting. With broadcasting, transmissions are streamed to all clients, regardless of whether they have requested it. That is the model used for old-fashioned radio and television. Multicasting transmits the same content to multiple clients who have requested it. For multicasting to work, all routers along the transmission path must cooperate; otherwise, QoS guarantees will be compromised (Silberschatz et al., 2009).

References Chen, I.-R., & Verma, N. (2003). A cost-based admission control algorithm for digital library multimedia systems storing heterogeneous objects. The Computer Journal, 46(6), 645–659. eCos. (n.d.). Home Page. Retrieved from http://ecos.sourceware.org/ Jiang, X., & Mohapatra, P. (1999). Efficient admission control algorithms for multimedia servers. Multimedia Systems, 7(4), 294–304. doi: 10.1007/s005300050131 Liu, C. L., & Layland, J. W. (1973). Scheduling algorithms for multiprogramming in a hard-real-time environment. Journal of the ACM (JACM), 20(1), 46–61. doi: 10.1145/321738.321743 Mahboob, A., & Zubairi, J. (2010). Intrusion avoidance for SCADA security in industrial plants. International Symposium on Collaborative Technologies and Systems (CTS 2010) (pp. 447–452). Matrosov, A., Rodionov, E., Harley, D., & Malcho, J. (2010, September). Stuxnet under the microscope. Retrieved from http://go.eset.com/us/resources/white-papers/Stuxnet_Under_the_Microscope.pdf Mills, E. (2009, April 10). Just how vulnerable is the electrical grid? Retrieved from http://news.cnet.com/83011009_3-10216702-83.html National Instruments. (2011). What is a real-time operating system (RTOS)? Retrieved from http://zone.ni.com/devzone/cda/tut/p/id/3938 Ramamritham, K., & Stankovic, J. A. (1994). Scheduling algorithms and operating systems support for realtime systems. Proceedings of the IEEE, 82(1), 55–67. doi: 10.1109/5.259426 Silberschatz, A., Galvin, P. B., & Gagne, G. (2009). Operating system concepts. Hoboken, NJ: John Wiley & Sons. Tanenbaum, A. (2008). Modern operating systems (3rd ed.). Upper Saddle River, NJ: Pearson. Vin, H., Goyal, P., & Goyal, A. (1994a). A statistical admission control algorithm for multimedia servers. Proceedings of the second ACM international conference on Multimedia (pp. 33-40). San Francisco: ACM. Vin, H., Goyal, P., & Goyal, A. (1994b). An observation-based admission control algorithm for multimedia servers. Proceedings of the International Conference on Multimedia Computing and Systems (pp. 234– 243).

term papers to buy
research papers