Delete EVA vdisk using HP SSSU (How to Article)

HP SSSU(Storage System Scripting Utility)command line interface is a speedy way to configure and control EVA storage systems, especially when we have to run repetitious and complex configuration tasks. Using HP Command View EVA graphical user interface for complex and repetitive tasks, is really time consuming and most of the time you may have to wait for the screen to refresh. I had a similar situation, where I am supposed to delete 200 vdisks and SSSU saved my life.

Let's see how can we do this in a better way!

Most of the time, SSSU will be installed along with your CV-EVA GUI software and you should be able to see the icon on your desktop.
Click on the desktop shortcut to open SSSU in interactive mode.

You will see a session as below,

SSSU for HP StorageWorks Command View EVA
Version: 9.3.0
Build: 072310A
Manager:

If you are loggedin to the management server,enter localhost else use the IP address of the management server. Use your EVA credentials to login.

Manager:localhost
Username:admin
Password:
NoSystemSelected>

To view available storage systems, enter the following command:
LS SYSTEM
NoSystemSelected> ls system
Systems available on this Manager:
  EVA02
  EVA03
  EVA04

To select a storage system to manage, enter the following command:
SELECT SYSTEM

NoSystemSelected> select system EVA03

To view the information about the hosts configured for the currently selected storage system enter the following command:
LS HOST

EVA03> ls host
Hosts available on this Cell:
  \Hosts\ESX\ESX01
  \Hosts\ESX\ESX02
  \Hosts\ESX\ESX03

to view the information about the LUNs configured for the selected storage system enter the following command
LS LUN

EVA03> ls lun
LUNs available on this Cell:
  \Hosts\ESX\ESX01\1
  \Hosts\ESX\ESX02\1
  \Hosts\ESX\ESX03\1
  \Hosts\ESX\ESX04\1
  \Hosts\ESX\ESX05\1
  \Hosts\ESX\ESX01\3
  \Hosts\ESX\ESX02\3
  \Hosts\ESX\ESX03\3
  \Hosts\ESX\ESX04\3
  \Hosts\ESX\ESX05\3

to view the information about the virtual disks for the currently selected storage system you have to enter the following command
LS VDISK

EVA03> ls vdisk
Vdisks available on this Cell:
  \Virtual Disks\ESX01-05\ESX01-05_LUN01\ACTIVE
  \Virtual Disks\ESX01-05\ESX01-05_LUN03\ACTIVE
  \Virtual Disks\ESX01-05\ESX01-05_LUN02\ACTIVE

now it is the time for me to delete the lun mapping from these servers. I have used the combination of two commands in a script to delete the vdisks permanently from the storage system and those commands are DELETE LUN and DELETE VDISK.

The "DELETE LUN" command removes access to a virtual disk from a host. While the "DELETE VDISK" command permanently removes the specified virtual disk. The virtual disk is no longer accessible and all data is lost.DELETE VDISK command will be rejected if the virtual disk is presented, so we have to unpresent the disk before we delete it.

My Script had two segments, one is to unpresent the luns and the other to delete the vdisk. This is how I did it

EVA03> DELETE LUN \Hosts\ESX\ESX01\1
Enter the remaining disk one by one. once it is completed, issue the command for deletion.

EVA03> DELETE VDISK "\Virtual Disks\ESX01-05\ESX01-05_LUN01" WAIT_FOR_COMPLETION
Enter the remaining disk one by one till all the disks are inculded in the script.

WAIT_FOR_COMPLETION option is used with DELETE VDISK command to stops executing further management commands from any other session until the DELETE VDISK command is complete.Once issued, the system waits for the command to finish before displaying the SSSU command prompt or running another command or script.

Now we are done! Enjoy.

No comments :

Post a Comment

Admin Helpline™ © , All Rights Reserved.
Privacy Policy