1 00:00:00,540 --> 00:00:07,380 In this video we will see operating system structure. There are two common structures 2 00:00:07,380 --> 00:00:08,670 monolithic structure and microkernels. 3 00:00:08,670 --> 00:00:16,560 An operating system typically contains scheduling, memory management and system call interface etc 4 00:00:16,560 --> 00:00:17,310 . 5 00:00:19,280 --> 00:00:26,930 In monolithic system structure, the entire operating system runs as a large executable program in kernel mode. 6 00:00:26,930 --> 00:00:34,790 So we can think all these modules as a single one. In this system structure, calling any function is simple 7 00:00:34,790 --> 00:00:35,420 . 8 00:00:35,630 --> 00:00:40,350 All we need to do is find the correct function which we need and call that function. 9 00:00:41,030 --> 00:00:48,560 So it is direct communication between modules and calling any function is efficient. 10 00:00:48,560 --> 00:00:55,430 But free to call any function without restrictions makes the system hard to maintain and any module having errors will affect 11 00:00:55,430 --> 00:00:57,200 the entire operating system. 12 00:00:57,890 --> 00:01:03,650 For example, if we encounter an error in memory management module, we will halt the whole system. 13 00:01:04,879 --> 00:01:12,080 Another structure is microkernel structure. In this structure, operating system is divided into small modules 14 00:01:12,080 --> 00:01:13,360 which runs in user mode. 15 00:01:13,970 --> 00:01:18,370 As you can see, the modules run as separate processes in the user mode. 16 00:01:19,320 --> 00:01:22,660 The microkernel which schedules processes, 17 00:01:22,690 --> 00:01:26,320 manage communications between these processes are running in the kernel mode. 18 00:01:26,960 --> 00:01:28,610 So the kernel is really small. 19 00:01:29,360 --> 00:01:34,420 Any error in those modules will only affect themselves and will not crash the whole system. 20 00:01:35,730 --> 00:01:41,610 In this course, we will write a monolithic kernel. The main reason is that the kernel we will write 21 00:01:41,610 --> 00:01:48,300 is really small and implementing a monolithic kernel is easy to understand and simple to do comparing to microkernel 22 00:01:48,300 --> 00:01:49,230 . 23 00:01:50,340 --> 00:01:56,250 In the next lecture, we will start writing our own operating system. See you in the next section.