Chapter 1: Introduction

Slides:



Advertisements
Similar presentations
Interactive lesson about operating system
Advertisements

Dr. Kalpakis CMSC 421, Operating Systems. Fall Introduction.
Silberschatz, Galvin and Gagne  Operating System Concepts Chapter 2: Computer-System Structures Computer System Operation I/O Structure Storage.
CMPT 300: Operating Systems I Dr. Mohamed Hefeeda
OS2-1 Chapter 2 Computer System Structures. OS2-2 Outlines Computer System Operation I/O Structure Storage Structure Storage Hierarchy Hardware Protection.
1 School of Computing Science Simon Fraser University CMPT 300: Operating Systems I Dr. Mohamed Hefeeda.
Chapter 1: Introduction. 1.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts – 7 th Edition, Jan 12, 2005 Chapter 1: Introduction What.
Silberschatz, Galvin and Gagne  Operating System Concepts Chapter 2: Computer-System Structures Computer System Operation I/O Structure Storage.
Silberschatz, Galvin and Gagne  Operating System Concepts Chapter 2: Computer-System Structures Computer System Operation I/O Structure Storage.
Operating System Concepts with Java – 7 th Edition, Nov 15, 2006 Silberschatz, Galvin and Gagne ©2007 Chapter 1: Introduction.
Modified from Silberschatz, Galvin and Gagne ©2009 CS 446/646 Principles of Operating Systems Lecture 1 Chapter 1: Introduction.
Computer-System Structures
1.1 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts School of Computing Science Simon Fraser University CMPT 300: Operating Systems I Instructor:
Lecture 1: Introduction CS170 Spring 2015 Chapter 1, the text book. T. Yang.
Chapter 1: Introduction. 1.2 Silberschatz, Galvin and Gagne ©2005 Operating System Principles Objectives To provide a grand tour of the major operating.
Chapter 1 Introduction to Operating System Bernard Chen Spring 2007.
What do operating systems do? manage processes manage memory and computer resources provide security features execute user programs make solving user.
Chapter 1: Introduction. 1.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts What is an Operating System? A program that acts as an intermediary.
Process Management A process is a program in execution. It is a unit of work within the system. Program is a passive entity, process is an active entity.
Introduction. 1.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts Chapter 1: Introduction What Operating Systems Do Computer-System Organization.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition, Chapter 1: Introduction.
Chapter 1: Introduction
Objectives To provide a grand tour of the major operating systems components To provide coverage of basic computer system organization.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition Chapter 1: Introduction.
CS212: OPERATING SYSTEM Lecture 1: Introduction 1.
Computer System Organization and Operating Systems.
Chapter 1. Introduction What is an Operating System? Mainframe Systems
CHAPTER 2: COMPUTER-SYSTEM STRUCTURES Computer system operation Computer system operation I/O structure I/O structure Storage structure Storage structure.
Chapter 2: Computer-System Structures
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition, Operating Systems CSCI 411.
Chapter 1: Introduction Adapted to COP4610 by Robert van Engelen.
Chapter 1: Introduction. 1.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts Chapter 1: Introduction What Operating Systems Do (previous.
Chapter 1: Introduction. 1.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts Chapter 1: Introduction What Operating Systems Do Computer-System.
Chapter 2: Computer-System Structures Computer System Operation I/O Structure Storage Structure Storage Hierarchy Hardware Protection Network Structure.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition, Chapter 1: Introduction.
Chapter 1: Introduction
Chapter 1: Introduction. 1.2 Silberschatz, Galvin and Gagne ©2005 Operating System Principles Chapter 1: Introduction What Operating Systems Do Computer-System.
Company Confidential 1 Operating Systems. Chapter 1: Introduction What Operating Systems Do Computer-System Organization Computer-System Architecture.
1.1 Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition Caching Important principle, performed at many levels in a computer (in.
Chapter 1: Introduction. 1.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts – 7 th Edition, Jan 12, 2005 Chapter 1: Introduction What.
Chapter 1: Introduction. 1.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts Chapter 1: Introduction What Operating Systems Do Computer-System.
Welcome to The University of Lahore Sargodha Campus.
Chapter 1. Introduction. 1.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts – 7 th Edition, Jan 12, 2005 Introduction Introduction What.
Chapter 1: Introduction. 1.2 What is an Operating System? A program that acts as an intermediary between a user of a computer and the computer hardware.
Review of Computer System Organization. Computer Startup For a computer to start running when it is first powered up, it needs to execute an initial program.
Chapter 1: Introduction
CSE Operating System Principles
Chapter 1: Introduction. 1.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts Chapter 1: Introduction What Operating Systems Do Computer-System.
Introduction to Operating System. 1.1 What is Operating System? An operating system is a program that manages the computer hardware. It also provides.
Chapter 1: Introduction. 1.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts – 7 th Edition, Jan 12, 2005 Chapter 1: Introduction What.
Chapter 1: Introduction. 1.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts – 7 th Edition, Jan 12, 2005 Chapter 1: Introduction What.
Operating System (Reference : OS[Silberschatz] + Norton 6e book slides)
Chapter 1: Introduction Narzu Tarannum(NAT) Reff: BIS.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition, Chapter 1: Introduction.
1.1 Silberschatz, Galvin and Gagne ©2013 Operating System Concepts – 9 th Edition Chapter 1: Introduction What Operating Systems Do √ Computer-System Organization.
Chapter 1: Introduction. 1.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts Objectives To provide a grand tour of the major operating.
Chapter 1: Introduction
Chapter 1: Introduction
Chapter 1: Introduction
Chapter 1: Introduction
Chapter 1: Introduction
Chapter 1: Introduction
Chapter 1 Introduction to Operating System
Chapter 1: Introduction
Chapter 1: Introduction
Chapter 1: Introduction
Chapter 1: Introduction
Chapter 1: Introduction
Chapter 1: Introduction
Chapter 1: Introduction
Presentation transcript:

Chapter 1: Introduction

Chapter 1: Introduction What Operating Systems Do Computer-System Organization Operating-System Structure Operating-System Operations Process Management Memory Management Storage Management Protection and Security

Distributed Systems Real-Time/Embedded Systems

Objectives To provide an overview of the major operating systems components To review basic computer system organization

What is an Operating System? A program that acts as an intermediary between a user and hardware Operating system goals: Execute user programs and make solving user problems easier Make the computer system convenient to use Use the computer hardware efficiently

Computer System Structure Computer system can be divided into four components Hardware – provides basic computing resources CPU, memory, I/O devices Operating system Controls and coordinates use of hardware among various applications and users

Application programs Word processors, compilers, web browsers, database systems, video games Users/clients People, machines, other computers

Four Components of a Computer System

Operating System Definition OS is a resource allocator Manages all resources Decides between conflicting requests for efficient and fair resource use OS is a control program Controls execution of programs to prevent errors and improper use of the computer Kernel: Core of OS

Computer Startup bootstrap program is loaded at power-up or reboot Firmware stored in ROM or EPROM Initializates the system Loads operating system kernel and starts execution

Computer System Organization CPU(s) & device controllers connect through common bus providing access to main memory

Storage-Device Hierarchy Faster More Expensive

Caching Data temporally copied from slower to faster storage Check cache first Cache < Storage being cached How to determine appropriate cache size Replacement policy Cache coherency in multiprocessor environment

SRAM Stores a bit in a flip-flop Two cross connected NAND or NOR gates Stores a bit as long as power is applied Consumes less power than DRAM but more complex circuitry Generally requires 6 transistors More expensive

DRAM One transistor + Capacitor Electrical charge on capacitor leaks over time Periodically refresh Slower than SRAM Consumes more power Cheaper than SRAM Simpler circuitry

Operating System Structure Multiprogramming Efficient resource usage Single user cannot keep CPU and I/O devices busy at all times Organizes jobs so that CPU always has one to execute A subset of total jobs in system is kept in memory When a job blocks, e.g., for I/O, OS switches to another job

CPU switches jobs very frequently Timesharing/Multitasking CPU switches jobs very frequently Users can interact with each job while it is running, creating interactive computing Response time should be < 1 second Each user has at least one program executing in memory process If several jobs ready to run at the same time  CPU scheduling If processes don’t fit in memory, swapping moves them in and out to run Virtual memory allows execution of processes not completely in memory

Memory Layout for Multiprogrammed System

Operating System Operations Hardware Interrupts Software error or request creates exception or trap Division by zero Other problems: infinite loop, processes modifying each other or OS Accounting & resource management Protection

Basic Protection Dual-mode operation User mode & kernel mode Mode bit Distinguish whether system is running user code or kernel code Privileged instructions only executable in kernel mode System call Change to kernel mode Process the system call Return the result Switch back to user mode

Process Management Unit of work Single- or multi-threaded A process is a program in execution Unit of work Single- or multi-threaded Resource allocation Process needs resources to accomplish its task CPU, memory, I/O, files, data Resources reclamation at process termination Program counter indicates the location Multiple processes can run concurrently on one or more CPUs Concurrency by multiplexing the CPUs among the processes / threads

Process Management Activities Create and delete both user and system processes Suspend and resume processes Provide mechanisms for process synchronization Provide mechanisms for process communication Provide mechanisms for deadlock handling

Memory Management Instruction and data need to be in main memory to be processed Keep track of which parts of memory are currently used and by whom Decide which processes and data to move into and out of memory Allocate and deallocate memory space as needed

Mass Storage Management Performance bottleneck Orders of magnitude performance difference between main memory & secondary storage OS activities Free space management Storage allocation Disk scheduling Some storage need not be fast Tertiary storage includes optical storage, magnetic tape Still must be managed Varies between WORM (write-once, read-many-times) and RW (read-write)

I/O Subsystem Put data in a designated buffer Hide peculiarities of hardware devices from the user I/O subsystem responsible for Buffering: store data temporarily while it is being transferred Caching: store parts of data in faster storage Spooling (Simultaneous Peripheral Operations On-Line) Put data in a designated buffer I/O device can pull the data at its own rate Print spooling can let a user do something else while printing and request several prints without waiting for one print request to finish Device-driver interfaces

Two I/O Methods Synchronous Asynchronous Synchronous I/O Application is blocked until the I/O finishes Only one I/O device is active Easy to determine which device needs service No concurrent I/O possible

I/O Interrupts Extract interrupt service vector Look up interrupt service table Save the current process status such as the register values and address of the interrupted instruction Disable interrupt if necessary Transfer control to the interrupt service routine

Interrupt Timeline

Direct Memory Access Structure Used for high-speed I/O devices able to transmit information at close to memory speed Device controller transfers blocks of data from buffer storage directly to main memory without CPU intervention Only one interrupt is generated per block, rather than one interrupt per byte Cycle stealing

Device-Status Table

Computer system architecture Single processor systems Multiprocessor systems Multiple CPUs sharing main memory Objectives Increase throughput Fault tolerance Asymmetric multiprocessing A master processor controls the system Symmetric multiprocessing (SMP) All processors are peers No master-slave relation

Multiprocessor systems (continued) Multicore CPU Essentially multiprocessors on a single chip Faster communications between processors Uses much less power than multiple single-core chips Good for servers such as web/database servers

Clustered systems Distributed systems A cluster consists of two or more individual systems unlike multiprocessor systems Clustered computers share storage and linked by a local area network, e.g., Ethernet or InfiniBand To support fault tolerance and high performance, for example, in a web server farm Distributed systems

Tips: vmware player Available at http://www.vmware.com/products/player/ More info. in page 39 You don’t have to use it to do assignments. Try this only if you are looking for some extra fun and challenges on your own.