Operating System: By: Swati Singh Assistant Professor Uttaranchal University
Operating System: By: Swati Singh Assistant Professor Uttaranchal University
• FORTRAN OS, General Motors OS, I/O system are the Operating systems
that were developed in 1950s, but they handled only a single task at a
time.
CONTROL
HANDLE
MANAGE
What is Kernel in OS?
• It is a core component of an Operating System that manages
operations of computer and hardware.
• It loads first into the memory when OS runs.
• Acts as a bridge between data processing at hardware level using
inter-process communication and system calls.
• Decide the state of incoming processes.
• Control the tasks.
Difference between OS and Kernel
Sr. No. Operating System Kernel
1 It is the first program when computer system Its is the first program to load when an operating
boots up system runs
2 It is a system software It is a part of Operating System
4 It acts as an interface between user and It acts as an interface between applications and
hardware hardware
5 Provides ease to use system operations, security Memory management, task management
etc. handled by kernel
Functions of Operating System
Functions
Ready
Waiting
Executing
Blocked Suspended
Terminated
Process Control Block
Uniquely identifies the
Process ID process
Process Operations
Corresponding to every task there is a The last step after the safe execution
process associated with it. of the process. Resources gets
Log in to Computer System, Open an released after the termination of a
application such as MS Word or process.
Printing of a document
Process Scheduling
• Through this OS decides the priority processes which are ready and
waiting states
• It ensures the maximum utilization of CPU.
• OS uses Scheduler for deciding the priority of process.
Scheduling Algorithms
• First Come First Serve (FCFS) Scheduling
• Shortest Job First (SJF) Scheduling
• Priority Scheduling
• Round Robin Scheduling
Deadlock
• It is a condition that occurs when multiple processes wait for each
other to free up resources and as a result all processes remain halted.
Memory Management
• Allocating the main memory space to a process
• Enable the execution of multiple processes at the same time
• Utilization of small free spaces
• It ensures accuracy, availability and consistency of data
Memory Management
File Access
File Attributes File Operations File System
Permissions
Internal External
Protection of activities Secure the data and
from one process to programs from
another process unauthorized access
Types of Operating System
Multi
Batch Processing
Programming
Job 2 Batch 2
Job 3 Batch 3
ADVANTAGES:
• Time constraint is not there
• Multiple users can share
• Easy to do large number of jobs at the same time
DISADVANTAGES:
• These are hard to debug
• Other jobs has to wait for an unknown time period
• If any job failed, then other jobs may suffer halt condition
Time Sharing Operating System
• Each task is given a time for execution
• The time given to each task for execution is called quantum.
Application 1
Operating System
Application 2
(Chrome)
Application 3
(Software
Download)
ADVANTAGES:
• Each task gets and equal priority to execute
• CPU Idle time reduce
DISADVANTAGES:
• Issue of security and integrity
• Data communication problem
Distributed Operating System
• Various autonomous computers connected with each other using a
shared communication network.
• These are also called loosely coupled systems.
• These systems are of different size and functions.
• One user access the files or software that actually not present on his
system but some other system connected with this system.
• Remote access is enabled.
ADVANTAGES:
• Failure of one will not affect the other network communication.
• Due to shared resources, computation is fast and durable.
• Load on host computer reduces.
• Delay in data processing reduces.
• Many systems can be added to the network.
DISADVANTAGES:
• These systems are not readily available, in turn costly.
• Failure of main network will stop the entire network.
Network Operating System
• It is a small private network.
• These network allow shared access of printers, files, security and
applications.
• All users are well aware of the underlying configuration, of all the
users within the network, their individual connections etc.
• These computers are tightly coupled systems.
ADVANTAGES:
• Highly stable centralized servers.
• New technologies and hardware up-gradation are easily integrated
into the system.
• Server access is possible remotely.
DISADVANTAGES:
• Servers are costly.
• Maintenance and updates are required regularly.
Real Time Operating System
• These systems are specially designed for handling real time
applications or embedded applications.
These operating system are meant These operating system are for
for applications where time applications where from time
constraints are very strict and even constraint is less strict. The delay
the shortest possible delay is not can be accepted. Example- online
acceptable. Example- Aircraft transaction system.
system.
ADVANTAGES:
• Maximum utilization of devices and system.
• These type of systems are error free.
• Focus more on running applications than the applications in queue.
DISADVANTAGES:
• Very few task run at the same time.
• The algorithms are very complex and difficult to design.
• Systems are less prone to switch the tasks.
System Call
• System call is a way of program to interact with operating system.
• It is a programmatic way in which a computer program requests a
service from the kernel of the operating system it is executed on.
• A system call created when a computer program makes a request to
the operating system’s kernel.
• System call provides the services of operating system to the kernel
through API(Application Program Interface).
• System calls are the only entry points into the kernel system.
System call Services
• Process creation and management.
• Main memory management
• File access.
• Device handling(I/O)
• Protection
• Networking
Examples of System calls in Windows and
UNIX
WINDOWS UNIX