Hi All,
Some SAN Environments that I manage has lots of Hosts connected to Storage Arrays. It is difficult to manage them through documenting. Any command or script which will show me the Host Group Names. This will help me in automating most of the daily work.
Thanks,
Avradeep Bhattacharya
Example of locking the array, changing label on LDEV, creating two host groups, adding WWNs to host groups, allocating LUN, and setting host mode options. Commands are long so watch for line wraps below. Also attached them as attachment. Also Commands are being executed on a VSP (R700).
Also my credentials and URL to HCS server is configured in my properties file so I don't have to specify them every time.
I use the included reports in tuning manager 7.6. They work great. (See attachment.) These reports must be imported to use. You also have to be running at minimum agent for raid 7.2 I believe.
./HiCommandCLI.sh AddArrayReservation serialnum=12345 model=R700
/share/HCSCLI/HiCommandCLI AddHost "hostname=hostabc" "wwnlist=00.01.00.80.02.A3.0B.A0,00.01.00.80.02.A3.0B.A2" >> /tmp/1444789.log 2>&1
/share/HCSCLI/HiCommandCLI ModifyLabel "serialnum=12345" "model=R700" "devnums=00:3E:0C" "label=Boot_hostabc" >> /tmp/1444789.log 2>&1
/share/HCSCLI/HiCommandCLI AddHostStorageDomain "serialnum=12345" "model=R700" "portname=CL1-C" "domain=7" "hostmode=HP" "hostmodeoption=12;40;43" "nickname=hostabc" >> /tmp/1444789.log 2>&1
/share/HCSCLI/HiCommandCLI AddHostStorageDomain "serialnum=12345" "model=R700" "portname=CL2-C" "domain=7" "hostmode=HP" "hostmodeoption=12;40;43" "nickname=hostabc" >> /tmp/1444789.log 2>&1
/share/HCSCLI/HiCommandCLI AddWWNForHostStorageDomain "serialnum=12345" "model=R700" "portname=CL1-C" "domain=7" "wwn=00.01.00.80.02.A3.0B.A0" "wwnnickname=hostabc_ba11_p4_26_a" >> /tmp/1444789.log 2>&1
/share/HCSCLI/HiCommandCLI AddWWNForHostStorageDomain "serialnum=12345" "model=R700" "portname=CL2-C" "domain=7" "wwn=00.01.00.80.02.A3.0B.A2" "wwnnickname=hostabc_ba10_p4_26_a" >> /tmp/1444789.log 2>&1
/share/HCSCLI/HiCommandCLI AddLun "serialnum=12345" "model=R700" "portname=CL1-C" "domain=7" "lun=000" "devnum=00:3E:0C" >> /tmp/1444789.log 2>&1
/share/HCSCLI/HiCommandCLI AddLun "serialnum=12345" "model=R700" "portname=CL2-C" "domain=7" "lun=000" "devnum=00:3E:0C" >> /tmp/1444789.log 2>&1
/share/HCSCLI/HiCommandCLI ModifyPort "serialnum=12345" "model=R700" "portname=CL1-C" "domain=7" "hostmode=HP" "hostmodeoption=12;40;43;60" >> /tmp/1444789.log 2>&1
/share/HCSCLI/HiCommandCLI ModifyPort "serialnum=12345" "model=R700" "portname=CL2-C" "domain=7" "hostmode=HP" "hostmodeoption=12;40;43;60" >> /tmp/1444789.log 2>&1
./HiCommandCLI.sh DeleteArrayReservation serialnum=12345 model=R700