0% found this document useful (0 votes)
3 views38 pages

OS Introduction UPDATED

The document provides an introduction to operating systems, covering their definition, functions, and services, as well as the structure and evolution of operating systems. It explains the roles of system software, utility software, and the importance of the kernel and shell. Additionally, it discusses various types of operating systems, including batch processing, multiprogramming, time-sharing, real-time, and distributed systems.

Uploaded by

shagun
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3 views38 pages

OS Introduction UPDATED

The document provides an introduction to operating systems, covering their definition, functions, and services, as well as the structure and evolution of operating systems. It explains the roles of system software, utility software, and the importance of the kernel and shell. Additionally, it discusses various types of operating systems, including batch processing, multiprogramming, time-sharing, real-time, and distributed systems.

Uploaded by

shagun
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 38

Amritsar College of Engineering & Technology, Amritsar, Punjab, INDIA

NAAC - A grade, NBA accredited courses(2009-12, 2016-18), UGC Autonomous College

SUBJECT: OPERATING SYSTEM


SUBJECT CODE:AGCS-21404
TOPIC: Introduction

Ms. Shagun Arora


Assistant Professor
Department of Computer Science and Engineering

Ms. Shagun Arora [email protected] CSE 4th Operating


OPERATING SYSTEMS
Chapter 1: Fundamentals of Operating system

CSE 4th Operating System


2
CONTENTS

1. What is an Operating System?


2. OS Functions
3. OS Services
4. Operating system as Resource Manager
5. Structure of OS
6. Evolution of OS

CSE 4th Operating System


3
SOFTWARE CLASSIFICATION

□ Utility software is software designed to help to analyze, configure, optimize or


maintain a computer. Examples of utility programs are antivirus software,
backup software and disk tools.

□ System software is a type of computer program that is designed to run a


computer's hardware and application programs. The system software is the
interface between the hardware and user applications. The operating system is
the best-known example of system software.

CSE 4th Operating System


4
WHAT IS OS?
• It is the System software that enables all the programs
we use.

• The OS organizes and controls the hardware (CPU,


RAM, I/O)

• OS acts as an interface between the application


programs and the machine hardware.

CSE 4th Operating System


5
Conceptual view Of Operating System

CSE 4th Operating System


6
Operating System Software

Examples: Microsoft Windows, Linux, Unix, Mac OS X, iOS, Android.

CSE 4th Operating


7 System
OS FUNCTIONS
The main functions of operating systems are:

• Manages and Interacts with Computer Hardware

• Process the tasks

• Provides the User/ Computer Interface (CLI / GUI)

• Provides the Interface for Application Software

• Input / Output Operations

• Error Detection, Resource Allocation, Security and Protection


CSE 4th Operating System
8
OS SERVICES
Operating system services such as,

• Input / Output Operations ,Controlling and Allocating


memory,

• Work as a Resource Allocator ,Prioritizing system


requests, File System Manipulation, Error Detection,

• Controlling input and output devices, Communication


• Managing file systems, protection

• CPUs have this capability to use at least two modes:


protected mode and supervisor mode.

CSE 4th Operating System


9
Manages the CPU: by CPU scheduling
algorithms.
Manages RAM
- What is processing in RAM
- Virtual memory.
Provides the Interface for
Application Software
-Operating systems are designed
and developed for a specific CPU
or “family of CPUs”

CSE 4th Operating System


10
Provides the interface for
storage devices and manages
how data is stored on those
devices.

Provides the Interface for


I/O Devices
• device drivers
• keyboard, mouse, printer

CSE 4th Operating System


11
VIRTUAL MEMORY

Virtual Memory (VM) = the ability of the CPU and the operating
system software to use the hard disk drive as additional RAM when
needed.
CSE 4th Operating
12 System
VIRTUAL MEMORY

CSE 4th Operating System


13
PROCESSES
Scheduler – Maintains a record of
the processes.
• Adds new processes when
launched.
• Removes old processes when
completed.
• Uses a process table.
Process Table – Information
about each process including:
• Main memory cells (RAM)
• Priority
• Running or waiting (input from
user or saving to disk)

CSE 4th Operating System


14
Viewing processes with Microsoft Windows
Ending a process – Killing the process
CSE 4th Operating
15 System
PROCESSES
Dispatcher - Oversees the
execution of each process by the
CPU.
• Gives each process a time slice
of CPU time.
• Changes between processes.

CSE 4th Operating System


16
MULTIPROCESSING

⚫ Another computer system is the multiprocessor system


having multiple processors sharing memory and
peripheral devices.

⚫ With this configuration, they have greater computing


power and higher reliability.

CSE 4th Operating System


17
MULTIPROCESSING WITH MULTIPLE
CPU’S
Asymmetric Multiprocessing = Tasks are assigned to a specific
CPU and each CPU has its own RAM memory
Symmetric Multiprocessing = Tasks are assigned to any
available CPU and CPU’s can share RAM memory

CSE 4th Operating System


18
Operating system as Resource Manager
⚫ Therefore operating system is the resource manager i.e. it can manage
the resource of a computer system internally. The resources are processor,
memory, files, and I/O devices. In simple terms, an operating system is the
interface between the user and the machine.

CSE 4th Operating System


19
STRUCTURE OF OPERATING SYSTEM:

Application Programs

System Programs

Software (Operating System)

HARDWARE

CSE 4th Operating System


20
STRUCTURE OF OPERATING SYSTEM

The structure of OS consists of 4 layers:


1. Hardware
Hardware consists of CPU, Main
memory, I/O Devices, etc,

2. Software (Operating System)


Software includes process management
routines, memory management routines, I/O
control routines, file management routines.

CSE 4th Operating System


21
STRUCTURE OF OPERATING SYSTEM

3. System programs
This layer consists of compilers, Assemblers,
linker etc.

4. Application programs
This is dependent on users need. Ex.
Railway reservation system, Bank database
management ,watsapp, MS office etc.,

CSE 4th Operating System


22
What is a kernel?
⚫ Kernel is actually the heart of operating systems.

⚫ It acts as an interface between the applications and


actual data processing done at hardware level (CPU,
disk memory etc.)

⚫ Kernel lies in the center of the operating system which


manages the communication b/w the user level
applications and the hardware installed on the system.

CSE 4th Operating System


23
What is a Shell in operating system?
⚫ A shell is simply a software that gives a user interface to
various operating system functions and services. So, in
layman words ”Your interface to operating system is called
shell”.
⚫ Shells provide a way for you to communicate with the
operating system. This communication is carried out either
interactively (input from the keyboard is acted upon
immediately) or as a shell script.
⚫ A shell script is a sequence of shell and operating system
command that is stored in a file.

CSE 4th Operating System


24
⚫ The interface between a process and an operating system is provided
by system calls. In general, system calls are available as assembly
language instructions. ... System calls are usually made when a process in
user mode requires access to a resource. Then it requests the kernel to
provide the resource via a system call.

CSE 4th Operating System


25
EVOLUTION OF OS:
Evolution of an OS from simple Batch processing to today’s
OS-
• Batch Operating System
• Multiprogramming Operating System
• Time Sharing or Multitasking Operating System
• Real-Time Systems
• Distributed Operating System

CSE 4th Operating System


26
BATCH
PROCESSING:
• In Batch processing same type of jobs batch (BATCH- a
set of jobs with similar needs) together and execute at a
time.
⚫ The OS was simple, its major task was to transfer
control from one job to the next.
• ⚫ The job was submitted to the computer operator in
form of punch cards. At some later time the output
appeared.

• ⚫ The OS was always resident in memory.
⚫ Common Input devices were card readers and tape drives
CSE 4th Operating System

27
Common output devices were line printers, tape drives,
and card punches.
Users did not interact directly with the computer
systems, but he prepared a job (comprising of the
program, the data, & some control information).
Eg: Programs were loaded into memory manually
using switches, punched cards, or paper tapes.

28 CSE 4th
Operating System punch card
ENIAC : coding by cable connections
Punch Card

Er. Bhuvnesh kumar


29 [email protected]
CSE 4th Operating System
MULTIPROGRAMMING
:
• Multiprogramming is a technique to execute number of
programs simultaneously by a single processor.
• In Multiprogramming, number of processes reside in
main memory at a time.
• The OS picks and begins to executes one of the jobs
in the main memory.
• If any I/O wait happened in a process, then CPU
switches from that job to another job.
• Hence CPU in not idle at any time.

CSE 4th Operating System


30
MULTIPROGRAMMIN
G
OS • Figuredipicts the layout of
multiprogramming system.
Job 1
• The main memory consists of 5 jobs
Job 2 at a time, the CPU executes one by
one.
Job 3
Advantages:
Job 4 • Efficient memory utilization

Job 5 • Throughput increases


• CPU is never idle, so performance
increases.
CSE 4th Operating System
31
SYSTEMS:

• Time sharing, or multitasking, is a logical extension of


multiprogramming.
• Multiple jobs are executed by switching the
CPU between them.
• In this, the CPU time is shared by different processes, so
it is called as “Time sharing Systems”.
• Time slice is defined by the OS, for sharing CPU time
between processes.
• Examples: Unix.

CSE 4th Operating System


32
PROCESS STATES FOR
TIME SHARING

New Job Execution Terminated


Ready Running

Time Slice
over

Wait for I/O


I/O Completed
Completion

Blocked

CSE 4th Operating System


33
REAL-TIME SYSTEMS:
• A real-time operating system is a multitasking
operating system intended for applications with fixed
deadlines.
• Such applications include some small embedded
systems, automobile engine controllers, industrial
robots, spacecraft, industrial control, and some
large-scale computing systems.
• An early example of a large-scale real-time operating
system was Transaction Processing Facility
developed by American Airlines and IBM for the
Airline Reservations System, IRCTC, ONLINE
BANKING , GOOGLE MAP etc.

CSE 4th Operating System


34
These are of two types: a) Hard Real Time,
b) Soft Real Time.
a) Hard real-time software systems have a set of strict
deadlines, and missing a deadline is considered
a system failure.
Examples of hard real-time systems: airplane sensor and
autopilot systems, spacecrafts and planetary rovers.
b) Soft real-time systems try to reach deadlines but do not

fail if a deadline is missed.

Ex: Multimedia systems, digital audio system.

CSE 4th Operating System


35
DISTRIBUTED SYSTEMS:
• A distributed computer system use multiple CPU to execute multiple process.

• Multiple processor communicate with each other through multiple


communication line.

• The distributed operating system provides a illusion to its users that it


has a single uniprocessor system, although it is actually consisted of
multiprocessors.

• Distributed OS provide the means for system- wide sharing of resources


such as computational capacity, files and I/O devices.

• These systems run on a server and provide the capability to manage data,
users, groups, security, applications, and other networking functions
• Ex: UNIX, LINUX.

CSE 4th Operating System


36
CSE 4th Operating System
37
Thanks

CSE 4th Operating System


38

You might also like