Types of an operating system
Sudha. S
Assistant Professor
Department of Computer Science
YIASCM
YIASCM 1
Types of Operating System :-
YIASCM 2
Batch operating system :-
⮚Effective form of processing.
⮚Programs are prepared Offline.
⮚ Groups of programs are collected together
& are processed one by one.
⮚Advantage:-Reduces computer idle time.
⮚Disadvantage:- Large turnaround time
YIASCM 3
Batch operating system :-
⮚Programmer prepares their programs and data on
deck of cards.
⮚Operator periodically collect the submitted programs
and would batch them together.
⮚Batched programs were loaded into input device.
⮚Operator gives command to start executing the jobs.
⮚Jobs automatically loads from the input device.
⮚After process, operator separates and keep the
printed output.
YIASCM 4
YIASCM 5
Uniprogramming System
User Job
Operating System OS area
User
Program
area
Main Memory
CPU
A Uniprogramming system model in which only one job is processed by the system at a time and all the
system resources are exclusively available for the job until it completes.
Execution
in
progress
YIASCM 6
⮚Is a interleaved execution of two or more programs by
the same computer.
⮚One or more programs are executed at the same time.
⮚ Different scheduling techniques are:-
✔ First come first serve
✔ Round robin (RR)
✔ Shortest job first (SJF)
Multiprogramming System
YIASCM 7
Multiprogramming System
Operating System
Job A
Job B
Job C (Writing
for CPU)
CPU
Execution in Progress
Main Memory
Writing O/P data
Secondary
Disk
Storage
YIASCM 8
Multiprogramming System
YIASCM 9
Multiprogramming System
• Two types of scheduling were introduced to handle this decision-
making - job scheduling and CPU scheduling. Job scheduling refers to
the selection of jobs to load into memory.
• CPU scheduling refers to the selection of a job existing in memory to
execute via the CPU. In a computer system, both these decisions are
made by the operating system.
10
Scheduling Basics
• Job Queue - Contains all processes that have been introduced into the
system
• Ready Queue - Contains processes that are waiting for CPU time, and
can be selected to run at any time
• Device Queue - Contains processes waiting on a certain device. Each
device has its own queue for processes that need input/output from it
11
First come First serve
• The name of this algorithm is self-explanatory. This is the simplest (but
least efficient) algorithm used to schedule processes for execution.
• The first process to arrive in the ready queue will be executed first.
Since this is not a preemptive algorithm, an incoming process is not
allowed to take over the CPU if the running process is not complete.
Thus, the running process will continue until it is completed.
12
Shortest job first
• In this algorithm, if more than one process is ready to execute, the
scheduler selects the process with the shortest "burst time" (time to
finish) and assigns it to the CPU.
• This is also a non-preemptive algorithm, so as soon as a process is
assigned to the CPU, it will not be replaced until it is completed.
13
Shortest remaining time first
• This is similar to Shortest Job First, but this algorithm is
preemptive.
• If a new process becomes ready, the scheduler will check if its
burst time is shorter than the remaining time of the currently
running process, then the new process will "preempt" the
current process.
• The current process will be returned to the ready queue.
14
⮚It is the system capability to concurrently work on more
than one task.
⮚ Same as multiprogramming.
⮚Multitasking is referred in context to single user.
Multitasking System
YIASCM 15
Time-sharing operating systems :-
■ Time-sharing is a technique which enables many people,
located at various terminals, to use a particular computer
system at the same time.
■ Time-sharing or multitasking is a logical extension of
multiprogramming. Processor's time which is shared among
multiple users simultaneously is termed as time-sharing.
YIASCM 16
Time-sharing operating systems :-
■ The main difference between Multiprogrammed Systems and Time-Sharing Systems
is that in case of Multiprogrammed systems, the objective is to maximize processor
use, whereas in Time-Sharing Systems, the 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.
■ The operating system uses CPU scheduling and multiprogramming to provide each
user with a small portion of a time. Computer systems that were designed primarily
as batch systems have been modified to time-sharing systems.
YIASCM 17
Time Sharing System
New
Job
Ready
Blocked
Running
Job is allocated the
CPU for execution
I/O
completed
Job must wait for
I/O completion
Job
processin g
completed
The process state diagram for a time-sharing system
Allocated time slice is over
YIASCM 18
P3, P2, P1
Multiprocessing System
⮚Multiprocessing system is a integrated system.
⮚Two or more CPU is present.
⮚Simultaneously execute several programs.
YIASCM 19
Multiprocessing System
20
Multiprocessing System
Types of Multiprocessors
There are mainly two types of multiprocessors i.e. symmetric and asymmetric multiprocessors. Details
about them are as follows −
Symmetric Multiprocessors
In these types of systems, each processor contains a similar copy of the operating system and they all
communicate with each other. All the processors are in a peer to peer relationship i.e. no master - slave
relationship exists between them.
An example of the symmetric multiprocessing system is the Encore version of Unix for the Multimax
Computer.
YIASCM 21
Multiprocessing System
Asymmetric Multiprocessors
• In asymmetric systems, each processor is given a predefined task. There
is a master processor that gives instruction to all the other processors.
Asymmetric multiprocessor system contains a master slave relationship.
• Asymmetric multiprocessor was the only type of multiprocessor
available before symmetric multiprocessors were created. Now also, this
is the cheaper option.
22
Advantages
More reliable Systems
• In a multiprocessor system, even if one processor fails, the system will
not halt. This ability to continue working despite hardware failure is
known as graceful degradation.
• For example: If there are 5 processors in a multiprocessor system and
one of them fails, then also 4 processors are still working. So the system
only becomes slower and does not ground to a halt.
23
Advantages
Enhanced Throughput
• If multiple processors are working in tandem, then the
throughput of the system increases i.e. number of processes
getting executed per unit of time increase.
• If there are N processors then the throughput increases by an
amount just under N.
24
Advantages
More Economic Systems
• Multiprocessor systems are cheaper than single processor systems in the
long run because they share the data storage, peripheral devices, power
supplies etc.
• If there are multiple processes that share data, it is better to schedule
them on multiprocessor systems with shared data than have different
computer systems with multiple copies of the data.
25
Disadvantages
Increased Expense
• Even though multiprocessor systems are cheaper in the long
run than using multiple computer systems, still they are quite
expensive. It is much cheaper to buy a simple single processor
system than a multiprocessor system.
26
Disadvantages
Complicated Operating System Required
• There are multiple processors in a multiprocessor system that
share peripherals, memory etc. So, it is much more
complicated to schedule processes and impart resources to
processes.
• Than in single processor systems. Hence, a more complex and
complicated operating system is required in multiprocessor
systems.
27
Disadvantages
Large Main Memory Required
• All the processors in the multiprocessor system share the
memory. So a much larger pool of memory is required as
compared to single processor systems.
28
Distributed operating System
■ Distributed systems use multiple central processors to serve
multiple real-time applications and multiple users.
■ Data processing jobs are distributed among the processors
accordingly.
■ The processors communicate with one another through various
communication lines (such as high-speed buses or telephone lines).
■ These are referred as loosely coupled systems or distributed
systems. Processors in a distributed system may vary in size and
function. These processors are referred as sites, nodes, computers,
and so on.
YIASCM 29
❑ With resource sharing facility, a user at one site may be able to use
the resources available at another.
❑ Speedup the exchange of data with one another via electronic mail.
❑ If one site fails in a distributed system, the remaining sites can
potentially continue operating.
❑ Reduction of delays in data processing.
❑ Reduction of the load on the host computer.
YIASCM 30
The advantages of distributed systems are as follows −
Distributed operating system
• OSes running on the different computers act like a single OS.
• Process does not get to know (or need to know) that other
resources/processes are at other computers
– Process gets input/output from hardware X, which can be on any computer
– Process A communicates with process B the same way whether they are on same
computer or not
– OS takes care of using the network if needed
31
Distributed operating system
• A process may be running on a different computer from where it was started.
Processes can be moved among different computers
• The “distributed” nature of the system is hidden from the processes
• The OS manages all the “distributed” aspects
• Example: Plan 9, Berkeley software distribution, MOSIX
32
Distributed operating system
33
YIASCM 34
Network operating System :-
■ 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) .
■ Examples of network operating systems include Microsoft Windows
Server 2003, Microsoft Windows Server 2008, UNIX, Linux, Mac OS X,
Novell NetWare, and BSD.
YIASCM 35
Advantages and disadvantages
– The advantages of network operating systems are as follows −
– Centralized servers are highly stable.
– Security is server managed.
– Upgrades to new technologies and hardware can be easily integrated into
the system.
– Remote access to servers is possible from different locations and types of
systems.
– The disadvantages of network operating systems are as follows
– High cost of buying and running a server.
– Dependency on a central location for most operations.
– Regular maintenance and updates are required.
YIASCM 36
YIASCM 37
Real Time operating System :-
■ A real-time system is defined as a 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 the response time. So in this
method, the response time is very less as compared to online processing.
YIASCM 38
Real Time operating System :-
■ Real-time systems are used when there are rigid time requirements on the operation
of a processor or the flow of data and real-time systems can be used as a control
device in a dedicated application.
■ A real-time operating system must have well-defined, fixed time constraints,
otherwise the system will fail.
■ For example, Scientific experiments, medical imaging systems, industrial control
systems, weapon systems, robots, air traffic control systems, etc.
YIASCM 39
YIASCM 40
Summary
 How we can make use of different types of operating system depending on the
performance.
 Different types of operating systems how it is different from each other.
 Advantages and disadvantages of different operating systems.
 Structure and functioning of different operating system in execution of process/ a
job.
41
References
● Abraham Silberschatz and Peter Baer Galvin. (2012). Operating System Concepts,
7th Ed., Pearson.
● H.M.Deitel. (2003). Operating Systems, 3rd Ed. Pearson Learning Solutions.
● William Stallings. (2010). Operating Systems, 6th Ed., Pearson Education.
● Stuart. (2008). Operating systems: Principles, Design and Implementation, 1st Ed.
Cengage Learning India
● Dhananjay M. Dhamdhere.Operating System,3rd Ed.Mc Graw Hill Education.
YIASCM 42

Unit1typesofos.pptx

  • 1.
    Types of anoperating system Sudha. S Assistant Professor Department of Computer Science YIASCM YIASCM 1
  • 2.
    Types of OperatingSystem :- YIASCM 2
  • 3.
    Batch operating system:- ⮚Effective form of processing. ⮚Programs are prepared Offline. ⮚ Groups of programs are collected together & are processed one by one. ⮚Advantage:-Reduces computer idle time. ⮚Disadvantage:- Large turnaround time YIASCM 3
  • 4.
    Batch operating system:- ⮚Programmer prepares their programs and data on deck of cards. ⮚Operator periodically collect the submitted programs and would batch them together. ⮚Batched programs were loaded into input device. ⮚Operator gives command to start executing the jobs. ⮚Jobs automatically loads from the input device. ⮚After process, operator separates and keep the printed output. YIASCM 4
  • 5.
  • 6.
    Uniprogramming System User Job OperatingSystem OS area User Program area Main Memory CPU A Uniprogramming system model in which only one job is processed by the system at a time and all the system resources are exclusively available for the job until it completes. Execution in progress YIASCM 6
  • 7.
    ⮚Is a interleavedexecution of two or more programs by the same computer. ⮚One or more programs are executed at the same time. ⮚ Different scheduling techniques are:- ✔ First come first serve ✔ Round robin (RR) ✔ Shortest job first (SJF) Multiprogramming System YIASCM 7
  • 8.
    Multiprogramming System Operating System JobA Job B Job C (Writing for CPU) CPU Execution in Progress Main Memory Writing O/P data Secondary Disk Storage YIASCM 8
  • 9.
  • 10.
    Multiprogramming System • Twotypes of scheduling were introduced to handle this decision- making - job scheduling and CPU scheduling. Job scheduling refers to the selection of jobs to load into memory. • CPU scheduling refers to the selection of a job existing in memory to execute via the CPU. In a computer system, both these decisions are made by the operating system. 10
  • 11.
    Scheduling Basics • JobQueue - Contains all processes that have been introduced into the system • Ready Queue - Contains processes that are waiting for CPU time, and can be selected to run at any time • Device Queue - Contains processes waiting on a certain device. Each device has its own queue for processes that need input/output from it 11
  • 12.
    First come Firstserve • The name of this algorithm is self-explanatory. This is the simplest (but least efficient) algorithm used to schedule processes for execution. • The first process to arrive in the ready queue will be executed first. Since this is not a preemptive algorithm, an incoming process is not allowed to take over the CPU if the running process is not complete. Thus, the running process will continue until it is completed. 12
  • 13.
    Shortest job first •In this algorithm, if more than one process is ready to execute, the scheduler selects the process with the shortest "burst time" (time to finish) and assigns it to the CPU. • This is also a non-preemptive algorithm, so as soon as a process is assigned to the CPU, it will not be replaced until it is completed. 13
  • 14.
    Shortest remaining timefirst • This is similar to Shortest Job First, but this algorithm is preemptive. • If a new process becomes ready, the scheduler will check if its burst time is shorter than the remaining time of the currently running process, then the new process will "preempt" the current process. • The current process will be returned to the ready queue. 14
  • 15.
    ⮚It is thesystem capability to concurrently work on more than one task. ⮚ Same as multiprogramming. ⮚Multitasking is referred in context to single user. Multitasking System YIASCM 15
  • 16.
    Time-sharing operating systems:- ■ Time-sharing is a technique which enables many people, located at various terminals, to use a particular computer system at the same time. ■ Time-sharing or multitasking is a logical extension of multiprogramming. Processor's time which is shared among multiple users simultaneously is termed as time-sharing. YIASCM 16
  • 17.
    Time-sharing operating systems:- ■ The main difference between Multiprogrammed Systems and Time-Sharing Systems is that in case of Multiprogrammed systems, the objective is to maximize processor use, whereas in Time-Sharing Systems, the 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. ■ The operating system uses CPU scheduling and multiprogramming to provide each user with a small portion of a time. Computer systems that were designed primarily as batch systems have been modified to time-sharing systems. YIASCM 17
  • 18.
    Time Sharing System New Job Ready Blocked Running Jobis allocated the CPU for execution I/O completed Job must wait for I/O completion Job processin g completed The process state diagram for a time-sharing system Allocated time slice is over YIASCM 18 P3, P2, P1
  • 19.
    Multiprocessing System ⮚Multiprocessing systemis a integrated system. ⮚Two or more CPU is present. ⮚Simultaneously execute several programs. YIASCM 19
  • 20.
  • 21.
    Multiprocessing System Types ofMultiprocessors There are mainly two types of multiprocessors i.e. symmetric and asymmetric multiprocessors. Details about them are as follows − Symmetric Multiprocessors In these types of systems, each processor contains a similar copy of the operating system and they all communicate with each other. All the processors are in a peer to peer relationship i.e. no master - slave relationship exists between them. An example of the symmetric multiprocessing system is the Encore version of Unix for the Multimax Computer. YIASCM 21
  • 22.
    Multiprocessing System Asymmetric Multiprocessors •In asymmetric systems, each processor is given a predefined task. There is a master processor that gives instruction to all the other processors. Asymmetric multiprocessor system contains a master slave relationship. • Asymmetric multiprocessor was the only type of multiprocessor available before symmetric multiprocessors were created. Now also, this is the cheaper option. 22
  • 23.
    Advantages More reliable Systems •In a multiprocessor system, even if one processor fails, the system will not halt. This ability to continue working despite hardware failure is known as graceful degradation. • For example: If there are 5 processors in a multiprocessor system and one of them fails, then also 4 processors are still working. So the system only becomes slower and does not ground to a halt. 23
  • 24.
    Advantages Enhanced Throughput • Ifmultiple processors are working in tandem, then the throughput of the system increases i.e. number of processes getting executed per unit of time increase. • If there are N processors then the throughput increases by an amount just under N. 24
  • 25.
    Advantages More Economic Systems •Multiprocessor systems are cheaper than single processor systems in the long run because they share the data storage, peripheral devices, power supplies etc. • If there are multiple processes that share data, it is better to schedule them on multiprocessor systems with shared data than have different computer systems with multiple copies of the data. 25
  • 26.
    Disadvantages Increased Expense • Eventhough multiprocessor systems are cheaper in the long run than using multiple computer systems, still they are quite expensive. It is much cheaper to buy a simple single processor system than a multiprocessor system. 26
  • 27.
    Disadvantages Complicated Operating SystemRequired • There are multiple processors in a multiprocessor system that share peripherals, memory etc. So, it is much more complicated to schedule processes and impart resources to processes. • Than in single processor systems. Hence, a more complex and complicated operating system is required in multiprocessor systems. 27
  • 28.
    Disadvantages Large Main MemoryRequired • All the processors in the multiprocessor system share the memory. So a much larger pool of memory is required as compared to single processor systems. 28
  • 29.
    Distributed operating System ■Distributed systems use multiple central processors to serve multiple real-time applications and multiple users. ■ Data processing jobs are distributed among the processors accordingly. ■ The processors communicate with one another through various communication lines (such as high-speed buses or telephone lines). ■ These are referred as loosely coupled systems or distributed systems. Processors in a distributed system may vary in size and function. These processors are referred as sites, nodes, computers, and so on. YIASCM 29
  • 30.
    ❑ With resourcesharing facility, a user at one site may be able to use the resources available at another. ❑ Speedup the exchange of data with one another via electronic mail. ❑ If one site fails in a distributed system, the remaining sites can potentially continue operating. ❑ Reduction of delays in data processing. ❑ Reduction of the load on the host computer. YIASCM 30 The advantages of distributed systems are as follows −
  • 31.
    Distributed operating system •OSes running on the different computers act like a single OS. • Process does not get to know (or need to know) that other resources/processes are at other computers – Process gets input/output from hardware X, which can be on any computer – Process A communicates with process B the same way whether they are on same computer or not – OS takes care of using the network if needed 31
  • 32.
    Distributed operating system •A process may be running on a different computer from where it was started. Processes can be moved among different computers • The “distributed” nature of the system is hidden from the processes • The OS manages all the “distributed” aspects • Example: Plan 9, Berkeley software distribution, MOSIX 32
  • 33.
  • 34.
  • 35.
    Network operating System:- ■ 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) . ■ Examples of network operating systems include Microsoft Windows Server 2003, Microsoft Windows Server 2008, UNIX, Linux, Mac OS X, Novell NetWare, and BSD. YIASCM 35
  • 36.
    Advantages and disadvantages –The advantages of network operating systems are as follows − – Centralized servers are highly stable. – Security is server managed. – Upgrades to new technologies and hardware can be easily integrated into the system. – Remote access to servers is possible from different locations and types of systems. – The disadvantages of network operating systems are as follows – High cost of buying and running a server. – Dependency on a central location for most operations. – Regular maintenance and updates are required. YIASCM 36
  • 37.
  • 38.
    Real Time operatingSystem :- ■ A real-time system is defined as a 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 the response time. So in this method, the response time is very less as compared to online processing. YIASCM 38
  • 39.
    Real Time operatingSystem :- ■ Real-time systems are used when there are rigid time requirements on the operation of a processor or the flow of data and real-time systems can be used as a control device in a dedicated application. ■ A real-time operating system must have well-defined, fixed time constraints, otherwise the system will fail. ■ For example, Scientific experiments, medical imaging systems, industrial control systems, weapon systems, robots, air traffic control systems, etc. YIASCM 39
  • 40.
  • 41.
    Summary  How wecan make use of different types of operating system depending on the performance.  Different types of operating systems how it is different from each other.  Advantages and disadvantages of different operating systems.  Structure and functioning of different operating system in execution of process/ a job. 41
  • 42.
    References ● Abraham Silberschatzand Peter Baer Galvin. (2012). Operating System Concepts, 7th Ed., Pearson. ● H.M.Deitel. (2003). Operating Systems, 3rd Ed. Pearson Learning Solutions. ● William Stallings. (2010). Operating Systems, 6th Ed., Pearson Education. ● Stuart. (2008). Operating systems: Principles, Design and Implementation, 1st Ed. Cengage Learning India ● Dhananjay M. Dhamdhere.Operating System,3rd Ed.Mc Graw Hill Education. YIASCM 42