Thursday, December 8, 2011

Storage Path Masking

This is VMware's approach for LUN masking. (after array level presenting, and switch level Zoning)

Storage is VMware preferred first step for drop a datastore from a host

Starting vSphere, esxcli corestorage is used to handle path masking, instead of previous configuration file editing.

 esxcli corestorage claiming is temporary, it won't survive the reboot.

Claim Rule modification does not operate on the VMkernel directly. Changing the current claim rules requires two steps:
  1. a call to add/remove/move claim rule: esxcli corestorage claimrule add/delete/move
  2. a call to esxcli corestorage claimrule load to load the change from config file to VMkernel.
vSphere is using MASK_PATH plugin as claim rule to implement storage path masking, instead of modifying configuration file.The rule ID is from 0 to 64k-1, and rule 101 to 65435 is available for general use.

Here are the steps for Path Masking:
  1. esxcli corestorage claimrule add --plugin MASK_PATH --rule <rule ID> --type location -A <adapter> -C <> -T <>  -L <>
  2. esxcli corestorage claimrule list to verify
  3. esxcli corestorage claimrule load to load the new rules into VMkernel
  4. esxcli corestorage claiming unclaim (remove old rules)
  5. esxcli corestorage claimrule run (run the path claiming rule without reboot)
Accordingly, here are the steps for unmasking a path:

  1. esxcli corestorage claimrule delete  --rule <rule ID> --type location -A <adapter> -C <> -T <>  -L <>
  2. esxcli corestorage claimrule list to verify
  3. esxcli corestorage claimrule load to load the new rules into VMkernel
  4. esxcli corestorage claiming unclaim (remove old rules)
  5. esxcli corestorage claimrule run (run the path claiming rule without reboot)

No comments:

Post a Comment