手动创建系统启动镜像文件:initrd.img
有时候为了能让某些模块提前加载,修改系统启动引导文件可能是唯一方法;下面是从网上摘录的提前加载multipath所需模块并提前启动multipath的过程;大体上分四步;
步骤一:创建新的启动文件
mkinitrd
--with=scsi_dh_rdac --with=dm-mod --with=dm-multipath --with=dm-round-robin
initrd-`uname -r`.img `uname -r`
步骤二:抽取这些文件
Extract the
initrd image to a temp directory
#mkdir temp
#cd temp
#gzip -dc ../initrdmp.gz | cpio -id
步骤三:修改部分内容
Copy
multipath.conf to the initrd image
#cp /etc/multipath.conf temp/etc/
步骤四:重新打包文件
Repackage the
initrd image
#find ./ | cpio -H newc -o > ../initrdmp
#gzip initrdmp
#cp initrdmp.gz /boot/
要想在系统启动时自动选择引导文件,还需要修改grub.conf文件;
[root@racdb ~]# vi /boot/grub/grub.conf
#