I was wondering if there was a command line available in the ESX server to place a LUN in an "offline" state.
If you want to turn a path to a lun off you can do something like this:
log]# esxcfg-mpath --path=vmhba1:0:0 --state=off --lun=vmhba1:0:0
Setting vmhba1:0:0 -- vmhba1:0:0 state to off
Disk vmhba1:0:0 /dev/sda (258052MB) has 2 paths and policy of Fixed
FC 5:7.0 210000e08b1a3472<->50060e8014427b00 vmhba1:0:0 Off
FC 5:7.1 210100e08b3a3472<->50060e8014427b10 vmhba2:0:0 On active preferred
What are you trying to do?
I think you would be better off doing something at the storage level such as making hte LUN read-only os simply masking it from the ESX hosts?
If you want to turn a path to a lun off you can do something like this:
log]# esxcfg-mpath --path=vmhba1:0:0 --state=off --lun=vmhba1:0:0
Setting vmhba1:0:0 -- vmhba1:0:0 state to off
Disk vmhba1:0:0 /dev/sda (258052MB) has 2 paths and policy of Fixed
FC 5:7.0 210000e08b1a3472<->50060e8014427b00 vmhba1:0:0 Off
FC 5:7.1 210100e08b3a3472<->50060e8014427b10 vmhba2:0:0 On active preferred