How to use rescue mode without CD/DVD installation media?
Environment
- Red Hat Enterprise Linux 4
- Red Hat Enterprise Linux 5
- Red Hat Enterprise Linux 6
- rescue mode
Issue
- How to use
rescuemode without CD/DVD installation media?
Resolution
- In some environment, there is neither CD-ROM nor installation CD/DVD. Maybe there is only an ISO image file in the system, at least one can download it from RHN.
- Using ISO image can use
rescuemode as well. - Use Red Hat Enterprise Linux 5 update 5 as an example:
1. Mount ISO image:
# mount -o ro,loop /path/to/RHEL5u5.iso /media
2. Copy vmlinuz and initrd file to /boot directory:
# cp /media/isolinux/vmlinuz /boot/rescue-vmlinuz
# cp /media/isolinux/initrd.img /boot/rescue-initrd.img
3. Host the DVD iso using http source at some location as per given in solution 7227. For example, the location to the installation tree is http://192.168.122.256/rhel/
4. Add a new "title" in /boot/grub/grub.conf file:
title Red Hat Enterprise Linux Server Rescue Mode
root (hd0,0)
kernel /rescue-vmlinuz linux rescue repo=http://192.168.122.256/rhel/
initrd /rescue-initrd.img
5. Reboot the system and choose the new "title" to start up.
Important Note
- Without installation tree, Red Hat Enterprise Linux 5/6 can't move further in
rescuemode, the filesrescue-vmlinuz/vmlinuzandrescue-initrd.img/initrd.imgwill be helpful to boot into rescue mode but to mount the installed RHEL, therescuemode needs the installation trees which can get taken from the DVD iso itself, so one need to provide therescue imagethrough NFS/FTP/HTTP/URL/Local Media/CDROM/Hard-disk medium. - See this documentation link, it mentions the following.
You are prompted to answer a few basic questions, including which language to use. It
also prompts you to select where a valid rescue image is located. Select from Local
CD-ROM, Hard Drive, NFS image, FTP, or HTTP. The location selected must contain
a valid installation tree, and the installation tree must be for the same version of Red
Hat Enterprise Linux as the Red Hat Enterprise Linux disk from which you booted.
If you used a boot CD-ROM or other media to start rescue mode, the installation tree
must be from the same tree from which the media was created. For more information
about how to setup an installation tree on a hard drive, NFS server, FTP server, or
HTTP server, refer to the earlier section of this guide.
- So installation media is required through any available means to have full fledged
rescue mode
Product(s)
Components
Category
This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.