Veritas VxVM : Grow Mirrored Volumes
Growing mirrored veritas volumes takes special care since it is desirable to keep each side of the mirror (plex) on different controllers. This procedure requires use of the GUI and command line interface.
Step 1 : In the GUI, remove the dirty volume log and pull one of the plex mirrors out of the volume.
Step 2 :When growing VxVM volumes with the Vxva GUI, you do not get to choose which drives to use to get the free space from. This limitation can be worked around by using the following command lines instead of the VxVA GUI.
Sample Scenerio :
Let’s say, for example, that you have a STRIPED volume (named “vol01” in the “rootdg” disk group) with 3 columns which you want to grow using 3 other drives named “disk01”, “disk02”, and “disk03”. You can first run
- # vxassist -g rootdg maxgrow vol01 disk01 disk02 disk03
This will return the largest size volume that can be made with these disks. A typical output would look like this:
- Volume vol01 can be extended by 10598400 to 10639360 (5195Mb)
Then, to actually grow the volume, run
- # vxassist -g rootdg growto vol01 10639360 disk01 disk02 disk03
If this volume contains a filesystem, you must now grow the filesystem to be the same size as the newly expanded volume. In this continuing example, the volume is mounted on /export. To resize the file system, run:
- # /usr/lib/fs/ufs/mkfs -F ufs -M /export /dev/vx/rdsk/rootdg/vol01 10639360
Don’t worry, this will not make a NEW filesystem, it WILL grow it, provided you enter the command with all of these options.
Step 3 : df -k will verify that the filesystem has grown to the new correct size.
Step 4: Delete the old plex and subdisk which you previously pulled from the volume.
Step 5: Remirror the volume making sure to select disk(s) on a different chain.
Step 6: Create the dirty volume log.
- Notes: Make sure that in the sun procedure you select apropriate disk(s) to add to the volume (i.e., disks that will not reside on the controller from which you will select the mirror disks) It is a good idea to leave 1080k on the newly added disks to be used for dirty volume logging. So in the vxassist growto command above, use a smaller number than what the maxgrow command showed.