An Operating system is a program that acts as an interface between the user and the computer
hardware and controls the execution of all kinds of programs.
It is a collection of software that manages computer hardware
resources and provides common services for computer programs.
It is a vital component of the system software in a computer system.
An operating system falls under the category of system software that performs all the
fundamental tasks like file management, memory handling, process management, handling
the input/output and governing and managing the peripheral devices like disk drives,
networking hardware, printers, etc.
Objective/Goals of Operating System
An Operating System has a special program which controls the execution of application programs.
OS acts as an intermediary among applications and the hardware components. OS can be thought
of as having three objectives. These are:
Convenience: It makes a computer more suitable to use.
Efficiency: It provides the computer system resources with efficiency and in easy to use
format.
Ability to develop: It should be built in such a way that it permits the efficient development,
testing and installation of new system functions without interfering with service.
Operating system as an extended machine
Operating systems perform two basically unrelated functions: providing a clean abstract set of
resources instead of the messy hardware to application programmers and managing these
hardware resources.
The architecture (instruction set, memory, I/O, and bus structure) of most computers at the
machine level language is primitive and awkward to program, especially for input/output
operations.
Users do not want to be involved in programming of storage devices.
Operating System provides a simple, high level abstraction such that these devices contain a
collection of named files.
Such files consist of useful piece of information like a digital photo, e mail messages, or web
page.
Operating System provides a set of basic commands or instructions to perform various
operations such as read, write, modify, save or close.
Dealing with them is easier than directly dealing with hardware.
Thus, Operating System hides the complexity of hardware and presents a beautiful interface to
the users.
Just as the operating system shields (protect from an unpleasant experience) the programmer
from the disk hardware and presents a simple file-oriented interface, it also conceals a lot of
unpleasant business concerning interrupts, timers, memory management, and other low level
features.
In each case, the abstraction offered by the operating system is simpler and easier to use than
that offered by the underlying hardware.
In this view, the function of the operating system is to present the user with the equivalent of
an extended machine or virtual machine that is easier to work with than the underlying
hardware.
Operating system as a Resource manager
The concept of an operating system as providing abstractions to application programs is a top-down
view. Alternatively, bottom-up view holds that the OS is there to manage all pieces of a complex
system. Also, a computer consists of a set of resources such as processors, memories, timers, disks,
printers and many others. The Operating System manages these resources and allocates them to
specific programs.
As a resource manager, the Operating system provides the controlled allocation of the processors,
memories, I/O devices among various programs.
Moreover, multiple user programs are running at the same time. The processor itself is a resource
and the Operating System decides how much processor time should be given for the execution of a
particular user program.
The operating system also manages memory and I/O devices when multiple users are working.
The primary task of OS is to keep the track of which programs are using which resources, to grant
resource requests, to account for usage, and to resolve conflicting requests from different programs
and users.
Also, Resource management includes multiplexing (sharing) resources in two ways: in time and
in space.