Birut Patel’s Weblog

July 12, 2008

Veritas VxVM & VxFS Upgrade

Veritas VxVM & VxFS 3.2 – 5.0 upgrade procedure

(this procedure should work for upgrading pre-4.0 versions to 4.1 and above)

** prior to starting, create the file: /etc/vx/reconfig.d/state.d/install-db

SUMMARY:

o if using EMC arrays/Powerpath for external storage, configure appropriately (see DETAILS below)
o break root mirror & unencapsulate
** (if any additional volumes have been created in the rootdg diskgroup, they should be backed up
as they will go away when the root drive is unencapsulated; it is never a good idea to
define data volumes on the boot drive in rootdg diskgroup) **
o uninstall 3.2 (remove pkgs & kill processes)
o install Storage Foundation 5.0 (and Maintenance Patch; MP1)
o if data disks are connected, verif the output of vxdisk list (the TYPE column)
o encapsulate & mirror root drive
o upgrading data disks

DETAILS:

o if using EMC arrays/Powerpath for external storage, configure appropriately
- decide if PowerPath should be upgraded or leave uninstalled to use Volume Manager DMP
(DMP will be automatically configured)
o if PowerPath will be upgraded, check with EMC for current compatible version of PowerPath
- see installation guide page 71 (Unsuppressing DMP for EMC PowerPath disks).
(http://support.veritas.com/docs/283887)

o break root mirror & unencapsulate

- … deport data disk groups …
(command: vxdg deport datadg (diskgroup)
(if the root drive is not mirrored, skip to “Unencapsulate boot drive” below)
- vxplex -g rootdg -o rm dis <plex name>
(do this for each of the mirror drive plexes)
- vxdg -g rootdg rmdisk <root mirror disk>
- /usr/lib/vxvm/bin/vxdiskunsetup <c#t#d# or mirror drive>
- cd /etc
- ls *.prevm
(verify that vfstab & system exist, if so)
mv system system-
mv vfstab vfstab-
cp system.prevm system
cp vfstab.prevm vfstab
** (the mounts in the vfstab.prevm should match the slices in the output of:
prtvtoc /dev/rdsk/<bot_device>s2) **
o unencapsulate boot drive
- vxunroot (yes to reboot)
(returns boot drive to booting from native slices)

o uninstall 3.2 (remove pkgs & kill processes)
- … kill vx processes if they exist (ps -aef|grep vx) …
- cp -r /etc/vx/licenses/elm /var/tmp
- pkgrm <all “VRTS” pkgs in /opt> (ls /opt/VRTS*|grep -v VRTS)
- rm -r /opt/VRTS*
- rm -r /etc/vx /var/vx
- reboot

o install SF 5.0 (and MP2 or latest release)
- … verify that no vx processes have started …
- uncompress & untar installation archive
(5.0 base release; must be downloaded from Customer Care; serial # require via license upgrade)
- run installsf
(or install<product_initials> ; ie … installvm for Volume Manager)
- uncompress & untar MP1 archive
(http://support.veritas.com/docs/288505)
- run installmp
(see included README and release notes)

o if data disks are connected, verify the output of vxdisk list (the TYPE column)
- auto:none (new uninitialized disks)
- auto:sliced (encapsulated disks containg slices)

o encapsulate & mirror root drive
- use vxdctl bootdg rootdg to create default rootdg disk group
- use vxdiskadm to encapsulate and mirror boot drive
(a spare drive must be initialized as sliced and belong to rootdg; vxdiskadm option 1)
(options 2 & 6)
- reboot

o upgrading data disks
- … import data disk groups …
- vxdg import datadg
- use “vxdg upgrade” to upgrade diskgroup versions
command: vxdg upgrade <diskgroup name>
- mount all data volumes
- use vxupgrade to upgrade vxfs filesystem versions one version at a time if appropriate
o use ‘fstyp <device> | grep version’ to determine starting version
- use fsck (-o full) then vxupgrade to next version
(command: vxupgrade [-n new_version] mount_point )
(repeat until version 7 is reached)
(repititious fsck -o full can be timely but is best practice)

May 30, 2008

Dynamic Relocation of HDD’s in Solaris Volume Manager

Filed under: Solaris Volume Manager, Sun Solaris OS — birutpatel @ 1:53 pm

 Dynamic Relocation of HDD’s in Solaris Volume Manager
===========================================

 Let say you have a Solaris 10 box connected to StorEdge S1 Array’s
 having boot disks in it as below.

 Array 1:   Array 2: 

 c0t0d0 (rootdisk) c1t0d0  (mirrordisk)
 c0t1d0 (not in use) c1t1d0  (rootdg)  
 c0t2d0 (rootdg)  c1t2d0  (rootdg) 

 Now you are doing live-upgrade to Solaris 10 on disk c0t1d0, and
 mirroed the disk with c1t0d0 using Solaris Volume Manager. Later
 on decided to move that disk to location c0t0d0. Is it possible
 without breaking the mirror?

 YES, you can do it as Solaris 10 SVM allows HOT Relocation of disk
 similar to Veritas Volume Manager.

 Run metastat and look for field “Reloc”. If it say Yes, that means
 you can relocate the disk.

 d17: Submirror of d7
    State: Okay
    Size: 196437504 blocks (93 GB)
    Stripe 0:
        Device     Start Block  Dbase        State Reloc Hot Spare
        c1t0d0s7          0     No            Okay    Yes

 Device Relocation Information:
 Device   Reloc  Device ID
 c0t1d0   Yes    id1,sd@n5000c5000781e83f
 c1t0d0   Yes    id1,sd@n5000c500078208c7

 Follow the procedure:

 - bring down the machine to ok prompt.
 - swap the disk c0t1d0 with c0t0d0.
 - boot the system up.
 - SVM will update the database automatcally without affecting the
   mirror.
 - verify the state of mirror using metastat.

Working with Solaris Volume Manager

Filed under: Sun Solaris OS — birutpatel @ 10:41 am

How to boot from SDS mirror disk
=======================================

 - c0t0d0 – rootdisk
 - c0t1d0 – mirrordisk

 - Find out the alias if any in eeprom
 - Boot from CD or jumpstart or anyway and mount the S0 of mirror disk.
 
 e.g. # mount /dev/dsk/c0t1d0s0 /mnt

 # vi /mnt/etc/vfstab

 modify all /dev/md/dsk/d0 ,d1, d2, d3 entries back to cxtxdxsx format.

 # vi /etc/system

 comment out rootdev:/pseudo/md@0:0,10,blk entry as below.

 * rootdev:/pseudo/md@0:0,10,blk

 # init 0 :go to ok prompt

 {0} ok boot mirrordisk

System Should come up normally.
Boot from main disk – root disk after mirror detach:
==========================================================

No modification required, system should boot normally

 

How to clear out all meta devices even from root disk:
==========================================================

 - detach mirror
 - clear mirror metadevices (submirrors)
 - modify /etc/vfstab and /etc/system in mirror disk, so incase you have to
   boot from mirror, you can boot from it.
 - modify /etc/vfstab and /etc/system same way as mirror disk, to completely
   clear md devices and change back to ctd format.

 

Blog at WordPress.com.