Use PowerCLI to apply your vSAN storage policy

I ┬ánoticed that VM’s created with the vSphere fat client, were not getting the vSAN storage policy applied to them. So they we’re not as protected as one might think.

lack of storage policy
lack of storage policy

I wanted to make sure that all the VM’s living on vSanDatastore were protected by the vSAN storage policy. I wrote a quick PowerCLI script to do this:

$VMlist = get-datastore vsandatastore | get-vm
$StoragePolicy = "vSAN"
foreach ($VM in $VMlist)
Get-VM -Name $VM | Set-SpbmEntityConfiguration -StoragePolicy $StoragePolicy


Using vSAN RVC to learn more about your vSAN environment

The vSAN Ruby vSphere Console (RVC) is a very-much undocumented feature of vSAN that allows you to explore some pretty kick-ass features of vSAN in terms of what-if scenarios, cluster info, and dashboard information from the vCenter server appliance.

To access the vSAN RVC, simply ssh to your vCenter server appliance and run:

rvc root@localhost

This will drop you into the RVC shell once you enter the root password: Continue reading “Using vSAN RVC to learn more about your vSAN environment”

Using PowerCLI to remotely execute esxcli commands

First, make sure you’re using a version of PowerCLI that supports the get-esxcli cmdlet. In this case, I used a fresh install of PowerCLI 5.5.

First, get-esxcli needs to be run against a single host individually, you can loop through you’re hosts later, but again, one at a time. So I did:

$getcli = Get-EsxCli -VMhost vmhost.domain.local

In my case, I wanted to remove a “greyed out” NFS mount, and in esxcli, I would run: Continue reading “Using PowerCLI to remotely execute esxcli commands”

Huge LACP Changes in ESX 5.5u1 from ESX 5.1

In vSphere 5.1, Link Aggregation Configuration Protocol (LACP) on the vSphere Distributed Switch (vDS) was configured on the Uplink Porgroup. There were basic options of enabled/disabled and active/passive.

These options were configured like below:

LACP Enabled
LACP Enabled

Continue reading “Huge LACP Changes in ESX 5.5u1 from ESX 5.1”