Tuesday, April 29, 2008

Solaris vxvm renaming diskgroup and disks

Renaming a disk group and volume
bansecdbdg -> secproddg used as an example

# Unmount all volumes in the bansecdbdg disk group.
# Stop all volumes
vxvol -g bansecdbdg stopall

# Deport bansecdbdg
vxdg deport bansecdbdg

# Import bansecdbdg using the -n option
vxdg -n secproddg import bansecdbdg

# Recover the disk group by the new dg name
vxrecover -g secproddg -sb

# Rename each volume
vxedit -g secproddg rename bansecdb01 sec01
vxedit -g secproddg rename bansecdb02 sec02
vxedit -g secproddg rename bansecdb08 sec08

# Update vfstab, your mount points and remount the volumes