Friday, January 11, 2013

Difference between Monolithic and Microlithic kernels





Micro kernel and Monolithic kernels
As the name suggest mono means everything put together in one huge unit that is called the monolithic. Monolithic kernel contains all of the services like process management, file management, Scheduler, Virtual memory etc are in kernel space.

On the other hand, in Microlithic kernel only small portion of basic services(lets call them primitive services) are put into kernel space and remaining services goes to the user space. The user space facilities are called as servers.
When any request comes which cannot be served by the kernel( remember in cases of micro kernel, kernel space contains essential of essential services), the primitive kernel passes the message to the related server, which in turn would gets the requested work done.

Below are the main difference.

1) Memory management : In case of Mono kernel everything in the kernel space. Micro kernels only keeps the basic of the facility in kernel code and remaining is implemented in the user space.

2) Security and stability : Say if one of the process crashes in process management module; then, in case of monolithic kernel whole system goes down.
But in case of micro, we still have a chance that kernel will be active as most of the work is done in user address space. One more fact is that lesser the code in the kernel space easy its to maintain to write the tighter code.

3) I/O: Even in mono kernels, the concept of module loading/unloading was present. Prime example was device driver. But, its still hardwired with the kernel. So, it means the module working with the generation A mono kernel may not work with generation B mono kernel. You can load/unload a device driver but you cannot replace A with B.
Micro kernel makes it easy, As kernel simply passes the message to the server, and then its expects results. It doesn't matter to the primitive kernel how work is getting done in server code. Driver manger pass the information to the related driver module. You can simply replace the driver manger without affecting the system.

4) Extensibility and Portability :
Beside size the extensibility is the most important factor of micro kernel. Adding new features to a monolithic system means recompilation of the whole kernel, often including the whole driver infrastructure. e.g. If you have a new memory management routine and want to implement it into a monolithic architecture, modification of other parts of the system could be needed. In case of a micro kernel the services are isolated from each other through the message system. It is enough to re-implement the new memory manager. The processes which formerly used the other manager, do not notice the change. micro kernels also show their flexibility in removing features . That way a micro kernel can be the base of a desktop operating system and as well as of real time appliances in single chip systems.

Example
Mono Kernels : Linux
Micro : QNX the real time Operating system

3 comments:

diwakar said...

thanks alot!!!!!!!!!!!! it was really useful

Unknown said...

Great answerπŸ‘πŸ‘πŸ‘πŸ‘

Unknown said...

Great answerπŸ‘πŸ‘πŸ‘πŸ‘