Managing Systems and Workgroups: A Guide for HP-UX System Administrators

Administering a System: Managing Disks and Files
Managing Disks
Chapter 6 565
As a system administrator, you can exercise control over which physical
volumes will contain the physical extents of a logical volume. You can do
this by using the following two steps:
1. Create a logical volume without specifying a size using lvcreate (1M)
or SAM. When you do not specify a size, by default, no physical
extents are allocated for the logical volume.
2. Now extend the logical volume (that is, allocate space) to the specific
physical volumes you wish to contain the file system using lvextend
(1M).
For more detailed information on this procedure, see “Extending a
Logical Volume to a Specific Disk” on page 577.
Setting Up Logical Volumes for Swap
When you enable a swap area within a logical volume, HP-UX
determines how large the area is and it will use no more space than that.
If your disk has enough remaining contiguous space, you can
subsequently increase the size of your primary swap area by using the
lvextend command (or SAM) to enlarge the logical volume and then
reboot the system. This allows HP-UX to use the extra space that you
have provided.
If you plan device swap areas in addition to primary swap, you will
attain the best performance when the device swap areas are on different
physical volumes (disks). This allows for the interleaving of I/O to the
physical volumes when swapping occurs.
You set up this swapping configuration by creating multiple logical
volumes for swap, each logical volume on a separate disk. You must use
HP-UX commands to help you obtain this configuration; SAM does not
allow you to create a logical volume on a specific disk. See “Extending a
Logical Volume to a Specific Disk” on page 577.
Setting Up Logical Volumes for Raw Data Storage
You can optimize raw I/O performance by planning your logical volumes
specifically for raw data storage. To create a raw data logical volume
(such as for a database), you will need to consider how large to create the
logical volume and how such a logical volume is distributed over your
disks.