What is an Operating System ?

Well… it’s easter holidays and I have to work a little more on the University project, maybe not just a little, but a lot… This is a subsection of the chapter : Concepts and Design

What is an Operating System:

An operating system is a program that works as an intermediate layer between the computer’s hardware and the applications the user is willing to use.
So the main purpose is to let the user use the hardware, another goal of the operating system is to use the Hardware in the most efficient manner.

Every computer system can be divided into four components : users, programs/applications, operating system and hardware.
PICTURE TO BE MADE : CERCLES QUE MOSTRIN DE DINS A FORA CADA PART

The hardware contains the CPU, the memory and the I/O devices, and is responsible of providing the computing resources. The applications are programs
dedicated to solve a problem, and communicate with the operating system to satisfy their need for resources. As we will see, many users can
be using different resources, so the operating system has to coordinate and control the use of the hardware among different users and applicatios.

The operating system is just an environment, for other programs to be able to work, we can see it as an allocator for resources, everything runs
on top of it, and the operating system “decides“:

  • What is being executed
  • Where the data is held
  • Which resources can be accessed

There is not any standard definition of which are the functions of the operating system. We can think of an operating system as everything that
comes in the box when you buy it. But this is a too broad definition, so from here on we will call operating system to the program that runs
all the time on the machine ( also called Kernel\footnote{Derived from the botanical meaning of all that is within the outer coat of the seed.}). From here on the terms operating system and Kernel mean the same thing.

To understand what a kernel is we will look at the functions it must be able to perform, looking historically which have been the needs and how have they been solved.

Mid 50s - mid 60s: Batch Systems

The input devices were normally punched cards or magnetic tapes. The operator had to load the program, data and the operation information to the computer
which processed the data and after some time give it to an output. The output usually consisted of a card puncher, a printer or magnetic tape writer.
The operating system (monitor) was always resident in memory and had to do very little, just transfer control automatically from job to job.
Usually the jobs which had similar resource need where processed together as group ( batch group) , making more efficient use of the hardware.

Advantages of batch systems compared to older systems:

  • Less work to the operator.
  • Increased performance, one job could start after the previous one just finished.

Disavanatges:

  • From user standpoint the turn-around time can be large.
  • Difficult to debug programs.
  • Lack of protection, one batch job can affect other batched jobs.
  • A job can corrupt the monitor.
  • A job could enter an infinite loop.

mid 60s - late 60s: Spooling Batch Systems

On batch systems, reading from the punched cards caused a long CPU idle time, and reading from a magnetic tape was faster, so most computer systems
contained an smaller computer that transfered the information from the cards to magnetic tapes, which where later processed by the batch system.
The output was also written in a tape for later use on a smaller computer which transfered it to the desired support.

As an extension of the above idea, it was logical that a timer was added to the computer, this timer interrupts the computer while performing a job and
starts a I/O transaction. While the I/O transaction is done the computer can continue processing. The computer can now perform I/O in parallel with computation,
it became possible to have a computer read a set of cards to a tape, write to a tape or print, all this while computing. This process is called SPOOLing:
Simultaneous Peripheral Operation OnLine. Spooling Batch is the simplest of the multiprograming systems.

60s - present: Multiprograming

As more memory was available to the system it was possible to create systems that would load several jobs into memory and cycle through them in some order,
working on each for some amount of time. So the idea is that th eoperating system keeps several jobs into memory, the monitor ( operating system ) picks one
and begins it’s execution, eventually the job may have to way for some I/O, so the monitor just chooses another jobs, and continues executing it. The CPU
never idles as long as there is some job in memory that can be executed. This way we make a more efficient use of the computing resources.

Now the monitor is responsible for:

  • Starting user jobs.
  • Spooling operations.
  • I/O for user jobs.
  • Switch between user jobs.
  • Ensuring protection for the above.

70s - present: Timesharing Systems

The idea of multiprogramming was extended to allow multiple terminals to be connected to the computer, with each terminal being associated to a job, now
called process. If the context switch between process was made fast enough, the user on the terminal had the impression of having direct access to the machine.

An interactive system provides response to the user based on the input, this response time should be very small. Normally the system has all process on memory
( can be virtual memory ), and gives an small slice of time to each one. Timesharing, also called multitask, systems are much more complex than
multiprogrammed systems. In both, several jobs must be kept simultaneously into memory, so the system must have some sort of protection scheme. To be able to
obtain a short response time, switch between jobs have to be done really often, so jobs may have to be backed to disk in order to be able to have other
processes loaded into memory. To ensure orderly execution the system must provide synchronization and communication mechanisms.

70s: Personal Computers

In late 70s, personal computers appeared, and after some time they were inexpensive enough to become popular. The operating system need for this comupter
has evolved to give a maximum emphasis to the convenience and responsiveness of the system.

Parallel, Real-Time and Distributed Systems

This is out of the scope of the project, so we will be covering this even more superficially than the rest of the operating system history.

A real-time system is one that execute programs that have a guaranteed time to finish. This can be either soft or hard real time, being soft more
permissive with the timings, with hard real time a program will not be executed if it will not have finished in the expected time. Often hard real time
operating systems can only perform a small very specific set of tasks, normally called dedicated systems.

A multiprocessor is one with more than one CPU, it can be divided into the following:

  • Shared Memory Multiprocessor: Multiple CPU, all access the same memory. Care has to be taken to avoid bus collision.
  • Distributed Memory Multiprocessor: Each processor has it’s own memory, communication is more compicated.

Distributed:

  • Networked Systems: Multiple computers networked together, sharing resources. Users are aware of the computers that make the system.
  • Distributed Systems: Transparent to the user, often include resource redundancy and sharing of workload.

4 Responses to “What is an Operating System ?”

  1. madhavi khandelwal says:

    please give some example for each

  2. For me, the best operating system is Linux because it rarely hangs.~.”

  3. Wonderful journey and experience!

  4. Taylor Lewis says:

    operating systems can either make or break your system that is why it is wise to choose a vey stable one.,.~

Leave a Reply