Operating Systems Purpose of an Operating System Manage

  • Slides: 29
Download presentation

Operating Systems

Operating Systems

Purpose of an Operating System • Manage system resources – – – CPU scheduling

Purpose of an Operating System • Manage system resources – – – CPU scheduling Process management Memory management Input/Output device management Storage device management (hard disks, CD/DVD drives, etc) – File System Management • Simplify the development and use of applications

Mainstream Operating Systems • Microsoft Windows • Mac. OS • Mac and PCs are

Mainstream Operating Systems • Microsoft Windows • Mac. OS • Mac and PCs are not directly compatible but virtualization can be used.

UNIX • Operating system for large computers about 40 years ago. • Linux –

UNIX • Operating system for large computers about 40 years ago. • Linux – Free implementation of Unix – Supported by most platforms

Special Purpose OS • Most “devices” use an operating system to make application development

Special Purpose OS • Most “devices” use an operating system to make application development easier. • Examples: – cell phones (Symbian, Black. Berry, Windows Mobile, etc). – Aircraft Systems (Vx. Works, p. SOS, QNX)

Layers • Layers need to be concerned with layer below (and above) • Layers

Layers • Layers need to be concerned with layer below (and above) • Layers are isolated from certain changes

Running Multiple Operating Systems

Running Multiple Operating Systems

Virtual Machine Linux Application Linux (OS) Windows Application VMWare Application Windows (OS) Hardware

Virtual Machine Linux Application Linux (OS) Windows Application VMWare Application Windows (OS) Hardware

Running a Virtual Machine

Running a Virtual Machine

OS Modes • A typical operating system has two modes of operation. – User

OS Modes • A typical operating system has two modes of operation. – User Mode – Kernel Mode • These are like layers of operation within the operating system layer.

User Mode • The User Mode is concerned with the actual interface between the

User Mode • The User Mode is concerned with the actual interface between the user and the system. • It controls things like running applications and accessing files.

Kernel Mode • The Kernel Mode is concerned with everything running in the background.

Kernel Mode • The Kernel Mode is concerned with everything running in the background. • It controls things like: – accessing system resources – controlling hardware functions – processing program instructions. • The Kernel forms the core of the operating system. – acts like a supervisor for everything that is happening in the computer.

The Client-Server OS Model • In the client-server model of an operating system, the

The Client-Server OS Model • In the client-server model of an operating system, the User Mode is considered a client. – the User Mode accesses resources provided by the Kernel (the server).

Typical OS Architecture Service User mode (client) Application Application Interface Kernel mode (server) Kernel

Typical OS Architecture Service User mode (client) Application Application Interface Kernel mode (server) Kernel Hardware Graphics System Security System File System I/O Device Manager Memory Manager Scheduler Dispatcher

User Interface • Way for the user to control the operating system. • Two

User Interface • Way for the user to control the operating system. • Two types: graphical user interface (GUI) and command line interface

Who starts the OS?

Who starts the OS?

GUI & Command Line

GUI & Command Line

Command Line Interpreter • Converts typed commands into operating system actions (system calls). •

Command Line Interpreter • Converts typed commands into operating system actions (system calls). • Most interpreters execute applications to perform the system calls.

Managing System Resources • An operating system needs to manage a wide range of

Managing System Resources • An operating system needs to manage a wide range of system resources: – CPU scheduling and process management – Memory (RAM) – Access to peripheral devices – File system management.

CPU Scheduling Applications Word Internet Explorer Microsoft Outlook Adobe Acrobat • Decide when applications

CPU Scheduling Applications Word Internet Explorer Microsoft Outlook Adobe Acrobat • Decide when applications should run; does the order matter? • Are the applications active or sleeping? • Multiple applications at the same time

The Process Table • Keeping track of all of the processes is done with

The Process Table • Keeping track of all of the processes is done with the Process Table. • The Process Table lists: – Processes that are currently being run – Processes that are waiting to be executed – Processes that have been temporarily suspended – It also keeps track of the current status, or state, of each process.

Memory Management RAM Windows Word Internet Explorer Unused • Give memory to each application

Memory Management RAM Windows Word Internet Explorer Unused • Give memory to each application as needed. • Protect applications from each other • Protect operating system from ‘bad’ applications

Peripherals • • Devices are very difficult to program OS Provides Drivers Applications speak

Peripherals • • Devices are very difficult to program OS Provides Drivers Applications speak to drivers Drivers communicate to device

File System • Manage Information (files and folders) • Provide common view of storage

File System • Manage Information (files and folders) • Provide common view of storage devices

Review Questions 1. Describe two tasks that are performed by an operating system. 2.

Review Questions 1. Describe two tasks that are performed by an operating system. 2. Describe the four layers of interaction in an operating system model. 3. Briefly describe how you can install multiple operating systems on the same computer. 4. Draw a diagram to demonstrate how virtualization can be used to run multiple operating systems at the same time.

5. Briefly describe the client-server model of an operating system. 6. Draw a simple

5. Briefly describe the client-server model of an operating system. 6. Draw a simple diagram to show the two modes of operations of an OS. 7. Briefly describe the function of the Command Line Interpreter. 8. What are the major differences between System Calls and Interrupts? 9. Describe the purpose of the Process Table.

Thank you

Thank you