he following is a procedure I used to hot swap a disk that was part of a mirror on a system.
# remove d1 and d4 devices from the arrays
root@server:# metadetach -f d0 d1
root@server:# metadetach -f d3 d4
# clear the data from the faulty disks
root@server:# metaclear d1
root@server:# metaclear d4
# clear the svm database from the faulty disk
root@server:# metadb -f -d c1t0d0s7
root@server:# format
# find where the faulty disk is
root@server:# cfgadm -alv
# remove the disk from the kernel
root@server:# cfgadm -c unconfigure c1::dsk/c1t0d0
# check the disk no longer appears
### If disk has gone then hot swap the disk ###
root@server:# format
# Tell the kernel about the device
root@server:# cfgadm -c configure c1::dsk/c1t0d0
# copy the vtoc from existing disk to new disk
root@server:# prtvtoc /dev/rdsk/c1t1d0s0 > /vtoc.c1t1d0s0
root@server:# fmthard -s /vtoc.c1t1d0s0 /dev/rdsk/c1t0d0s0
# Initialize and add the new disk to each array
root@server:# metainit d1 1 1 c1t0d0s1
root@server:# metattach d0 d1
root@server:# metainit d4 1 1 c1t0d0s0
root@server:# metattach d3 d4
# create the svm databases
root@server:# metadb -a -c 3 c1t0d0s7
# make the new disk bootable
root@server:# installboot /usr/platform/`uname -i`/lib/fs/ufs/bootblk /dev/rdsk/c1t0d0s0
Friday, May 22, 2009
Hot swap a disk from an array
Labels:
UNIX
Subscribe to:
Post Comments (Atom)
0 comments:
Post a Comment