Skip to main content

Microkernel vs monolithic kernel

Short answer

Microkernels offer modularity, small size, reliability (server failure do not crash kernel), flexibility, and distribution support via message passing. They are preferable for distributed OS because message passing naturally extends across machines, enabling location transparency, dynamic service placement, and tolerance of service failures.

What are the advantages of micro-kernel over monolithic-kernel? In your view, which kernel is preferable for distributed operating system and why?

Advantages of microkernel over monolithic kernel

  1. Modularity and flexibility: services are separate servers that can be added, replaced or upgraded without recompiling the kernel.
  2. Small size: the kernel is small and simple, easier to understand, test and verify.
  3. Reliability: failure of a server (file or driver) does not crash the kernel; it can be restarted.
  4. Security: the services run in user space with less privilege.
  5. Portability: only the small kernel depends on hardware.
  6. Distribution support: the same message passing is used for local and remote services, so servers may run on any node (location transparency).
  7. Several OS personalities can run on one microkernel.

Drawback: message passing and extra context switches make it slower than a monolithic kernel.

PointMonolithic kernelMicrokernel
StructureAll OS services (file system, memory, scheduling, drivers, networking) in one large kernel in kernel spaceOnly minimum functions (IPC, basic scheduling, low level memory, interrupts) in kernel
Other servicesPart of kernelRun as user-level servers
CommunicationDirect procedure calls (fast)Message passing between servers (slower)
SizeLargeSmall
ReliabilityA bug in one module can crash the systemA server failure does not crash the kernel
Flexibility, extensibilityHard; needs recompilationEasy; add/replace servers
ExamplesUNIX, Linux, MS-DOSMach, Amoeba, Chorus, QNX

Preferred kernel for a distributed OS

The microkernel is preferable. A distributed OS needs communication by messages across machines, transparent location of services, the ability to put different services on different nodes, to add or change services dynamically, and to tolerate the failure of services. A microkernel gives all of these, with IPC as the basic mechanism. The performance loss is acceptable compared with the network delays, and can be reduced by optimising IPC.

✓ Answer checked by Claude Opus 5.5 (high effort)

All Distributed System chapter 3 questions →