Docsity

web-based compliant management system, Exams of Computer Programming

Partial preview of the text

Download web-based compliant management system and more Exams Computer Programming in PDF only on Docsity!

Chapter One

Introduction to

Operating Systems

OS - Introduction

  • (^) Computer System
    • (^) A computer system basically has four components
      • (^) Hardware – provides basic computing resources (CPU, memory, I/O devices).
      • (^) Software
        • (^) System Software
          • (^) Operating system – controls and coordinates the use of the hardware among the various application programs for the various users.
          • (^) Applications programs – define the ways in which the system resources are used to solve the computing problems of the users (compilers, database systems, video games, business programs).
      • (^) Users (people, machines, other computers).

What is an Operating System (OS)?

 (^) many definitions:  (^) An operating system (OS):  (^) an intermediary between users and computer hardware.  (^) a software program that manages the hardware and software resources of a computer.

Tasks of an Operating System

 OS performs basic tasks :

 controlling and allocating memory,

 prioritizing the processing of instructions,

 controlling input and output devices,

 facilitating networking,

 managing files.

Purposes of OS cont.…

 (^) OS is designed to serve two basic purposes:  (^) It controls the allocation and use of the computing system ‘s resources among the various user and tasks.  (^) It provides an interface between the computer hardware and the programmer that simplifies and makes feasible for coding, creation, debugging of application programs.

OS - Tasks

 (^) must support the following tasks:  (^) Provides the facilities to create, allow modification of program and data files using an editor.  (^) Access to the compiler for translating the user program from high level language to machine language.  (^) Provide a loader program to move the compiled program code to the computer ‘s memory for execution.  (^) Provide routines that handle the details of I/O programming.

Process Management cont…

 The OS is responsible for the following activities

in connection with process management:  (^) Creating and deleting both user and system processes,  (^) Suspending and resuming processes,  (^) Providing mechanisms for process synchronization,  (^) Providing mechanisms for process communication,  (^) Providing mechanisms for deadlock handling

Memory Management

Types of OS

 (^) Single Tasking system  (^) In a very simple OS, only one program at a time is in the memory.  (^) To run a second program, the first one has to be removed and the second one placed in memory..

 Multi-Tasking system

 (^) More sophisticated OS that allow multiple programs to be in memory at the same time.  (^) To keep them from interfering with one another, some kind of protection mechanism is needed.

File Management

cont…  (^) File attributes:  (^) the file name,  (^) file type,  (^) protection codes,  (^) account information, and so on.  (^) Actions with Files:  (^) read, write, or  (^) reposition (rewinding or skipping to the end of the file, for example),  (^) close the file, indicating that we are no longer using it.

File Management

 (^) The OS is responsible for the following activities in connection with file management:  (^) Creating and deleting files,  (^) Creating and deleting directories to organize files,  (^) Supporting primitives for manipulating files and directories,  (^) Mapping files onto secondary storage,  (^) Backing up files on stable (nonvolatile) storage media.

I/O management

I/O traffic controller:  (^) module that keeps track of the status of devices  (^) Each I/O device has a device handler that resides in a separate process associated with that device.  The I/O subsystem consists of:  (^) A memory management component that includes buffering, caching and spooling.  A general device driver interface.  (^) Operating system is used to assist the user and to satisfy the interaction with the computer.

User Management

History of Operating Systems  (^) The History of Operating Systems is tied very much to development of computer hardware and software.  (^) Generations of computer developments:  (^) First Generations (1945- 1955)  (^) Second Generations (1955- 1965)  (^) Third Generations (1965-1980) - ICs and Multi Programming  (^) Fourth Generations Fourth Generation (1980-Present) READING ASSIGNMENT!!!!!

Types of Operating System

 (^) Operating systems keep evolving over the period of time.  (^) Types of operating system which are most commonly used.  (^) Batch operating system  (^) No user interaction with the computer directly.  (^) Jobs are submitted on an off-line device like punch cards  (^) jobs with similar needs are batched together and run as a group to speed up processing  (^) Problems with Batch Systems:  (^) Lack of interaction between the user and job,  (^) CPU is often idle, because the speeds of the mechanical I/O devices are slower than CPU.  (^) Difficulty to provide the desired priority.

Time-sharing Operating

^ Systems

Time-sharing/ Multitasking (logical extension of multiprogramming):  (^) a technique which enables many people, located at various terminals, to use a particular computer system at the same time.  (^) Processor's time which is shared among multiple users simultaneously  (^) Multiprogram med Batch Systems Vs Time-Sharing Systems:  (^) in multiprogrammed batch systems, objective is to maximize processor use, whereas in Time-Sharing Systems objective is to minimize response time.  (^) Multiple jobs are executed by the CPU by switching between them, but the switches occur so frequently.  (^) Thus, the user can receive an immediate response.  (^) For example, in a transaction processing system, the processor execute each user program in a short burst or quantum of computation. That is if n users are present, each user can get time quantum.