To rescan an entire SCSI bus and re-register all devices found:
When dealing with fibre attached storage, it is necessary to issue a LIP (loop initialization primitive) on the fabric:
shell> echo "1" > /sys/class/scsi_device/0\:0\:0\:0/device/rescan
shell> echo "1" > /sys/class/fc_host/host#/issue_lip
Replace the “#” with the number of the SCSI bus to be rescanned.
Note: Issueing a LIP (above) on Red Hat Enterprise Linux 5 is all that is needed to rescan fibre
attached storage. Once the LIP is issued, the bus scan may take a few seconds to complete.
To rescan all other SCSI attached storage, a rescan should be issued:
shell> echo "- - -" > /sys/class/scsi_host/host#/scan
Replace the “#” with the number of the SCSI bus to be rescanned.
1) Extract
mv initrd.img initrd.img.xz
xz --format=lzma initrd.img.xz --decompress
mkdir initrd-new
cd initrd-new
cpio -ivdum < ../initrd.img
2) Add/delete/modify files
3) Build
find . -print |cpio -o -H newc | xz --format=lzma > ../initrd.img