Veritas Volume Manager 5.0 Administrator's Guide (September 2006)

194 Creating and administering disk groups
Reorganizing the contents of disk groups
The following command moves the self-contained set of objects implied by specifying
disk mydg01 from disk group mydg to rootdg:
# vxdg -o expand move mydg rootdg mydg01
The moved volumes are initially disabled following the move. Use the following
commands to recover and restart the volumes in the target disk group:
# vxrecover -g targetdg -m [volume ...]
# vxvol -g targetdg startall
The output from vxprint after the move shows that not only mydg01 but also volume
vol1 and mydg05 have moved to rootdg, leaving only mydg07 and mydg08 in disk
group mydg:
# vxprint
Disk group: rootdg
TY NAME ASSOC KSTATE LENGTH PLOFFS STATE TUTIL0 PUTIL0
dg rootdg rootdg - - - - - -
dm mydg01 c0t1d0 - 17678493 - - - -
dm rootdg02 c1t97d0 - 17678493 - - - -
dm rootdg03 c1t112d0 - 1767849 3 - - - -
dm rootdg04 c1t114d0 - 17678493 - - - -
dm mydg05 c1t96d0 - 17678493 - - - -
dm rootdg06 c1t98d0 - 17678493 - - - -
v vol1 fsgen ENABLED 2048 - ACTIVE - -
pl vol1-01 vol1 ENABLED 3591 - ACTIVE - -
sd mydg01-01 vol1-01 ENABLED 3591 0 - - -
pl vol1-02 vol1 ENABLED 3591 - ACTIVE - -
sd mydg05-01 vol1-02 ENABLED 3591 0 - - -
Disk group: mydg
TY NAME ASSOC KSTATE LENGTH PLOFFS STATE TUTIL0 PUTIL0
dg mydg mydg - - - - - -
dm mydg07 c1t99d0 - 17678493 - - - -
dm mydg08 c1t100d0 - 17678493 - - - -
The following commands would also achieve the same result:
# vxdg move mydg rootdg mydg01 mydg05
# vxdg move mydg rootdg vol1
Splitting disk groups
To remove a self-contained set of VxVM objects from an imported source disk group to a
new target disk group, use the following command:
# vxdg [-o expand] [-o override|verify] split sourcedg targetdg \
object ...
For a description of the -o expand, -o override, and -o verify options, see “Moving
objects between disk groups” on page 193.
See “Splitting disk groups” on page 418 for more information on splitting shared disk
groups in clusters.
For example, the following output from vxprint shows the contents of disk group
rootdg: