[ Bottom of Page | Previous Page | Next Page | Contents | Index | Library Home | Legal | Search ]

Commands Reference, Volume 1

chpv Command

Purpose

Changes the characteristics of a physical volume in a volume group.

Syntax

chpv [ -h Hotspare ] [  -a Allocation ] [  -v Availability ] [ -c ] PhysicalVolume ... [ -C HDiskName ]

Description

Attention: This command is not allowed if the volume group is varied on in concurrent mode.

The chpv command changes the state of the physical volume in a volume group by setting allocation permission to either allow or not allow allocation and by setting the availability to either available or removed. This command can also be used to clear the boot record for the given physical volume. Characteristics for a physical volume remain in effect unless explicitly changed with the corresponding flag.

Note
To use this command, you must either have root user authority or be a member of the system group.

You can use the Volumes application in Web-based System Manager (wsm) to change volume characteristics. You can also use the System Management Interface Tool (SMIT) smit chpv fast path to run this command.

Flags

-a Allocation Sets the allocation permission for additional physical partitions on the physical volume specified by the PhysicalVolume parameter. Either allows (yes) the allocation of additional physical partitions on the physical volume, or prohibits (no) the allocation of additional physical partitions on the physical volume. The Allocation variable can be either:
y
Allows the allocation of additional physical partitions on the physical volume.
n
Prohibits the allocation of additional physical partitions on the physical volume. The logical volumes that reside on the physical volume can still be accessed.
-c Clears the boot record of the given physical volume.
-C HDiskName Clears the owning volume manager from a disk. This flag is only valid when running as the root user. This command will fail to clear LVM as the owning volume manager if the disk is part of an imported LVM volume group.
-h Hotspare Sets the sparing characteristics of the physical volume so that the physical volume can be used as a hot spare. Also sets the allocation permission for physical partitions on the physical volume specified by the PhysicalVolume parameter. This flag has no meaning for non-mirrored logical volumes. The Hotspare variable can be either:
y
Marks the disk as a hot spare disk within the volume group it belongs to and prohibits the allocation of physical partitions on the physical volume. The disk must not have any partitions allocated to logical volumes to be successfully marked as a hot spare disk.
n
Removes the disk from the hot spare pool for the volume group in which it resides and allows allocation of physical partitions on the physical volume.
Note
This flag is not supported for the concurrent capable volume groups.
-v Availability Sets the availability of the physical volume. If you set the availability to closed, logical input and output to the physical volume are stopped. You should close a physical volume when the physical volume is removed from operation. Access to physical volume data by the file system or the virtual memory manager is stopped, but you can continue to use the system management commands. The Availability variable can be either:
a
Makes a physical volume available for logical input and output.
r
Makes a physical volume unavailable (removed) for logical input and output. If the physical volume is required in order to maintain a volume group quorum, an error occurs and the physical volume remains open.

Examples

  1. To close physical volume hdisk03, enter:
    chpv -v r hdisk03
    The physical volume is closed to logical input and output until the -v a flag is used.
  2. To open physical volume hdisk03, enter:
    chpv -v a hdisk03
    The physical volume is now open for logical input and output.
  3. To stop the allocation of physical partitions to physical volume hdisk03, enter:
    chpv -a n hdisk03
    No physical partitions can be allocated until the -a y flag is used.
  4. To clear the boot record of a physical volume hdisk3, enter:

    chpv -c hdisk3

Files

/usr/sbin Directory where the chpv command resides.
/tmp Directory where temporary files are stored while the command is running.

Related Information

The lspv command.

The Logical Volume Storage Overview in AIX 5L Version 5.2 System Management Concepts: Operating System and Devices explains the Logical Volume Manager, physical volumes, logical volumes, volume groups, organization, ensuring data integrity, and understanding the allocation characteristics.

For information on installing the Web-based System Manager, see Chapter 2: Installation and System Requirements in AIX 5L Version 5.2 Web-based System Manager Administration Guide.

The System Management Interface Tool (SMIT): Overview in AIX 5L Version 5.2 System Management Concepts: Operating System and Devices explains the structure, main menus, and tasks that are done with SMIT.

[ Top of Page | Previous Page | Next Page | Contents | Index | Library Home | Legal | Search ]