HP-UX Reference (11i v1 05/09) - 1M System Administration Commands A-M (vol 3)
l
lvlnboot(1M) lvlnboot(1M)
First, initialize the disk, say /dev/dsk/c0t0d0
, so that it can be used as an LVM boot disk.
pvcreate -B /dev/rdsk/c0t0d0
Place the LIF information on the disk using the
mkboot command.
mkboot /dev/rdsk/c0t0d0
Create the volume group vglvmroot .
vgcreate /dev/vglvmroot /dev/dsk/c0t0d0
Create a logical volume that is suitable for use as the root volume. This logical volume has to be the
first in the volume group and should be a contiguous volume with bad block relocation turned off.
lvcreate -n root -L 120 -C y -r n /dev/vglvmroot
Create a logical volume that will be used as primary swap. This volume should be contiguous.
lvcreate -n swap -L 64 -C y /dev/vglvmroot
Create a logical volume that will be used as the dump volume. This volume should be contiguous.
lvcreate -n dump -L 64 -C y /dev/vglvmroot
Specify that the logical volume, root, will be used as the root volume.
lvlnboot -r /dev/vglvmroot/root
Specify that the logical volume, swap, will be used as the primary swap.
lvlnboot -s /dev/vglvmroot/swap
Specify that the logical volume, dump, will be used as the dump volume.
lvlnboot -d /dev/vglvmroot/dump
Display the results of the previous operations.
lvlnboot -v /dev/vglvmroot
The following examples show configuration of separate root and boot volumes.
Create a root volume group, vglvmroot, containing root, boot, swap, and dump logical volumes.
Assume that an appropriate directory called /dev/vglvmroot
and a corresponding group file
already exist (see lvm(7)).
First, initialize the disk, say
/dev/dsk/c0t0d0
, so that it can be used as an LVM boot disk.
pvcreate -B /dev/rdsk/c0t0d0
Place the LIF information on the disk using the mkboot command.
mkboot /dev/rdsk/c0t0d0
Create the volume group vglvmroot .
vgcreate /dev/vglvmroot /dev/dsk/c0t0d0
Create a logical volume that is suitable for use as the boot volume. This logical volume has to be the
first in the volume group and should be a contiguous volume with bad block relocation turned off.
lvcreate -n boot -L 24 -C y -r n /dev/vglvmroot
Create a logical volume that is suitable for use as the root volume. This logical volume should be a
contiguous volume with bad block relocation turned off.
lvcreate -n root -L 64 -C y -r n /dev/vglvmroot
Create a logical volume that will be used as primary swap. This volume should be contiguous.
lvcreate -n swap -L 64 -C y /dev/vglvmroot
Create a logical volume that will be used as the dump volume. This volume should be contiguous.
lvcreate -n dump -L 64 -C y /dev/vglvmroot
Specify that the logical volume, root, will be used as the root volume.
lvlnboot -r /dev/vglvmroot/root
HP-UX 11i Version 1: September 2005 − 3 − Hewlett-Packard Company Section 1M−−455