Jump to content United States-English
HP.com Home Products and Services Support and Drivers Solutions How to Buy
» Contact HP
More options
HP.com home
Configuring HP-UX For Peripherals: HP 9000 Computers > Chapter 4 Configuring Disk Drives, Disk Arrays, and CD-ROM Drives

Configuring into your System an LVM Disk Already Containing Data

» 

Technical documentation

Complete book in PDF
» Feedback
Content starts here

 » Table of Contents

 » Index

NOTE: This procedure is provided for configuring a Series 800 legacy LVM disk into HP-UX 10.0. Before proceeding, make sure you have read “Planning to Configure into your System a Disk Already Containing Data ” and have performed the examination documented in “Ensuring Against Clashes with HP-UX 10.0”.
  1. Back up the data on the disk; see the backup chapter in Managing Systems and Workgroups.

  2. Unmount any file systems residing on the LVM disk by using the umount command.

  3. Deactivate the disk's volume group by using the vgchange command.

  4. Remove the volume group of the disk from its current configuration and prepare to export it using the vgexport command. The -m option creates a mapfile that retains the names of the logical volumes in the volume group.

    /usr/sbin/umount /dev/vg01/lvol1
    /usr/sbin/vgchange -a n /dev/vg01
    /usr/sbin/vgexport -m mapfile /dev/vg01
  5. Copy the mapfile to the new system on which the disk will reside. On a networked system, you can use rcp or ftp.

  6. Create a record of your system's current disk configuration for later use.

    /usr/sbin/ioscan -fun -C disk
  7. Note whether the current configuration includes the device driver needed to communicate with the disk being configured. If any necessary driver is absent from the kernel, you will need to rebuild the kernel to include it. Here is how you rebuild the kernel:

    1. Change directory to the build environment (/stand/build). There, execute a system preparation script, system_prep, which extracts the system file from the current kernel and writes a system file in your current directory. (That is, it creates /stand/build/system.) The -v gives verbose explanation as the script executes.

      cd /stand/build
      /usr/lbin/sysadm/system_prep -v -s system
    2. Modify the /stand/build/system file to add the absent driver(s) by invoking the kmsystem command. The -c Y specifies that driver-name is to be configured into the system.

      /usr/sbin/kmsystem -S /stand/build/system -c Y driver-name
      NOTE: To avoid introducing format errors, do not edit the HP-UX system description files directly. Instead, use the commands kmsystem and kmtune. These commands are new for Release 11.0; consult kmsystem(1M) and kmtune(1M) in the HP-UX Reference.
    3. Build the new kernel by invoking the mk_kernel command. This creates /stand/build/vmunix_test, a kernel ready for testing.

      /usr/sbin/mk_kernel -s /stand/build/system
    4. Save the old system file by moving it. Then move the new system file into place.

      mv /stand/system /stand/system.prev
      mv /stand/build/system /stand/system
    5. Prepare for rebooting by invoking the kmupdate command. This sets a flag that tells the system to use the new kernel when it restarts.

      /usr/sbin/kmupdate
  8. Bring the system down and physically install the disk device.

  9. Turn on the power to all peripheral devices. Wait for them to become "ready", then turn on power to the SPU.

  10. Watch the bootup sequence and record the name of the block device special file created for the new LVM disk.

    You can also identify the disk device by using the ioscan command. /usr/sbin/ioscan -fn -C disk will display all disks and their device special files. Or, you can use /usr/sbin/ioscan -H hardware_path -fn to identify the disk device by location.

  11. Scan your current system to identify all disks by their volume groups.

    /usr/sbin/vgscan -v
  12. Create a directory for the volume group to which the new LVM disk will belong. For example, a new volume group might be called vg06.

    mkdir /dev/vg06
  13. Check to make sure that you are creating a unique minor number for the new group file. Then create a character device special file for the new volume group's group file. The character major number for LVM is 64. In the minor number, n must be in the range between 0 and 9, because the maximum number of volume groups by default allowed on a system is ten. You can increase the number by changing the operating-system parameter maxvgs in /usr/conf/master.d/core-hpux or by using SAM.

    ll /dev/*/group
    mknod /dev/vg06/group c 64 0x0n0000
  14. Import the LVM disk to the current system, citing the the block device special file name you noted when the system booted up and the mapfile you created when invoking vgexport at the beginning of the procedure. You can preview the effect of the import by using the -p option.

    vgimport -pv -m mapfile /dev/vg06 block_device_special_file
    vgimport -v -m mapfile /dev/vg06 block_device_special_file

    The vgimport command adds the volume group name to the /etc/lvmtab file. It also adds the device special files associated with the volume group's logical volumes to the system.

  15. Activate the new volume group.

    /usr/sbin/vgchange -a y /dev/vg06
  16. Mount the logical volumes to their new mount point. For further information on mounting and unmounting, consult the Managing Systems and Workgroups manual.

    mkdir /new_location
    mount /dev/vg06/lvol1 /new_location
Printable version
Privacy statement Using this site means you accept its terms Feedback to webmaster
© 2000 Hewlett-Packard Development Company, L.P.