An operating system is software that sits directly on top of hardware on which it runs programs that we use to solve our daily problems like managing out bank accounts and taking photos and writing emails etc and all that is done by operating systems. Operating systems provides many services for helping these tasks come to completion and makes these programs run. These components of operating system manages all the resources to ensure proper execution of programs.
Operating System Services & Compoents
An operating system provides services and environment to execute all the porgrams that we use in our daily life. These services let the users perform task much efficiently. Not all operating systems provide same services and all have reasons to not use one service or another. Following are most common services an operating system provides to the users. Not all of these you will find in all of the operating systems but it's better to know about them.
Process Management
A process is a program in execution and all processes need resources like CPU, memory, time, I/O devices interactions etc to complete their execution. Process management handles all these and is responsible for following activites in the porcess management.
- Creating and deleting Users and System Processes
- Suspension and resumption of processes
- Mechanisms for process scnchronization and communication
- Mechanisms for handling of deadlock situations
Simply it loads the program into memory and ensures it executes until the end either normally or abnormally.
User Interface
An operating system provides a User Interface either a Graphical which allmost every OS provides today to a command-line or both of them. A GUI is an interface that provides graphical representations of all the serviecs like file systems to the user to help them know what is happening when they perform some actions. On the otherhand, a CLI or command-line interface provides a command-line where you type commands to perform some actions like copy pasting or running programs.
I/O Operations Management
I/O operations or Input/Output operations are handeled by the operating systems. A process in execution may require in I/O operation to complete its execution like a click by a mouse, a ket pressed on a keyboard or a file from the filesystem. An OS handeles all these with the help of device drivers which the I/O manufacturers have wrote the code for themselves.
File-System Management
A file is a collection of related information defined by its creator. A file can be a program or some other format like an image or a text file. A file-management system handles all these files. It handles creating and deleting files and able to search them with their names and other list of information. A file-system also handles file permissions so that an unauthorized person without the file permissions should not be able to access them.
Communications
A porcess needs to be ablt to communicate with other devices to be able to complete its execution. OS provides the service for the processes to be able to communicate with other devices ask for input or provide output to other devices during the execution for the user.
Security
A file-system stores all the files and data a user has in the computer and as OS manages the file-system it must provide some ways to secure it from other. An OS offer services to better secure the file and not let others take control of your computers resources without you knowing about them. Nowdays we store very valuable information on our computers, information which must not be fallen into others hands and that is why an OS must provide complete security over users data.
Security is also implemented by means of authentication. Which means that you have to prove by some way that you can have access to the system. The most common way of authentication is using passwords.
Resource Allocation
Just like process management, OS is responsible for Resource allocation to the processes for execution. When there are multiple processe running at the same time, resources must be allocated to them. OS ensures that all processes running at the same time equally gets resources to complete their execution with encountring any error and as much efficiently as possible.
Error Detection
An OS handeles error detection to know if a process executed perfectly or it ended in the middle. It is constantly checking and correcting errors. These errors occur in memoty, CPU or in I/O devices and user programs and for all these OS must take appropriate actions to ensure correct and consistent execution.