An operating system (OS) is a suite of programs that controls computer hardware and software resources. It provides common services for computer programs to allow them to run correctly.
It is the software foundation on which all other software rests, allowing us to write programs that interact with the machine.
OS manages resources. These resources are often shared among various programs that use them
Multiple programs executing concurrently share the use of main memory. They take turns using the CPU
Programs/processes compete for an opportunity to use input/output devices
The hardware,
The operating system,
The application programs, and
The users
Abstract View of Computer System
presents the user with the equivalent of an extended machine or virtual machine that is easier to program than the underlying hardware.
manages resources of the computer system such as processor, memory, files, and I/O device.
keeps track of the status of each resource, and decides who gets a resource, for how long and when.
resolves conflicting requests for resources in manner that preserves system integrity, and in doing so attempts to optimize the resulting performance.
process by which a computer or virtual machine executes the instructions of a computer program
load a program into memory and run that program
end program execution, either normally or abnormally (indicating error).
A running program may require I/O. This I/O may involve a file or an I/O device. For specific devices, special functions may be desired.
For efficiency and protection, users usually cannot control I/O devices directly. Therefore, the operating system must provide a means to interact with I/O.
Programs need to read and write files.
Programs also need to create and delete files by name.
In many circumstances, one process needs to exchange information with another process.
Communications may be implemented via shared memory, or by the technique of message passing, in which packets of information are moved between processes by the operating system.
The operating system constantly needs to be aware of possible errors.
Errors may occur in the CPU and memory hardware, in I/O devices, and in the user program.
For each type of error, the operating system should take the appropriate action to ensure correct and consistent computing.
When multiple users are logged on the system or multiple jobs are running at the same time, resources must be allocated to each of them.
Many different types of resources are managed by the operating system. Some may have special allocation code, whereas others (such as I/O devices) may have much more general request and release code.
Protection involves ensuring that access to system resources is controlled. Security of the system from outsiders is also important. Such security starts with each user having to authenticate himself to the system, usually by means of a password, to be allowed access to the resources.