Operating System Full and Final Notes
Operating System Full and Final Notes
[Unit 1] Introduction and Operating system structures: Definition, Types of Operating system, Real-
Time operating system, System Components: System Services, Systems Calls, System Programs,
System structure, Virtual Machines, System Design and Implementation, System Generations.
An operating system (OS) is basically a collection of software that manages computer hardware
resources and provides common services for computer programs. Operating system is a crucial
component of the system software in a computer system.
Operating System (OS) is the most important program that is first loaded on a computer when
you switch on the system. Operating System is system software. The communication between a
user and a system takes place with the help of operating systems.
Windows, Linux, and Android are examples of operating systems that enable the user to use
programs like MS Office, Notepad, and games on the computer or mobile phone. It is necessary
to have at least one operating system installed in the computer in order to run basic programs like
browsers.
Functions of Operating System
What is Kernel?
The kernel is the core component of an operating system for a computer (OS). All other
components of the OS rely on the core to supply them with essential services. It serves as the
primary interface between the OS and the hardware and aids in the control of devices,
networking, file systems, and process and memory management.
Functions of kernel
The kernel is the core component of an operating system which acts as an interface between
applications, and the data is processed at the hardware level.
When an OS is loaded into memory, the kernel is loaded first and remains in memory until the OS
is shut down. After that, the kernel provides and manages the computer resources and allows
other programs to run and use these resources. The kernel also sets up the memory address space
for applications, loads the files with application code into memory, and sets up the execution
stack for programs.
Types of Kernel
Linus Torvalds introduced the concept of a monolithic kernel in 1991 as a part of the Linux kernel. A
monolithic kernel is a single large program that contains all operating system components. However,
the Linux kernel evolved over the years and now consists of different types of kernels, as listed below.
1. Monolithic Kernel As the name suggests, a monolithic kernel is a single large program that
contains all operating system components. The entire kernel executes in the processor’s privileged
mode and provides full access to the system’s hardware. Monolithic kernels are faster than
microkernels because they don’t have the overhead of message passing. This type of kernel is
generally used in embedded systems and real-time operating systems.
2. Microkernel A microkernel is a kernel that contains only the essential components required for the
basic functioning of the operating system. All other components are removed from the kernel and
implemented as user-space processes. The microkernel approach provides better modularity,
flexibility, and extensibility. It is also more stable and secure than monolithic kernels.
Distributed OS
A distributed OS is a recent advancement in the field of computer technology and is utilized all over
the world that too with great pace. In a distributed OS, various computers are connected through a
single communication channel. These independent computers have their memory unit and CPU and
are known as loosely coupled systems. The system processes can be of different sizes and can
perform different functions. The major benefit of such a type of operating system is that a user can
access files that are not present on his system but in another connected system. In addition, remote
access is available to the systems connected to this network.
Advantages of Distributed OS
Failure of one system will not affect the other systems because all the computers are independent of
each other.
The load on the host system is reduced.
The size of the network is easily scalable as many computers can be added to the network.
As the workload and resources are shared therefore the calculations are performed at a higher
speed.
Data exchange speed is increased with the help of electronic mail.
Disadvantages of Distributed OS
The setup cost is high.
Software used for such systems is highly complex.
Failure of the main network will lead to the failure of the whole system.
Examples of Distributed OS: LOCUS, etc.
Multitasking OS
The multitasking OS is also known as the time-sharing operating system as each task is given some
time so that all the tasks work efficiently. This system provides access to a large number of users,
and each user gets the time of CPU as they get in a single system. The tasks performed are given by a
single user or by different users. The time allotted to execute one task is called a quantum, and as
soon as the time to execute one task is completed, the system switches over to another task.
Advantages of Multitasking OS
Each task gets equal time for execution.
The idle time for the CPU will be the lowest.
There are very few chances for the duplication of the software.
Disadvantages of Multitasking OS
Processes with higher priority cannot be executed first as equal priority is given to each process or
task.
Various user data is needed to be taken care of from unauthorized access.
Sometimes there is a data communication problem.
Examples of Multitasking OS: UNIX, etc.
Network OS
Network operating systems are the systems that run on a server and manage all the networking
functions. They allow sharing of various files, applications, printers, security, and other networking
functions over a small network of computers like LAN or any other private network. In the network
OS, all the users are aware of the configurations of every other user within the network, which is
why network operating systems are also known as tightly coupled systems.
Advantages of Network OS
New technologies and hardware can easily upgrade the systems.
Security of the system is managed over servers.
Servers can be accessed remotely from different locations and systems.
The centralized servers are stable.
Disadvantages of Network OS
Server costs are high.
Regular updates and maintenance are required.
Users are dependent on the central location for the maximum number of operations.
Examples of Network OS: Microsoft Windows server 2008, LINUX, etc.
Real-Time OS
Real-Time operating systems serve real-time systems. These operating systems are useful when
many events occur in a short time or within certain deadlines, such as real-time simulations.
Types of the real-time OS are:
Hard real-time OS
The hard real-time OS is the operating system for mainly the applications in which the slightest delay
is also unacceptable. The time constraints of such applications are very strict. Such systems are built
for life-saving equipment like parachutes and airbags, which immediately need to be in action if an
accident happens.
Soft real-time OS
The soft real-time OS is the operating system for applications where time constraint is not very strict.
In a soft real-time system, an important task is prioritized over less important tasks, and this priority
remains active until the completion of the task. Furthermore, a time limit is always set for a specific
job, enabling short time delays for future tasks, which is acceptable. For Example, virtual reality,
reservation systems, etc.
Advantages of Real-Time OS
It provides more output from all the resources as there is maximum utilization of systems.
It provides the best management of memory allocation.
These systems are always error-free.
These operating systems focus more on running applications than those in the queue.
Shifting from one task to another takes very little time.
Disadvantages of Real-Time OS
System resources are extremely expensive and are not so good.
The algorithms used are very complex.
Only limited tasks can run at a single time.
In such systems, we cannot set thread priority as these systems cannot switch tasks easily.
Examples of Real-Time OS: Medical imaging systems, robots, etc.