Tuesday, August 2, 2011

Procedure to replace VxVM Bootdisk(i.e for rootdisk02)

Ex:
 Here is disk c2t0d0(rootdisk02) you needs to replace the c2t0d0 from all the commands below to the correct device file of rootdisk02, etc




a) If the disk is failed then vxdisk list will show the following:

# vxdisk list

DEVICE TYPE DISK GROUP STATUS

c0t0d0 simple rootdisk01 rootdg online

c2t0d0 simple - - failed

- - rootdisk02 rootdg failed was:c2t0d0



b) Replace the faulty disk c2t0d0:

#ioscan -fnCdisk



Ensure disk is CLAIMED



#vxdctl enable

#vxdisk list

DEVICE TYPE DISK GROUP STATUS

c0t0d0 simple rootdisk01 rootdg online

c2t0d0 simple - - online Invalid

- - rootdisk02 rootdg failed was:c2t0d0



c) Remove the disk rootdisk02 from vxdiskadm ==> Option 3

After that vxdisk list should show like this

#vxdisk list

DEVICE TYPE DISK GROUP STATUS

c0t0d0 simple rootdisk01 rootdg online

c2t0d0 simple - - online Invalid

- - rootdisk02 rootdg removed was:c2t0d0



d) OPTIONAL STEP

Note : If you have latest VxVM Command patches are installed then there is no need to do vxdisk rm c2t0d0 i.e step d)



If you got the following error when we are doing

vxdisksetup -iB then use step d) otherwise not required



#/etc/vx/bin/vxdisksetup -iB c2t0d0

vxvm:vxdisk: ERROR: Device c2t0d0: define failed:

Attribute cannot be changed with a reinit



#vxdisk rm c2t0d0



After that vxdisk will show like this

#vxdisk list

DEVICE TYPE DISK GROUP STATUS

c0t0d0 simple rootdisk01 rootdg online

- - rootdisk02 rootdg removed was:c2t0d0



e) Initialize the replacement disk

#/etc/vx/bin/vxdisksetup -iB c2t0d0

Ensure private offset length is 2144 from the command: vxdisk list c2t0d0

# vxdisk list c2t0d0



private: slice=0 offset=2144 len=1024





f) Use vxdiskadm option 4 to replace the disk

This will automatically start the syncing the volumes

Check the status of the mirror with the command: vxtask list



# vxtask list

TASKID PTID TYPE/STATE PCT PROGRESS

165 PARENT/R 75.00% 8/6(1) VXRECOVER

165 165 ATCOPY/R 20.32% 0/1093632/222208 PLXATT usrvol usrvol-02





g) Configure the LIF area and boot,swap,root information

#/etc/vx/bin/vxbootsetup rootdisk02



Ensure LIF Area and boot,swap,root configuration are correct & check ISL and HPUX are there

#lifls /dev/rdsk/c2t0d0

ODE MAPFILE SYSLIB CONFIGDATA SLMOD2

SLDEV2 SLDRV2 SLSCSI2 MAPPER2 IOTEST2

PERFVER2 PVCU SSINFO ISL HPUX

AUTO LABEL



Check boot,swap,root are configured properly

#vxvmboot -v /dev/rdsk/c2t0d0

LIF Label File @ (1k) block # 1434 on VxVM Disk /dev/rdsk/c2t0d0:

Label Entry: 0, Boot Volume start: 3168; length: 350 MB

Label Entry: 1, Root Volume start: 8750176; length: 512 MB

Label Entry: 2, Swap Volume start: 361568; length: 8192 MB

Label Entry: 3, Dump Volume start: 361568; length: 8192 MB



Ensure all the volumes and plexs belongs to rootdisk02 are in enabled and active states with vxprint command

If required use vxrecover -b command once again and verify everything is proper



Once all the disks are fine, if downtime permits try to boot the server with rootdisk02 hardware path.





No comments:

Post a Comment