An Introduction To Operating Systems

An Introduction To Operating Systems
An Introduction To Operating Systems

Introduction 

In this era of technology, there is no sphere of life where computers are not used. From large production systems to small-scale local businesses all use computers to manage and optimize their workflows. 

If we talk about computers in general, every computer is built on an IPO logic that is Input, Process, and Output. Now there are several devices that are meant to function according to this IPO logic.

  • Input consists of devices like a mouse, keyboard, or webcam. These are devices that can initiate a process for the CPU to perform.
  • The processing part of the IPO logic is done by the CPU(Central Processing Unit) which performs all the operations of a computer like arithmetic calculations, memory input and output, and many more.
  • The output consists of devices that show the result of all the operations performed by the CPU on our input. These include devices like a monitor, printer, etc.

What is an Operating System?

Defining Operating System in a single line is a very difficult task but to define an Operating System in layman’s terms we can say that an Operating System is a computer program that manages the scheduling, execution, and termination of other computer programs and also acts as an interface for users to interact with the underlying hardware.


 An Operating System can be considered as the brain of a computer. Just like a human brain an Operating System also helps in the proper functioning of all computer operations.

Why Do We Need An Operating System?

We can view a Computer as consisting of Hardware, Software, and Data. So, an Operating System:

  • Controls the hardware and coordinates its use among the various application programs for the various users.
  • Provides the means for the proper use of these resources in the operation of the computer system.
  • Provides an environment for other programs to perform their tasks and complete their execution cycle.
  • Execute user programs and make solving user programs easier.
  • Make the computer system convenient to use.
  • Use computer hardware in an efficient manner.

Operating System Design And Implementation

The design and implementation of an operating system highly vary from user to user and from usage to usage. 

For Example:

  • Kali Linux, a Linux-based open-source operating system is highly used in hacking and penetration testing. So, according to the usage the operating system has a highly advanced Command Line Interface which provides a fast exception of commands but the GUI (Graphic User Interface) of the operating system is not that good. 
  • Now if we talk about Mac OS, an enterprise operating system by Apple has a great GUI and provides a closely bound ecosystem for the cross-device integration for all the devices which are manufactured by Apple. This ensures a seamless and premium experience to the user which adds to the worth of the device and the company. 
  • Similarly, Windows, an operating system by Microsoft Inc. is one of the most widely used operating systems due to its ease of use, high availability, reliability, and customization which it provides over the device to the user. 

So, based on the above examples we can say that the design and implementation of an operating system highly depend on the user and the system requirements. There are two goals that are taken into perspective while defining the requirements for an operating system that are:

  • User Goals: an operating system should be convenient to use, easy to learn, safe, fast, and reliable.  
  • System Goals: an operating system should be easy to design, implement and maintain as well as flexible, reliable, error-free and efficient. 

These Goals are very important to keep in while designing an operating system so that it can cater to the needs of the user.

Types of Operating System

1. Batch Operating System

  • This type of Operating System doesn’t interact with the CPU directly.
  • Batch Type Operating System uses something called an Operator, which takes Jobs jobs having similar requirements and clubs them into batches.
  • This Operator is responsible to sort the jobs for similar requirements.

Advantages Of Batch Operating System

  • Due to the operator combining jobs into batches, Multiple users can work on the same system at a single time.
  • The idle time of the batch systems is very less.
  • Large workloads can be easily handled.

Disadvantages of Batch Operating System

  • Batch Systems are very hard to debug.
  • Due to this difficulty in debugging, sometimes the jobs can have to wait for a long amount of time if any job in a batch fails.
  • If in any case, the operator fails the entire system fails.

2. Time-Sharing Operating System

  • Each task in the system has some time associated with it so that all the tasks run smoothly in the system.
  • In a Time Sharing Operating System, each user shares the CPU based on time and work just like a single system. 
  • The time for which each task takes to execute is called a quantum. After this time is over, the OS switches over to a new task. 
  • This ensures that all the tasks get equal time to get executed.

Advantages of Time Sharing Operating System

  • Ensures that each task gets equal time to get executed. 
  • Reduces the chance of CPU idle time.

Disadvantages of Time Sharing Operating System

  • If the quantum is very small, there can be a chance that the system can go throttling. This means that the system will spend more time in task switching than task execution.
  • There can be chances of data loss.
  • Security can be a major concern in these types of systems.

3. Distributed Operating System

  • In a distributed operating system, several computers are connected to each other using a common network.
  • Each and every connection is an indigenous system, which accepts tasks from the user. 
  • The task is then distributed among the network to provide faster execution times.

Advantages of Distributed Operating System

  • The load on the computer reduces as the task is divided into parts that are executed by multiple systems.
  • Due to this load sharing, there is less chance of failure. 
  • If in any case, a system in the network fails, there is no effect on the other systems.
  • The system is highly scalable. The system can be robust to load changes. 

Disadvantages of Distributed Operating System

  • The setup cost is very high, as it needs very complex software to function. So the cost to develop and run these systems is very high. 
  • If in any case, the central distribution node fails the entire system fails. 
  • The system can be very critical and needs high security.

4. Network Operating System

  • These operating systems usually run on large community or enterprise servers and feed the needs of a large number of systems. 
  • Network operating systems are very good for applications that need shared access to files, security applications and databases.
  • All the users in the system are tightly integrated into each other as all the usage and configuration are visible to all the users. 

Advantages of Network Operating System

  • The server holds most of the data and sharing, the overhead cost on all the client devices can be reduced.
  • The upgrade of the system is very easy.
  • The servers can also be accessed from a remote location, making it easier to work upon. 

Disadvantages of Network Operating Systems

  • If the central server gets attacked it might cause a lot of damage to data and business logic. 
  • Central servers are very costly.

5. Real-Time Operating System

  • These are the operating systems that work on streams of data. 
  • The data is continuously fed and is processed within a small amount of time making them fast and dependable.

Advantages of Real-Time Operating System

  • The Systems are fast. 
  • Can handle heavy loads in a very small amount of time. 

Disadvantages of Real-Time Operating System

  • The systems are costly to develop. 
  • These systems run critical applications like industrial production lines and rocket launch systems, a small error can cause heavy losses.

Now take a quiz on which types of Operating system is it.

Roles of an Operating System

An operating system has three main functions: 

blog banner 1
  • Manage the computer’s resources, such as the central processing unit, memory, disk drives, and printers.
  • Establish a user interface
  • Execute and provide services for applications software. Keep in mind, however, that much of the work of an operating system is hidden from the user; many necessary tasks are performed behind the scenes. 

In particular, the first listed function, managing the computer’s resources, is taken care of without the user being aware of the details. Furthermore, all input and output operations, although invoked by an applications program, are actually carried out by the operating system.

Although much of the operating system functions are hidden from view, you will know when you are using an applications software package, and this requires that you invoke-call into the action-the operating system. Thus you both establish a user interface and execute software.

Advantages of Operating Systems

  1. User Interface:
    • This is the most important advantage of an Operating System.
    • It provides an environment for users to interact with the underlying hardware, without taking processing times, memory management and task scheduling into consideration. 
    • If operating systems were not developed this much, we would have to write all our tasks in assembly language or binary logic.
  2. Multitasking:
    • With the evolution of multiprocessor CPUs, the operating system has made concurrent task execution possible. 
    • We can make use of concepts like multithreading and multiprocessing to achieve multitasking. 
  3. Resource Management:
    • The Operating System manages all our resources like printers, processors, speakers, GPUs. 
    • For example, if we have to give multiple print commands, we need not worry as the OS will schedule the jobs and manage the resources accordingly. 
  4. Disk Management:
    • The Operating System manages all the data stored on disks.
    • It also manages all the Page Tables, Index Tables, and Interrupts Vector Tables.
  5. Security:
    • The Operating System is responsible to keep the data inside the device as safe as possible. 
    • Most of the operating systems do this by encrypting all the data from the hardware side.
    • Most of the operating systems come with some antivirus software like Windows Defender to save against malware and trojan attacks.

Disadvantages of Operating Systems

  1. Reliability
    • This is one of the biggest disadvantages of an operating system.
    • If an operating system fails, in 90% of cases the data in the device is also lost. 
    • Installing a new operating system can be a cumbersome task.
  2. Data Fragmentation
    • Due to low memory availability, the operating system stores data in small blocks on the physical memory. This process is called fragmentation. 
    • If in future the physical memory gets corrupted, it gets very difficult to retrieve the data as it is in fragments.
  3. Cost
    • The cost becomes a really challenging factor in operating systems. 
    • Due to large development input and complex architectural and design problems, the cost to develop an operating system is very high. 
    • This high development cost makes it difficult for companies to sell these operating systems at a throwaway price.
  4. Viruses
    • Even after so much advancement in technology, Viruses still are a big challenge for developers and companies.
    • Viruses can not only erase data but can also destroy entire systems and steal important information.
  5. Complexity
    • Operating Systems have high complexity making it difficult for a less learned person to understand. 
    • This complexity causes high maintenance and service costs in case of failures and crashes.

Also, read about the commonly asked interview question on System Design Interview Questions

Frequently Asked Questions

What are an operating system and its types?

Operating System is a program that manages other computer programs. There are several types of operating systems, some of them are:

1. Batch Operating Systems
2. Time-Sharing Operating System
3. Network Operating System

What is the importance of an operating system?

Operating System controls the hardware and coordinates its use among the various application programs for the various users.

What are the advantages of an operating system?

Operating System provides a user interface to interact with the hardware, provides security to our stored data and also manages the underlying memory and resources.

What are the five examples of operating systems?

The most famous operating systems are:
1. Microsoft Windows
2. Apple MacOS
3. Google Android OS
4. Ubuntu
5. Kali Linux

What are the types of OS?

Different types of operating systems:
1. Batch Operating Systems
2. Time-Sharing Operating System
3. Network Operating System
4. Distributed Operating System
5. Real-Time Operating System

What are the advantages and disadvantages of an operating system?

The advantages of an operating system are:
1. User Interface
2. Multitasking
3. Security
4. Resource Management
5. Memory Management

The Disadvantages of an operating system are:
1. High Cost
2. Low Reliability
3. High Complexity

Key Takeaways

Adhering to all the advantages and disadvantages of Operating Systems we cannot deny the importance of Operating Systems in our life. From the start of our day with a text message to the end of the day with Youtube videos we use operating systems without acknowledging the fact that we use them.

Coding Ninjas have an amazing course on Operating systems and you can practice this problem for free.

Be it Apple, Microsoft, or Linux all the organizations work day and night to provide their users with the best operating system to make their work easy, convenient and reliable. It’s time that we should all start to accept operating systems as an integral part of our life.

By Sarthak Dhawan