 |
» |
|
|
 |
If your system
should become so compromised or corrupt that it will not boot at
the login prompt, or the system boots, but critical files are corrupted,
adversely affecting overall system performance, it may be useful
to restore system elements with core recovery media. Before you attempt to recover an HP-UX system, you should
have the following information about your system disk available. Much of this information, including file system types, can
be obtained by accessing your on-line system manifest, either via
Ignite-UX, or by reading the hardcopy that came with your system The hardware path of the root filesystem on the
disk (that is, what file system you will be checking/repairing using fsck). The address of the bootlif path of that disk. What the autofile in the bootlif should contain. Whether you have an LVM, VXVM, or whole-disk system.
The more you know about the system disk and its partitioning
scheme, before you encounter major damage or corruption,
the easier it will be for you to recover. The procedures which follow assume that both fsck and mount can be run successfully on the system disk; otherwise,
the following procedures are not applicable. Automated
Recovery Procedures |  |
There
are four possible expert recovery situations, each of which has
its associated recovery procedure: If, after a system problem, you can't
get the system to the ISL> prompt from the system disk, you will want to
rebuild the bootlif on the system disk, and install all critical
files required to boot on the root filesystem. If you can get the system to the ISL> prompt, but cannot boot vmunix, the system disk is corrupted; you will want to
install only the critical files required to
boot on the root filesystem. If you can't get to the ISL> prompt, but you know that the root file system
is good, you will want to rebuild the bootlif on the system disk. If you believe your kernel is corrupted, you will
want to replace only the kernel on the root filesystem.
The following subsections describe these procedures in detail. Rebuilding
the bootlif and Installing Critical Files |  |
Following is an example of the detailed procedure for rebuilding
the bootlif of the system disk, and for installing all the critical
files necessary to boot from the root filesystem: Have the Core OS CD for the appropriate HP-UX
ready. Reset the System Processor Unit (SPU) using the reset
button, or keyswitch, as appropriate. The console displays boot path information. If Autoboot is
enabled, the system console eventually displays messages similar
to this: Autoboot from primary path enabled To override, press any key within 10 seconds. With older systems, press any key within 10 seconds.
The system console displays: Boot from primary boot path (Y or N)?> Enter n at the prompt. The next prompt is: Boot from alternate boot path (Y or N)?> If the alternate boot path specifies the address of
the CD device where the Core CD is mounted, enter: y If the alternate boot path does not specify the address of
the CD device where the HP-UX Core media is mounted, enter n at the prompt. The next prompt is: Enter boot Path or ?> Enter the address of the CD device where the HP-UX Core
media is mounted. The next prompt is: Interact with IPL (Y or N)> Enter n at the prompt. After several minutes and several screens of status
information, the this is displayed: Welcome to the HP-UX installation/recovery process! Use the <tab> and/or arrow keys to navigate through the following menus,and use the <return> key to select an item. If the menu items are not clear, select the "Help" item for more information. [ Install HP-UX ] [ Run a Recovery Shell ] [ Advanced Options ] [ Help ] Select: Run a Recovery Shell. The next prompt is: Would you like to start up networking at this time? [n] Unless you need networking to ftp to other systems,
enter: n * Loading in a shell... * Loading in the recovery system commands... HP-UX SYSTEM RECOVERY CORE MEDIA WARNING: YOU ARE SUPERUSER !! NOTE: Commands residing in the RAM-based file system are unsupported 'mini'commands. These commands are only intended for recovery purposes.Loading commands needed for recovery!Press <return> to continue. Press Return or Enter. The next prompt is: Loading commands needed for recovery! This menu is displayed: HP-UX CORE MEDIA RECOVERY MAIN MENU s. Search for a file b. Reboot l. Load a file r. Recover an unbootable HP-UX system x. Exit to shellThis menu is for listing and loading the tools contained on the core media. Once a tool is loaded, it may be run from the shell. Some tools require other files to be present in order to successfully execute. Select one of the above: To load a file or files, enter l at the prompt. Filesystem kbytes used avail %cap iused ifree iused Mounted on / 2011 1459 552 73% 137 343 29% ? /duped_root 2011 1418 593 71% 49 431 10% ? Enter the filename(s) to load: Enter the name(s) of the damaged/corrupted file(s) you
wish to load. For example: sh vi date grep The following example lists two files (ex and egrep) which must be loaded before the files vi and grep can be loaded. It also lists a file (date) which is not in the load list. NOTE : Since ./usr/bin/vi is linked to ./usr/bin/ex './usr/bin/ex' must precede './usr/bin/vi' in the load list. The file 'date' is NOT in the LOADCMS archive. <Press return to continue> NOTE : Since ./usr/bin/grep is linked to ./usr/bin/egrep './usr/bin/egrep' must precede './usr/bin/grep' in the loadlist. ******** THE REQUESTED FILE(S): *********** ./sbin/sh ./usr/bin/vi ./usr/bin/grep Is the above load list correct? [n] This load list is incorrect, because ./usr/bin/ex does not precede ./usr/bin/vi in the list of requested files. So you would enter: n Nothing will be loaded! <Press return to return to Main Menu> Press Enter and the Main Menu appears. To search for a file you wish
to load, select: s Either enter the filename(s) to be searched for, or 'all' for a total listing. Enter: vi awk /sbin/sh date You will receive this response: ./usr/bin/vi linked to ./usr/bin/ex ./sbin/awk ./usr/bin/awk ./sbin/sh **** The file 'date' was not found in the LOADCMDS archive. **** <Press return to continue> Press Enter to return to the Main Menu. To begin the actual system recovery and invoke the Recovery
Menu, select: r HP-UX Recovery MENU Select one of the following: a. Mount the root disk and exit to shell only. b. Recover the bootlif/os partitions. c. Replace the kernel on the root file system. d. Both options b and c v. Read information about VxVM/LVM recovery m. Return to 'HP-UX Recovery Media Main Menu'. x. Exit to the shell. To install both the bootlif and critical files, select: a DEVICE FILE VERIFICATION MENU This menu is used to specify the path of the root file sysem. When the information is correct, select 'a'.INFORMATION to verify: Device file used for '/'(ROOT) is c1t6d0 The path to disk is 56/52.6.0 Select one of the following: a. The above information is correct. b. WRONG!! The device file used for '/'(ROOT) is incorrect. m. Return to the 'HP-UX Recovery MENU.' x. Exit to the shell. Assuming the root device file is incorrect, select: b Enter the device file associated with the '/'(ROOT) file system. (example: c1t6d0): On a system with hard-sectored disks, the prompt and response
might look like this: Enter the device file associated with the '/'(ROOT) file system (example: c0t1d0s1lvm ) : c0t0d0s13 /dev/rdsk/c0t0d0s13 not a special file <Press return to continue> Enter the address associated with the '/'(ROOT) file system (example: 4.0.1) : 4.0.0 NOTE: if your '/'(ROOT) is not part of a sectioned disk layout enter a 'W' for whole disk layout or enter a 'l' for an LVM disk layout instead of a section number. Enter the section associated with the '/'(ROOT) file system (example: 13 ): 13 making rdsk/c0t0d0s13 c 214 0x00000d making dsk/c0t0d0s13 b 26 0x00000d If you entered c1t1d0 as the root device filename, you would see: DEVICE FILE VERIFICATION MENU This menu is used to specify the path of the root file system When the information is correct, select 'a'. INFORMATION to verify: Device file used for '/'(ROOT) is c1t1d0 The path to disk is 56/52.1.0 Select one of the following: a. The above information is correct. b. WRONG!! The device file used for '/'(ROOT) is incorrect. m. Return to the 'HP-UX Recovery MENU.' x. Exit to the shell.
Since c1t1d0 is the correct root device filename, select: a BOOTLIF PATH VERIFICATION MENU This menu must be used to determine the path to the bootlif(ISL, HPUX and the AUTO file). When the information is correct, select 'a'. INFORMATION to verify: Path to the bootlif is 56/52.1.0 Select one of the following: a. The above information is correct. b. WRONG!! The path to bootlif is incorrect. m. Return to the 'HP-UX Recovery MENU.' x. Exit to the shell. Selection: Assuming that the bootlif path is correct, enter: a FILE SYSTEM CHECK MENUThe file system check'/sbin/fs/hfs/fsck -y /dev/rdsk/c1t10' will now be run. Select one of the following: a. Run fsck -y . b. Prompt for the fsck run string on c1t1d0. m. Return to the 'HP-UX Recovery MENU.' Selection: Select a to run fsck -y to check your file system for corruption. ** /dev/rdsk/c1t1d0 ** Last Mounted on /ROOT ** Phase 1 - Check Blocks and Sizes ** Phase 2 - Check Pathnames ** Phase 3 - Check Connectivity ** Phase 4 - Check Reference Counts ** Phase 5 - Check Cyl groups 6256 files, 0 icont, 149423 used,1563824 free(928 frags,195362 blocks) Mounting c1t1d0 to the HP-UX Recovery Media /ROOT directory... <Press return to continue> Assuming your file system is not corrupted, and you
wish to continue with the system recovery, press Return to mount your root file system under the / directory.
You'll see messages like this: ***** Downloading files to the target disk ***** x ./sbin/lvchange, 528384 bytes, 1032 tape blocks ./sbin/lvcreate linked to ./sbin/lvchange ./sbin/lvdisplay linked to ./sbin/lvchange
Filesystem kbytes used avail %cap iused ifree iused Mounted on /ROOT 1713247 149426 1392496 10% 6261 275339 2% ? Should the existing kernel be 'left', 'overwritten', or 'moved'?[overwritten] To overwrite the existing kernel with your new file
system, enter overwritten or over at the prompt. downloading INSTALL to /stand/vmunix **** Creating device files on the target disk **** ******* Renaming the following files: ******* '/.profile' has been renamed '/.profileBK' *********** Installing bootlif *********** mkboot -b /dev/rmt/1m -i ISL -i HPUX /dev/rdsk/c1t1d0 mkboot -a hpux (56/52.1.0;0)/stand/vmunix /dev/rdsk/c1t1d0 Complete the recovery process by selecting: a NOTE: System rebooting ... - PDC - Processor Dependent Code - Version 1.3 (c) Copyright 1990-1993, Hewlett-Packard Company, All rights reserved. - 16 MB of memory configured and tested. Primary boot path: 56/52.5 (dec) Alternate boot path: 56/52.3 (dec) Manufacturing permissions ON - Main Menu Command Description - - BOot [PRI|ALT| &<path>] Boot from specified path PAth [PRI|ALT|][ &<path>] Display or modify a path SEArch [DIsplay|IPL][&<path>] Search for boot devices COnfiguration menu Displays or sets boot values INformation menu Displays hardware information SErvice menu Displays service commands MFG menu Displays manufacturing commands DIsplay Redisplay the current menu HElp [&<menu>|&<command>] Display help for menu or command RESET Restart the system - Main Menu: Enter command or menu item. Enter bo pri at the prompt to boot from the primary boot path. The
next prompt is: Interact with IPL (Y or N)?> Enter n for unattended boot. Several screens of status information
are displayed, followed by this warning: THIS SYSTEM HAS BEEN BOOTED USING A TEMPORARY KERNEL! DO NOT ATTEMPT TO INVOKE MULTI-USER RUN-LEVEL USING THIS KERNEL! Type the following command from the shell prompt for more information about completing the recovery process: cat /RECOVERY.DOC To obtain more information on the recovery process,
enter: cat /RECOVERY.DOC 1) Restore valid copies of the following files (either from backup or from the filename.BK files created during the recovery process). /etc/fstab, /etc/inittab, /stand/ioconfig, /etc/ioconfig, /etc/passwd, /sbin/pre_init_rc, /.profile, and /etc/profile NOTE: The backup archive may be extracted using '/sbin/frecover' or'/sbin/pax' (for backups made with 'tar' or 'cpio'). If using '/sbin/pax', linking it to 'tar' or 'cpio' will force'pax' to emulate the respective command line interface. 2) Replace /stand/vmunix from backup, since the present kernelis probably missing desired drivers. 3) If you have an lvm root, refer to the /LVM.RECOVER text file. If you have an LVM system, and want more information
on recovery procedures, enter: cat /LVM.RECOVER Follow the displayed instructions shown below.  |  |  |  |  | NOTE: If a card has been added to, or removed from, your system
since the original installation was completed, there is a chance
that the device file for the root disk has changed. Consequently,
before you run the LVM script ./lvmrec.scrpt (Step
2 in the displayed instructions below), you should first recover /stand/ioconfig from
backup, and reboot. |  |  |  |  |
INSTRUCTIONS to complete your LVM recovery: The system must now be up now in "maintenance mode". NOTE: In order for the following steps to lead to a successful lvm recovery the LVM label information must be valid. If the bootlif was updated from the RAM-based recovery system, then "mkboot -l" has already been run to repair this label. step 1. If the autofile was altered to force the system to boot in maintenance mode, use "mkboot -a" to remove the "-lm" option. Example: to change "hpux -lm (52.6.0;0)/stand/vmunix" to "hpux (52.6.0;0)/stand/vmunix" use mkboot -a "hpux (52.6.0;0)/stand/vmunix" /dev/rdsk/<device file> (Use lssf /dev/rdsk/* to match the device file with the boot address.) step 2. Run '/lvmrec.scrpt' to repair the following LVM configuration information: a. LVM records (lvmrec) b. BDRA (Boot Data Reserve Area) c. LABEL information Requirement: The following files must reside on disk before the script can complete: a. /etc/lvmtab b. /etc/fstab c. /etc/lvmconf/<rootvg>.conf d. all device files specified in /etc/fstab To run '/lvmrec.scrpt' provide the device filename used to access the bootlif as an argument to the script. Example: /lvmrec.scrpt c0t6d0 In this example 'c0t6d0' is the device file used to access the bootlif. step 3. Once '/lvmrec.scrpt' completes, issue the command "reboot" and bringthe system fully up. The recovery of the root LVM is complete. If the'/lvmrec.scrpt' issued the following warning: "************ I M P O R T A N T ***************** "Root logical volume has been repaired, but......." "you need to reboot the system and repair the Swap" "logical volume using the following LVM command: " " lvlnboot -A n -s /dev/<root lv>/<swap lvol> " "because Recovery has no way to find out what is " "the Swap logical volume information at this point" "*************************************************"The Swap and Dump logical volumes will need to be re-configured The BDRA contains the "root", "swap" and "dump" logical volumeinformation. '/lvmrec.scrpt' only fixes the root logical volume information in the BDRA.The "swap" and "dump" areas can be updated via the "lvlnboot" command. Example: lvlnboot -s /dev/<vg00>/lvol2 lvlnboot -d /dev/<vg00>/lvol3 In this example 'lvol2' and 'lvol3' are the "swap" and "dump" logical volumes respectively. step 4. Perform any further data recovery deemed necessary. *** NOTE *** If the same volume group contains more than one corrupted bootdisk, Repeat the above steps for each disk that needs to be repaired. This completes the process for rebuilding
the bootlif and installing critical files.
Installing
Critical Root Files Only |  |
Following
is an example of the detailed procedure for installing all the critical
files necessary to boot on the target root file system: Boot the Core media, following the steps in Chapter 2. You
will see some status messages, and then a menu: Welcome to the HP-UX installation process! Use the <tab> and/or arrow keys to navigate through the following menus,and use the <return> key to select an item. If the menu items are not clear, select the "Help" item for more information. [ Install HP-UX ] [ Run a Recovery Shell ] [ Advanced Options ] [ Help ] Select Run a Recovery Shell, the screen clears, and the following question appears: Would you like to start up networking at this time? [n] If you have no need to access the net, enter: n * Loading in a shell... * Loading in the recovery system commands... (c) Copyright 1983, 1984, 1985, 1986 Hewlett-Packard Co. (c) Copyright 1979 The Regents of the University of Colorado, a body corporate (c) Copyright 1979, 1980, 1983 The Regents of the University of California (c) Copyright 1980, 1984 AT&T Technologies. All Rights Reserved. HP-UX SYSTEM RECOVERY CORE MEDIA WARNING: YOU ARE SUPERUSER !! NOTE: Commands residing in the RAM-based file system are unsupported 'mini' commands. These commands are only intended for recovery purposes. Loading commands needed for recovery! WARNING: If ANYTHING is changed on a root (/) that is mirrored, 'maintenance mode' (HPUX -1m) boot MUST be done in order to force the mirrored disk to be updated!Press <return> to continue. Press: Return Loading commands needed for recovery!Then the following menu will be displayed:HP-UX CORE MEDIA RECOVERY MAIN MENU s. Search for a file b. Reboot l. Load a file r. Recover an unbootable HP-UX system x. Exit to shell c. Instructions on chrooting to a lvm /(root). This menu is for listing and loading the tools contained on the core media. Once a tool is loaded, it may be run from the shell. Some tools require other files to be preset in order to successfully execute. Select one of the above: To begin the actual system recovery, select r to see the HP-UX Recovery Menu: HP-UX Recovery MENU Select one of the following: a. Mount the root disk and exit to shell only. b. Recover the bootlif/os partitions. c. Replace the kernel on the root file system. d. Both options b and c v. Read information about VxVM/LVM recovery m. Return to 'HP-UX Recovery Media Main Menu'. x. Exit to the shell. To install critical files only, select: b DEVICE FILE VERIFICATION MENU This menu is used to specify the path of the root file system. When the information is correct, select 'a'. INFORMATION to verify: Device file used for '/'(ROOT) is c1t6d0 The path to disk is 56/52.6.0 Select one of the following: a. The above information is correct. b. WRONG!! The device file used for '/'(ROOT) is incorrect m. Return to the 'HP-UX Recovery MENU.' x. Exit to the shell. Assuming the root device file is incorrect, select b; you will be prompted to enter the correct device filename: Enter the device file associated with the '/'(ROOT) file system (example: c1t6d0): On a system with hard-sectored disks, the prompt and response
might look like this: Enter the device file associated with the '/'(ROOT) file system (example: c0t1d0s1lvm ) : c0t0d0s13 /dev/rdsk/c0t0d0s13 not a special file <Press return to continue> Enter the address associated with the '/'(ROOT) file system (example: 4.0.1) : 4.0.0 NOTE: if your '/'(ROOT) is not part of a sectioned disk layout enter a 'W' for whole disk layout or enter a 'l' for an LVM disk layout instead of a section number. Enter the section associated with the '/'(ROOT) file system (example: 13 ): 13 making rdsk/c0t0d0s13 c 214 0x00000d making dsk/c0t0d0s13 b 26 0x00000d If you were to enter, for example, c1t1d0 as the root device filename, you would see this: DEVICE FILE VERIFICATION MENU This menu is used to specify the path of the root file system. When the information is correct, select 'a'. INFORMATION to verify: Device file used for '/'(ROOT) is c1t1d0 The path to disk is 56/52.1.0 Select one of the following: a. The above information is correct. b. WRONG!! The device file used for '/'(ROOT) is incorrect m. Return to the 'HP-UX Recovery MENU.' x. Exit to the shell. Since c1t1d0 is the correct root device filename, select: a FILE SYSTEM CHECK MENU The file system check '/sbin/fs/hfs/fsck -y /dev/rdsk/c1t1d0' will now be run. Select one of the following: a. Run fsck -y . b. Prompt for the fsck run string on c1t1d0. m. Return to the 'HP-UX Recovery MENU.' Select a to run fsck -y to check your file system for corruption. ** /dev/rdsk/c1t1d0 ** Last Mounted on /ROOT ** Phase 1 - Check Blocks and Sizes ** Phase 2 - Check Pathnames ** Phase 3 - Check Connectivity ** Phase 4 - Check Reference Counts ** Phase 5 - Check Cyl groups 6256 files, 0 icont, 149423 used, 1563824 free (928 frags, 195362 blocks) Mounting c1t1d0 to the CORE media /ROOT directory... <Press return to continue> Assuming your file system is not corrupted, and you
wish to continue with the system recovery, press Return to mount your root file system under the Core media / directory. ***** Downloading files to the target disk ***** x ./sbin/lvchange, 528384 bytes, 1032 tape blocks ./sbin/lvcreate linked to ./sbin/lvchange ./sbin/lvdisplay linked to ./sbin/lvchange ./sbin/lvextend linked to ./sbin/lvchange ... Filesystem kbytes used avail %cap iused ifree iused Mounted on /ROOT 1713247 149426 1392496 10% 6261 275339 2% ? Should the existing kernel be 'left', 'overwritten', or 'moved'?[overwritten] To overwrite the existing kernel with your new file
system, enter overwritten or over at the prompt. downloading INSTALL to /stand/vmunix **** Creating device files on the target disk **** ******* Renaming the following files: ******* '/.profile' has been renamed '/.profileBK' RECOVERY COMPLETION MENU Use this menu after the recovery process has installed all requested files on your system. Select one of the following: a. REBOOT the target system and continue with recovery. b. Return to the CORE Media Main Menu. Complete the recovery process by selecting: a NOTE: System rebooting... PDC - Processor Dependent Code - Version 1.3 (c) Copyright 1990-1993, Hewlett-Packard Company, All rights reserved 16 MB of memory configured and tested. Primary boot path: 56/52.5 (dec) Alternate boot path: 56/52.3 (dec) Manufacturing permissions ON - Main Menu - Command Description - - BOot [PRI|ALT|<path>] Boot from specified path PAth [PRI|ALT] [<path>] Display or modify a path SEArch [DIsplay|IPL] [<path>] Search for boot devices COnfiguration menu Displays or sets boot values INformation menu Displays hardware information SERvice menu Displays service commands MFG menu Displays manufacturing commands DIsplay Redisplay the current menu HElp [<menu>|<command>] Display help for menu or command RESET Restart the system - Main Menu: Enter command or menu > Enter bo pri at the prompt to boot from the primary boot path. Interact with IPL (Y or N)?> Enter n for unattended boot; several screens of status information
will be displayed, followed by this warning: THIS SYSTEM HAS BEEN BOOTED USING A TEMPORARY KERNEL! DO NOT ATTEMPT TO INVOKE MULTI-USER RUN-LEVEL USING THIS KERNEL! Type the following command from the shell prompt for more information about completing the recovery process: cat /RECOVERY.DOC To obtain more information on the recovery process,
enter: cat /RECOVERY.DOC 1) Restore valid copies of the following files (either from backup or from the <filename>BK files created during the recovery process). /etc/fstab, /etc/inittab, /stand/ioconfig, /etc/ioconfig, /etc/passwd, /sbin/pre_init_rc, /.profile, and /etc/profile NOTE: The backup archive may be extracted using '/sbin/frecover' or '/sbin/pax' (for backups made with 'tar' or 'cpio'). If using '/sbin/pax', linking it to 'tar' or 'cpio' will force 'pax' to emulate the respective command line interface. 2) Replace /stand/vmunix from backup, since the present kernel is probably missing desired drivers. 3) If you have an lvm root, refer to /LVM.RECOVER . If you have an LVM system, and want more information
on recovery procedures, enter: cat /LVM.RECOVER The file contains the following information: If a card has been added to, or removed from, your system since the original installation was completed, there is a chance that the device file for the root disk has changed. Consequently, before you run the LVM script ./lvmrec.scrpt (Step 2, below), you should first recover /stand/ioconfig from backup and reboot. INSTRUCTIONS to complete your LVM recovery: The system must now be up now in "maintenance mode". NOTE: In order for the following steps to lead to a successful lvm recovery the LVM label information must be valid. If the bootlif was updated from the RAM-based recovery system, then "mkboot -l" has already been run to repair this label. step 1. If the autofile was altered to force the system to boot in maintenance mode, use "mkboot -a" to remove the "-lm" option. Example: to change "hpux -lm (52.6.0;0)/stand/vmunix" to "hpux (52.6.0;0)/stand/vmunix" use mkboot -a "hpux (52.6.0;0)/stand/vmunix"/dev/rdsk/<device file>  |  |  |  |  | NOTE: To match device file with boot address, use: lssf /dev/rdsk/* |  |  |  |  |
step 2. Run '/lvmrec.scrpt' to repair the following LVM configuration information: a. LVM records (lvmrec) b. BDRA (Boot Data Reserve Area) c. LABEL information Requirement: The following files must reside on disk before the script can complete: a. /etc/lvmtab b. /etc/fstab c. /etc/lvmconf/<rootvg>.conf d. all device files specified in /etc/fstab To run '/lvmrec.scrpt' provide the device filename used to access the bootlif as an argument to the script. Example: /lvmrec.scrpt c0t6d0 In this example 'c0t6d0' is the device file used to access the bootlif. step 3. Once '/lvmrec.scrpt' completes, issue the command "reboot" and bring the system fully up. The recovery of the root LVM is complete. If the '/lvmrec.scrpt' issued the following warning: "************ I M P O R T A N T ******************" " " "Root logical volume has been repaired, but......." "you need to reboot the system and repair the Swap" "logical volume using the following LVM command: " " lvlnboot -A n -s /dev/<root lv>/<swap lvol> " "because Recovery has no way to find out what is " "the Swap logical volume information at this point" " " "*****************************************************" The Swap and Dump logical volumes will need to be re-configured. The BDRA contains the "root", "swap" and "dump" logical volume information. '/lvmrec.scrpt' only fixes the root logical volume information in the BDRA. The "swap" and "dump" areas can be updated via the "lvlnboot" command. Example: lvlnboot -s /dev/<vg00>/lvol2 lvlnboot -d /dev/<vg00>/lvol3 In this example 'lvol2' and 'lvol3' are the "swap" and "dump" logical volumes respectively. step 4. Perform any further data recovery deemed necessary. *** NOTE *** If the same volume group contains more than one corrupted boot disk, repeat the above steps for each disk that needs to be repaired. This completes the process for installing
critical files only.
Rebuilding
the ''bootlif'' Only |  |
Boot
the Core media, following the steps in Chapter 2. You will see some status
messages, and then a menu: Welcome to the HP-UX installation process! Use the <tab> and/or arrow keys to navigate through the following menus, and use the <return> key to select an item. If the menu items are not clear, select the "Help" item for more information. [ Install HP-UX ] [ Run a Recovery Shell ] [ Advanced Options ] [ Help ]
Select: Run a Recovery Shell . The screen clears, and this is displayed: Would you like to start up networking at this time? [n] Enter: n * Loading in a shell... * Loading in the recovery system commands... (c) Copyright 1983, 1984, 1985, 1986 Hewlett-Packard Co. (c) Copyright 1979 The Regents of the University of Colorado, a body corporate (c) Copyright 1979, 1980, 1983 The Regents of the University of California (c) Copyright 1980, 1984 AT&T Technologies. All Rights Reserved. HP-UX SYSTEM RECOVERY CORE MEDIA WARNING: YOU ARE SUPERUSER !! NOTE: Commands residing in the RAM-based file system are unsupported 'mini'commands. These commands are only intended for recovery purposes. Loading commands needed for recovery! WARNING: f ANYTHING is changed on a root(/) that is mirrored a 'maintenance mode'(HPUX -lm) boot MUST be done in order to force the mirrored disk to be updated!! Press <return> to continue. Press: Return Loading commands needed for recovery! After boot steps, this message appears: HP-UX CORE MEDIA RECOVERY MAIN MENU s. Search for a file b. Reboot l. Load a file r. Recover an unbootable HP-UX system x. Exit to shell c. Instructions on chrooting to a lvm /(root). Select one of the above: To begin the actual system recovery, select: r HP-UX Recovery MENU Select one of the following: a. Mount the root disk and exit to shell only. b. Recover the bootlif/os partitions. c. Both options b and c v. Read information about VxVM/LVM recovery m. Return to 'HP-UX Recovery Media Main Menu'. x. Exit to the shell. Select c to rebuild the bootlif. BOOTLIF PATH VERIFICATION MENU This menu must be used to determine the path to the bootlif (ISL, HPUX and the AUTO file). When the information is correct, select 'a'. INFORMATION to verify: Path to the bootlif is 56/52.1.0 Select one of the following: a. The above information is correct. b. WRONG!! The path to bootlif is incorrect. m. Return to the 'HP-UX Recovery MENU.' x. Exit to the shell. Selection: BOOT STRING VERIFICATION MENU This menu must be used to verify the system's boot string. When the information is correct, select 'a'. INFORMATION to verify: The system's boot string should be: 'hpux -lm (56/52.5.0)/stand/vmunix' Select one of the following: a. The above information is correct. b. WRONG!! Prompt the user for the system's boot string. m. Return to the 'HP-UX Recovery MENU.' x. Exit to the shell. NOTE: For an LVM '/'(ROOT) the '-lm' option MUST be specified (example: 'hpux -lm (2.3.4)/stand/vmunix' ) Selection:
Assuming that the bootlif path is correct, enter: a Assuming the boot string is incorrect, enter b at the prompt. You will see a message similar to the
following: AUTO FILE should be (replacing 'hpux (56/52.5.0)/stand/vmunix'): Enter the correct information (for example, hpux); you will then see the BOOT STRING VERIFICATION MENU
displayed again: BOOT STRING VERIFICATION MENU This menu must be used to verify the system's boot string. When the information is correct, select 'a'. INFORMATION to verify: The system's boot string should be: 'hpux' Select one of the following: a. The above information is correct. b. WRONG!! Prompt the user for the system's boot string. m. Return to the 'HP-UX Recovery MENU.' x. Exit to the shell. NOTE: For an LVM '/'(ROOT) the '-lm' option MUST be specified (example: 'hpux -lm (2.3.4)/stand/vmunix' ) Selection:  |  |  |  |  | NOTE: Use the -lm option to enter LVM administration mode only when recovering
an LVM system. Use the -V option to enter VxVM administration mode only when recovering
a VxVM system. |  |  |  |  |
Assuming the information is now correct, enter: a For an LVM system, you will see something
like the following: *********** Installing bootlif *********** mkboot -b /dev/rmt/1m -i ISL -i HPUX /dev/rdsk/c1t1d0 mkboot -a hpux (56/52.5.0;0)/stand/vmunix /dev/rdsk/c1t1d0
RECOVERY COMPLETION MENU Use this menu after the recovery process has installed all requested files on your system. Select one of the following: a. REBOOT the target system and continue with recovery. b. Return to the CORWE Media Main Menu. Selection: Complete the recovery process by selecting a, rebooting your system.
This completes the process for rebuilding
the bootlif only. Replacing
the Kernel Only |  |
Boot
the Core media, following the steps in Chapter 2. This menu appears
after some status messages: Welcome to the HP-UX installation process! Use the <tab> and/or arrow keys to navigate through the following menus,and use the <return> key to select an item. If the menu items are not clear, select the "Help" item for more information. [ Install HP-UX ] [ Run a Recovery Shell ] [ Advanced Options ] [ Help ]
Click: Run a Recovery Shell Would you like to start up networking at this time? [n] Enter: n * Loading in a shell... * Loading in the recovery system commands... HP-UX SYSTEM RECOVERY CORE MEDIA WWARNING: YOU ARE SUPERUSER !! NOTE: Commands residing in the RAM-based file system are unsupported 'mini' commands. These commands are only intended for recovery purposes. Loading commands needed for recovery! WARNING:If ANYTHING is changed on a root(/) that is mirrored a 'maintenance mode'(HPUX -lm) boot MUST be done in order to force the mirrored disk to be updated!! Press <return> to continue. Press Return and the following status message is displayed: Loading commands needed for recovery! You will see the following menu: HP-UX CORE MEDIA RECOVERY MAIN MENU s. Search for a file b. Reboot l. Load a file r. Recover an unbootable HP-UX system x. Exit to shell c. Instructions on chrooting to a lvm /(root). This menu is for listing and loading the tools contained on the CORE media. Once a tool is loaded, it may be run from the shell. Some tools require other files to be present in order to successfully execute. Select one of the above: To begin the actual system recovery, select: r HP-UX Recovery MENU Select one of the following: a. Mount the root disk and exit to shell only. b. Recover the bootlif/os partitions. c. Replace the kernel on the root file system. d. Both options b and c v. Read information about VxVM/LVM recovery m. Return to 'HP-UX Recovery Media Main Menu'. x. Exit to the shell. Select d to replace only the kernel on the root file system. DEVICE FILE VERIFICATION MENU This menu is used to specify the path of the root file system. When the information is correct, select 'a'. INFORMATION to verify: Device file used for '/'(ROOT) is c1t6d0 The path to disk is 56/52.6.0 Select one of the following: a. The above information is correct. b. WRONG!! The device file used for '/'(ROOT) is incorrect. m. Return to the 'HP-UX Recovery MENU.' x. Exit to the shell. Assuming the root device file is incorrect, select: b Enter the device file associated with the '/'(ROOT) file system (example: c1t6d0): On a system with hard-sectored disks, the prompt and response
might look like this: Enter the device file associated with the '/'(ROOT) file system (For example: c0t1d0s1lvm ) : device_file /dev/rdsk/device_file not a special file <Press return to continue> Enter the address associated with the '/'(ROOT) file system (For example: 4.0.1) : address NOTE: if your '/'(ROOT) is not part of a sectioned disk layout enter a 'W' for whole disk layout or enter a 'l' for an LVM disk layout instead of a section number. Enter the section associated with the '/'(ROOT) file system (For example: 13 ): 13 making rdsk/c0t0d0s13 c 214 0x00000d making dsk/c0t0d0s13 b 26 0x00000d If you were to enter c1t1d0 as the root device filename.: DEVICE FILE VERIFICATION MENU This menu is used to specify the path of the root file system. When the information is correct, select 'a'. INFORMATION to verify: Device file used for '/'(ROOT) is c1t1d0 The path to disk is 56/52.1.0 Select one of the following: a. The above information is correct. b. WRONG!! The device file used for '/'(ROOT) is incorrect. m. Return to the 'HP-UX Recovery MENU.' x. Exit to the shell. Since c1t1d0 is the correct root device filename, select: a FILE SYSTEM CHECK MENU The file system check '/sbin/fs/hfs/fsck -y /dev/rdsk/c1t1d0' will now be run. Select one of the following: a. Run fsck -y . b. Prompt for the fsck run string on c1t1d0. m. Return to the 'HP-UX Recovery MENU.' Selection: Select a to run fsck -y to check your file system for corruption; you will see
a display similar to the following: ** /dev/rdsk/c1t1d0 ** Last Mounted on /ROOT ** Phase 1 - Check Blocks and Sizes ** Phase 2 - Check Pathnames ** Phase 3 - Check Connectivity ** Phase 4 - Check Reference Counts ** Phase 5 - Check Cyl groups 6256 files, 0 icont, 149423 used, 1563824 free (928 frags, 195362 blocks) Mounting c1t1d0 to the CORE media /ROOT directory... Filesystem kbytes used avail %cap iused ifree iused Mounted on /ROOT 434773 352461 38834 90% 15241 54647 22% ? Should the existing kernel be 'left', 'overwritten', or 'moved'?[moved]over To move the existing kernel with your new file system,
enter move at the prompt. Complete the recovery process by selecting a, REBOOT the target system.
This completes the process for replacing
the kernel only.
|