284

Administering volumes

Resizing a volume

Removing a RAID-5 log

To identify the plex of the RAID-5 log, use the following command:

#vxprint [-g diskgroup] -ht volume

where volume is the name of the RAID-5 volume. For a RAID-5 log, the output lists a plex with a STATE field entry of LOG.

To dissociate and remove a RAID-5 log and any associated subdisks from an existing volume, use the following command:

#vxplex [-g diskgroup] -o rm dis plex

For example, to dissociate and remove the log plex volraid-02from volraid in the disk group, mydg, use the following command:

#vxplex -g mydg -o rm dis volraid-02

You can also remove a RAID-5 log with the vxassist command, as follows:

#vxassist [-g diskgroup] remove log volume [nlog=n]

By default, the vxassist command removes one log. Use the optional attribute nlog=n to specify the number of logs that are to remain after the operation completes.

Note: When removing the log leaves the volume with less than two valid logs, a warning is printed and the operation is not allowed to continue. The operation may be forced by additionally specifying the -foption to vxplex or vxassist.

Resizing a volume

Resizing a volume changes the volume size. For example, you might need to increase the length of a volume if it is no longer large enough for the amount of data to be stored on it. To resize a volume, use one of the commands: vxresize (preferred), vxassist, or vxvol. Alternatively, you can use the graphical Veritas Enterprise Administrator (VEA) to resize volumes.

If a volume is increased in size, the vxassist command automatically locates available disk space. The vxresize command requires that you specify the names of the disks to be used to increase the size of a volume. The vxvol command requires that you have previously ensured that there is sufficient space available in the plexes of the volume to increase its size. The vxassist and vxresize commands automatically free unused space for use by the disk group. For the vxvol command, you must do this yourself. To find out by how much you can grow a volume, use the following command:

# vxassist [-g diskgroup] maxgrow volume

When you resize a volume, you can specify the length of a new volume in sectors, kilobytes, megabytes, or gigabytes. The unit of measure is added as a suffix to the length (s, m, k, or g). If no unit is specified, sectors are assumed. The

Page 283
Image 283
HP Veritas Volume Manager 5.0 -UX 11i v3 manual Resizing a volume, Removing a RAID-5 log, # vxprint -g diskgroup -ht volume