nixCraft Linux Forum

nixCraft

Linux Tech Support Forum

Is Linux kernel is monolithic or modular kernel?

This is a discussion on Is Linux kernel is monolithic or modular kernel? within the Linux software forums, part of the Linux Getting Started category; IS Linux kernel is monolithic or compiled and statically linked modular kernel? I am bit confused on this – Linux ...


Go Back   nixCraft Linux Forum > Linux Getting Started > Linux software

Register FAQ Members List Calendar Forgotten your password? Mark Forums Read
  #1 (permalink)  
Old 06-02-2005, 02:03 PM
Member
User
 
Join Date: Feb 2005
Posts: 66
Rep Power: 0
chiku
Default Is Linux kernel is monolithic or modular kernel?

IS Linux kernel is monolithic or compiled and statically linked modular kernel?

I am bit confused on this – Linux is Monolithic kernel or it is a compiled and statically linked traditional UNIX like modular kernel?

How do I find out running Linux kernel is Monolithic or modular kernel?

It will be nice if someone point out to good Linux kernel books, or some other online resources too
__________________
There's no place like 127.0.0.1
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 06-02-2005, 04:08 PM
rockdalinux's Avatar
Contributors
User
 
Join Date: May 2005
Location: Bangalore
My distro: RHEL, HP-UX, Solaris, FreeBSD, Ubuntu
Posts: 581
Rep Power: 7
rockdalinux is a jewel in the rough rockdalinux is a jewel in the rough rockdalinux is a jewel in the rough rockdalinux is a jewel in the rough
Default

Quote:
IS Linux kernel is monolithic or compiled and statically linked modular kernel?
It can be compiled as both!

Monolithic kernel
- Single binary file
- All drivers included in kernel itself

Modular kernel
- Multiple files for kernel
- Drivers can be loaded or unloaded into kernel using modprob command, see man page of
lsmod, modprob etc
- Almost all drivers are build and linked against kernel

You can built modular kernel by setting option in kernel configuration option:
Enable loadable module support (CONFIG_MODULES) [Y/n/?]
If you set above option to Y then kernel becomes modular and three possibilities occurs for each and every feature/driver:
m - you can compile driver as module
y - built into kernel itself
n - Don't include feature/driver

Note if you set option to (CONFIG_MODULES) to n (no) then kernel becomes Monolithic and two possibilities occurs for each and every feature/driver:
y - Include feature/driver
n - Don't include feature/driver

Quote:
I am bit confused on this – Linux is Monolithic kernel or it is a compiled and statically linked traditional UNIX like modular kernel?
See above

Quote:
How do I find out running Linux kernel is Monolithic or modular kernel?
You can see kernel configuration file or you can type command (To see CONFIG_MODULES option)
make xconfig
make menuconfig

If the file /etc/modules.conf and modutils (such as lsmod, modprob) are installed then it is safe to assume that you have modular kernel. Most modern disto comes with modular kernel.

Quote:
It will be nice if someone point out to good Linux kernel books, or some other online resources too
Books
Linux Kernel Programming (3rd ed.). Addison Wesley, 2002.
Linux Core Kernel Commentary. The Coriolis Group, LLC, 1999.
IA-64 Linux Kernel: Design and Implementation. Prentice Hall, Inc
Linux Device Drivers (2nd ed.). O'Reilly & Associates, Inc.
Linux IP Stacks Commentary. The Coriolis Group, LLC
WWW Links

www.tldp.org has some docs
www.google.com/linux search you should get tons of info/doc
Reply With Quote
  #3 (permalink)  
Old 06-02-2005, 04:40 PM
monk's Avatar
Senior Member
User
 
Join Date: Jan 2005
Location: Tibet
My distro: Debian GNU/Linux
Posts: 482
Rep Power: 5
monk will become famous soon enough monk will become famous soon enough
Default

Some reasons to use Monolithic kernel

Kernel will be faster as less code will be included and no kernel parts will not swapped to virtual memory, modules are slower

More stable as unnecessary drivers/features not included, so attacker cannot take advantage of unused stuff in kernel.

However, many supports modular as best choice because you don't have to recompile the kernel to include support for your new devices ... it is upto you which one satisfies your needs

For server -- Monolithic is good choice
Desktop - Modular is good as we connect pen drives, dig-cam, scanners and so on..

Feel free to search newsgroup using http://groups-beta.google.com/grphp?hl=en&tab=wg for more on this topic
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads

Thread Thread Starter Forum Replies Last Post
Linux kernel deleted from /boot - how do I resinstall the kernel vaibhav.kanchan Getting started tutorials 2 03-25-2008 01:31 AM
Display Linux kernel information sweta Getting started tutorials 0 07-27-2007 08:00 AM
Yum install kernel debuginfo packages kernel-debuginfo repo rockdalinux Getting started tutorials 0 06-15-2007 10:59 PM
What are the advances of Kernel 2.6 over Kernel 2.4 ricc Linux software 3 03-14-2006 01:42 PM
Linux find out kernel version? Linux software 1 01-17-2006 05:41 PM


All times are GMT +5.5. The time now is 10:49 PM.


Powered by vBulletin® Version 3.7.4 - Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36