Tagged articles
10 articles
Page 1 of 1
Deepin Linux
Deepin Linux
Sep 21, 2025 · Fundamentals

Why Linux Uses Copy‑On‑Write: Boosting Process Creation and Memory Efficiency

This article explains Linux’s Copy‑On‑Write mechanism, detailing how it avoids full memory duplication during process creation, the underlying page‑table workflow, its implementation in the kernel, and real‑world applications such as Redis persistence, Docker image layering, and filesystem snapshots, while also discussing its advantages and drawbacks.

Copy-on-WriteLinuxMemory Management
0 likes · 73 min read
Why Linux Uses Copy‑On‑Write: Boosting Process Creation and Memory Efficiency
Linux Kernel Journey
Linux Kernel Journey
Oct 9, 2024 · Fundamentals

Understanding Linux Process Creation and Termination (Part 1)

This article walks through the Linux kernel mechanisms for creating and destroying processes, covering copy‑on‑write, the fork/vfork/clone system calls, the kernel_clone implementation in kernels 5.0 and 6.5, the copy_process workflow, and the steps the kernel takes to wake up a new task and clean up a terminated one.

KernelLinuxclone
0 likes · 26 min read
Understanding Linux Process Creation and Termination (Part 1)
Liangxu Linux
Liangxu Linux
Jun 25, 2023 · Fundamentals

Understanding Linux Process Creation: Kernel and User Space APIs

This article explains Linux process creation and termination, covering kernel functions like kernel_thread, kthread_create, kthread_run, the central _do_fork implementation, and user‑space interfaces such as fork, vfork, and pthread_create, with code snippets and diagrams.

KernelLinuxfork
0 likes · 7 min read
Understanding Linux Process Creation: Kernel and User Space APIs
ITPUB
ITPUB
Mar 9, 2022 · Fundamentals

Why Does Linux Report “Out of Memory” When PID Allocation Fails?

The article explains why Linux’s fork() can return a misleading “fork: cannot allocate memory” error, tracing the issue to PID allocation failures in the kernel’s do_fork and alloc_pid functions, and shows how excessive threads, not actual memory shortage, trigger the problem.

ENOMEMKernelLinux
0 likes · 12 min read
Why Does Linux Report “Out of Memory” When PID Allocation Fails?
OPPO Kernel Craftsman
OPPO Kernel Craftsman
Feb 25, 2022 · Fundamentals

Inside Linux’s fork: How the Kernel Creates a New Process

This article dissects the Linux kernel’s fork implementation, explaining why the child receives a return value of 0, how parent and child share code execution, the internal steps of sys_fork, kernel_clone, copy_process, thread handling, scheduling initialization, and the final insertion of the new task into the run‑queue.

LinuxSchedulingfork
0 likes · 10 min read
Inside Linux’s fork: How the Kernel Creates a New Process