[ SRE_ARENA ]
LINUX KERNEL & SYSCALLS

The Kernel is the Bouncer. You are the Guest.

Visualization: 1. User Space vs. Kernel Space
DOWNLOADING CONCEPT: 1. USER SPACE VS. KERNEL SPACE...
  • ↳Modern CPUs have protection rings.
  • ↳Ring 3 (User Space) is heavily restricted.
  • ↳This is where your applications run.
  • ↳Ring 0 (Kernel Space) has absolute, unrestricted access to the CPU, RAM, and hardware.
  • ↳Your Python app cannot physically talk to a hard drive or a network card.
  • ↳If it wants to read a file, it must politely ask the Kernel to do the work on its behalf.
  • ↳The bridge between the restricted User Space and the omnipotent Kernel Space is the System Call (Syscall).
  • ↳This barrier protects the system.
  • ↳If your app crashes in User Space, the app dies.
  • ↳If the Kernel crashes in Kernel Space, the entire server Kernel Panics and dies.
▲ LIVE INCIDENTApp is unresponsive. CPU is at 0%.
sre@arena:~/advanced-kernel
sre@arena:~$ strace -c -p 1234