BCA / B.Tech 11 min read

Kernel & Signals in Linux

Kernel & Signals in Linux:


Linux is a powerful and modular operating system where the kernel and signals play significant roles. The kernel is the core part of the system, acting as a mediator between hardware and software. Signals are used to send messages between processes. In this article, we will discuss the kernel and signals in Linux in detail.

The Linux Kernel:

The Linux kernel is the central component of the operating system that establishes communication between hardware and software. It manages hardware resources and allows software programs to use them. The main functions of the Linux kernel are:
  • Process Management: Manages process creation, execution, scheduling, and termination.
  • Memory Management: Controls the use of physical and virtual memory.
  • File System Management: Manages the creation, reading, writing, and deletion of files and directories.
  • Driver Management: Loads and manages hardware drivers.
  • Security: Manages user authentication, permission control, and security policies.

Signals in Linux:


Signals are a way to send messages between processes in Linux. A signal is a type of software interrupt sent to a process to inform it that a specific event has occurred. Signals are important for process control and communication.

Types of Signals:

Linux has many types of signals that report different events:
  • SIGINT (Interrupt Signal): Usually sent when the user presses Ctrl+C. Used to interrupt a process.
  • SIGTERM (Terminate Signal): Sent to terminate a process. It is a request for the process to shut down cleanly.
  • SIGKILL (Kill Signal): Immediately terminates a process. It is a force signal that does not give the process a chance to clean up.
  • SIGSTOP (Stop Signal): Sent to temporarily stop a process. The `SIGCONT` signal is sent to resume it.
  • SIGSEGV (Segmentation Fault Signal): Sent when a process attempts to make an invalid memory access.
  • SIGHUP (Hangup Signal): Sent when a terminal is disconnected. It is often used to reload daemon processes.

Sending and Receiving Signals:

The `kill` command is used to send signals to a process. The `signal()` system call is used by a process to set up a signal handler to process signals.

Signal Handler:

A signal handler is a function that processes a signal received by a process. When a process receives a signal, the corresponding signal handler is called. There can be a default handler provided by Linux (like terminating the process) or a custom handler defined by the user.

In this Chapter

Kernel & Signals in Linux
Distributed System in Operating System
Real-Time System in Operating System
System Calls in Operating System
System Programs in Operating System
Structure of an Operating System
Layered Design of an Operating System Structure
UNIX in Operating System
Virtual Machine in Operating System
Kernel-Based Operating System
Process Concept in Operating System
Interacting Processes in Operating System
Threads in Operating System
Fundamentals of Scheduling in Operating System
Scheduling Criteria in Operating System
Long, Medium, and Short-Term Scheduling
Scheduling Algorithms in Operating System
Structure of a Concurrent System
Critical Region in Operating System
Critical Section in Operating System
Inter-process Communication (IPC) in Operating System
Monitors in Operating System
Semaphores in Operating System
Semaphore Implementation & Uses in Operating System
Logical and Physical Address in Operating System
Swapping in Operating System
Contiguous Allocation in Operating System
Segmentation in Operating System
Paging in Operating System
Virtual Memory using Segmentation in Operating System
Interprocess Communication Protocol in Operating System
Network Operating System
Design Issues in Distributed File System
Network Structure in Operating System
Structure of a Distributed System
File System and Coordination in Operating System
History of Linux in Operating System
Linux Commands
Programmer Interface & File Manipulation in Linux
Process Control in Linux
File System in Linux
Blocks and Inodes in Linux
System Editors in Linux
Character Transliteration in Linux
The `ed` Line Editor in Linux
The `vi` Editor and Its Commands
Shell Scripting in Linux
Looping & Decision Making in Linux Shell Scripting
Variables & File Name Expansion in Linux
Arrays in Linux Shell Scripting
Subprograms (Functions) in Linux Shell Scripting
C Interface with Linux
Simple Shell Programs in Linux
BCA Part-1 | Operating Systems | Semester-I | MDSU Exam Paper 2023 (Held in 2024)
What is an Operating System (OS)
Operating System (OS) All Important Questions and Answers in English (MDSU)
BCA || Operating System 2025 Paper || MDSU Exam Paper
BCA | OS(Operating System) 2023 Paper | MDSU Exam Paper
Types of Operating Systems
Goals of an Operating System
Operations of an Operating System
Resource Allocation & Functions in an Operating System
Classes of Operating System
Batch Processing in Operating System
Multiprocessing in Operating System
Time-Sharing in Operating System