Operating System is software that users need to use a computer.

The operating system acts as an intermediary between the hardware and software, managing resources, providing a user interface, and facilitating communication between different components of the computer system.


A Typical Operating System is: Windows, Linux, Mac OS

Windows

Windows, developed by Microsoft, is the most widely used OS for personal computers, known for its user-friendly interface and extensive software compatibility. Popular in both home and office environments, it powers a range of devices from desktops to tablets.

Linux

Linux is an open-source operating system prized for its flexibility, security, and robust performance. It’s especially popular among developers and server administrators due to its customization capabilities and wide variety of distributions.

Mac OS

Mac OS, developed by Apple, is known for its sleek design, seamless integration with other Apple products, and strong focus on user experience. It’s a favorite among creative professionals for its powerful multimedia tools and reliable performance.


the structure of a computer (simplified)

If we simplify the structure of a computer, it looks like this as a below:

simplify the structure of a computer

simplify the structure of a computer

Processor usually means CPU. When we look at main memory, it’s divided in ROM and RAM.

ROM (Read-Only Memory)

Non-volatile. it contents are still there when the power is turned off. uses a small part of memory. (just several KB)

RAM (Random Access Memory)

Volatile. when the power is turned off, everything in memory is wiped. uses a lot of memory. (several MB to several GB)


How does my computer turn on?

Bootloader boots my computer

  1. When the computer is powered on, the processor (CPU) reads the contents in the ROM.
  2. in the ROM, Power-on self-test (POST) and bootloader are stored.
  3. when it is powered on, POST is the first program to checks the status of the current computer.
  4. After the POST operation is completed, the bootloader runs.
  5. Bootloader finds the Operating System stored on the hard disk, and brings it to the main memory (RAM).
  6. The process of this bootloader is called booting.

What the bootloader is doing

What the bootloader is doing

In the above state, operating system is ready to perform. operating system ends when the computer powered off.


kernel and command interpreter (shell)

Operating system is largely divided into kernel and command interpreter (shell).

Kernel is core of operating system. kernel stores everything the operating system does.

The command interpreter is, it interprets commands that the user requests from the kernel (operating system). Request the kernel and output the result.

Users can request commands from the operating system in a way such as graphical user interface (GUI) or command line interface (CLI), such as fetching file lists in the current directory, executing programs, and checking disk capacity.


Location of the operating system

Application is created for a specific operating system.

Therefore, one application cannot run on different operating systems. (The same hardware has nothing to do with it.)

For example:

if you move a program that Windows runs to Linux, it won’t run.

Shape of application and OS

Shape of application and OS

The application runs on the operating system as shows in the figure above.

That is, only the resources provided by the operating system may be used without using the hardware resources directly.

The operating system is similar to the government in the real world.

Here’s what the government does.

  • Resources such as land, manpower, and budget exist and must be used efficiently.
  • For efficient resource management, it is divided into departments such as the administration, the Ministry of Land, Infrastructure, and Transport, the Ministry of Education, and the Ministry of National Defense.
  • Each department is asked and appropriately distributes resources to the people.

Here’s what the operating system does.

  • Hardware resources such as processes, memory, and hard disks exist, and they must be used efficiently.
  • For resource management, functions such as process management, memory management, disk management, network, and security are divided.
  • Each function is performed according to the request of the applications and resources are appropriately distributed.