Operating System Concepts
What is an Operating System?
An Operating System (OS) is a software interface between computer hardware and the user.
Every computer needs at least one OS to run other programs.
Applications like browsers, MS Office, and games require an environment provided by the OS to run.
The OS facilitates communication with the computer without needing to know the computer's language.
Computers and mobile devices cannot be used without an OS.
History of OS
Operating systems were first developed in the late 1950s to manage tape storage.
The General Motors Research Lab implemented the first OS in the early 1950s for their IBM 701.
In the mid-1960s, operating systems began using disks.
The first version of the Unix OS was developed in the late 1960s.
Microsoft's first OS was DOS, built in 1981 by purchasing 86-DOS software.
Windows first appeared in 1985 as a GUI paired with MS-DOS.
Examples of Operating Systems with Market Share
Windows: 40.34%
Android: 37.95%
iOS: 15.44%
Mac OS: 4.34%
Linux: 0.95%
Chrome OS: 0.14%
Windows Phone OS: 0.06%
Types of Operating Systems
Batch Operating System:
Processes similar jobs together to speed up processing.
Users do not directly interact with the computer; jobs are submitted offline (e.g., via punch cards).
Multitasking/Time-Sharing Operating Systems:
Allows multiple users at different terminals to use a single computer system simultaneously.
Processor time (CPU) is shared among multiple users, known as time sharing.
Real-Time Operating Systems:
Processes and responds to inputs in a very small time interval.
Examples: Military software systems, space software systems.
Distributed Operating Systems:
Uses multiple processors located in different machines to provide fast computation.
Network Operating Systems:
Runs on a server and manages data, users, groups, security, applications, and other networking functions.
Mobile Operating Systems:
Designed to power smartphones, tablets, and wearable devices.
Examples: Android, iOS, BlackBerry, Web, and watchOS.
Functions of Operating Systems
Managing memory, files, processes, I/O system & devices, security, etc.
Detailed Functions:
1. Process Management
Creates and deletes processes.
Provides mechanisms for synchronization and communication among processes.
2. Memory Management
Allocates and de-allocates memory space to programs.
3. File Management
Manages file-related activities: organization, storage, retrieval, naming, sharing, and protection of files.
4. Device Management
Keeps track of all devices through the I/O controller.
Allocates and de-allocates devices.
5. I/O System Management
Hides the peculiarities of hardware devices from the user.
6. Secondary-Storage Management
Manages primary storage, secondary storage, and cache storage.
Instructions and data must be stored in primary storage or cache for running programs.
7. Security
Protects data and information against malware and unauthorized access.
8. Command Interpretation
Interprets commands given by the user and allocates system resources.
9. Networking
Enables communication between processors that do not share memory, hardware devices, or a clock, through a network.
10. Job Accounting
Tracks time and resources used by various jobs and users.
11. Communication Management
Coordinates and assigns compilers, interpreters, and other software resources to various users.
Features of Operating Systems
Protected and supervisor mode
Allows disk access and file systems
Device drivers
Networking
Security
Program Execution
Memory management
Virtual Memory
Multitasking
Handling I/O operations
Manipulation of the file system
Error Detection and handling
Resource allocation
Information and Resource Protection
Advantages of Using Operating Systems
Hides hardware details by creating an abstraction.
Easy to use with a GUI.
Provides an environment to execute programs/applications.
Makes the computer system convenient to use.
Acts as an intermediary between applications and hardware.
Provides computer system resources in an easy-to-use format.
Acts as an intermediator between all hardware and software of the system.
Disadvantages of Using Operating Systems
Issues in the OS can lead to data loss.
OS software can be expensive for small organizations.
Operating systems are never entirely secure and are always vulnerable to threats.
What is the Kernel?
The kernel is the central component of an operating system.
It manages communication between software and hardware.
It is the nucleus of a computer, making hardware and software communication possible.
The kernel is the innermost part of an OS, while the shell is the outermost part.
Features of the Kernel
Low-level scheduling of processes
Inter-process communication
Process synchronization
Context switching
Types of Kernels
1. Monolithic
A single block of code that provides all OS services.
Simplistic design with a distinct communication layer between hardware and software.
2. Microkernels
Manages system resources where services are implemented in different address spaces.
User services are stored in user address space, and kernel services are stored under kernel address space.
Reduces the size of both the kernel and the operating system.
Difference Between Firmware and Operating System
Feature | Firmware | Operating System |
|---|---|---|
Definition | Embedded programming on a chip controlling a specific device. | Provides functionality over and above that of firmware. |
Modifiability | Programs encoded by the manufacturer and typically cannot be changed. | Can be installed and changed by the user. |
Storage | Stored on non-volatile memory. | Stored on the hard drive. |
Difference Between 32-Bit vs. 64-Bit Operating Systems
Parameter | 32-Bit | 64-Bit |
|---|---|---|
Architecture | Allows 32 bits of data processing. | Allows 64 bits of data processing. |
Compatibility | Requires 32-bit OS and CPUs. | Requires a 64-bit OS and CPU. |
Systems Available | All versions of Windows 8, 7, Vista, XP, Linux | Windows XP Professional, Vista, 7, Mac OS X, Linux |
Memory Limits | Limited to 3.2 GB of RAM. | Allows a maximum of 17 Billion GB of RAM. |
Summary
An operating system acts as an interface between the user and computer hardware.
Different types of OS include Batch, Multitasking/Time Sharing, Multiprocessing, Real Time, Distributed, Network & Mobile OS.
Operating systems were first developed in the late 1950s to manage tape storage.
The OS works as an intermediary, helping users communicate with the computer.
The kernel is the central component, managing communication between hardware and software.
Two popular kernel types are Monolithic and Microkernels.
Key functions include Process, Device, File, I/O, Secondary-Storage, and Memory management.