The PXE boot:

The Pre-boot eXecution Environment allows the computer to query the network, when it is not set up to use a hard drive to boot the operating system.

It queries the DHCP server which responds with an IP address and a boot file with a TFTP location from which the computer could retrieve the boot image.


The boot image contains the Linux kernel.
PXE loads the boot image into memory and boots from it.

The iPXE is an improved version that allow us to use HTTP instead of the TFTP protocol to get the boot file.
After the GRUB starts, we could select the kernel to boot from. 

Remark:

We can also edit the boot configuration by hitting <e>  at the menu boot.
Sometimes we don't see the boot menu unless we hit the <SHIFT> or the <Esc> while the machine is booting.

The boot process:


UEFI start GRUB which runs a code that points us to the Linux kernel "vmlinux" or "vmlinuz". 
The "z" at the end of "vmlinuz" image means that it is a compressed kernel.

After the kernel boots, it will mount all the filesystems, then it will load al the modules from the hard drive.

Remark:

The modules are not part of the kernel

initrd:

initrd or initial ramdisk gives the necessary information about the modules and the drivers to allow the kernel to access the filesystem so it could load the modules from there.

initramFS:

The initramFS or the initial RAM filesystem, is a part of the kernel.
It is a program that creates a filesystem and mounts it into memory.

It allows the system to temporarily have access to a root filesystem until it gets to the stage where it can load the full kernel with its modules.

The "/boot" folder:

In the "/boot" folder we can find the initrd file and also the kernel file "system.map" that  tells the kernel where all its modules are located.
The config file show the configuration with which the kernel was compiled
The kernel modules are located in the "/lib/module/$(uname -r)" directory.
Brando Sabatini and Ikbal C ©. Powered by Blogger.