首页 > 系统服务 > 详细

Linux Kernel: Introduction and Booting

时间:2015-04-20 00:24:24      阅读:374      评论:0      收藏:0      [点我收藏+]

 

1. Computer System Review

  To begin with, we should have a refresher on the skeleton of a computer system, especially the Operating System:

 

技术分享

 

 

2. Overview of Linux Kernel

  What we learn here is Linux 0.11, which is a modular, UNIX-like, monolithic kernel. The major tasks of a kernel includes Process Management, Memory Management, Device Management, supporting System Calls and so forth.

技术分享

 

   The following picture is the layout of Linux Source Tree:

技术分享

 

3. Booting Procedure

  When the computer is tuned on, CPU will jump to memory 0xFFFF0 (the address of BIOS), and run a Power-On Self Test (POST) of BIOS. After that, once a bootale device is found, BIOS will extract the Master Boot Record (MBR) from the first sector (512B) of the hard disk into memory 0x7C00, and then transfer control to the boot loader, the first 446B of the MBR followed by the Partition Table.

  GNU GRUB is an operating system independent boot loader.The 1st stage of GRUB boot process lies within MBR, and its task is just to load GRUB stage 1.5, which immediately follows MBR and contains file sytem drivers. Then GRUB stage 2 will be loaded by stage 1.5, and will display boot menu to the user. Finally, GRUB will load the user-selected (or default) kernel into memory and pass on control to the kernel.

  Once the kernel has finished all the initialization, it will create the init process (pid = 1), which is the root of all processes running on Linux. The init process will start various processes according to the run-level, and typically create instances of "getty" to spawn user‘s shell process. Besides creating more processes, another task of the init process lies in the system shutdown.

 

Linux Kernel: Introduction and Booting

原文:http://www.cnblogs.com/DevinZ/p/4433693.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!