0% found this document useful (0 votes)
12 views24 pages

Operating System_weak_1_1732618040000_012258

The document outlines the objectives and functions of operating systems, emphasizing their role in managing hardware and software resources, ensuring efficient and fair resource allocation, and providing a user-friendly interface. It details various management tasks including process, memory, CPU, device, file, and storage management, as well as security and performance monitoring. Additionally, it discusses different types of operating systems such as batch, multiprogramming, and multitasking systems.

Uploaded by

primestar279
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)
12 views24 pages

Operating System_weak_1_1732618040000_012258

The document outlines the objectives and functions of operating systems, emphasizing their role in managing hardware and software resources, ensuring efficient and fair resource allocation, and providing a user-friendly interface. It details various management tasks including process, memory, CPU, device, file, and storage management, as well as security and performance monitoring. Additionally, it discusses different types of operating systems such as batch, multiprogramming, and multitasking systems.

Uploaded by

primestar279
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/ 24

Objectives of OS

The primary goals of an operating system are as follows:

 Convenience – An operating system improves the use of a machine. Operating systems enable
users to get started on the things they wish to complete quickly without having to cope with
the stress of first configuring the system.

 Efficiency – An operating system enables the efficient use of resources. This is due to less
time spent configuring the system.

 Ability to evolve – An operating system should be designed in such a way that it allows for
the effective development, testing, and introduction of new features without interfering with
service.

 Management of system resources – It guarantees that resources are shared fairly among
various processes and users.
A computer system has many hardware and software resources that may be required to solve a
problem: CPU time, memory space, file storage space, I/O devices etc. The operating system acts
as the manager of these resources, facing numerous and possibly conflicting requests for resources,
the operating system must decide how (and when) to allocate (and deallocate) them to specific
programs and users so that it can operate the computer system efficiently, fairly, and securely. So,
the bottom-up view is that operating system is a resource manager who manages the hardware and
software resources in the computer system. A slightly different view of an operating system
emphasizes the need to control the various I/O devices and programs. An operating system is a
control program that manages the execution of user programs to prevent errors and improper use
of a computer.
Primary goal (convenience)
Operating System Definition and Function
In the Computer System (comprises of Hardware and software), Hardware can only understand
machine code (in the form of 0 and 1) which doesn't make any sense to a naive user.

We need a system which can act as an intermediary and manage all the processes and resources
present in the system.
An Operating System can be defined as an interface between user and hardware. It is
responsible for the execution of all the processes, Resource Allocation, CPU management, File
Management and many other tasks.

The purpose of an operating system is to provide an environment in which a user can execute
programs in convenient and efficient manner.

Structure of a Computer System


A Computer System consists of:

o Users (people who are using the computer)


o Application Programs (Compilers, Databases, Games, Video player, Browsers, etc.)
o System Programs (Shells, Editors, Compilers, etc.)
o Operating System ( A special program which acts as an interface between user and
hardware )
o Hardware ( CPU, Disks, Memory, etc)
Why are Operating Systems Used?
Operating System is used as a communication channel between the Computer hardware and the
user. It works as an intermediate between System Hardware and End-User. Operating System
handles the following responsibilities:
 It controls all the computer resources.
 It provides valuable services to user programs.
 It coordinates the execution of user programs.
 It provides resources for user programs.
 It provides an interface (virtual machine) to the user.
 It hides the complexity of software.
 It supports multiple execution modes.
 It monitors the execution of user programs to prevent errors.

What does an Operating system do?

1. Process Management
2. Process Synchronization
3. Memory Management
4. CPU Scheduling
5. File Management
6. Security

Functions of Operating System

1. Memory Management

It is the management of the main or primary memory. Whatever program is executed, it has to be
present in the main memory. Main memory is a quick storage area that may be accessed directly by
the CPU. When the program is completed, the memory region is released and can be used by other
programs. Therefore, there can be more than one program present at a time. Hence, it is required to
manage the memory.

The operating system:

 Allocates and deallocates the memory.

 Keeps a record of which part of primary memory is used by whom and how much.

 Distributes the memory while multiprocessing.

 In multiprogramming, the operating system selects which processes acquire memory when and
how much memory they get.
2. Processor Management/Scheduling

Every software that runs on a computer, whether in the background or in the frontend, is a process.
Processor management is an execution unit in which a program operates. The operating system
determines the status of the processor and processes, selects a job and its processor, allocates the
processor to the process, and de-allocates the processor after the process is completed.

When more than one process runs on the system the OS decides how and when a process will use the
CPU. Hence, the name is also CPU Scheduling. The OS:

 Allocates and deallocates processor to the processes.


 Keeps record of CPU status.

Certain algorithms used for CPU scheduling are as follows:

 First Come First Serve (FCFS)

 Shortest Job First (SJF)

 Round-Robin Scheduling

 Priority-based scheduling etc.


Purpose of CPU scheduling

The purpose of CPU scheduling is as follows:

 Proper utilization of CPU. Since the proper utilization of the CPU is necessary. Therefore, the
OS makes sure that the CPU should be as busy as possible.

 Since every device should get a chance to use the processor. Hence, the OS makes sure that
the devices get fair processor time.

 Increasing the efficiency of the system.


3. Device Management

An operating system regulates device connection using drivers. The processes may require devices
for their use. This management is done by the OS. The OS:

 Allocates and deallocates devices to different processes.

 Keeps records of the devices.

 Decides which process can use which device for how much time.
4. File Management

The operating system manages resource allocation and de-allocation. It specifies which process
receives the file and for how long. It also keeps track of information, location, uses, status, and so on.
These groupings of resources are referred to as file systems. The files on a system are stored in
different directories. The OS:

 Keeps records of the status and locations of files.

 Allocates and deallocates resources.

 Decides who gets the resources.


5. Storage Management

Storage management is a procedure that allows users to maximize the utilization of storage devices
while also protecting data integrity on whatever media on which it lives. Network virtualization,
replication, mirroring, security, compression, deduplication, traffic analysis, process automation,
storage provisioning, and memory management are some of the features that may be included. The
operating system is in charge of storing and accessing files. The creation of files, the creation of
directories, the reading and writing of data from files and directories, as well as the copying of the
contents of files and directories from one location to another are all included in storage management.

The OS uses storage management for:

 Improving the performance of the data storage resources.

 It optimizes the use of various storage devices.

 Assists businesses in storing more data on existing hardware, speeding up the data retrieval
process, preventing data loss, meeting data retention regulations, and lowering IT costs

What are the functions of Operating System

 Security – For security, modern operating systems employ a firewall. A firewall is a type of
security system that monitors all computer activity and blocks it if it detects a threat.

 Job Accounting – As the operating system keeps track of all the functions of a computer
system. Hence, it makes a record of all the activities taking place on the system. It has an
account of all the information about the memory, resources, errors, etc. Therefore, this
information can be used as and when required.

 Control over system performance – The operating system will collect consumption statistics
for various resources and monitor performance indicators such as reaction time, which is the
time between requesting a service and receiving a response from the system.

 Error detecting aids – While a computer system is running, a variety of errors might occur.
Error detection guarantees that data is delivered reliably across susceptible networks. The
operating system continuously monitors the system to locate or recognize problems and
protects the system from them.

 Coordination between other software and users – The operating system (OS) allows
hardware components to be coordinated and directs and allocates assemblers, interpreters,
compilers, and other software to different users of the computer system.

 Booting process – The process of starting or restarting a computer is referred to as Booting.


Cold booting occurs when a computer is totally turned off and then turned back on. Warm
booting occurs when the computer is restarted. The operating system (OS) is in charge of
booting the computer.

Types of Operating Systems (OS)

An operating system is a well-organized collection of programs that manages the computer


hardware. It is a type of system software that is responsible for the smooth functioning of the
computer system.
Batch Operating System
In the 1970s, Batch processing was very popular. In this technique, similar types of jobs
were batched together and executed in time. People were used to having a single
computer which was called a mainframe.

In Batch operating system, access is given to more than one person; they submit their
respective jobs to the system for the execution.

The system put all of the jobs in a queue on the basis of first come first serve and then
executes the jobs one by one. The users collect their respective output when all the jobs
get executed.
The purpose of this operating system was mainly to transfer control from one job to another as
soon as the job was completed. It contained a small set of programs called the resident monitor
that always resided in one part of the main memory. The remaining part is used for servicing
jobs.

Advantages of Batch OS
o The use of a resident monitor improves computer efficiency as it eliminates CPU time
between two jobs.
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.
Advantages of Batch Operating System
 It is very difficult to guess or know the time required for any job to complete. Processors of
the batch systems know how long the job would be when it is in the queue.
 Multiple users can share the batch systems.
 The idle time for the batch system is very less.
 It is easy to manage large work repeatedly in batch systems.
Disadvantages of Batch Operating System
 The computer operators should be well known with batch systems.
 Batch systems are hard to debug.
 It is sometimes costly.
 The other jobs will have to wait for an unknown time if any job fails.
Examples of Batch Operating Systems: Payroll Systems, Bank Statements, etc.

Definition of Process

Basically, a process is a simple program.

An active program which running now on the Operating System is known as the process. The
Process is the base of all computing things. Although process is relatively similar to the computer
code but, the method is not the same as computer code
Multiprogramming Operating System (Non preemptive)

Cpu minimize the Idleness

Multitasking/ time sharing OS ( preemptive)

advanatage responsiveness
Multiprogramming is an extension to batch processing where the CPU is always kept busy. Each
process needs two types of system time: CPU time and IO time.

In a multiprogramming environment, when a process does its I/O, The CPU can start the execution
of other processes. Therefore, multiprogramming improves the efficiency of the system.
The multitasking operating system is a logical extension of a multiprogramming system that
enables multiple programs simultaneously. It allows a user to perform more than one computer
task at the same time.

Disadvantages of Multitasking operating system


o The multiple processors are busier at the same time to complete any task in a multitasking
environment, so the CPU generates more heat.

You might also like