Understand and apply LUN masking using PSA-related commands P2

Part#2 LUN masking by Vendor:
We will be Masking All LUNs from vendor openfiler:

esxcli storage core device list

This highlighted one should be left as it is local disk and not OPENFILER LUN type:

Listing the target LUN willing to hide:

At first try one LUN was masked , other 2 were not:

~ # esxcli storage core claimrule add –rule 300 -t vendor -V OPNFILER -P MASK_PATH

~ # esxcli storage core claimrule load

~ # esxcli storage core claimrule run

~ # esxcli storage core claiming reclaim -d t10.F405E46494C454256514C41787A4D266F69615D293F666E6

Unable to unclaim path vmhba33:C0:T0:L0 on device t10.F405E46494C454256514C41787A4D266F69615D293F666E6.
esxcli storage core adapter rescan –all
Some paths may be left in an unclaimed state. You will need to claim them manually using the appropriate commands or wait for periodic path claiming to reclaim them automatically.

~ # esxcli storage core claiming reclaim -d t10.F405E46494C45425A59347A6A5C6D213A57403D2E497A6A4

~ # esxcli storage core claiming reclaim -d t10.F405E46494C4542564F6F6154547D22436E646D2474705D6

Unable to unclaim path vmhba33:C0:T0:L1 on device t10.F405E46494C4542564F6F6154547D22436E646D2474705D6.
Some paths may be left in an unclaimed state. You will need to claim them manually using the appropriate commands or wait for periodic path claiming to reclaim them automatically.

~ # esxcli storage core adapter rescan –all

I suspected there’s some IO access with the 2 remaining datastores, trying to unmount , I had 3 things to fix

-> I removed SIOC option:

-> Migrated all VMs which were already shutdown.

-> Taking those 2 Datastores outside my Storage cluster:

I had to run the below commands one more times after scanning storgae :

/var/log # esxcli storage core claiming reclaim -d t10.F405E46494C454256514C41787A4D266F69615D293F666E6

esxcli storage core claiming reclaim -d t10.F405E46494C45425A59347A6A5C6D213A57403D2E497A6A4

esxcli storage core claiming reclaim -d t10.F405E46494C4542564F6F6154547D22436E646D2474705D6

/var/log # esxcli storage core claiming reclaim -d t10.F405E46494C45425A59347A6A5C6D213A57403D2E497A6A4

Unknown Device name t10.F405E46494C45425A59347A6A5C6D213A57403D2E497A6A4

/var/log # esxcli storage core claiming reclaim -d t10.F405E46494C4542564F6F6154547D22436E646D2474705D6

Unable to unclaim path vmhba33:C0:T0:L1 on device t10.F405E46494C4542564F6F6154547D22436E646D2474705D6. Some paths may be left in an unclaimed state. You will need to claim them manually using the appropriate commands or wait for periodic path claiming to reclaim them automatically.

/var/log # esxcli storage core claiming reclaim -d t10.F405E46494C4542564F6F6154547D22436E646D2474705D6

/var/log #

Now No LUNs from Vendor type Open filer is there:


->Now
we revert back mask for a whole vendor

esxcli storage core claimrule list

esxcli storage core claimrule remove -r 300

esxcli storage core claimrule load

esxcli storage core claiming unclaim -t vendor -v OPNFILER

esxcli storage core claiming unclaim -t location -A vmhba33

esxcli storage core adapter rescan -A vmhba33

Welcome back babies 🙂

And from GUI :

Advertisements

About Ahmad Sabry ElGendi

https://www.linkedin.com/pub/ahmad-elgendi/94/223/559
This entry was posted in Objective 1.1 – Implement Complex Storage Solutions, Section 1 – Implement and Manage Storage, VCAP5-DCA, Vmware. Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s