0% found this document useful (0 votes)
27 views108 pages

4i Os Unt 1

The document outlines a course on Operating Systems, detailing its learning objectives, course outcomes, and syllabus covering key topics such as process management, memory management, and types of operating systems. It explains the functions of an operating system, including resource management, user interface establishment, and execution of application software. Additionally, it discusses various operating system types like batch, multiprogramming, time-sharing, distributed, and real-time systems, along with their advantages and disadvantages.

Uploaded by

vedantgupta411
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)
27 views108 pages

4i Os Unt 1

The document outlines a course on Operating Systems, detailing its learning objectives, course outcomes, and syllabus covering key topics such as process management, memory management, and types of operating systems. It explains the functions of an operating system, including resource management, user interface establishment, and execution of application software. Additionally, it discusses various operating system types like batch, multiprogramming, time-sharing, distributed, and real-time systems, along with their advantages and disadvantages.

Uploaded by

vedantgupta411
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/ 108

Operating System (CS3CO36)

Unit-1

By: Prof. Amit goud


Course Learning Objectives (CLOs):
• CLO01: To learn the need and concepts of Operating

systems, its functions and to distinguish different

types of operating systems.

• CLO02: To learn various scheduling algorithms,

problems of understanding multiple process

executions with the concept of deadlock, its

prevention and avoidance techniques.


Course Learning Objectives (CLOs):
• CLO03: To understand the concept of memory
management and to implement it with the applications
of segmentations and paging.
• CLO04: To learn the concept of virtual memory, page
replacement algorithms and computational problems
related to securities in operating systems.
• CLO05: To understand the concept of file, file
protection, file sharing in various types of operating
systems.
Course Outcomes (COs): After completion of
this course the students shall be able to-
• CO01: To understand the concepts of
Operating systems and functions and to
distinguish different types of operating
systems and describe various types of process
and its execution.
• CO02: To implement various types of
scheduling algorithms, its evaluations, to
understand the concept of deadlock, its
prevention and avoidance techniques.
• CO03: To understand the concept of memory
management and to implement the concept of
worst fit, best fit and and first fit memory
allocations along with the applications of
segmentations and paging in operating system.
• CO04: To make the students familiar with
concepts of virtual memory, page replacement
algorithms and computational problems related to
securities in operating systems.
• CO05: To Involve students in designing,
development and testing of file concept, file
protection, file organizations and file sharing in
various types of operating systems.
SYALLBUS
• Unit I: Introduction to OS. Operating system
functions, evaluation of O.S., Different types of
O.S.: Batch, Multi-Programmed, Time-Sharing,
Real-Time, Distributed, Parallel. Process:
Concept of Processes, Process Scheduling,
Operations on Processes, Cooperating
Processes, Inter-Process Communication.
Precedence Graphs, Critical Section Problem,
Semaphores, Threads.
• Unit II: CPU Scheduling: Scheduling Criteria,
Preemptive & Non-Preemptive Scheduling,
Scheduling Algorithms, Algorithm Evaluation,
Multi-Processor Scheduling, Deadlock:
Deadlock Problem, Deadlock Characterization,
Deadlock Prevention, Deadlock Avoidance,
Deadlock Detection, Recovery From Deadlock,
Methods for Deadlock Handling.
• Unit III: Memory Management: Concepts of
Memory Management, Logical and Physical
Address Space, Swapping, Fixed and Dynamic
Partitions, Best Fit, First Fit and Worst Fit
Allocation, Paging, Segmentation, and Paging
Combined With Segmentation.
• Unit IV: Concepts of Virtual Memory, Cache
Memory Organization, Demand Paging, Page
Replacement Algorithms, Allocation of
Frames, Thrashing, Demand Segmentation,
Role of Operating System in Security, Security
Breaches, System Protection, and Password
Management.
• Unit V: Disk Scheduling, File Concepts, File
Manager, File Organization, Access Methods,
Allocation Methods, Free Space
Managements, Directory Systems, File
Protection, File Organization & Access
Mechanism, File Sharing Implement Issue, File
Management in Linux, Introduction to
Distributed Systems.
Software
• Software is a set of programs, which is designed to
perform a well-defined function.
• A program is a sequence of instructions written to
solve a particular problem.

• There are two types of software −

• System Software

• Application Software
System Software
• The system software is a collection of programs designed to

operate, control, and extend the processing capabilities of the

computer itself. These software products comprise of

programs written in low-level languages, which interact with

the hardware at a very basic level. System software serves as

the interface between the hardware and the end users.

• Some examples of system software are Operating System,

Compilers, Interpreter, Assemblers, etc.


Application Software
• Application software products are designed to satisfy
a particular need of a particular environment.
• Application software may consist of a single program,
such as Microsoft's notepad for writing and editing a
simple text. It may also consist of a collection of
programs, often called a software package, which
work together to accomplish a task, such as a
spreadsheet package.
Application software
• Application software are the following:
• Payroll Software
• Student Record Software
• Inventory Management Software
• Income Tax Software
• Railways Reservation Software
• Microsoft Office Suite Software
• Microsoft Word
• Microsoft Excel
• Microsoft PowerPoint
What is Operating System ?
What is Operating System ?
• An Operating System (OS) is an interface between
computer user and computer hardware. An
operating system is software which performs all the
basic tasks like file management, memory
management, process management, handling input
and output, and controlling peripheral devices such
as disk drives and printers.
• An operating system is a software
programmed required to manage
and operate a computing device like
smart phones, tablets, computers,
supercomputers, web servers, cars,
network towers, smart watches, etc.
... It is a layer of graphical user
interface (GUI), which acts as a
platform between the user and the
computer hardware.
What is OS?
• Operating System is a software, which makes a computer
to actually work.

• It is the software the enables all the programs we use.

• The OS organizes and controls the hardware.

• OS acts as an interface between the application programs


and the machine hardware.

• Examples: Windows, Linux, Unix and Mac OS, etc.,


What OS does?
An operating system performs basic tasks such as,

• controlling and allocating memory,


• prioritizing system requests,
• controlling input and output devices,
• facilitating networking and
• managing file systems.
Structure of Operating System:
Application Programs

System Programs

Software (Operating System)

HARDWARE

(Contd…)
Structure of Operating System
(Contd…):
• 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.

(Contd…)
Structure of Operating System
(Contd…):

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
etc.,
What is Operating System ?
Examples of Operating System
Examples of Operating System

• Windows (GUI based, PC).


• GNU/Linux (Personal, Workstations, ISP, File and
print server, Three-tier client/Server).
• macOS (Macintosh), used for Apple’s personal
computers and work stations (MacBook, iMac).
• Android (Google’s Operating System for
smartphones/tablets/smartwatches).
• iOS (Apple’s OS for iPhone, iPad and iPod Touch)..
Objective:

- User convenience .

- Efficient management of resources.

- Error Handler and controller.


Goals of Operating system
• An operating system has three main functions:
(1) Manage the computer's resources, such as
the central processing unit, memory, disk
drives, and printers.
• (2) Establish a user interface.
• (3)Execute and provide services for
applications software.
Functions of an operating System
Functions of an operating System
• Memory Management.
• Processor Management.
• Device Management.
• File Management.
• Security.
• Control over system performance.
• Job accounting.
• Error detecting aids.
Functions of an operating System
• Process management:- Process management helps
OS to create and delete processes. It also provides
mechanisms for synchronization and communication
among processes.
• Memory management:- Memory management
module performs the task of allocation and
de-allocation of memory space to programs in need
of this resources.
• File management:- It manages all the file-related
activities such as organization storage, retrieval,
naming, sharing, and protection of files.
Functions of an operating System
• Device Management: Device management keeps tracks of
all devices. This module also responsible for this task is
known as the I/O controller. It also performs the task of
allocation and de-allocation of the devices.
• I/O System Management: One of the main objects of any
OS is to hide the peculiarities of that hardware devices
from the user.
• Secondary-Storage Management: Systems have several
levels of storage which includes primary storage,
secondary storage, and cache storage. Instructions and
data must be stored in primary storage or cache so that a
running program can reference it.
Functions of an operating System
• Security:- Security module protects the data
and information of a computer system against
malware threat and authorized access.
• Command interpretation: This module is
interpreting commands given by the and
acting system resources to process that
commands.
• Networking: A distributed system is a group of
processors which do not share memory,
hardware devices, or a clock. The processors
communicate with one another through the
Functions of an operating System
• Job accounting: Keeping track of time & resource
used by various job and users.
• Communication management: Coordination and
assignment of compilers, interpreters, and another
software resource of the various users of the
computer systems.
Types of OS
1. Batch Operating System :
• Batch processing is a technique in which an
Operating System collects the programs and data
together in a batch before processing starts.

• Batch system process a collection of jobs, called a


batch. Batch is a sequence of user jobs.
Batch Operating System

• 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.
The programmers leave their programs with the operator
and the operator then sorts the programs with similar
requirements into batches.
Batch Operating System
• The batch operating system grouped jobs that
perform similar functions. These job groups are
treated as a batch and executed simultaneously. A
computer system with this operating system
performs the following batch processing activities:
• A job is a single unit that consists of a preset
sequence of commands, data, and programs.
• Processing takes place in the order in which they
are received, i.e., first come, first serve.
• These jobs are stored in memory and executed
without the need for manual information.
• When a job is successfully run, the operating
system releases its memory.
• The problems with Batch Systems are as
follows :
1. Lack of interaction between the user and the
job.
2. CPU is often idle, because the speed of the
mechanical I/O devices is slower than the
CPU.
3. Difficult to provide the desired priority.
Advantages
• It isn't easy to forecast how long it will take to
complete a job; only batch system processors
know how long it will take to finish the job in
line.
• This system can easily manage large jobs again
and again.
• The batch process can be divided into several
stages to increase processing speed.
• When a process is finished, the next job from
the job spool is run without any user
interaction.
• CPU utilization gets improved.
Disadvantages

• Difficult to debug program.


• A job could enter an infinite loop.

• Due to lack of protection scheme, one batch


job can affect pending jobs.
• When a job fails once, it must be scheduled to
be completed, and it may take a long time to
complete the task.
• Computer operators must have full knowledge
of batch systems.
• The batch system is quite difficult to debug.
• The computer system and the user have no
direct interaction.
• If a job enters an infinite loop, other jobs must
wait for an unknown period of time.
Disadvantages of Batch OS

• 1. Starvation :Batch processing suffers from


starvation.
• There are five jobs J1, J2,
J3, J4, and J5, present in
the batch. If the
execution time of J1 is
very high, then the other
four jobs will never be
executed, or they will
have to wait for a very
long time. Hence the
other processes get
starved.
2. Not Interactive
• Batch Processing is not suitable for jobs that
are dependent on the user's input. If a job
requires the input of two numbers from the
console, then it will never get it in the batch
processing scenario since the user is not
present at the time of execution.
2. Multiprogramming OS

• Sharing the processor, when two or more programs


reside in memory at the same time, is referred as
multiprogramming. Multiprogramming assumes a
single shared processor.
• Multiprogramming increases CPU utilization by
organizing jobs so that the CPU always has one to
execute.
• A multiprogramming operating system may run
many programs on a single processor computer. If
one program must wait for an input/output
transfer in a multiprogramming operating system,
the other programs are ready to use the CPU. As a
result, various jobs may share CPU time. However,
the execution of their jobs is not defined to be at
the same time period.
Multiprogramming OS
An OS does the following activities related to
multiprogramming.

• The operating system keeps several jobs in memory at a time.

• This set of jobs is a subset of the jobs kept in the job pool.

• The operating system picks and begins to execute one of the


jobs in the memory.
• Multiprogramming operating systems monitor the state of all
active programs and system resources using memory
management programs to ensures that the CPU is never idle,
unless there are no jobs to process.
Advantages

• High and efficient CPU utilization.


• User feels that many programs are allotted
CPU almost simultaneously.
Disadvantages

• CPU scheduling is required.


• To accommodate many jobs in memory,
memory management is required.
Time-Sharing Operating Systems / Multitasking OS:

• Each task is given some time to execute, so that all the


tasks work smoothly.
• Each user gets time of CPU as they use single system.
These systems are also known as Multitasking Systems.

• The task can be from single user or from different users


also. The time that each task gets to execute is called
quantum. After this time interval is over OS switches over
to next task.
Time-Sharing Operating Systems / Multitasking OS:
Advantages of Time-Sharing OS:

• Each task gets an equal opportunity


• Less chances of duplication of software

• CPU idle time can be reduced


Disadvantages of Time-Sharing OS:

• Reliability problem
• One must have to take care of security and
integrity of user programs and data
• Data communication problem
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.
- These are referred as loosely coupled systems or
distributed systems.
- Processors in a distributed system may vary in size and
function.
Distributed OS
Distributed OS
Advantages of Distributed Operating System:

• Failure of one will not affect the other network communication, as all

systems are independent from each other.

• Electronic mail increases the data exchange speed

• Since resources are being shared, computation is highly fast and durable

• Load on host computer reduces

• These systems are easily scalable as many systems can be easily added to

the network

• Delay in data processing reduces


Disadvantages of Distributed Operating System:

• Failure of the main network will stop the entire


communication
• To establish distributed systems the language which are
used are not well defined yet

• These types of systems are not readily available as they


are very expensive. Not only that the underlying software
is highly complex and not understood well yet.
Real-Time operating system:
• Real time os is known as REAL TIME
PROCESSING SYSTEM.
• In this system, response time is already fixed
means time to display the results after
processing has fixed by the processor or CPU.
• RTS is used at those places in which we
required higher and timely response.
Real-Time operating system:
• These types of OSs serve the real-time systems. The
time interval required to process and respond to
inputs is very small. This time interval is
called response time.
• Real-time systems are used when there are times
requirements are very strict like missile systems, air
traffic control systems, robots etc.
Examples of Real-Time Operating
Systems
• Scientific experiments
• medical imaging systems
• industrial control systems
• weapon systems
• robots
• air traffic control systems, etc.
Types of Real-Time Operating System
1. Hard Real Time OS:
• These OSs are meant for the applications where time
constraints are very strict and even the shortest possible
delay is not acceptable.
• Hard real-time systems guarantee that critical tasks
complete on time. In hard real-time systems, secondary
storage is limited or missing and the data is stored in ROM.
In these systems, virtual memory is almost never found.
Examples of Hard Real Time OS
Types of Real-Time Operating System

• Soft real-time systems are less restrictive. A critical


real-time task gets priority over other tasks and
retains the priority until it completes. Soft real-time
systems have limited utility than hard real-time
systems.
Examples of Soft Real Time OS
Advantages of RTOS

• Maximum Consumption: Maximum utilization of


devices and system, thus more output from all the
resources.
• Task Shifting: Time assigned for shifting tasks in
these systems are very less. For example in older
systems it takes about 10 micro seconds in shifting
one task to another and in latest systems it takes 3
micro seconds.
• Focus on Application: Focus on running
applications and less importance to applications
which are in queue.
Advantages of RTOS

• Real time operating system in embedded


system: Since size of programs are small, RTOS
can also be used in embedded systems like in
transport and others.
• Error Free: These types of systems are error
free.
• Memory Allocation: Memory allocation is best
managed in these type of systems.
Disadvantages of RTOS:

• Limited Tasks: Very few tasks run at the same


time and their concentration is very less on
few applications to avoid errors.
• Complex Algorithms: The algorithms are very
complex and difficult for the designer to write
on.
Network operating system (NOS)

• A network operating system (NOS) is a


computer operating system (OS) that is designed
primarily to support workstations, personal
computers and, in some instances,
older terminals that are connected on a local area
network (LAN).
• The software behind a NOS allows multiple
devices within a network to communicate and
share resources with each other.
Network operating system (NOS)

• 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, typically a local area network (LAN),
a private network or to other networks.
Network operating system (NOS)
Examples of network operating
systems
• Microsoft Windows Server 2003
• Microsoft Windows Server 2008
• UNIX
• Linux
• Mac OS X
• Novell NetWare
• BSD (Berkeley Software Distribution)
Advantages of Network Operating System:

• Highly stable centralized servers.


• Security concerns are handled through servers
• New technologies and hardware up-gradation are
easily integrated to the system.
• Server access are possible remotely from different
locations and types of systems.
Disadvantages of Network Operating System

• Servers are costly.


• User has to depend on central location for
most operations.

• Maintenance and updates are required


regularly.
Parallel O.S
• Parallel processing requires multiple processors
and all the processor works simultaneously in the
system. Here, the task is divided into subparts and
these subparts are then distributed among the
available processors in the system. Parallel
processing completes the job on the shortest
possible time.
Parallel O.S
Advantages
• Increasing the number of processors will increase the throughput of the
system.
• In parallel processing if one of the processors in the system fails, the
process is further rescheduled to get executed on another processor, it
increases fault tolerance.

• The system can be configured according to the need. With the


increasing need for computing, the number of processors can also be
increased.

• The maintenance, build-up cost is lower as components are


commercially available.
Process
Program

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy