TRB Study Materials Operating System: WWW - Governmentexams.co - in 1
TRB Study Materials Operating System: WWW - Governmentexams.co - in 1
Operating System
Some popular Operating Systems include Linux Operating System, Windows Operating
System, VMS, OS/400, AIX, z/OS, etc.
Definition
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.
Memory Management
Processor Management
Device Management
File Management
Security
Control over system performance
Job accounting
Error detecting aids
Coordination between other software and users
www.governmentexams.co.in 1
Operating System
Memory Management
Memory management refers to management of Primary Memory or Main Memory. Main
memory is a large array of words or bytes where each word or byte has its own address.
Main memory provides a fast storage that can be accessed directly by the CPU. For a
program to be executed, it must in the main memory. An Operating System does the
following activities for memory management:
Keeps tracks of primary memory, i.e., what part of it are in use by whom, what
part are not in use.
In multiprogramming, the OS decides which process will get memory when and
how much.
Processor Management
In multiprogramming environment, the OS decides which process gets the processor when
and for how much time. This function is called process scheduling. An Operating System
does the following activities for processor management:
Keeps tracks of processor and status of process. The program responsible for this
task is known as traffic controller.
Device Management
An Operating System manages device communication via their respective drivers. It does
the following activities for device management:
Keeps tracks of all devices. The program responsible for this task is known as the
I/O controller.
Decides which process gets the device when and for how much time.
De-allocates devices.
File Management
A file system is normally organized into directories for easy navigation and usage. These
directories may contain files and other directions.
www.governmentexams.co.in 2
An Operating System does the following activities for file management:
Keeps track of information, location, uses, status etc. The collective facilities are
often known as file system.
Job accounting -- Keeping track of time and resources used by various jobs and
users.
Error detecting aids -- Production of dumps, traces, error messages, and other
debugging and error detecting aids.
www.governmentexams.co.in 3
2. Operating System ─ Types
Operating systems are there from the very first computer generation and they keep
evolving with time. In this chapter, we will discuss some of the important types of
operating systems which are most commonly used.
CPU is often idle, because the speed of the mechanical I/O devices is slower than
the CPU.
The main difference between Multiprogrammed Batch Systems and Time-Sharing Systems
is that in case of Multiprogrammed batch 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. For example, in a
transaction processing, the processor executes each user program in a short burst or
quantum of computation. That is, if n users are present, then each user can get a time
quantum. When the user submits the command, the response time is in few seconds at
most.
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.
www.governmentexams.co.in 4
Disadvantages of Time-sharing operating systems are as follows:
Problem of reliability
Question of security and integrity of user programs and data
Problem of data communication
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.
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.
Examples of network operating systems include Microsoft Windows Server 2003, Microsoft
Windows Server 2008, UNIX, Linux, Mac OS X, Novell NetWare, and BSD.
Upgrades to new technologies and hardware can be easily integrated into the
system.
www.governmentexams.co.in 5
Remote access to servers is possible from different locations and types of systems.
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.
www.governmentexams.co.in 6
3. Operating System ─ Services
An Operating System provides services to both the users and to the programs.
Program execution
I/O operations
File System manipulation
Communication
Error Detection
Resource Allocation
Protection
Program Execution
Operating systems handle many kinds of activities from user programs to system
programs like printer spooler, name servers, file server, etc. Each of these activities is
encapsulated as a process.
A process includes the complete execution context (code to execute, data to manipulate,
registers, OS resources in use). Following are the major activities of an operating system
with respect to program management:
I/O Operation
An I/O subsystem comprises of I/O devices and their corresponding driver software.
Drivers hide the peculiarities of specific hardware devices from the users.
An Operating System manages the communication between user and device drivers.
I/O operation means read or write operation with any file or any specific I/O device.
Operating system provides the access to the required I/O device when required.
www.governmentexams.co.in 7
File System Manipulation
A file represents a collection of related information. Computers can store files on the disk
(secondary storage), for long-term storage purpose. Examples of storage media include
magnetic tape, magnetic disk and optical disk drives like CD, DVD. Each of these media
has its own properties like speed, capacity, data transfer rate and data access methods.
A file system is normally organized into directories for easy navigation and usage. These
directories may contain files and other directions. Following are the major activities of an
operating system with respect to file management:
Communication
In case of distributed systems which are a collection of processors that do not share
memory, peripheral devices, or a clock, the operating system manages communications
between all the processes. Multiple processes communicate with one another through
communication lines in the network.
The OS handles routing and connection strategies, and the problems of contention and
security. Following are the major activities of an operating system with respect to
communication:
Both the processes can be on one computer or on different computers, but are
connected through a computer network.
Error Handling
Errors can occur anytime and anywhere. An error may occur in CPU, in I/O devices or in
the memory hardware. Following are the major activities of an operating system with
respect to error handling:
www.governmentexams.co.in 8
Resource Management
In case of multi-user or multi-tasking environment, resources such as main memory, CPU
cycles and files storage are to be allocated to each user or job. Following are the major
activities of an operating system with respect to resource management:
Protection
Considering a computer system having multiple users and concurrent execution of multiple
processes, the various processes must be protected from each other's activities.
www.governmentexams.co.in 9