Linux Boot process
In this section, we will see how the linux system boots. When we start the system, below sequence of events occur.
- Read BIOS and see the boot device(CD ROM, USB or hard disk).
- Try to locate the MBR (Master Boot Record) in boot device.
- MBR contains the GRUB which stores the details of the kernels available for booting.
- If there are multiple operating systems installed on your system, GRUB (also called as boot loader) displays the list of them and finally reads the selected kernel of the OS.
- Kernel executes init process and then starts various other services.
- Finally login prompt is displayed if the password is set for the user.
While executing above steps, below files are used in the process.
- /boot/grub/grub.conf – stores details about kernels
- /sbin/init – first process started in linux
- /etc/inittab – defines run levels of the system
Also note that init is the first process started by kernel. init process keeps running in the background as long as system is up and running. So it is also called as daemon process.