In the event a disk needs to be removed from the system.
Procedure to remove devices.
Let's list all available devices:
# vxdisk list
DEVICE TYPE DISK GROUP STATUS
c0t0d0 auto:LVM - - LVM
c0t1d0s2 auto:LVM - - LVM
c2t15d0 auto:cdsdisk - - online << NEED TO REMOVE THIS
c2t15d1 auto:cdsdisk - - online
c2t15d2 auto:cdsdisk - - online
c2t15d3 auto:cdsdisk - - online
c2t15d4 auto:none - - online invalid
c2t15d5 auto:none - - online invalid
# vxdisk list c2t15d0
Device: c2t15d0
devicetag: c2t15d0
type: auto
hostid: sprigniteip-04
disk: name= id=1275982469.34.sprigniteip-04
group: name=nbudg id=1275909889.34.sprigniteip-04
info: format=cdsdisk,privoffset=128
flags: online ready private autoconfig autoimport
pubpaths: block=/dev/vx/dmp/c2t15d0 char=/dev/vx/rdmp/c2t15d0
guid: {459aee30-1dd2-11b2-8f6d-00226493af1d}
udid: HITACHI%5FDF600F%5F73061247%5F0154
site: -
version: 3.1
iosize: min=512 (bytes) max=256 (blocks)
public: slice=0 offset=1152 len=10443648 disk_offset=0
private: slice=0 offset=128 len=1024 disk_offset=0
update: time=1283948737 seqno=0.26
ssb: actual_seqno=0.1
headers: 0 120
configs: count=1 len=640
logs: count=1 len=96
Defined regions:
config priv 000024-000119[000096]: copy=01 offset=000000 enabled
config priv 000128-000671[000544]: copy=01 offset=000096 enabled
log priv 000672-000767[000096]: copy=01 offset=000000 enabled
lockrgn priv 000768-000839[000072]: part=00 offset=000000
Multipathing information:
numpaths: 1
c2t15d0 state=enabled type=primary
Let's check which persistent DSF is related to our device (ie the one to be removed)
# ioscan -m dsf
Persistent DSF Legacy DSF(s)
========================================
/dev/rdisk/disk2 /dev/rdsk/c0t1d0
/dev/rdisk/disk2_p1 /dev/rdsk/c0t1d0s1
/dev/rdisk/disk2_p2 /dev/rdsk/c0t1d0s2
/dev/rdisk/disk2_p3 /dev/rdsk/c0t1d0s3
/dev/rdisk/disk3 /dev/rdsk/c0t0d0
/dev/rdisk/disk5 /dev/rdsk/c1t0d0
/dev/rdisk/disk12 /dev/rdsk/c2t15d0 <<<< HERE
/dev/rdisk/disk13 /dev/rdsk/c2t15d1
/dev/rdisk/disk14 /dev/rdsk/c2t15d2
/dev/rdisk/disk15 /dev/rdsk/c2t15d3
/dev/rdisk/disk16 /dev/rdsk/c2t15d4
/dev/rdisk/disk17 /dev/rdsk/c2t15d5
Then retrieve device information:
# scsimgr get_info -D /dev/rdisk/disk12
STATUS INFORMATION FOR LUN : /dev/rdisk/disk12
Generic Status Information
SCSI services internal state = ONLINE <<< IS ONLINE SINCE CURRENTLY IN USE BY VXVM
Device type = Direct_Access
EVPD page 0x83 description code = 2
EVPD page 0x83 description association = 0
EVPD page 0x83 description type = 1
World Wide Identifier (WWID) = "HITACHI 730612470340"
Serial number = "730612470154 "
Vendor id = "HITACHI "
Product id = "DF600F "
Product revision = "0000"
Other properties = ""
SPC protocol revision = 3
Open count (includes chr/blk/pass-thru/class) = 2 <<< IS NOT 0 SINCE DEVICE IS OPENED
Raw open count (includes class/pass-thru) = 2 <<< IS NOT 0 SINCE DEVICE IS OPENED
Pass-thru opens = 0
LUN path count = 1
Active LUN paths = 1
Standby LUN paths = 0
Failed LUN paths = 0
Maximum I/O size allowed = 2097152
Preferred I/O size = 2097152
Outstanding I/Os = 0
I/O load balance policy = round_robin
Path fail threshold time period = 0
Transient time period = 120
Tracing buffer size = 1024
LUN Path used when policy is path_lockdown = NA
LUN access type = NA
Asymmetric logical unit access supported = No
Asymmetric states supported = NA
Preferred paths reported by device = No
Preferred LUN paths = 0
Driver esdisk Status Information :
Capacity in number of blocks = 20971520
Block size in bytes = 512
Number of active IOs = 0
Special properties =
Maximum number of IO retries = 45
IO transfer timeout in secs = 30
FORMAT command timeout in secs = 86400
START UNIT command timeout in secs = 60
Timeout in secs before starting failing IO = 120
IO infinite retries = false
Let's remove the device from VxVM:
# vxdisk rm c2t15d0
Then check the status at IOS level
# scsimgr get_info -D /dev/rdisk/disk12
STATUS INFORMATION FOR LUN : /dev/rdisk/disk12
Generic Status Information
SCSI services internal state = UNOPEN <<< NOT LONGER IN USE
Device type = Direct_Access
EVPD page 0x83 description code = 2
EVPD page 0x83 description association = 0
EVPD page 0x83 description type = 1
World Wide Identifier (WWID) = "HITACHI 730612470340"
Serial number = "730612470154 "
Vendor id = "HITACHI "
Product id = "DF600F "
Product revision = "0000"
Other properties = ""
SPC protocol revision = 3
Open count (includes chr/blk/pass-thru/class) = 0 <<< NOW ARE 0 SINCE DEVICE IS NOT IN USE
Raw open count (includes class/pass-thru) = 0 <<< NOW ARE 0 SINCE DEVICE IS NOT IN USE
Pass-thru opens = 0
LUN path count = 1
Active LUN paths = 1
Standby LUN paths = 0
Failed LUN paths = 0
Maximum I/O size allowed = 2097152
Preferred I/O size = 2097152
Outstanding I/Os = 0
I/O load balance policy = round_robin
Path fail threshold time period = 0
Transient time period = 120
Tracing buffer size = 1024
LUN Path used when policy is path_lockdown = NA
LUN access type = NA
Asymmetric logical unit access supported = No
Asymmetric states supported = NA
Preferred paths reported by device = No
Preferred LUN paths = 0
Driver esdisk Status Information :
Capacity in number of blocks = 20971520
Block size in bytes = 512
Number of active IOs = 0
Special properties =
Maximum number of IO retries = 45
IO transfer timeout in secs = 30
FORMAT command timeout in secs = 86400
START UNIT command timeout in secs = 60
Timeout in secs before starting failing IO = 120
IO infinite retries = false
Note: since device is not longer in use, the device definition cane be removed along with all special file(s) referring to it:
# rmsf -[v]a /dev/rdisk12 (it's possible to add -v option in order to get information about rmsf activity)
It is now possible to refresh VxVM configuration as usual:
# rm /dev/vx/rdmp/*
# rm /dev/vx/dmp/*
# mv /etc/vx/array.info /etc/vx/array.info.000
# mv /etc/vx/disk.info /etc/vx/disk.info.000
# vxconfigd -k -m enable
Let's check whic revices are currently available:
# vxdisk list
DEVICE TYPE DISK GROUP STATUS
c0t0d0 auto:LVM - - LVM
c0t1d0s2 auto:LVM - - LVM
c2t15d1 auto:cdsdisk - - online
c2t15d2 auto:cdsdisk - - online
c2t15d3 auto:cdsdisk - - online
c2t15d4 auto:none - - online invalid
c2t15d5 auto:cdsdisk - - online