Hello, everyone, and welcome to this video.
So in this video, we are going to see the Linux boot process.
Now, every one of you must be knowing that whenever we press the power button, our computer gets started.
But what's actually happening behind the hood in the background is very important to know and understand.
That is the reason we are going to understand the Linux boot process and how a system actually starts.
So it follows six high level steps in the boot process.
And we are going to understand each one of them, one by one, in-depth.
So let's begin with the first one, which is BIOS.
So BIOS stands for basic input output system, which executes the MBR.
The second one is MBR, which stands for Master Boot Record, which then executes the grub.
The full form of grub is Grand Unified Bootloader, which then in turn execute the kernel.
Next is the kernel, which is also known as the heart of the computer, which executes the spin and
the in IT programs.
Next is in it, which is also known as initialization, which executes the run level programs into the
Linux system.
The next one is the run levels.
Now, run level are the programs which are executed from this directory, which is slash etsi, slash
RC, dot D, slash RC one dot rd, rc two dot rd, which has been demonstrated here with RC star dot
D.
Now run levels are those levels in which the Linux system will boot.
For example, there are multiple run levels which start from one level zero to run level six, which
we are going to understand in the later part of the lesson.
Now let's quickly understand what is bias.
As we have learned, the full form of bias is basic input output system.
Now, what does actually the BIOS does?
It performs the integrity checks.
It also searches, loads and executes the bootloader program.
Now, whenever you start your computer bios quickly checks for all the CD, DVDs, SD cards and the
hard disk drives which have been attached to your computer.
It also checks the boot sequence.
Now, if you want to modify the boot sequence, you can press the keys, which is F2, L or F2.
And it may also vary based on your system.
The next one is the MBR, which stands for the Master Boot Record.
Now the NBA is located into the first sector of the bootable disk.
It is usually into this path which is slash dev slash SDA, where dev steps for device or sometimes
it's in slash dev slash HD.
This is the first sector of the bootable disk.
Now it is always less than 512 bytes in size and it has three major components.
As you can see onto the right hand side of the screen, the first four, four, six bytes are being
assigned to the primary bootloader info.
The next 64 bytes have been assigned to the partition table and the last two bytes are given to the
grub, which we are going to see the next.
So what does GRUB stands for and what is the importance of it?
So GRUB stands for Grand Unified Bootloader.
Now it chooses the kernel image to load and it executes it later on.
It is like a splash screen onto your computer which execute the default kernel images from your computer.
You can have multiple kernel images like kernel one, kernel two, kernel three.
That can be different operating systems like Kali, Bharat or RedHat.
So it loads and executes the kernel and gives you the opportunity to load into a specific operating
system.
The next is the colonel, which is also known as the heart of the computer.
It execute the has been slash in it and there are multiple system programs which get executed into the
step.
Now the kernel mounts the root file system into the grub configuration file, which has been specified.
It also executes the initialized programs, which is located into the S-pen folder, which is the system
in folder.
And finally, it loads the file system of the operating system.
Next is the init.
So init executes the run level programs.
Now you may think what are the run levels?
You're going to understand the run levels in next couple of seconds.
So init decides in which run level your system needs to be booted.
It also decides the programs to be loaded when your computer starts.
So coming to the run level, how many are there?
As you can see onto your screen in the right hand side.
There are different rent levels which starts from one level zero run level one to run level six.
Now, whenever your system boots, it goes into a fixed run level, which is the run level three, which
is multi user plus networking.
Let's understand all the run levels one by one.
So what does the run level zero stands for?
It stands for shut down or halt, which means onto your computer into a terminal.
If you type run level zero, then your computer is going to shut down.
Now, you cannot type the command run level.
You have to take the command, which is in it zero, which gives the instruction to your computer that
the user wants to go into the run level, which is zero.
So the command is in it, which stands for initialize the run level zero.
The next is run level one.
Now if you type in it one into your terminal, you're going to go into a single user mode without networking.
That means only one user can now use the system and there will be no Internet.
Next is the level two, which is multiple users with no networking run level three is the default run
level into which any operating system boot, which is the multi user plus networking.
Now this is the level which every one of us gets by default.
Booted in within multiple users can be switched as well as we have the network access.
Next one is the run level four, which is undefined and which is used for research and development purposes.
The next is the run level five.
Now a run level five works exactly as run level three, which is multi user plus networking with X11
protocol support.
Now X11 protocol is a display GUI protocol which is used to enhance the operating system.
And the last one is the run level six, which is used to reboot or restart the system.
So onto your terminal if you type in it six, which means you are given the instruction to initialize
the run level six, your computer will automatically restart.
So now we have completed the run levels, which is the level 0123, four, five, six respectively.
Now, as we have also understood, the run levels and the programs that are executed from this directory,
which is slash ETSI, slash RC D slash RC one dot D, RC two point D and so on.
We have also understood how the system executes program based on fixed run levels.
We have also understood the directories of these programs.
Now, one important thing to remember over here is the programs that start with SSE into those directories
are used for start up and the programs which start with K are used for shutdown.
Now why K?
Because K stands for kill.
I hope you guys understood that.
What are the run levels and how the Linux boot process functions?
If you have any questions or queries, you can always post it into the Q&A.
Thank you.