0% found this document useful (0 votes)
56 views

Chapter 3: Operating-System Structures: 1. Process Management

The document summarizes the key components and functions of an operating system. It discusses process management, main memory management, file management, I/O system management, secondary storage management, networking, protection systems, and command interpreters. It also outlines the basic services operating systems provide like program execution, I/O operations, file system manipulation, communications, and error detection. System calls are described as the interface between programs and the operating system.

Uploaded by

Sk Mujeef
Copyright
© © All Rights Reserved
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
56 views

Chapter 3: Operating-System Structures: 1. Process Management

The document summarizes the key components and functions of an operating system. It discusses process management, main memory management, file management, I/O system management, secondary storage management, networking, protection systems, and command interpreters. It also outlines the basic services operating systems provide like program execution, I/O operations, file system manipulation, communications, and error detection. System calls are described as the interface between programs and the operating system.

Uploaded by

Sk Mujeef
Copyright
© © All Rights Reserved
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 8

Chapter 3: Operating-System Structures

The following various system components are service provided by an Operating


System.

1. Process Management

2. Main Memory Management

3. File Management

4. I/O System Management

5. Secondary Management

6. Networking

7. Protection System

8. Command-Interpreter System

1. Process Management :

We know that a program is a set of instructions. Sometimes CPU does not require all
the program at a time. It needs to execute only some part of the program at a time. It needs to
execute only some part of the program. In this case, the set of instructions which are needed
by CPU are loaded into memory. In some other cases, we can accommodate entire program
in memory. So, we accommodate entire program in memory. So, we accommodate some part
of the program in main memory. After executing it, we can accommodate another part and so
on. In some other cases, the program is very small and CPU requires entire program, then
entire program is loaded into main memory.

A process can be a program or set of instructions which are in main memory and
ready to execute.

We can say that a program is a Passive entity, which stored on the disk. A process is
an Active entity which is stored in main memory.

Page 1
A process needs several system resources like CPU time, files, I/O devices to
complete its task. These resources are allocated to the process at the time of creating the
process or at the time of running and these resources can be allocated by operating system.

Operating System is responsible for the following activities with process


management.

a) Process creation and deletion.

b) Process suspension and resumption.

c) Provision of mechanisms for:

i) process synchronization

ii) process communication

d) Mechanism for handling deadlocks.

There are two types of processes a) System Processes b) User Processes.

User Processes are some part of the code in the user program. These processes
will run in the user program.

System Processes are some part of the code in the operating system. These
processes will run in monitor mode.

2. Main Memory Management :

Main Memory is a large array of bytes. Any user must copied into main memory for
execution. CPU reads instructions from main memory and executes one after another. Some
part of main memory is reserved operating system. In the multiprogramming, to utilize CPU
and system resources efficiently, number of processes are copied into main memory and
those are executed concurrently.

Page 2
The following are responsibilities of operating system regarding memory
management.

a) Keep track of which parts of memory are currently being used and by whom.

b) Decide which processes to load when memory space becomes available.

c) Allocate and deallocate memory space as needed.

3. File Management :

File is a collection of records and it is going to store some data. Generally, the files
are stored on disk. A file consists of sequence of bits, bytes, lines, records and whose
meaning is given by the creator of the file.

The operating system is responsible for the following activities in connections with
file management.

a) File creation and deletion.

b) Directory creation and deletion.

c) Support of primitives for manipulating files and directories.

d) Mapping files onto secondary storage.

e) File backup on stable (nonvolatile) storage media.

4. I/O System Management :

The important purpose of operating system is to hide some properties of hardware


device from the user i.e., user is unable to execute I/O instructions directly.

The I/O system consists of :

a) A buffer-caching system
Page 3
b) A general device-driver interface

c) Drivers for specific hardware devices

5. Secondary Management :

All the programs must be in main memory before their execution. Main Memory is
known as primary storage and this is volatile and it is volatile and it has limited capacity. So,
we require secondary storage, which is non volatile and high capacity.

All the programs in the secondary storage must be copied into main memory before
their execution.

The operating system is responsible for the following activities in connection with

disk management:

a) Free space management

b) Storage allocation

c) Disk scheduling

6. Networking :

A distributed system is a collection of processors and each processor is having its own
memory, peripheral devices and clock. The processors communicate with one another
through communication lines. The processors in distributed system are connected through a
network and it is configurated in different ways. Operating System generalizes network
access just like the file access with the details of networking contained in the network
interface driver by means of network protocol.

Access to a shared resource allows:

a) Computation speed-up

b) Increased data availability

c) Enhanced reliability

Page 4
7. Protection System :

In the multiprogramming, multiple processes are executing concurrently. Various


processes must be protected from other processes. We have to protect our memory by means
of register and limit register. Here one process is unable to access information from another
process and from operating system. We can protect all I/O by means of declaring all I/O
instructions are privileged and they will be executed in monitor mode. Finally CPU
protection achieved by timer.

The protection mechanism must:

a) distinguish between authorized and unauthorized usage.

b) specify the controls to be imposed.

c) provide a means of enforcement

8. Command-Interpreter System :

Command Interpreter is one of the most important system program and it is interface
between user and operating system. Some operating systems include this program in the
kernel. Some operating systems like MS-DOS and UNIX treat this program as a special
program and they invoke this program when a job is initiated.

Commands are given to operating system by means of control statements. The


functionality of command interpreter is very simple.

“ Take the command and execute it, get next command”

It is also known as control call interpreter / command line interpreter and sometimes it
is called as Shell.

Many commands are given to the operating system by control statements which deal

with:

i) process creation and management

Page 5
ii) I/O handling

iii) secondary-storage management

iv) main-memory management

v) file-system access

vi) protection

vii) networking

Operating System Services :

i) Program execution – system capability to load a program into memory and to run
it.

ii) I/O operations – since user programs cannot execute I/O operations directly, the
operating system must provide some means to perform I/O.

iii) File-system manipulation – program capability to read, write, create, and delete
files.

iv) Communications – exchange of information between processes executing either


on the same computer or on different systems tied together by a network.
Implemented via shared memory or message passing.

v) Error detection – ensure correct computing by detecting errors in the CPU and
memory hardware, in I/O devices, or in user programs.

Additional Operating System Functions :

Additional functions exist not for helping the user, but rather for ensuring efficient
system operations.

i) Resource allocation – allocating resources to multiple users or multiple jobs


running at the same time.

Page 6
ii) Accounting – keep track of and record which users use how much and what
kinds of computer resources for account billing or for accumulating usage
statistics.

iii) Protection – ensuring that all access to system resources is controlled.

System Calls :

System calls provide the interface between a running program and the operating
system.

i) Generally available as assembly-language instructions.

ii) Languages defined to replace assembly language for systems programming


allow system calls to be made directly (e.g., C, C++)

Three general methods are used to pass parameters between a running program and
the operating system.

i) Pass parameters in registers.

ii) Store the parameters in a table in memory, and the table address is passed
as a parameter in a register.

iii) Push (store) the parameters onto the stack by the program, and pop off the
stack by operating system.

Page 7
Passing of Parameters As A Table :

Types of System Calls :

i) Process control

ii) File management

iii) Device management

iv) Information maintenance

v) Communications

********** End of Chapter 3 **********

Page 8

You might also like