Operating System Components



Similar documents
Chapter 3: Operating-System Structures. Common System Components

Common Operating-System Components

Chapter 3: Operating-System Structures. System Components Operating System Services System Calls System Programs System Structure Virtual Machines

Objectives. Chapter 2: Operating-System Structures. Operating System Services (Cont.) Operating System Services. Operating System Services (Cont.

Chapter 3 Operating-System Structures

Operating system Dr. Shroouq J.

Introduction to Operating Systems. Perspective of the Computer. System Software. Indiana University Chen Yu

Components of a Computer System

Overview of Operating Systems Instructor: Dr. Tongping Liu

How do Users and Processes interact with the Operating System? Services for Processes. OS Structure with Services. Services for the OS Itself

Operating Systems OS Architecture Models

System Structures. Services Interface Structure

Operating System Structures

Kernel Types System Calls. Operating Systems. Autumn 2013 CS4023

Last Class: OS and Computer Architecture. Last Class: OS and Computer Architecture

Review from last time. CS 537 Lecture 3 OS Structure. OS structure. What you should learn from this lecture

Last Class: OS and Computer Architecture. Last Class: OS and Computer Architecture

Operating System Structures

Example of Standard API

Operating Systems 4 th Class

Chapter 2 System Structures

Lesson Objectives. To provide a grand tour of the major operating systems components To provide coverage of basic computer system organization

CPS221 Lecture: Operating System Structure; Virtual Machines

Lecture 1 Operating System Overview

CSE 120 Principles of Operating Systems. Modules, Interfaces, Structure

OPERATING SYSTEM SERVICES

Operating System Structure

CS3600 SYSTEMS AND NETWORKS

OPERATING SYSTEMS STRUCTURES

OS Concepts and structure

Chapter 2: OS Overview

ELEC 377. Operating Systems. Week 1 Class 3

Principles of Operating Systems CS 446/646

CS420: Operating Systems OS Services & System Calls

CS161: Operating Systems

Operating System Components and Services

Introduction. What is an Operating System?

Chapter 6, The Operating System Machine Level

EECS 678: Introduction to Operating Systems

Operating System Organization. Purpose of an OS

Operating Systems. Rafael Ramirez (T, S)

Chapter 2: Operating-System Structures. Operating System Concepts 9 th Edition

CHAPTER 15: Operating Systems: An Overview

Computer Science 4302 Operating Systems. Student Learning Outcomes

Operating System Tutorial

COS 318: Operating Systems


Operating Systems. Design and Implementation. Andrew S. Tanenbaum Melanie Rieback Arno Bakker. Vrije Universiteit Amsterdam

Outline. Operating Systems Design and Implementation. Chap 1 - Overview. What is an OS? 28/10/2014. Introduction

Chapter 1: Introduction. Chapter 1: Introduction. Operating System Concepts, 7th Edition. Objectives

Page 1 of 5. IS 335: Information Technology in Business Lecture Outline Operating Systems

Chapter 1: Introduction. What is an Operating System?

Chapter 11 I/O Management and Disk Scheduling

Introduction to Virtual Machines

A Comparison of Distributed Systems: ChorusOS and Amoeba

Operating System Software

CHAPTER 1: OPERATING SYSTEM FUNDAMENTALS

Introduction. System Calls

Unit 10 : An Introduction to Linux OS

Process Description and Control william stallings, maurizio pizzonia - sistemi operativi

Microkernels, virtualization, exokernels. Tutorial 1 CSC469

Operating Systems PART -A

CS 377: Operating Systems. Outline. A review of what you ve learned, and how it applies to a real operating system. Lecture 25 - Linux Case Study

How To Write A Windows Operating System (Windows) (For Linux) (Windows 2) (Programming) (Operating System) (Permanent) (Powerbook) (Unix) (Amd64) (Win2) (X

Operating Systems Overview

Virtualization for Cloud Computing

Distributed File Systems

Chapter 10 Case Study 1: LINUX

Weighted Total Mark. Weighted Exam Mark

Operating Systems OBJECTIVES 7.1 DEFINITION. Chapter 7. Note:

Chapter 3. Operating Systems

CSC 2405: Computer Systems II

Computer Organisation Operating Systems

International Engineering Journal For Research & Development

The Plan Today... System Calls and API's Basics of OS design Virtual Machines

This tutorial will take you through step by step approach while learning Operating System concepts.

Lecture 25 Symbian OS

CS 3530 Operating Systems. L02 OS Intro Part 1 Dr. Ken Hoganson

Multi-core Programming System Overview

INTRODUCTION TO OPERATING SYSTEMS

Computer Systems and Networks. ECPE 170 Jeff Shafer University of the Pacific. Linux Basics

Multiprogramming. IT 3123 Hardware and Software Concepts. Program Dispatching. Multiprogramming. Program Dispatching. Program Dispatching

Chapter 1: Introduction. Operating System Concepts 9 th Edit9on

Raid storage. Raid 0: Striping. Raid 1: Mirrored

Red Hat Linux Internals

Operating Systems: Basic Concepts and History

Linux Kernel Architecture

Have both hardware and software. Want to hide the details from the programmer (user).

Memory management basics (1) Requirements (1) Objectives. Operating Systems Part of E1.9 - Principles of Computers and Software Engineering

Star System Deitel & Associates, Inc. All rights reserved.

FAME Operating Systems

COS 318: Operating Systems. Virtual Machine Monitors

UNISOL SysAdmin. SysAdmin helps systems administrators manage their UNIX systems and networks more effectively.

Configuring Apache Derby for Performance and Durability Olav Sandstå

Unit 4 Objectives. System Software. Component 4: Introduction to Information and Computer Science. Unit 4: Application and System Software Lecture 2

GETTING STARTED WITH ANDROID DEVELOPMENT FOR EMBEDDED SYSTEMS

Virtual machine interface. Operating system. Physical machine interface

Chapter 2 Basic Structure of Computers. Jin-Fu Li Department of Electrical Engineering National Central University Jungli, Taiwan

Transcription:

Lecture Overview Operating system software introduction OS components OS services OS structure Operating Systems - April 24, 2001 Operating System Components Process management Memory management Secondary storage management I/O system management File management Protection system Networking Command interpreter 1

Process Management A process is the unit of work in an operating system Processes are active with a program counter, programs are not The execution of a process is sequential A process uses resources provided by the OS, including CPU time, memory, files, and I/O devices, to accomplish its task The operating system is responsible for Process creation and deletion Process suspension and resumption Providing mechanisms for Process synchronization and communication Process Management All processes form a process tree A is a child of a special system process, init A has two child processes, B and C B has three child processes, D, E, and F 2

Memory Management Memory is a large array of words or bytes, each with its own address; it is a quickly accessible storage repository shared by the CPU and I/O devices Main memory is a volatile storage device; it loses its contents in the case of system failure The operating system is responsible for Keeping track of which parts of memory are currently being used and by whom Deciding which processes to load when memory space becomes available Allocating and deallocating memory space as needed Secondary Storage Management Main memory (primary storage) is volatile and too small to accommodate all data and programs, the computer system must provide nonvolatile secondary storage to back up main memory Most modern computer systems use disks as the principle online storage medium, for both programs and data The operating system is responsible for Free space management Storage allocation Disk scheduling 3

I/O System Management The OS must hide all of the peculiarities of the underlying I/O devices The I/O system consists of A general device-driver interface A buffer-caching system Drivers for specific hardware devices File Management A file is a collection of related information defined by its creator; files represent programs and data Files are grouped into directories; directories may can directories as well as file, forming a hierarchy The operating system is responsible for File creation and deletion Directory creation and deletion Support of primitives for manipulating files and directories Mapping files onto secondary storage File backup on stable (nonvolatile) storage media 4

File Management An example of a file system hierarchy Protection System Protection refers to a mechanism for controlling access by programs, processes, or users to both system and user resources The protection mechanism must Distinguish between authorized and unauthorized usage Specify the controls to be imposed Provide a means of enforcement 5

Networking A distributed system is a collection processors that do not share memory or a clock The processors in the system are connected through a communication network A distributed system provides user access to various system resources Access to a shared resource allows Computation speed-up Increased data availability Enhanced reliability Command Interpreter The operating system must provide some mechanism for users to submit commands for Process creation and management I/O handling Secondary-storage management Main-memory management File-system access Protection Networking The program that reads and interprets commands is the command-line interpreter or shell The shell is not typically part of the operating system 6

Operating System User Services User/program services (mirrors system components to a large degree) Program execution I/O operations File-system manipulation Communications Error detection System services Resource allocation Accounting Protection How does the OS provide programs access to services? System Calls System calls provide the interface between a running program and the operating system Generally available as assembly-language instructions, but also available as functions in high-level languages Three general methods are used to pass parameters between a running program and the operating system Pass parameters in registers Store the parameters in a table in memory, and the table address is passed as a parameter in a register Push (store) the parameters onto the stack by the program, and pop off the stack by operating system 7

Classes of System Calls Process management Create, terminate, wait for process File management Create, delete, read, write files Device management Read, write, access devices Information maintenance Get/set time, system data, file/process attributes Communication Create communication connections; send, receive messages; shared memory POSIX System Calls 8

Win32 System Calls API versus system call - APIs may not map one-to-one to OS system calls, in fact, they may be completely different Performing a System Call Consider the read(fd, buffer, nbytes) system call 9

Operating System Design Like all programs, operating systems are built using some architectural design approach The architectural design of an OS affects its overall strengths and weaknesses Due to the complexity of an OS, choosing a good design approach is important Good is relative to your goals Monolithic Operating System Design Monolithic approach (this includes Linux) The Big Mess [Tanenbaum] A collection of procedures in a single object/executable file No information hiding The generic structure of a monolithic OS 10

Monolithic Operating System Design MS-DOS was written to provide the most functionality in the least space Not divided into modules Interfaces and levels of functionality are not well separated Limited by its hardware (Intel 8088) Victim of its own success Monolithic Operating System Design Unix is typically separated into two parts, the kernel and the system programs 11

Layered Operating System Design The operating system is divided into a number of layers (levels), each built on top of lower layers The bottom layer (layer 0), is the hardware; the highest (layer N) is the user interface With modularity, layers are selected such that each uses functions (operations) and services of only lower-level layers Structure of the THE operating system MULTICS also used a similar layered approach Virtual Machine OS Design A timesharing OS provides multiprogramming and an extended machine with a convenient interface; it is possible to separate these two functions A virtual machine provides multiprogramming only by providing an exact virtual copies of the bare hardware The operating system creates the illusion of multiple processes, each executing on its own processor with its own (virtual) memory Each virtual machine can run any OS on top of it 12

Virtual Machine OS Design The resources of the physical computer are shared to create the virtual machines CPU scheduling creates the appearance that users have their own processor Resource allocation and sharing creates the appearance of virtual devices for I/O, files, etc. This is Java s approach, it is also similar to processor emulation modes Virtual Machine OS Design Non-virtual Machine Virtual Machine 13

Virtual Machine OS Design The virtual-machine concept provides complete protection of system resources since each virtual machine is isolated from all other virtual machines. This isolation, however, permits no direct sharing of resources. A virtual-machine system is a perfect vehicle for operating-systems research and development. System development is done on the virtual machine, instead of on a physical machine and so does not disrupt normal system operation. The virtual machine concept is difficult to implement due to the effort required to provide an exact duplicate to the underlying machine. Client-Server Operating System Design Microkernels/client-server model Key concept: the kernel should be as small as possible (e.g., process, memory, and communication management), everything else should be in user space Communication among modules is provided via message passing using a client-server paradigm Allows for better protection since services cannot affect the rest of the operating system Very adaptable for use in distributed systems It is not always possible to have a clean separation between a service and the kernel This approach adds overhead Examples: Mach, Mac OS X, GNU Hurd 14

Client-Server Operating System Design Microkernel approach in a local setting Microkernel approach in a distributed setting Linux Approach Linux is monolithic but It has the notions of modules A module is an object file whose code can be linked to (and unlinked from) the kernel at runtime The module executes in kernel mode Modules export symbols and depend on other modules Modules are managed with reference counting Modules can be linked on demand Modules provide many of the same benefits as the microkernel approach, but it mostly offers a degree of modularity and performance, not protection or applicability to distributed systems 15