I am not a big believer in root disk encapsulation with Veritas Volume Manager, now part of Symantec Storage Foundation. There have been a number of times when I have had to boot off the mirror disk, and had to completely de-encapsulate the mirror disk from Veritas Volume Manager to recover.
Here is how to do it with Solaris. It is pretty similar for Linux as well.
Firstly, lets boot off the mirror disk and disable Veritas Volume Manager from starting.
Executing last command: boot vx-rootmirror -a -s
Boot device: /pci@83,4000/FJSV,ulsa@2,1/disk@0,0:a File and args: -a -s
Enter filename [kernel/sparcv9/unix]:
Enter default directory for modules [/platform/FJSV,GPUZC-M/kernel /platform/sun4us/kernel /kernel /usr/kernel]:
Name of system file [etc/system]: /dev/null
SunOS Release 5.10 Version Generic_127127-11 64-bit
Copyright 1983-2008 Sun Microsystems, Inc. All rights reserved.
Use is subject to license terms.
root filesystem type [ufs]:
Enter physical name of root device
[/pci@83,4000/FJSV,ulsa@2,1/disk@0,0:a]:
Booting to milestone "milestone/single-user:default".
fjgi0:Using local MAC address
fjgi1:Using local MAC address
# example - in this case c0t0d0 corresponds to mirror disk
mount -F ufs -o remount,rw /dev/dsk/c0t0d0s0 /
/etc/system --- remove all vx lines
/etc/vfstab – go back to normal devices e.g. /dev/vx/c0t0d0 ..
# Now make sure Volume Manager does not start on the next boot:
touch /etc/vx/reconfig.d/state.d/install-db
# make sure you setup boot-device to boot of mirror from now on, very important for re-encapsulation step later
eeprom | grep dev
e.g. eeprom "boot-device=vx-rootmirror"
syc;sync;init 6
After the previous steps volume manager should not be running.
# vxdisk list
VxVM vxdisk ERROR V-5-1-684 IPC failure: Configuration daemon is not accessible
Now, re-install Volume manager
bash-3.00# vxinstall
VxVM uses license keys to control access. If you have a SPARCstorage
Array (SSA) controller or a Sun Enterprise Network Array (SENA) controller
attached to your system, then VxVM will grant you a limited use license
automatically. The SSA and/or SENA license grants you unrestricted use
of disks attached to an SSA or SENA controller, but disallows striping,
RAID-5, and DMP on non-SSA and non-SENA disks. If you are not running an
SSA or SENA controller, then you must obtain a license key to operate.
Licensing information:
System host ID: 80f2a60a
Host type: FJSV,GPUZC-M
SPARCstorage Array or Sun Enterprise Network Array: No arrays found
Some licenses are already installed. Do you wish to review them
[y,n,q,?] (default: y) Feb 23 22:16:56 ibsza3002 root[1501]: Starting agent n
Do you wish to enter another license key [y,n,q,?] (default: n)
Do you want to setup a system wide default disk group?
[y,n,q,?] (default: y) Feb 23 22:17:16 ibsza3002 syseventd[353]:
n
Do you want to use enclosure based names for all disks ?
[y,n,q,?] (default: n)
The installation is successfully completed.
Check to see if Veritas can see your disks.
bash-3.00# vxdisk list
DEVICE TYPE DISK GROUP STATUS
c0t0d0s2 auto:sliced - - online
c1t0d0s2 auto:sliced - - online
Check to see if Veritas still thinks that it owns the disks.
vxdisk -o alldgs list
DEVICE TYPE DISK GROUP STATUS
c0t0d0s2 auto:sliced - (rootdg) online
c1t0d0s2 auto:sliced - (rootdg) online
If it does, make sure Veritas forgets about them completely.
bash-3.00# /etc/vx/bin/vxdiskunsetup -C c1t0d0
bash-3.00# /etc/vx/bin/vxdiskunsetup -C c0t0d0
Now follow the normal steps to re-encapsulate vx-rootmirror as your root disk and the other disk as your mirror disk.
Encapsulate root disk (e.g. c0t0d0)
vxdiskadm – option 2
Mirror root disk to other disk (e.g. c1t0d0)
vxdiskadm – option 6
About Danny W Sheehan
Danny has over 25 years in the IT industry and loves to blog about how to setup computer software, hardware, electronics and gadgets in general.





No comments yet.