Knowledge
- Identify RAID levels
- Identify supported HBA types
- Identify virtual disk format types
Skills and Abilities
- Determine use cases for and configure VMware DirectPath I/O
- Determine requirements for and configure NPIV
- Determine appropriate RAID level for various Virtual Machine workloads
- Apply VMware storage best practices
- Understand use cases for Raw Device Mapping
- Configure vCenter Server storage filters
- Understand and apply VMFS resignaturing
- Understand and apply LUN masking using PSA-related commands
- Analyze I/O workloads to determine storage performance requirements
Tools
- Fibre Channel SAN Configuration Guide
- iSCSI SAN Configuration Guide
- ESX Configuration Guide
- ESXi Configuration Guide
- vSphere Command-Line Interface Installation and Scripting Guide
- Product Documentation
- vSphere Client
- vscsiStats
- vSphere CLI
- vicfg-*
- vifs
- vmkfstools
- esxtop/resxtop
Notes
Determine use cases for and configure VMware DirectPath I/O
VMware DirectPath I/O allows a guest VM to directly access an I/O device via bypassing the virtualization layer. This can result in improved performance and a good use case would be 10 Gigabit Ethernet for guests requiring a lot of network throughput.
Requirements from VMware’s Direct Path I/O documentation:
- VMDirectPath supports a direct device connection for virtual machines running on Intel Xeon 5500 systems, which feature an implementation of the I/O memory management unit (IOMMU) called Virtual Technology for Directed I/O (VT-d). VMDirectPath can work on AMD platforms with I/O Virtualization Technology (AMDIOMMU), but this configuration is offered as experimental support.
- Some machines might not have this technology enabled in the BIOS by default
- Each guest can support up to two pass through devices.
A good guide to setup DirectPath I/O can be found at Petri It Knowledgebase.
Determine requirements for and configure NPIV
So far the best resource I’ve found for how to configure NPIV is Simon Long’s blog which also references a great
article from Jason Boche’s blog.
NPIV allows a single N_PORT to have multiple WWPNs and multiple N_PORT IDs. This requires a supported set of hardware, includes HBAs and Switches. With NPIV you could present a LUN to a specific virtual machine, something which is not possible without NPIV. Also it is good to bring up NPV, or N_Port Virtualization in which we talk about NP_Ports. The NP_Port will look like an NPIV host to the F_Port. This requires support from the upstream switch. Ultimately NPV allows you to add switches and ports to the fabric without requiring more domain ids. Another good read on NPIV is this blog from Scott Lowe.
There are some specific requirements to using NPIV:
- It can only be used with Raw Device Mappings.
- You must have NPIV aware FC switches
- ESX(i) hosts must have HBAs that support NPIV. This is currently limited to QLogic and Emulex with NPIV compatible firmware. I suspect this may have been expanded since some of the information I’ve read may be a little older.
Determine appropriate RAID level for various Virtual Machine workloads
Similar to sizing physical servers, you will want to ensure your virtual machine workloads are evenly distributed (remember SCSI reservations) and on appropriately given storage for performance purposes. The determination of the RAID level of the storage will be made on a per virtual machine basis. I recommend reading the below to start thinking about how to best go about sizing virtual machine workloads.
Duncan Epping has a discussion over on his blog which highlights the write penalty and overall performance of different RAID levels, showing the differences in writes. For the test reads were consistent across the board, but
writes suffered differently. Check out this chart which shows a real life example.
Apply VMware storage best practices
Read these two to help gain a better understanding of best practices for storage.
- VMware Best Practices for virtual storage
- vSphere 4.1 Performance Guide
- By default, Active/Passive storage arrays use Most Recently Used path policy.
- Do not use Fixed Path policy for Active/Passive storage arrays to avoid LUN thrashing.
Understand use cases for Raw Device Mapping
Raw device mappings allow management and access of raw SCSI disks or LUNs as VMFS files. An RDM file exists on a VMFS volume acting as a proxy for the device, which contains metadata used for managing and redirecting access to the physical disk.
A good read is the blog here which discusses why RDMs should probably not be used for performance purposes. Its main source of information comes from VMware’s write-up for Performance Characterization of VMFS and RDM Using a SAN.
According to VMware:
- The main conclusions that can be drawn from the tests described in this study are: for random reads and writes, VMFS and RDM yield a similar number of I/O operations per second.
- For sequential reads and writes, performance of VMFS is very close to that of RDM (except on sequential reads with an I/O block size of 4K).
- Both RDM and VMFS yield a very high throughput in excess of 300megabytes per second depending on the I/O block size.
- For random reads and writes, VMFS requires 5 percent more CPU cycles per I/O operation compared to RDM.
- For sequential reads and writes, VMFS requires about 8 percent more CPU cycles per I/O operation compared to RDM.
You can configure RDM in two ways:
- Virtual compatibility mode-this mode fully virtualizes the mapped device, which appears to the guest operating system as a virtual disk file on a VMFS volume. Virtual mode provides such benefits of VMFS as advanced file locking for data protection and use of snapshots.
- Physical compatibility mode-this mode provides access to most hardware characteristics of the mapped device. VMkernel passes all SCSI commands to the device, with one exception, thereby exposing all the physical characteristics of the underlying hardware.
VMFS is the preferred option for most enterprise applications such as databases, ERP, CRM, VMware Consolidated Backup, Web servers, and file servers. Some of the common uses of RDM are in cluster data and quorum disks for configurations using clustering between virtual machines or between physical
and virtual machines or for running SAN snapshot or other layered applications in a virtual machine.
When using RDMs you are limited in some of the actions you can perform:
- No migrating VMs with physical mode RDMs if the migration involves copying the disk (Storage vMotion)
- No VMware snapshots with physical mode RDMs
- No VCB support with physical mode RDMs, because VCB requires VMware snapshots
- No cloning VMs that use physical mode RDMs
- No converting VMs that use physical mode RDMs into templates
Configure vCenter Server storage filters
A couple of good blogs can be found here and here for some background on the topic.
To turn off vCenter Server Storage Filters (from the ESX configuration guide):
When you perform VMFS datastore management operations, vCenter Server uses default storage filters. The filters help you to avoid storage corruption by retrieving only the storage devices, or LUNs, that can be used for a particular operation. Unsuitable LUNs are not displayed for selection. You can turn off the filters to view all LUNs.
Before making any changes to the LUN filters, consult with the VMware support team. You can turn off the filters only if you have other methods to prevent LUN corruption.
Procedure
- In the vSphere Client, select Administration > vCenter Server Settings.
- In the settings list, select Advanced Settings.
- In the Key text box, type a key.
- config.vpxd.filter.vmfsFilter
- config.vpxd.filter.rdmFilter
- config.vpxd.filter.SameHostAndTransportsFilter
- config.vpxd.filter.hostRescanFilter
- NOTE: If you turn off the Host Rescan Filter, your hosts continue to perform a rescan each time you present a new LUN to a host or a cluster.
- In the Value text box, type False for the specified key.
- Click Add.
- Click OK.
- You are not required to restart the vCenter Server system.
Understand and apply VMFS resignaturing
Check out this KB article from VMware that will explain further VMFS resignaturing and how to do it from the GUI or command line. Prior to vSphere 4 enabling resignaturing was done server wide and applied to all volumes of the host. Now, with the use of the esxcfg-volume/vicfg-volume commands this can be done per volume.
The vicfg-volume command supports resignaturing a snapshot volume and mounting and unmounting the volume. You can also make the mounted volume persistent across reboots and query a list of snapshot volumes and original volumes. Remember, this command is for volumes with snapshots only and as such will only list those volumes.
See the vSphere CLI Reference for full syntax and usage of the vicfg-volume command.
Understand and apply LUN masking using PSA-related commands
Check out Masking a LUN from ESX and ESXi 4.0 using the MASK_PATH plug-in.
Refer to Sean Crookston’s study topic on troubleshooting storage performance.
Analyze I/O workloads to determine storage performance requirements
Refer to Sean Crookston’s study topic on troubleshooting storage performance and checkout this great technical paper that goes in depth on the topic.