Chapter 13. Miscellaneous recipes 191
To enter a rescue environment, initiate an interactive Linux installation. Perform the following
steps to enter a rescue environment on the LINUX03 user ID:
1. Logon to LNXMAINT. Copy the RHEL5 EXEC file to a new file named RESCUE EXEC, and copy the
user’s PARM-RH5 file to a new file (LINUX03 RESCUE, in this example):
==> copy rhel52 exec d rescue = =
==> copy linux03 parm-rh5 d = rescue =
2. Next, edit RESCUE EXEC to point to the new LINUX03 RESCUE file:
==> xedit RESCUE EXEC
...
00005 'PUN RHEL52 KERNEL * (NOH'
00006 'PUN' userid() ' RESCUE * (NOH'
00007 'PUN RHEL52 INITRD * (NOH'
...
==> file
3. Edit the LINUX03 RESCUE file, replacing any kickstart or VNC lines with the rescue
command line option:
==> xedit LINUX03 RESCUE
ramdisk_size=40000 root=/dev/ram0 ro ip=off
CMSDASD=191 CMSCONFFILE= LINUX03.CONF-RH5
rescue
4. Now logoff from LNXMAINT and logon to LINUX03. Respond no to the IPL from DASD
question, and run RESCUE EXEC.
==> rescue
Linux version 2.6.18-92.el5 (brewbuilder@spark.z900.redhat.com) (gcc version 4.1
.2 20071124 (Red Hat 4.1.2-41)) #1 SMP Tue Apr 29 13:16:58 EDT 2008
We are running under VM (64 bit mode)
Detected 4 CPU's
Boot cpu address 0
Built 1 zonelists. Total pages: 524288
Kernel command line: ramdisk_size=40000 root=/dev/ram0 ro ip=off
CMSDASD=191 CMSCONFFILE=Z12.conf
rescue
...
The install process directs you to telnet or SSH to the IP address of your Linux server to
begin the first stage of the installation.
5. Use SSH to connect and log in as root. After choosing the language, the rescue
environment will prompt you for the location of the rescue image, which is located in the
install tree on the controller.
6. Choose NFS image, then enter the IP address or host name of the controller and the path
/nfs/rhel5.2
7. The rescue image will search for your Linux installation and will prompt you to mount the
partitions it finds. When prompted, select Continue to mount the partitions. After this, you
will be presented with a shell prompt. Because you chose to mount your root partition, it
will be automatically mounted to the /mnt/sysimage directory.
You can use the chroot command to run an interactive bash shell from the /mnt/sysimage
directory. To do this, run the following command:
sh-3.2# chroot /mnt/sysimage /bin/bash
The /bin/bash argument instructs chroot to run the bash shell after changing the root
directory to /mnt/sysimage. From the chroot shell, the system appears almost exactly as it
would if it were running (the only difference is that, because udev is not running, there may
Comentarios a estos manuales