Presentation is loading. Please wait.

Presentation is loading. Please wait.

Operating System Introduction

Similar presentations


Presentation on theme: "Operating System Introduction"— Presentation transcript:

1 Operating System Introduction
-Compiled for CSIT Ref: Tanenbaum, Modern Operating Systems 3 e, (c) 2008 Prentice-Hall, Inc.

2 Content 1.1 Introduction Definition and Function, Two views of Operating System, Evolution/History and Types 1.2 System Calls

3 1.1: Introduction

4 What Is An Operating System?
Lots of hardware !! One or more processors Main memory Disks Printers Various input/output devices Managing all these components requires a layer of software – the operating system

5 Where is the software? Where the operating system fits in.

6 Functions of operating system
Process management Process creation, deletion, suspension and resumption Process synchronization and inter process communication Process interactions – deadlock detection, avoidance and correction Mutitasking Memory management Allocate and deallocate memory to process Manage multiple processes within the memory Manage the sharing of memory between processes Determine which processed to load when memory is available

7 Functions of operating system
Storage Management Directory / File creation and deletion File system management File/directory manipulation Backup and achieve Free-space management Disk scheduling I/O management Device driver installation Device interface and management

8 Functions of operating system
Protection and security File attribute for accidental modification Provides policy for user Authentication Data encryption Firewall Networking Provides different sets of protocols that are used for secure networking TCP/IP, FTP, POP, SMTP Interface CUI GUI Interactive

9 Two Views of OS OS as Extended Machine OS as Resource Manager

10 The Operating System as an Extended Machine

11 The Operating System as a Resource Manager
Allow multiple programs to run at the same time Manage and protect memory, I/O devices, and other resources Multiplexes (shares) resources in two different ways: In time In space

12 History of Operating Systems
Generations: (1945–55) Vacuum Tubes (1955–65) Transistors and Batch Systems (1965–1980) ICs and Multiprogramming (1980–Present) Personal Computers, Tablets, Phones

13 Transistors and Batch Systems (1)
Figure 1-3. An early batch system. (a) Programmers bring cards to (b)1401 reads batch of jobs onto tape.

14 Transistors and Batch Systems (2)
Figure 1-3. (c) Operator carries input tape to (d) 7094 does computing. (e) Operator carries output tape to (f) 1401 prints output.

15 ICs and Multiprogramming
MULTICS Timesharing CTSS (MIT) Multics UNix Figure 1-5. A multiprogramming system with three jobs in memory.

16 More third generation . Time Sharing (CTSS) Multics Unix Linux MULTICS
Timesharing CTSS (MIT) Multics UNix .

17 Fourth generation . PCs Network Operating Systems
Distributed Operating Systems MULTICS Timesharing CTSS (MIT) Multics UNix .

18 The Operating System Types
Mainframe operating systems Big-thousands of disks…. Lots of jobs with lots of I/O Services-batch (payroll) transactions (airline reservations, timesharing (query database) Elderly-Unix, Linux replacing them

19 The Operating System Types:

20 The Operating System Types:
Batch operating systems The users of a batch operating system do not interact with the computer directly. Each user prepares his job on an off-line device like punch cards and submits it to the computer operator. To speed up processing, jobs with similar needs are batched together and run as a group. Disadvantage: Lack of interaction between the user and the job. CPU is often idle, because the speed of the mechanical I/O devices is slower than the CPU. Difficult to provide the desired priority.

21 The Operating System Types:
Server operating systems Workstations File, print, web servers BSD, Linux, Windows Multiprocessor operating systems Use multiple cores

22 The Operating System Types:
PC operating systems-Linux, Mac, Windows Smart phone operating systems- Android, iPhone, Blackberry No hard disk Palm, Symbian popular OS’s Multiprogramming OS Run multiple program on single core Advantage: Reduce CPU idle time and utilize it Disadvantage: Question of security and integrity of user programs and data.

23 The Operating System Types:
Real-Time OS- Data processing system in which the time interval required to process and respond to inputs is so small that it controls the environment. The time taken by the system to respond to an input and display of required updated information is termed as response time. Types: Hard real-time: Guarantee that critical tasks complete on time. Secondary storage is limited or missing with data stored in ROM. Virtual memory is almost never found.

24 The Operating System Types:
Soft real-time: Soft real time systems are less restrictive. Have limited utility than hard real-time systems. Example: Multimedia, virtual reality, Advanced Scientific Projects like undersea exploration and planetary rovers etc.

25 The Operating System Types:
Embedded Operating System An operating system for embedded computer systems. Typically designed to be resource-efficient and reliable. Resource efficiency comes at the cost of losing some functionality or granularity that larger computer operating systems provide, including functions which may not be used by the specialized applications they run. The hardware running an embedded operating system can be very limited in resources such as RAM and ROM In order to take better advantage of the processing power of the CPU, software developers may write critical code directly in assembly. Often times, embedded operating systems are written entirely in more portable languages, like C. Unlike a desktop operating system, the embedded operating system does not load and execute applications. This means that the system is only able to run a single application.

26 The Operating System Types:
Smart Card Operating System OS designed for smart card Every smart card has an operating system. The OS is the hardware-specific firmware that provides basic functionality as secure access to on-card storage, authentication and encryption. Some cards allow writing programs that are loaded onto the smart card – just like programs on a computer. Example: Javacard OS, MultOS(Multi-application OS)

27 Operating Systems Structure
Monolithic systems A main program that invokes the requested service procedure. A set of service procedures that carry out the system calls. A set of utility procedures that help the service procedures.

28 Monolithic Systems

29 Easy for error detection
Layered Systems-THE operating system Components are organized and module are layered them from one top to next Module are not free to communicate directly without maintaining hierarchy Easy for error detection

30 Layered Systems-THE operating system
Dijkstra’s the author

31 Layered Systems

32 Microkernels

33 Microkernels Small number of processes are allowed in the kernel
Minimizes effects of bugs Don’t want bug in driver to crash system Put mechanism in kernel and policy outside the kernel Mechanism- schedule processes by priority scheduling algorithm Policy-assign process priorities in user space

34 Microkernels Structure of the MINIX 3 system.

35 Microkernels

36 Client-Server Model Divide operating kernel into several process I/O server, memory server, thread interface server, print server etc Servers run in user mode provide service when client demands

37 Client-Server Model The client-server model over a network.

38 Virtual Machines (1) The structure of VM/370 with CMS.

39 Virtual Machines (2) (a) A type 1 hypervisor. (b) A type 2 hypervisor.

40

41 1.2: System Call

42 What is System Call A system call is the programmatic way in which a computer program requests a service from the kernel of the operating system it is executed on. A system call is a way for programs to interact with the operating system. A computer program makes a system call when it makes a request to the operating system’s kernel. System call provides the services of the operating system to the user programs via Application Program Interface(API). It provides an interface between a process and operating system to allow user-level processes to request services of the operating system. System calls are the only entry points into the kernel system. All programs needing resources must use system calls.

43 Kernel mode and User Mode
Every modern OS supports Kernel Mode and User Mode

44 Kernel Mode When CPU is in kernel mode, the code being executed can access any memory address and any hardware resource.  Hence kernel mode is a very privileged and powerful mode. If a program crashes in kernel mode, the entire system will be halted.

45 User Mode When CPU is in user mode, the programs don't have direct access to memory and hardware resources.  In user mode, if any program crashes, only that particular program is halted. That means the system will be in a safe state even if a program in user mode crashes. Hence, most programs in an OS run in user mode.

46 Service Provided By System Calls
Process creation and management Main memory management File Access, Directory and File system management Device handling(I/O) Protection Networking, etc.

47 Types: Process control: end, abort, create, terminate, allocate and free memory. File management: create, open, close, delete, read file etc. Device management Information maintenance Communication

48 Examples of windows and unix system call

49


Download ppt "Operating System Introduction"

Similar presentations


Ads by Google