In this video we will see operating system structure. There are two common structures
monolithic structure and microkernels.
An operating system typically contains scheduling, memory management and system call interface etc
.
In monolithic system structure, the entire operating system runs as a large executable program in kernel mode.
So we can think all these modules as a single one. In this system structure, calling any function is simple
.
All we need to do is find the correct function which we need and call that function.
So it is direct communication between modules and calling any function is efficient.
But free to call any function without restrictions makes the system hard to maintain and any module having errors will affect
the entire operating system.
For example, if we encounter an error in memory management module, we will halt the whole system.
Another structure is microkernel structure. In this structure, operating system is divided into small modules
which runs in user mode.
As you can see, the modules run as separate processes in the user mode.
The microkernel which schedules processes,
manage communications between these processes are running in the kernel mode.
So the kernel is really small.
Any error in those modules will only affect themselves and will not crash the whole system.
In this course, we will write a monolithic kernel. The main reason is that the kernel we will write
is really small and implementing a monolithic kernel is easy to understand and simple to do comparing to microkernel
.
In the next lecture, we will start writing our own operating system. See you in the next section.