I. Preparation of knowledge
1. ISO documents
Our commonly used ISO file refers to the entire CD-ROM (ISO-9660 file system) content
The image is a complete copy of the entire disc from the 0 sector to the last sector, and is often used for transmission over the network.
For ISO files we can:
1) Burn to Disc
2 use Winrar,magiciso and other software to view or release its contents under Windows
3 under a Linux system, mount the mount command to load a directory for example:
Mount-t Iso9660-o Loop./cdimg.iso/mnt/test
2. Representation of Linux partitions
The way Linux identifies a hard disk is different from Windows, and if you're using an IDE hard disk, your first hard drive is labeled/dev/hda second for/dev/hdb and so on;
And the first partition of the first hard disk is identified as/dev/hda1 the second partition is/dev/hda2 and so on;
If it is a SCSI hard drive, it is the form of/dev/sda,/dev/sdb and/dev/sda1,/dev/sda2.
In addition, Linux uses 1-4 to identify the primary partition of the hard disk, 5 and 5 represents the logical partition of the extended partition
A typical Windows system has only one primary partition C: and logical partitions for several extended partitions
So C: It corresponds to/DEV/HDA1, and D: it jumps to/dev/hda5.
3. root file System
Linux does not manage the file system as a partition as Windows does, it takes the root form:
A unique root directory \ "/\", where all the files and other directories on the system are built under it
Like a tree, starting from the only root, and increasing the length of the leaves
and windows like a forest, each partition is a tree
4. Loadlin procedure
Loadlin is a program specifically designed to boot Linux in a DOS environment, with the Linux kernel
The location of the image's file and the location of the root file system are the main parameters, such as
C:> Loadlin C:\\vmlinuz Root=/dev/hda2
The above command loads the Linux kernel image file Vmlinuz and mounts the root partition to start Linux
5. Vmlinuz and initrd.img documents
Vmlinuz is a mirrored file of the Linux kernel that can be loaded by the bootstrapper to start the Linux system
INITRD----Boot loader initialized RAM disk (full name)
is a way to start a Linux system
The current popular version of Linux is typically a modular kernel, which can be implemented without recompiling the build kernel
Add functional Modules
But if your Linux root file system is on a device driven by a module (not compiled into the kernel image)
, it cannot be loaded directly by a bootstrapper (for example, Loadlin)
This will be a initrd way to start your Linux system.
This approach consists of two stages:
1 Create a temporary root file system on a RAM disk that contains the drive modules you need on this RAM disk
2 Load the required drive module, mount the actual root file system, start Linux
And initrd.img is the image of RAM disk.
The Linux root file system does not exist until the Linux system is installed, and INITRD is also used
Way, this is the case for Loadlin
C:> Loadlin Autoboot\\vmlinuz initrd=autoboot\\initrd.img
This is where we want to specify the location of the INITRD mirrored file.
And it's no longer the root file system location.