An Operating System is a program that controls the execution of application programs. It acts as an interface between applications(or user) and the computer hardware.
The main objectives of an Operating System are,
- Convenience – An operating system makes a computer more convenient to use.
- Efficiency – An operating system permits the resources to be used efficiently.
- Ability to evolve – An operating system should be constructed in such a way that, it should allow the effective development, testing and introduction of new features without any interference with service.
Th hardware and software in a computer system can be viewed in a layered fashion as shown in the figure.
The end-user views the computer system as a set of applications. Application users are not concerned with the details of computer hardware. The operating system masks the details of the hardware from the programmer and acts as a mediator, making it easier to access the services.
An Operating System functions in the same way as ordinary computer software. It is a program that is executed by the CPU. It provides many services to the user and the programmer. A few common services of an Operating System are,
- Program development.
- Program execution.
- Access I/O devices.
- Controlled access to files.
- System access.
- Error detection and response.
An operating system assist programmers in program development by providing tools like editors, debuggers, etc.
Executing programs requires numerous tasks. The operating system all these tasks and make the program execution efficient.
Access I/O Devices
Each device connected to the computer system will have unique interfaces. The operating System provides a standard interface to the user to communicate with the I/O devices.
Controlled Access to Files
The operating system provides a common interface to users but accessing different files. This approach makes files protected in a multi-user system.
The Operating system also controls the access to system and its resources by different users.
Error Detection and Response
The Operating system is responsible for detecting all internal and external hardware errors and software errors. It should also provide a response to clear the error condition.
The Operating System collects the usage statistics and it will also monitor the performance of the computer system.