An operating system provides an environment for the execution of programs. The O/S provides certain services to program and to the user of those programs.
These O/S services are provided for the convenience of the programmers to make the programming task easier.
Program execution:
The system must be able to load a program into memory and to run it. The program must be able to end its execution, either normally or indicating error.
I/O operation:
A running program may require I/O. this I/O may involve a file or an I/O device. For efficiently and protection users usually cannot control I/O device directly. Therefore the O/S must provide some means to do I/O.
File system management:
The file system is of particular interest. It should be obvious that programs need to read and write files. They also need to create and delete files by names.
Communication:
There are many circumstances in which one process needs to exchange information with another process. There are two major ways in which communication can occurs.
I. Processes executing on the same computer
II. Processes executing on different computer system that are tied together by a computer network.
Communication may be implemented via a shared memory, or by the technique of message passing, in which packets of information are moved between processes by the O/S.
Error Detection:
The o/S constantly needs to be aware of possible errors. Errors may occurs in the:
I. CPU
II. Memory H/W (memory error, power failure)
III. I/O devices (connection failure on a network, lack of paper in the printer)
IV. In the user program (illegal memory location, too use of CPU time)
For each types of error, the O/S should take the appropriate action to ensure correct and consistent computing.
Resource Allocation:
When there are multiple users or multiple jobs running at the same time, resources must be allocated to each of them.
The O/S manages many different types of resources.
I. Some may have special allocation code.
Eg. CPU cycle, main memory, file storage
II. Some may have more general request
Eg. I/O devices
O/S has CPU scheduling routines that take into
I. Speed of the CPU
II. Jobs must be executed
III. No of registers available
Accounting:
We want to keep track of which user uses how much and what kinds of computing resources.
This record keeping may be for accounting or simply for accumulating usage statistics.
Usage statistics may be valuable tools for researchers who wish to reconfigure the system to improve computing services.
Protection:
When several disjoints processes executes concurrently it should not be possible for one process to interface with the others, or with the O/S system itself.
Protection involves ensuring all access to system resources is controlled.
Securities of the system from outsiders is also important. Usually by mean of password to be allowed access to the resources. If a system is to be protected and secure, precaution must be through out it.
No comments:
Post a Comment