SYSTEM SOFTWARE
Lakmini Wanninayake
Bsc. Computer Science(sp) – University of Peradeniya
Introduction to Operating Systems
Layers of a computer system
Why do we need an OS?
A modern computer consists of many hardware
components.
Writing programs to keep track of all these
components & using them is a difficult job.
A layer of software called OS is used.
OS manages all the devices & provides
applications with a simple interface to hardware.
OS as a virtual machine
What is OS?
Part of the system software that manages the use of
hardware by other system software and application
software.
Software that is implemented “closest to the
hardware”.
Extends the machine
Manages resources
OS as an extended machine
Hides all the messy details about the underlying
hardware.
Presents the user a machine that is easier to use
Offers various services to applications running on
top of it.
These are offered through set of functions called system
calls.
OS as a resource manager
Manages resources in the machine
Each process gets time with the resource
Eg: allocation of CPU time for a program
Each program gets space on the resource
eg: allocation of memory for a program
History of OSs
First generation (1945 - 1955)
Vacuum tubes
Plug boards
Second generation (1955 - 1965)
Transistors
Batch systems
Third generation (1965 - 1980)
ICs
Multiprogramming
Fourth generation (1980 - present)
VLSI
Personal Computer OSs
First generation - Vacuum tubes
Plug boards
Second generation - Transistors
Batch systems
A structure of a typical job
Batch systems
Users prepared jobs & submitted them to the
operator
Usually in the form of punch cards
To speed up processing operators:
Jobswith similar needs batched together
When one job is finished OS automatically ran the next
job
Outputs sent back to the user
May take a long time, possibly a day or even more
Third generation
Multiprogramming
Computers contain many resources
A single job rarely uses all resources
When a job needs an I/O activity CPU is idle until I/O
is finished
Leads to underutilization of resources
As a solution memory was divided into partitions
Called multiprogramming
Multiprogramming cont.
Multiprogramming cont.
OS could keep a number of jobs on the disk
When the first job is selected it moves into the memory
for execution
When the job get blocked due to I/O activity another
job is moved into an empty partition in the memory
If the second job get blocked another is loaded
Eventually, the first job will finish waiting for I/O and
gets CPU back
As a result resource utilization increases
Timesharing systems
Is a variant of multiprogramming
Also called multitasking
No real user interaction in any of the previous
approaches
Operator has some control before starting a job, but
not while its running
In timesharing, instructions are given directly using
the keyboard
Provides direct communication
Timesharing systems cont.
Interactive I/O runs at “human speeds”
Typing 7 characters per second is fast for people
But incredibly slow for computers
CPU can execute other programs by the time the
user types the next character
CPU executes multiple jobs by switching among
them
The switching occurs so rapidly
Timesharing systems cont.
Fourth generation
Desktop systems
Appeared in 1970s
Less weight on CPU & peripheral utilization
Cheap hardware
Maximize user convenience and responsiveness
Some features in larger OSs are incorporated
Some left out initially but adapted later
Eg: file protection, multitasking
Fifth generation
Type of OSs
1) Batch mode operating system
2) Timeshared operating system
3) Networked OS
4) Personal computer OS
5) Real-time OS
6) Embedded OS
7) Distributed OS
8) Smartcard OS
Batch operating system
The programmers leave their programs with the
operator and the operator then sorts the programs
with similar requirements into batches.
The problems with Batch Systems
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.
Timesharing OS
Multiple jobs are executed by the CPU by switching
between them, but the switches occur so frequently.
The operating system uses CPU scheduling and
multiprogramming to provide each user with a small
portion of a time.
Timesharing OS
Advantages of Timesharing operating systems
Providesthe advantage of quick response.
Avoids duplication of software.
Reduces CPU idle time.
Disadvantages of Time-sharing operating systems
Problem of reliability.
Question of security and integrity of user programs and
data.
Problem of data communication.
Personal computer OSs
Interactive systems
Today these are also called multimedia OSs
Offer
Multimedia features
Word processing
Desktop publishing
Gaming
Internet access
Examples
Windows ME/XP/7/8/10, Windows Media Center
Edition, Fedora 2/3/4/5, Apple iMac
Network OS
A Network Operating System runs on a server and
provides the server the capability to manage data,
users, groups, security, applications, and other
networking functions.
The primary purpose of the network operating
system is to allow shared file and printer access
among multiple computers in a network
Examples
Microsoft Windows Server 2008
UNIX
Real-time OS
Intended to serve real-time applications that
process data as it comes in
They either are event driven or time sharing
Event driven systems switch between tasks based on
their priorities while time sharing systems switch the
task based on clock interrupts
Examples
VxWorks
QNS
Real-time OS
Response time is very less as compared to online
processing
A real-time operating system must have well-
defined, fixed time constraints, otherwise the system
will fail
Two types real-time systems
Hard real-time systems
Soft real-time systems
Real-time OS
Hard real-time systems
guarantee that critical tasks complete on time
secondary storage is limited or missing and the data is
stored in ROM
virtual memory is almost never found
Soft real-time systems
lessrestrictive
have limited utility than hard real-time systems
Eg: virtual reality, Advanced Scientific Projects like
undersea exploration and planetary rovers
Distributed OS
Distributed systems use multiple central processors to
serve multiple real-time applications and multiple users.
Data processing jobs are distributed among the
processors accordingly.
Distributed OS is a software over a collection of
independent, networked, communicating and physically
separate computational nodes
Embedded OSs
Used in palmtop computers and embedded systems
Used in PDAs, pocket PCs, mobile phones,
networking devices, microwave ovens etc.
Has to deal with limited processing power, size,
memory & power constraints.
Examples
PalmOS
Windows CE
Windows mobile
Smartcard OSs
The smart card has a microprocessor or memory chip
embedded in it
The chip stores electronic data and programs that are
protected by advanced security features
When coupled with a reader, the smart card has the
processing power to serve many different applications
Smart cards provide data portability, security and
convenience
Smart cards currently are used in telephone,
transportation, banking, and healthcare transactions
Smartcard OSs
Examples:
Java cards with inbuilt JVM
Functions of an OS
Process & thread management
Memory management
Managing Input and output
Managing storage media and files
Administrating security
Monitoring system performance
Process and thread management
Creating and terminating processes
Allocating & de-allocating resources
Scheduling processes
Threading
Memory management
Allocating & de-allocating memory
Addressing
Swapping
Swapping
Input & output
Controlling & managing input and output devices
Configuring devices
Spooling print jobs
Power management
Multimedia capabilities can be part of this.
I/O – spooling print jobs
I/O configuring devices
Managing storage media & files
Administrating security
Managing users
Authentication
Auditing
Monitoring system performance
Summary
OS is
An extended machine
A resource manager
History of OSs
Types of OSs
Functions of OSs