Skip to content
geeksforgeeks
  • Tutorials
    • Python
    • Java
    • Data Structures & Algorithms
    • ML & Data Science
    • Interview Corner
    • Programming Languages
    • Web Development
    • CS Subjects
    • DevOps And Linux
    • School Learning
    • Practice Coding Problems
  • Courses
    • DSA to Development
    • Get IBM Certification
    • Newly Launched!
      • Master Django Framework
      • Become AWS Certified
    • For Working Professionals
      • Interview 101: DSA & System Design
      • Data Science Training Program
      • JAVA Backend Development (Live)
      • DevOps Engineering (LIVE)
      • Data Structures & Algorithms in Python
    • For Students
      • Placement Preparation Course
      • Data Science (Live)
      • Data Structure & Algorithm-Self Paced (C++/JAVA)
      • Master Competitive Programming (Live)
      • Full Stack Development with React & Node JS (Live)
    • Full Stack Development
    • Data Science Program
    • All Courses
  • Aptitude
  • Engineering Mathematics
  • Discrete Mathematics
  • Operating System
  • DBMS
  • Computer Networks
  • Digital Logic and Design
  • C Programming
  • Data Structures
  • Algorithms
  • Theory of Computation
  • Compiler Design
  • Computer Org and Architecture
Open In App
Next Article:
Monolithic Kernel and Key Differences From Microkernel
Next article icon

Monolithic Kernel and Key Differences From Microkernel

Last Updated : 29 Jul, 2024
Comments
Improve
Suggest changes
Like Article
Like
Report

Apart from microkernel, Monolithic Kernel is another classification of Kernel. Like microkernel, this one also manages system resources between application and hardware, but user and kernel services are implemented under the same address space. It increases the size of the kernel, thus increasing the size of the operating system as well.  This kernel provides CPU scheduling, memory management, file management, and other operating system functions through system calls. As both services are implemented under the same address space, the operating system execution is faster. 

What is a Monolithic Kernel?

A monolithic kernel is an operating system kernel in which all the operating system services run in kernel space, meaning they all share the same memory space. This type of kernel is characterized by its tight integration of system services and its high performance.

Below is the diagrammatic representation of the Monolithic Kernel: 

Monolithic Kernel
Monolithic Kernel

Advantages of Monolithic Kernel

  • One of the major advantages of having a monolithic kernel is that it provides CPU scheduling, memory management, file management, and other operating system functions through system calls.
  • The other one is that it is a single large process running entirely in a single address space.
  • It is a single static binary file. Examples of some Monolithic Kernel-based OSs are Unix, Linux, Open VMS, XTS-400, z/TPF.
  • No need for complex inter-process communication (IPC), which speeds up system call execution.

Disadvantages of Monolithic Kernel

  • Stability Issues: One of the major disadvantages of a monolithic kernel is that if anyone service fails it leads to an entire system failure.
  • Lack of Modularity: If the user has to add any new service. The user needs to modify the entire operating system.
  • Security Risks: A bug or vulnerability in any service can affect the entire system since all services run in kernel mode.
  • Large Size: The kernel can become very large and complex as more services are added.

What is Microkernel?

A microkernel is a type of operating system kernel in which only the most basic services run in kernel space, with other services running in user space. This type of kernel is characterized by its modularity, simplicity, and ability to run multiple operating systems on the same hardware. 

The microkernel itself typically includes only the most fundamental services, such as:

  • Inter-process Communication (IPC): Mechanisms for processes to communicate and synchronize with each other.
  • Basic Scheduling: Managing the execution of processes.
  • Minimal Memory Management: Essential functions for memory allocation and protection.

Other functionalities that are often part of a monolithic kernel, like device drivers, file systems, and network protocols, are implemented in user space as separate processes. This contrasts with a monolithic kernel, where all these services run in kernel space.

Kernel Space vs User Space

Before comparing types of kernels, it's important to know whether components run in kernel space or user space, as this impacts how the system works.

In an operating system, there are two main areas where code runs: user space and kernel space. User space is where user applications run, while kernel space is where the operating system and other important parts run. In kernel space, code can directly access system resources like memory and hardware, allowing it to perform special tasks that user space code can't.

System calls are important for connecting user space and kernel space. They let user applications ask the kernel for specific services. When an application makes a system call, it switches from user space to kernel space, allowing the kernel to do what the application requested.

Key Differences Between Monolithic and Micro Kernel

  • System Services: In a monolithic kernel, all system services run in kernel space, whereas in a microkernel, only the most basic services (such as memory management and process scheduling) run in kernel space, with other services running in user space.
  • Performance: Monolithic kernels are generally faster and more efficient than microkernels, because there is no overhead associated with moving data between kernel space and user space.
  • Modularity: Microkernels are more modular than monolithic kernels, because services are separated into different processes running in user space. This makes it easier to add or remove services without affecting other parts of the system.
  • Security: Microkernels are generally considered more secure than monolithic kernels, because a bug or vulnerability in a service running in user space is less likely to affect the entire system.
  • Development: Developing a monolithic kernel is generally simpler and faster than developing a microkernel, because all system services are integrated and share the same memory space.

Differences Between Monolithic Kernel and Microkernel

Basics Micro KernelMonolithic Kernel
SizeSmallerLarger as OS and both user lie in the same address space.
ExecutionSlower Faster 
ExtendibleEasily extendibleComplex to extend
SecurityIf the service crashes then there is no effect on working on the microkernel.If the process/service crashes, the whole system crashes as both user and OS were in the same address space.
CodeMore code is required to write a microkernel.Less code is required to write a monolithic kernel. 
ExamplesL4Linux, macOSWindows, Linux BSD
SecurityMore secure because only essential services run in kernel modeSusceptible to security vulnerabilities due to the amount of code running in kernel mode
Platform independenceMore portable because most drivers and services run in user spaceLess portable due to direct hardware access
CommunicationMessage passing between user-space serversDirect function calls within kernel
PerformanceLower due to message passing and more overheadHigh due to direct function calls and less overhead

Conclusion

In summary, monolithic kernels are characterized by their tight integration of system services and high performance, while microkernels are characterized by their modularity, simplicity, and security. The choice between a monolithic and microkernel architecture depends on the specific needs and requirements of the operating system being developed.


Next Article
Monolithic Kernel and Key Differences From Microkernel

A

akash1295
Improve
Article Tags :
  • Operating Systems

Similar Reads

    Difference Between Microkernel and Monolithic Kernel
    In the world of operating systems, the terms "microkernel" and "monolithic kernel" describe two different ways of organizing and managing the core functions of a computer's operating system. The kernel is a computer program at the core of a computer's operating system and has complete control over e
    5 min read
    Difference between Micro Kernel and Modular Kernel
    Prerequisite - Kernel in Operating System 1. MicroKernel:Micro Kernel, as the name suggests, is basically a software or code that usually contains a minimum number of functions that are required, data, and features simply to implement OS. It is a very small kernel and represents well studied OS stru
    3 min read
    Difference Between User Mode and Kernel Mode
    User mode and kernel mode are two working states inside a laptop's working system that determine the level of access and control, a technique can have over machine resources. Understanding the differences among these modes is critical to knowing how modern working systems manage safety and resource
    5 min read
    Difference between Operating System and Kernel
    In the world of computing, two terms that are frequently mentioned are Operating System (OS) and Kernel. In this article, we will explore the key differences between the OS and the Kernel, their functions, and how they work together to manage hardware and software.What is an Operating System?An Oper
    3 min read
    Difference between Shell and Kernel
    In computing, the operating system (OS) serves as the fundamental layer that bridges the gap between computer hardware and the user. Two critical components of an operating system are the kernel and the shell. Understanding the relationship between these two components is fundamental to grasping how
    4 min read
geeksforgeeks-footer-logo
Corporate & Communications Address:
A-143, 7th Floor, Sovereign Corporate Tower, Sector- 136, Noida, Uttar Pradesh (201305)
Registered Address:
K 061, Tower K, Gulshan Vivante Apartment, Sector 137, Noida, Gautam Buddh Nagar, Uttar Pradesh, 201305
GFG App on Play Store GFG App on App Store
Advertise with us
  • Company
  • About Us
  • Legal
  • Privacy Policy
  • In Media
  • Contact Us
  • Advertise with us
  • GFG Corporate Solution
  • Placement Training Program
  • Languages
  • Python
  • Java
  • C++
  • PHP
  • GoLang
  • SQL
  • R Language
  • Android Tutorial
  • Tutorials Archive
  • DSA
  • Data Structures
  • Algorithms
  • DSA for Beginners
  • Basic DSA Problems
  • DSA Roadmap
  • Top 100 DSA Interview Problems
  • DSA Roadmap by Sandeep Jain
  • All Cheat Sheets
  • Data Science & ML
  • Data Science With Python
  • Data Science For Beginner
  • Machine Learning
  • ML Maths
  • Data Visualisation
  • Pandas
  • NumPy
  • NLP
  • Deep Learning
  • Web Technologies
  • HTML
  • CSS
  • JavaScript
  • TypeScript
  • ReactJS
  • NextJS
  • Bootstrap
  • Web Design
  • Python Tutorial
  • Python Programming Examples
  • Python Projects
  • Python Tkinter
  • Python Web Scraping
  • OpenCV Tutorial
  • Python Interview Question
  • Django
  • Computer Science
  • Operating Systems
  • Computer Network
  • Database Management System
  • Software Engineering
  • Digital Logic Design
  • Engineering Maths
  • Software Development
  • Software Testing
  • DevOps
  • Git
  • Linux
  • AWS
  • Docker
  • Kubernetes
  • Azure
  • GCP
  • DevOps Roadmap
  • System Design
  • High Level Design
  • Low Level Design
  • UML Diagrams
  • Interview Guide
  • Design Patterns
  • OOAD
  • System Design Bootcamp
  • Interview Questions
  • Inteview Preparation
  • Competitive Programming
  • Top DS or Algo for CP
  • Company-Wise Recruitment Process
  • Company-Wise Preparation
  • Aptitude Preparation
  • Puzzles
  • School Subjects
  • Mathematics
  • Physics
  • Chemistry
  • Biology
  • Social Science
  • English Grammar
  • Commerce
  • World GK
  • GeeksforGeeks Videos
  • DSA
  • Python
  • Java
  • C++
  • Web Development
  • Data Science
  • CS Subjects
@GeeksforGeeks, Sanchhaya Education Private Limited, All rights reserved
We use cookies to ensure you have the best browsing experience on our website. By using our site, you acknowledge that you have read and understood our Cookie Policy & Privacy Policy
Lightbox
Improvement
Suggest Changes
Help us improve. Share your suggestions to enhance the article. Contribute your expertise and make a difference in the GeeksforGeeks portal.
geeksforgeeks-suggest-icon
Create Improvement
Enhance the article with your expertise. Contribute to the GeeksforGeeks community and help create better learning resources for all.
geeksforgeeks-improvement-icon
Suggest Changes
min 4 words, max Words Limit:1000

Thank You!

Your suggestions are valuable to us.

What kind of Experience do you want to share?

Interview Experiences
Admission Experiences
Career Journeys
Work Experiences
Campus Experiences
Competitive Exam Experiences