< Day Day Up > |
If your system uses certain block devices unsupported by the kernel, such as some SCSI, RAID, or IDE devices, you will need to load certain required modules when you boot. Such block device modules are kept on a RAM disk that is accessed when your system first starts up (RAM disks are also used for diskless systems). For example, if you have a SCSI hard drive or CD-ROMs, the SCSI drivers for them are often held in modules that are loaded whenever you start up your system. These modules are stored in a RAM disk from which the startup process reads. If you create a new kernel that needs to load modules to start up, you must create a new RAM disk for those modules. You need to create a new RAM disk only if your kernel has to load modules at startup. If, for example, you use a SCSI hard drive but you incorporated SCSI hard drive and CD-ROM support (including support for the specific model) directly into your kernel, you don't need to set up a RAM disk (support for most IDE hard drives and CD-ROMs is already incorporated directly into the kernel).
If you need to create a RAM disk, you can use the mkinitrd command to create a RAM disk image file. The mkinitrd command incorporates all the IDE, SCSI, and RAID modules that your system uses, including those listed in your /etc/modules.conf file. See the Man pages for mkinitrd and RAM disk documentation for more details. mkinitrd takes as its arguments the name of the RAM disk image file and the kernel that the modules are taken from. In the following example, a RAM disk image called initrd-2.4.22-1.img is created in the /boot directory, using modules from the 2.4.22-1 kernel. The 2.4.22-1 kernel must already be installed on your system and its modules created.
# mkinitrd /boot/initrd-2.4.22-1.img 2.4.22-1
You can select certain modules to be loaded before or after any SCSI module. The --preload option loads before the SCSI modules, and --with loads after. For example, to load RAID 5 support before the SCSI modules, use --preload=raid5:
mkinitrd --preload=raid5 raid-ramdisk 2.4.22-1
In the grub.conf segment for the new kernel, place an initrd entry specifying the new RAM disk:
initrd /boot/initrd-2.4.22-1.img
< Day Day Up > |
This HTML Help has been published using the chm2web software. |