Chapter 14 - Structure of operating systems. This chapter discusses three methods of structuring an operating system. The layered structure of operating systems simplifies coding, the kernel-based structure provides ease of implementation on different computer systems, and the microkernel-based structure permits modification of an operating system’s features to adapt to changes in the computing environment and also provides ease of implementation on different computer systems.
Trang 1PROPRIETARY MATERIAL. © 2007 The McGrawHill Companies, Inc. All rights reserved. No part of this PowerPoint slide may be displayed, reproduced or distributed
Trang 2– Protection and Security
• OS should be structured so that it can cope with
changes in computer systems and computing
environments
Trang 3Operation of an OS
• Three key aspects of OS operation are
– Booting
* Determines configuration of the system, viz CPU, I/O devices, etc.
* Loads the kernel, initializes its data structures and hands over control
Trang 6* A guiding principle that should be used to manage a class of entities
* For example, round-robin scheduling
– Mechanism
* A specific operation needed to implement a policy
* For example, dispatching
Trang 7Portability and extensibility of OS
• For cost-effectiveness, OS lifetime should be >10 years
– Several changes take place during this time
* Computer architecture, I/O device technology, computing environments change
– The OS should be able to cope with these changes
It should be possible to adapt to changes
For example, modify OS functionalities or add new ones
Trang 8Operating Systems Dhamdhere: Operating Systems—A ConceptBased Approach, 2 ed Copyright © 2008Slide No: 8
Problems with monolithic OS structure
• OS code did not have modules with well-defined
interfaces
– Functionalities knew each other’s data and could access directly – The OS layer had both architecture dependent and architecture independent code
* Hence portability was poor
Trang 9Alternative OS structures
• Problems with monolithis structure led to developments
of three methods of structuring
Trang 10Operating Systems Dhamdhere: Operating Systems—A ConceptBased Approach, 2 ed Copyright © 2008Slide No: 10
Layered design of operating systems
• An OS is structured into a number of layers
– Each layer provides a set of services
– A higher layer uses the services of the immediate lower layer
* Helps in controlling complexity and cost of developing and maintaining an OS by reducing the semantic gap
Trang 13Layers of THE multiprogramming system
• Layers 0 and 1 perform processor and memory management, respectively
• Layer 3 hides intricacies of devicelevel I/O
Trang 14– It creates several virtual machines
* A virtual machine is like a virtual resource
* It has the same architecture as the real computer, i.e the host machine, but does not contain some of its features
For example, it may not support some instructions of the host computer
– VM OS interleaves operation of several virtual machines
* Instructions of the selected virtual machine are executed on the host machine, which ensures efficiency of its operation
– Each virtual machine has its own operating system, called a
guest OS
– This way, several operating systems can operate on the host
computer concurrently
Trang 15VM OS
• VM/370 is an early widely known VM OS; it worked on IBM/370
Trang 16* Application processes uses the capabilities of a virtual machine
– Virtualization is the process by which capabilities of host
machine are made available in virtual machine (VM)
* Full virtualization: all capabilities of host are available in VM
May lead to lack of security as VM OS cannot prevent an application process from using privileged instructions
* If full virtualization is not used, guest OS must invoke the VM OS to use some capabilities of the host machine
Trang 19Mechanisms in a kernel
Trang 20Operating Systems Dhamdhere: Operating Systems—A ConceptBased Approach, 2 ed Copyright © 2008Slide No: 20
Dynamically loadable kernel modules
• Kernel modules have well-specified interfaces
– Facilitates dynamic loading of kernel modules
* Conserves memory by loading only the required modules
* Provides extensibility as kernel modules can be modified separately
Trang 23Architecture of Windows
• The HAL provides abstractions of I/O interfaces, interrupt controllers and interprocess communication processes in a multiprocessor system
• HAL and the kernel are together equivalent of the conventional kernel