Overview of Operating Systems used in Various Electronics Domains

Before I start with the detailing of various kinds of Operating Sytems which you find inside the differnet types of Semi-conductor Devices, it is very important to understand the definition of the OPERATING-SYSTEM that is, "An Operating System (OS) is the fundamental software suite that manages a computer's hardware and software resources. It acts as an intermediary between the user and the computer hardware, ensuring that applications can run efficiently and securely. An operating system (OS) is essential system software that manages a computer's hardware, memory, and processes, acting as the interface between the user and the computer. It facilitates running applications, manages resources like the CPU and file storage, and ensures that different software programs coexist without crashing."

Key Aspects of an Operating System:

  • Core Function: It serves as the foundation of a computing device, handling resource allocation, file system management, and security.
  • User Interface (UI): Users interact with the OS through a Graphical User Interface (GUI) or a Command-Line Interface (CLI).
  • Examples: Common operating systems include Windows, macOS, Linux, Android, and iOS.
  • Types: Types include desktop operating systems, mobile operating systems, embedded systems, and real-time operating systems.

Key Functions of an Operating System:

  • Resource Management: Allocates Central Processing Unit time, memory space, and input/output devices.
  • Process Management: Determines which applications run and for how long through scheduling.
  • File Management: Organizes files on storage devices, allowing for storage and retrieval.
  • Security: Provides built-in protection through encryption, user authentication, and threat monitoring.

When you press the power button to boot-up or select "Shut down" from a menu, the operating system (OS) follows a rigid, step-by-step sequence to ensure hardware safety and data integrity.

The Boot-Up Process (Startup) of Operating System

The boot process, often called bootstrapping, is the series of events that happens from the moment power is applied until the user desktop appears.

  1. Power-On Self-Test (POST): The computer's firmware (BIOS or the modern UEFI) performs a quick "health-check" on your hardware (CPU, RAM, and storage).
  2. Locating the Bootloader: The firmware searches for a bootable device (like your SSD) based on a pre-set order.
    • Legacy BIOS looks for the Master Boot Record (MBR) in the very first sector of the disk.
    • Modern UEFI looks for a specific {EFI System Partition<---->"https://uefi.org/specs/ACPI/6.5/03_ACPI_Concepts.html"} containing .efi boot files.
  3. Loading the Bootloader: The firmware loads a small program called the Bootloader (e.g., Windows Boot Manager or GRUB for Linux).
  4. Kernel Initialization: The bootloader loads the OS Kernel into RAM. The kernel then takes control, initializes essential device drivers, and starts system services.
  5. User Space & Login: Finally, the OS starts the graphical interface and displays the login screen, waiting for user authentication. 

The Shut Down Process of Operating System

Shutting down is a controlled "power off" that prevents data corruption and hardware damage. 

  • Signal Termination: The Operating System sends a signal (like SIGTERM) to all running applications, asking them to save their work and close.
  • Forced Closing: If an application doesn't respond within a few seconds, the Operating System sends a "kill" signal (SIGKILL) to stop it immediately.
  • Flushing Buffers: The OS ensures all data currently in temporary RAM (buffers) is written ("flushed") to the permanent storage (HDD/SSD).
  • Unmounting File Systems: It safely "unmounts" the storage drives so no data is being written while power is cut.
  • Hardware Power-Off: The Operating System uses the {A.C.P.I. (Advanced Configuration and Power Interface)<---->"https://oneuptime.com/blog/post/2026-03-02-how-to-set-up-acpi-power-management-on-ubuntu/view"} to send a final command to the motherboard to physically cut the power to the components.

In modern Operating Systems, managing how multiple tasks execute simultaneously is critical for performance and reliability. Here is an exhaustive breakdown of these core concurrency concepts.

Threading

A Thread is the smallest unit of execution within a process. While a process provides the environment (memory space, file handles), the thread is the entity that actually executes the code.

  • Components: Each thread has its own Program Counter (PC), stack, and set of registers.

  • Shared Resources: Threads within the same process share the same code section, data section, and OS resources (like open files).

  • Efficiency: Creating a thread is much "lighter" than creating a process because it doesn't require allocating a new address space.

Multi-threading

Multi-threading is the ability of an OS to support multiple, concurrent paths of execution within a single process. This allows a program to perform multiple tasks at once.

  • Concurrency vs. Parallelism: * Concurrency: On a single-core CPU, the OS switches between threads so fast it appears they are running at once.

    • Parallelism: On multi-core systems, different threads can literally run on different cores at the exact same time.

  • Responsiveness: In a GUI application, one thread can handle user input while another performs a heavy calculation in the background, preventing the app from "freezing."

  • Resource Sharing: Because threads share memory, they can communicate more easily than separate processes.

Mutual Exclusion (Mutex)

Mutual Exclusion is a program object that prevents multiple-threads from accessing a Critical Section (a shared resource, like a global variable or a file) at the same time.

  • The Critical Section Problem: If two threads try to increment the same counter simultaneously, a Race Condition occurs where the final value might be incorrect.

  • Locking Mechanism:

    1. A thread Acquires a lock before entering the critical section.

    2. Other threads trying to acquire the same lock are forced to wait (blocked).

    3. The thread Releases the lock when it finishes, allowing the next thread in line to proceed.

Deadlock

A Deadlock is a specific situation where a set of threads are blocked because each process is holding a resource and waiting for another resource held by another thread in the set. No one can move forward.

The Four Necessary Conditions (Coffman Conditions)

For a deadlock to occur, all four of these must hold true:

  1. Mutual Exclusion: At least one resource must be held in a non-sharable mode.

  2. Hold and Wait: A thread is holding at least one resource and waiting to acquire additional resources held by others.

  3. No Preemption: Resources cannot be forcibly taken from a thread; they must be released voluntarily.

  4. Circular Wait: A closed chain of threads exists where each thread holds a resource the next one needs (Thread A waits for B, B waits for C, C waits for A).

Deadlock Handling

  • Prevention: Design the system so that at least one of the Coffman conditions can never occur (e.g., forcing threads to request all resources at once).

  • Avoidance: The OS dynamically examines the resource-allocation state (using algorithms like the Banker’s Algorithm) to ensure a "safe state" always exists.

  • Detection and Recovery: Let the deadlock happen, detect it via a resource-allocation graph, and then recover by killing a process or preempting resources.

To delve deeper into these Operating System concepts, we need to look at how the kernel manages these threads, the specific synchronization primitives used to enforce mutual exclusion, and the mathematical models used to prevent system-wide stalls.

Thread Models and Management

How threads are mapped from the application to the processor depends on the relationship between User Threads and Kernel Threads.

Multi-threading Models

  • Many-to-One: Many user-level threads map to one kernel thread. If a thread makes a blocking system call, the entire process blocks.

  • One-to-One: Each user thread maps to a distinct kernel thread. This allows for true concurrency on multi-core systems. This is the model used by Windows and Linux.

  • Many-to-Many: Multiple user threads are multiplexed over a smaller or equal number of kernel threads, balancing efficiency and concurrency.

Threading Issues

  • Fork() and Exec() System Calls: If one thread calls fork(), does the new process duplicate all threads or just the calling one?

  • Signal Handling: In a multi-threaded program, where should a signal (like a keyboard interrupt) be delivered? To the first thread, all threads, or a specific designated thread?

Advanced Mutual Exclusion Primitives

Beyond simple Mutexes, OS designers use various tools to synchronize data and manage "Critical Sections."

Semaphores

A semaphore is an integer variable accessed through two atomic operations: wait() (or $P$) and signal() (or $V$).

  • Binary Semaphores: Function like Mutexes (0 or 1).

  • Counting Semaphores: Used to manage a finite pool of resources (e.g., a printer pool with 5 printers). The value represents the number of available units.

Spinlocks

A thread "spins" in a loop while repeatedly checking if the lock is available.

  • Pros: No context switch is required, which is faster for very short wait times.

  • Cons: Wastes CPU cycles if the lock is held for a long time.

Monitors

A high-level abstraction that provides a convenient and effective mechanism for process synchronization. Only one process at a time can be active within the monitor.

Deadlock Avoidance: The Banker’s Algorithm

Instead of just preventing deadlock conditions, an Operating System can use Avoidance by checking every resource request to ensure the system stays in a Safe State.

A system is in a safe state if there exists a Safe Sequence of processes $<P_1, P_2, \dots, P_n>$ such that for each $P_i$, the resources that $P_i$ can still request can be satisfied by the currently available resources plus the resources held by all $P_j$ (where $j < i$).

Classic Synchronization Problems

These scenarios are used to test the efficiency and correctness of threading and mutual exclusion logic:

  1. Bounded-Buffer (Producer-Consumer) Problem: Ensuring a producer doesn't add data to a full buffer and a consumer doesn't remove data from an empty one.

  2. Readers-Writers Problem: Allowing multiple readers to access data simultaneously, but ensuring exclusive access for a writer.

  3. Dining Philosophers Problem: A classic illustration of deadlock and starvation where $N$ philosophers sit at a table with $N$ forks, needing two forks to eat.

Starvation and Livelock

  • Starvation: A thread is perpetually denied the resources it needs to process. For example, if a "high priority" thread keeps arriving, a "low priority" thread may never execute.

  • Livelock: Two or more threads continually change their state in response to each other without doing any useful work. Unlike deadlock, the threads are not "blocked," but they are effectively stuck in a loop (like two people trying to pass each other in a hallway, both stepping to the same side repeatedly).

Operating-system signals are asynchronous notifications (software interrupts) sent to a running process to notify it of specific events, such as errors, user requests (e.g., Ctrl+C), or termination requests. They are used in Unix, Linux, and POSIX systems to trigger predefined actions—such as killing, pausing, or quitting a process—or to execute customized signal-handling routines.

Key Aspects of Operating System Signals

  • Asynchronous Nature: Signals can arrive at any time, interrupting a process's normal flow of execution to handle the event.
  • Purpose: Primarily used for process control (e.g., terminating runaway processes), inter-process communication (IPC), and notifying processes of exceptional situations (e.g., illegal memory access).
  • Signal Handling: When a process receives a signal, it can:
    • Take Default Action: Perform default actions like terminating or stopping the process.
    • Catch and Handle: Run a custom function (signal handler) designed to handle that specific event.
    • Ignore: Ignore the signal (unless it is a specific, non-maskable signal).
  • Common Signal Types:
    • SIGINT (Signal Interrupt): Sent when a user presses Ctrl+C to terminate a program. SIGINT (Signal Interrupt) is a specific operating-system signal sent to a process to request its termination, typically triggered by the user pressing Ctrl+C in the terminal. It acts as a polite request for the process to interrupt its current execution, allowing it to perform cleanup tasks (like closing files) before shutting down, rather than forcing an immediate kill. 
    • SIGTERM (Signal Terminate): The default signal sent to ask a program to stop (allows graceful cleanup). SIGTERM (Signal 15) is the default POSIX signal used in Linux/Unix to request a process to terminate gracefully. Unlike a forced kill, SIGTERM allows the program to handle the signal, finish ongoing tasks, close file connections, and free memory before stopping. It is the standard method for graceful shutdowns.
    • SIGKILL (Signal Kill): Forcefully terminates a process instantly. Cannot be caught or ignored. SIGKILL (signal 9) is the ultimate, non-catchable, and non-ignorable signal used in Unix-like systems to immediately terminate a process. Unlike SIGTERM, it allows no cleanup or graceful shutdown, making it a "last resort" for stopping unresponsive or stuck processes.
    • SIGSTOP (Signal Stop): Stops/pauses a process. Cannot be caught or ignored. SIGSTOP is a POSIX operating system signal used to immediately pause (suspend) the execution of a running process. Unlike other signals, SIGSTOP cannot be ignored, handled, or blocked by the application, making it a reliable tool for administrators and system debuggers.
    • SIGSEGV (Segmentation Violation): Sent when a process attempts invalid memory access. SIGSEGV (Segmentation Violation) is a specific signal sent by the operating system to a process when it attempts to access memory it is not allowed to (e.g., reading uninitialized pointers, writing to read-only memory, or buffer overflows). Commonly known as a "segmentation fault," it usually results in the immediate termination of the program and, often, the creation of a core dump file for debugging.

Key Details About SIGINT:

  1. Trigger: Usually initiated by a user via the terminal keyboard shortcut Ctrl+C.
  2. Behavior: The default action is to terminate the process, but unlike SIGKILL, a program can catch, handle, or ignore a SIGINT signal.
  3. Purpose: It allows for "graceful termination" of foreground processes that are running in an infinite loop, hanging, or no longer needed.
  4. Signal Number: It is usually represented by the number 2 in POSIX systems.

Key Aspects of SIGTERM

  1. Purpose: It instructs a program to stop, allowing it to perform cleanup tasks to prevent data loss or corruption.
  2. Origin: It is the default signal sent by the command line kill command (e.g., kill <pid>).
  3. Handling: The process can catch, handle, or ignore this signal. If a process does not terminate within a specified time after receiving SIGTERM, a SIGKILL is often sent to terminate it forcibly.
  4. Usage in Containers: In Docker/Kubernetes, a SIGTERM is sent first to shutdown containers gracefully, often resulting in exit code 143 if caught properly.

Key Characteristics of SIGKILL

  1. Forced Termination: The kernel terminates the process immediately.
  2. No Handling: The process cannot catch, block, or ignore SIGKILL.
  3. No Cleanup: Because the process is killed instantly, it cannot run cleanup routines (e.g., closing files, releasing locks, saving state).
  4. Use Case: Ideal for killing deadlocked, zombie, or unresponsive processes that do not respond to regular kill commands.
  5. Command: Sent using kill -9 <PID>.

Risks of Using SIGKILL: Because it does not allow a process to shut down cleanly, SIGKILL can lead to corrupted data files, locked resources (like semaphores), or orphaned child processes.

Common Use Case: When a script or application (like a web server) is running in your terminal and you want to stop it, pressing Ctrl+C sends the SIGINT signal, allowing it to stop gracefully.

Here is a detailed breakdown of SIGSTOP:

Behavior and Mechanism

  • Purpose: Pauses a process instantly, freezing it in its current state without terminating it.
  • Uninterruptible: It cannot be caught, ignored, or blocked by the process. The operating system kernel enforces this stop.
  • State: The process is moved into a TASK_STOPPED state (or T in ps output), meaning it stays in memory but is removed from the CPU scheduling run queue.
  • Resumption: A process stopped by SIGSTOP can only resume execution upon receiving a SIGCONT (Signal Continue) signal. 

Common Use Cases

  • Debugging: Pausing a program in its current state to inspect its memory or variable values using tools like GDB.
  • Resource Management: Temporarily pausing a runaway or non-critical process to free up CPU cycles for more important tasks.
  • Job Control: Managing processes in the background (similar to CTRL+Z, but without the user interaction). 

SIGSTOP vs. SIGTSTP vs. SIGKILL

It is important to differentiate SIGSTOP from other similar signals: 

Signal  Action Can be Caught/Ignored? Trigger
SIGSTOP Stop/Pause No kill -STOP <pid>
SIGTSTP Terminal Stop Yes Ctrl+Z (Keyboard)
SIGKILL Immediate Kill No kill -9 <pid>
  • SIGSTOP vs. SIGTSTP: SIGTSTP (Terminal Stop) is triggered by Ctrl+Z, which allows the program to catch the signal and potentially perform cleanup before pausing. SIGSTOP is programmatic and unconditional.
  • SIGSTOP vs. SIGKILL: SIGSTOP pauses the process; SIGKILL destroys it. 

Important Interaction Notes

  • Pending Signals: While a process is paused by SIGSTOP, it cannot receive most other signals (e.g., SIGTERM). Those signals become "pending" and are only delivered once the process is continued with SIGCONT.
  • Exceptions: SIGKILL and SIGCONT can still be delivered to a stopped process.
  • Command Example: kill -STOP <PID> sends this signal.

Signals are identified by unique numeric identifiers, and they serve as a lightweight form of IPC. 

Common Causes of SIGSEGV

  • NULL Pointer Dereference: Attempting to access memory through a pointer set to NULL.
  • Buffer Overflow: Writing data outside the bounds of an allocated array.
  • Using Uninitialized Pointers: Dereferencing a pointer that has not been assigned a valid memory address.
  • Stack Overflow: Excessive recursion or declaring massive local variables, exceeding the stack limit.
  • Writing to Read-Only Memory: Attempting to write to memory locations that are marked read-only, such as string literals or code segments. 

Debugging SIGSEGV: Since this signal indicates a critical memory error, it requires debugging techniques to pinpoint the exact location of the error, such as: 

  • Using a Debugger (GDB): Running gdb ./program, then run, and using backtrace (or bt) after the crash to find the offending line.
  • Memory Analyzers: Using tools like Valgrind or AddressSanitizer to detect memory mismanagement.
  • Checking Code: Looking for NULL pointers or incorrect loop boundaries. 

In Linux environments, this signal is commonly referred to as Signal 11.

Code

An operating system (OS) is the main software that manages a computer's hardware and allows other programs to run. It acts as a bridge between you (the user) and the machine's physical components like the CPU, memory, and storage. 

Think of it as the "manager" of the house: it decides which applications get to use the computer's resources and ensures they don't crash into each other. 

Common examples include:

  • Windows (for PCs)
  • macOS (for Apple computers)
  • Linux (for servers and developers)
  • Android and iOS (for mobile devices)

An Operating-System (OS) is more than just a background program; it is a complex architecture of components that coordinate every action on your device.

Core Components

An Operating System is typically divided into several layers or parts that work together: 

  • Kernel: The "heart" of the OS. It remains in memory at all times and directly manages hardware, CPU time, and memory.
  • Shell: The interface you interact with. It can be a GUI (Graphical User Interface) like the Windows-desktop or a CLI (Command-Line Interface) like a Terminal.
  • Device Drivers: Special programs that act as translators, allowing the OS to communicate with hardware like printers, graphics cards, and keyboards.
  • File System: Manages how data is organized, stored, and retrieved on your drives. 

Key Functions

The OS acts as a resource manager to keep everything running smoothly: 

  • Process Management: It handles multiple programs at once (multitasking) by deciding which process gets to use the CPU and for how long.
  • Memory Management: It tracks every byte of RAM, allocating space to programs that need it and freeing it up when they close.
  • Security & Protection: It prevents unauthorized users from accessing your files and ensures one program can't crash another.
  • Networking: It handles the complex protocols (like TCP/IP) required for your device to connect to the internet or local networks. 

Specialized Types of Operating Systems

Beyond the Windows and macOS you use daily, there are other types designed for specific tasks:

  • Real-Time Operating System (RTOS): Used where timing is critical, such as in car airbags, medical devices, or industrial robots.
  • Embedded Operating System: Found in specialized hardware like smart appliances, traffic lights, or ATMs.
  • Distributed Operating System: Coordinates multiple independent computers so they appear as a single, unified system to the user.
  • Batch Operating System: Processes similar jobs in groups without user interaction, often used for massive data tasks like payroll. 

To understand how an operating system (OS) truly works, we can look at the "magic" it performs to keep your computer fast and stable even when you have dozens of apps open. 

Virtual Memory: Making Random Access Memory "Infinite"

The Operating Systme uses a trick called Virtual Memory to let you run programs that are larger than your actual RAM. 

  • Paging: The OS breaks programs into small, fixed-size chunks called pages.
  • Demand Paging: Instead of loading a whole-application (like Photoshop etc.) into RAM, the Operating System only loads the specific pages you are currently using.
  • Swapping: When Random Access Memory gets full, the Operating System moves "cold" (unused) pages to your hard drive (the Swap File) to make room for "hot" ones.
  • Page-Fault: If you click a feature that isn't in Random Access Memory, a "Page-Fault" occurs. The Operating System pauses the application for a millisecond, grabs the needed data from the disk, and puts it into Random Access Memory. 

CPU Scheduling: The Master Juggler

Since a single CPU core can technically only do one thing at a time, the OS uses Scheduling Algorithms to switch between tasks so fast it looks like they’re running simultaneously. 

  • Round Robin (RR): Every application gets a tiny "time slice" (e.g., 10ms). When time is up, the Operating System pauses it and moves to the next application in line.
  • Shortest Job First (SJF): The OS looks at the queue and picks the quickest task to finish first, reducing overall wait times.
  • Priority Scheduling: Important tasks (like your video call) get a higher priority than background tasks (like an antivirus scan). 

Kernel Architectures: The Operating System Blueprint

Different operating systems are built using different philosophies regarding the Kernel (the core code). 

  • Monolithic Kernel (e.g., Linux, Windows): Everything—drivers, file systems, and memory management—is packed into one big, fast piece of software.
    • Pro: Very fast because all parts talk to each other directly.
    • Con: If one driver crashes, the whole system might Blue Screen.
  • Microkernel (e.g., macOS, QNX): Only the bare essentials stay in the kernel. Everything else (like drivers) runs as separate, "safe" applications.
    • Pro: Extremely stable. If a driver crashes, the OS just restarts that one part without affecting the rest.
    • Con: Slightly slower because parts have to send "messages" to each other. 

How the Operating System "Boots-Up"

When you press the power button, the hardware is "dumb." It looks for a tiny piece of code called the Bootstrap Loader (stored in Read Only Memory). This loader finds the Operating-System-Kernel on your disk, copies it into Random Access Memory, and starts it. Once the Kernel is running, it "wakes up" the rest of the system.

The architecture of an operating system involves complex systems that manage how your data is stored and how your device remains secure from threats. 

File Systems: Digital Filing Cabinets

A file system is the structure an Operating System uses to organize and manage files on storage devices like SSDs or hard drives. Without it, all data would be a single massive block, and the computer wouldn't know where one file ends and the next begins. 

  • Common File Systems:
    • NTFS: Default for Windows; supports advanced security, large file sizes, and "journaling" to recover quickly from crashes.
    • APFS: Modern Apple file system optimized for SSDs; supports "cloning" (near-instant file copying) and space sharing.
    • Ext4: The go-to for Linux and Android; known for its high reliability and scalability.
    • FAT32/exFAT: Used for USB drives and SD cards due to wide compatibility across all devices.
  • Key Functions:
    • Metadata: It stores "data about data," such as who created a file, when it was last changed, and its size.
    • Space Allocation: It decides how to fit files into blocks on a disk. If a file is scattered in pieces, the Operating System handles defragmentation to tidy them up. 

Operating System Security vs. Protection

While often used interchangeably, these are actually two different layers of defense. 

  • Protection (Internal): Focuses on internal threats. It ensures that one program cannot access the memory or files of another program without permission. It uses Access Control Lists (ACLs) to manage who can read or write specific files.
  • Security (External): Focuses on defending against outside threats like hackers and malware (viruses, worms, trojans). It uses tools like Firewalls and Encryption to safeguard your data. 

Virtualization: "Computers Within Computers"

Virtualization allows one physical computer to act as multiple independent "virtual machines" (VMs). 

  • Hypervisor: A specialized piece of software that sits between the hardware and the VMs. It allocates CPU and RAM to each virtual "guest" OS so they don't interfere with each other.
  • Cloud Computing: Most of the internet (like AWS or Azure) runs on virtualization. When you "rent a server," you're usually renting a VM on a massive physical server shared with others.
  • Containerization: A lightweight alternative (like Docker) where apps share the same OS kernel but remain isolated, making them faster to start than full VMs. 

Now, I provides the details of all the Signals implemented inside the Operating System as under:

In operating systems (specifically Unix-like systems like Linux and macOS), signals are software interrupts used for inter-process communication. They notify a process that a specific event has occurred, such as a user request to stop a program or a hardware error. 

There are two main groups: Standard Signals (the first 31) and Real-time Signals (for high-priority, queued events). 

Common Termination Signals

These are the signals you encounter most often when stopping or managing programs:

  • SIGINT (2)Interrupt. Sent when you press Ctrl+C. It politely asks the program to stop, allowing it to perform cleanup tasks like saving files.
  • SIGTERM (15)Termination. The default signal sent by the kill command. Like SIGINT, it is a "polite" request that the process can catch to shut down gracefully.
  • SIGKILL (9)Kill. The "nuclear option." It forces the process to stop immediately. The process cannot ignore or handle this signal, meaning no cleanup happens, which can occasionally lead to corrupted files.
  • SIGQUIT (3)Quit. Triggered by Ctrl+\. It terminates the process and typically produces a "core dump" (a file containing the program's memory state) for debugging.
  • SIGHUP (1)Hangup. Originally used when a modem connection was lost. Today, it’s often used to tell background services (daemons) to reload their configuration files without fully restarting. 

Hardware & Error Signals

These signals are usually triggered by the system when a program does something illegal or encounters a hardware fault: 

  • SIGSEGV (11)Segmentation Fault. Occurs when a program tries to access memory it doesn’t have permission to use.
  • SIGFPE (8)Floating-Point Exception. Triggered by erroneous math, most commonly a division by zero.
  • SIGILL (4)Illegal Instruction. Sent if a program tries to execute a command the CPU doesn't understand.
  • SIGBUS (7)Bus Error. Indicates a physical memory access error, like misaligned data. 

Job Control & Utility Signals

These help manage how processes run in the background or interact with timers: 

  • SIGSTOP (19)Stop. Pauses a process immediately. Like SIGKILL, it cannot be ignored or handled.
  • SIGTSTP (20)Terminal Stop. Sent by pressing Ctrl+Z. It asks the process to pause but, unlike SIGSTOP, it can be ignored or handled.
  • SIGCONT (18)Continue. Tells a paused or stopped process to resume execution.
  • SIGALRM (14)Alarm. Sent when a timer set by the program expires.
  • SIGCHLD (17)Child. Sent to a parent process whenever one of its "child" processes terminates or stops.
  • SIGUSR1 / SIGUSR2User-defined. These have no set meaning; developers can use them for custom communication between their own programs.

"Most Linux and Unix-like systems typically support 64 signals"

"In the context of electrical signals, there is a widely used industrial standard known as a 4-20mA (milliamp) loop, which is used to transmit data from sensors to controllers.

In a standard Linux/Unix OS, the signals are divided as follows:

  • Standard Signals (1–31): Used by the kernel for common notifications like interrupts or errors.
  • Real-time Signals (34–64): Reserved for application-defined purposes and high-priority tasks. 

Below is the complete list of the standard signals found on most Linux systems:

Number  Name Description
1 SIGHUP Terminal line hangup or death of controlling process
2 SIGINT Terminal interrupt (Ctrl+C)
3 SIGQUIT Terminal quit (Ctrl+\)
4 SIGILL Illegal instruction executed by process
5 SIGTRAP Trace/breakpoint trap for debuggers
6 SIGABRT / SIGIOT Process aborted
7 SIGBUS Bus error (bad memory access)
8 SIGFPE Floating point exception (e.g., division by zero)
9 SIGKILL Forced termination (cannot be ignored)
10 SIGUSR1 User-defined signal 1
11 SIGSEGV Segmentation fault (invalid memory access)
12 SIGUSR2 User-defined signal 2
13 SIGPIPE Broken pipe (writing to a pipe with no readers)
14 SIGALRM Timer signal (alarm clock)
15 SIGTERM Software termination (sent by kill by default)
16 SIGSTKFLT Stack fault on math co-processor
17 SIGCHLD Child process stopped or terminated
18 SIGCONT Resume a stopped process
19 SIGSTOP Stop process execution (cannot be ignored)
20 SIGTSTP Terminal stop signal (Ctrl+Z)
21 SIGTTIN Background process attempting to read from terminal
22 SIGTTOU Background process attempting to write to terminal
23 SIGURG Urgent condition on a socket
24 SIGXCPU CPU time limit exceeded
25 SIGXFSZ File size limit exceeded
26 SIGVTALRM Virtual timer expired
27 SIGPROF Profiling timer expired
28 SIGWINCH Window size change
29 SIGIO / SIGPOLL I/O is now possible
30 SIGPWR Power failure detected
31 SIGSYS Bad system call

Real-time Signals (32–64) 

Real-time signals do not have fixed names like "SIGKILL." Instead, they are referenced by their range from SIGRTMIN to SIGRTMAX

  • SIGRTMIN: The highest-priority real-time signal (usually starting at number 34 in Linux because 32 and 33 are used internally by the {pthreads_library<---> "https://www.chromium.org/chromium-os/developer-library/reference/linux-constants/signals/"}
  • SIGRTMAX: The lowest-priority real-time signal (number 64).
  • SIGRTMIN+n: How developers reference intermediate signals (e.g., SIGRTMIN+1SIGRTMIN+2). 

The SIGRTMIN & SIGRTMAX values listed below are technically dynamic. Implementations (e.g. glibc) are allowed to reserve things internally from the user's program. The constants listed below reflect the most common scenarios people see, especially since real-time signal usage is not that common. Keep this in mind if you see signal usage in that range.

number hex-codes symbol description
1 0x01 SIGHUP Hangup
2 0x02 SIGINT Interrupt
3 0x03 SIGQUIT Quit
4 0x04 SIGILL Illegal instruction
5 0x05 SIGTRAP Trace/breakpoint trap
6 0x06 SIGABRT Aborted
6 0x06 SIGIOT (Same value as SIGABRT) Aborted
7 0x07 SIGBUS Bus error
8 0x08 SIGFPE Floating point exception
9 0x09 SIGKILL Killed
10 0x0a SIGUSR1 User defined signal 1
11 0x0b SIGSEGV Segmentation fault
12 0x0c SIGUSR2 User defined signal 2
13 0x0d SIGPIPE Broken pipe
14 0x0e SIGALRM Alarm clock
15 0x0f SIGTERM Terminated
16 0x10 SIGSTKFLT Stack fault
17 0x11 SIGCHLD Child exited
17 0x11 SIGCLD (Same value as SIGCHLD) Child exited
18 0x12 SIGCONT Continued
19 0x13 SIGSTOP Stopped (signal)
20 0x14 SIGTSTP Stopped
21 0x15 SIGTTIN Stopped (tty input)
22 0x16 SIGTTOU Stopped (tty output)
23 0x17 SIGURG Urgent I/O condition
24 0x18 SIGXCPU CPU time limit exceeded
25 0x19 SIGXFSZ File size limit exceeded
26 0x1a SIGVTALRM Virtual timer expired
27 0x1b SIGPROF Profiling timer expired
28 0x1c SIGWINCH Window changed
29 0x1d SIGPOLL I/O possible
29 0x1d SIGIO (Same value as SIGPOLL) I/O possible
30 0x1e SIGPWR Power failure
31 0x1f SIGSYS Bad system call
32 0x20 SIGRTMIN-2 Real-time signal reserved by the C library for ; see signal(7)
33 0x21 SIGRTMIN-1 Real-time signal reserved by the C library for NPTL; see signal(7)
34 0x22 SIGRTMIN Real-time signal 0
35 0x23 SIGRTMIN+1 Real-time signal 1
36 0x24 SIGRTMIN+2 Real-time signal 2
37 0x25 SIGRTMIN+3 Real-time signal 3
38 0x26 SIGRTMIN+4 Real-time signal 4
39 0x27 SIGRTMIN+5 Real-time signal 5
40 0x28 SIGRTMIN+6 Real-time signal 6
41 0x29 SIGRTMIN+7 Real-time signal 7
42 0x2a SIGRTMIN+8 Real-time signal 8
43 0x2b SIGRTMIN+9 Real-time signal 9
44 0x2c SIGRTMIN+10 Real-time signal 10
45 0x2d SIGRTMIN+11 Real-time signal 11
46 0x2e SIGRTMIN+12 Real-time signal 12
47 0x2f SIGRTMIN+13 Real-time signal 13
48 0x30 SIGRTMIN+14 Real-time signal 14
49 0x31 SIGRTMIN+15 Real-time signal 15
50 0x32 SIGRTMAX-14 Real-time signal 16
51 0x33 SIGRTMAX-13 Real-time signal 17
52 0x34 SIGRTMAX-12 Real-time signal 18
53 0x35 SIGRTMAX-11 Real-time signal 19
54 0x36 SIGRTMAX-10 Real-time signal 20
55 0x37 SIGRTMAX-9 Real-time signal 21
56 0x38 SIGRTMAX-8 Real-time signal 22
57 0x39 SIGRTMAX-7 Real-time signal 23
58 0x3a SIGRTMAX-6 Real-time signal 24
59 0x3b SIGRTMAX-5 Real-time signal 25
60 0x3c SIGRTMAX-4 Real-time signal 26
61 0x3d SIGRTMAX-3 Real-time signal 27
62 0x3e SIGRTMAX-2 Real-time signal 28
63 0x3f SIGRTMAX-1 Real-time signal 29
64 0x40 SIGRTMAX Real-time signal 30

Real-time signals (numbered 32 to 64) do not have unique names like "SIGKILL" or "SIGINT." Instead, they are defined as a range that developers can use for custom application logic.

In a standard Linux environment, the list looks like this:

The Real-time Range

Signal Number Symbolic Name Description
32 & 33 N/A Reserved internally by the NPTL (Native POSIX Thread Library) for managing threads.
34 SIGRTMIN The first available real-time signal for user applications.
35 – 63 SIGRTMIN+n Intermediate signals (e.g., SIGRTMIN+1SIGRTMIN+2, etc.).
64 SIGRTMAX The final real-time signal in the sequence.

How they differ from Standard Signals

Real-time signals were added to the POSIX standard to solve limitations found in the original 31 signals:

  1. Queuing: If you send the same standard signal (like SIGUSR1) to a process three times quickly, the process might only "see" it once. Real-time signals are queued; if you send it three times, the process will receive all three in order.
  2. Order of Delivery: Real-time signals are delivered in a specific priority. Lower-numbered signals (closer to SIGRTMIN) are always delivered before higher-numbered ones.
  3. Carrying Data: You can attach an integer or a pointer to a real-time signal. This allows one process to send actual information to another, not just a "ping."
  4. No Predefined Meaning: The OS never sends these automatically. They are strictly for programmers to use as a private "intercom" system between different parts of their software.
Select Chapter