What is OS (Operating System) in detail?

  • An operating system (OS) is a collection of software that manages computer hardware resources and provides various services for computer programs. 
  • It acts as an intermediary between the user of a computer and the computer hardware
  • On the top of the hardware is the software. 
  • Operating system runs on the bare hardware and it provides base for the rest of the software.
  • Most computers have two modes of operation: kernel mode and user mode.
  • The operating system is the most fundamental piece of software and runs in kernel mode.
  • In this mode it has complete access to all the hardware and can execute any instruction that the machine is capable of executing.
  • The rest of the software runs in user mode, in which only a subset of the machine instructions is available. 
  • Here we find the command interpreter (shell), compilers, editors, and other system programs.
  • Finally, above the system programs are the application programs. 
  • These programs are purchased or written by the users to solve their particular problems, such as word processing, spreadsheets, web browser or music player. 
  • To hide complexity of hardware, an operating system is provided. 
  • It consists of a layer of software that (partially) hides the hardware and gives the programmer a more convenient set of instructions to work with.

Give the view of OS as an extended machine 

  • Operating systems perform two basically unrelated functions: providing a clean abstract set of resources instead of the messy hardware to application programmers and managing these hardware resources.
  • The architecture (instruction set, memory, I/O, and bus structure) of most computers at the machine level language is primitive and awkward to program, especially for input / output operations.
  • Users do not want to be involved in programming of storage devices.
  • Operating System provides a simple, high level abstraction such that these devices contain a collection of named files.
  • Such files consist of useful piece of information like a digital photo, e mail messages, or web page.
  • Operating System provides a set of basic commands or instructions to perform various operations such as read, write, modify, save or close.
  • Dealing with them is easier than directly dealing with hardware.
  • Thus, Operating System hides the complexity of hardware and presents a beautiful interface to the users.  
  • Just as the operating system shields (protect from an unpleasant experience) the programmer from the disk hardware and presents a simple file-oriented interface, it also conceals a lot of unpleasant business concerning interrupts, timers, memory management, and other low level features.
  • In each case, the abstraction offered by the operating system is simpler and easier to use than that offered by the underlying hardware.
  • In this view, the function of the operating system is to present the user with the equivalent of an extended machine or virtual machine that is easier to work with than the underlying hardware.
  • The operating system provides a variety of services that programs can obtain using special instructions called system calls. 

OS (Operating  System) as a resource manager 
  • The concept of an operating system as providing abstractions to application programs is a top down view. 
  • Alternatively, bottom up view holds that the OS is there to manage all pieces of a complex system.
  • A computer consists of a set of resources such as processors, memories, timers, disks, printers and many others.
  • The Operating System manages these resources and allocates them to specific programs.
  • As a resource manager, Operating system provides controlled allocation of the processors, memories, I/O devices among various programs.
  • Multiple user programs are running at the same time.
  • The processor itself is a resource and the Operating System decides how much processor time should be given for the execution of a particular user program.
  • Operating system also manages memory and I/O devices when multiple users are working.
  • The primary task of OS is to keep the track of which programs are using which resources, to grant resource requests, to account for usage, and to resolve conflicting requests from different programs and users.
  • An Operating System is a control program. A control program controls the execution of user programs to prevent errors and improper use of computer.
  • Resource management includes multiplexing (sharing) resources in two ways: in time and in space. 
  • When a resource is time multiplexed, different programs or users take turns using it.
  • First one of them gets to use the resource, then another, and so on.
  • For example, CPU and printer are time multiplexed resources. OS decides who will use it and for how long.
  • The other kind of multiplexing is space multiplexing, instead of the customers taking turns, each one gets part of the resource.
  • For example, both primary and secondary memories are space multiplexed. OS allocates them to user programs and keeps the track of it. 

If you have any doubts please feel to free and comment and ask to questions.

Previous Post Next Post

Contact Form