Managing vVol Storage Policies with PowerShell

I just posted about some new cmdlets here:

Also in that release are a few more cmdlets concerning storage policy creation, editing, and assignment. They were built to make the process easier–the original cmdlets and their use is certainly an option–and for very specific things you might want to do they might be necessary, but the vast majority of common operations can be more easily achieved with these.

As always, to install run:

Install-Module PureStorage.FlashArray.VMware

Or to upgrade:

Update-Module PureStorage.FlashArray.VMware

These modules are open source, so if you just want to use my code or open an RFE or issue go here:

https://github.com/PureStorage-OpenConnect/PureStorage.FlashArray.VMware/

For detailed help on a cmdlet, run Get-Help

Continue reading “Managing vVol Storage Policies with PowerShell”

New vVol Replication PowerShell Cmdlets

Happy New Year everyone! Let’s work to make 2021 a better year.

In furtherance of that goal, I have put out a few new vVol-related PowerShell cmdlets! So baby steps I guess.

The following are the new cmdlets:

Basics:

  • Get-PfaVvolStorageArray

Replication:

  • Get-PfaVvolReplicationGroup
  • Get-PfaVvolReplicationGroupPartner
  • Get-PfaVvolFaultDomain

Storage Policy Management:

  • Build-PfaVvolStoragePolicyConfig
  • Edit-PfaVvolStoragePolicy
  • Get-PfaVvolStoragePolicy
  • New-PfaVvolStoragePolicy
  • Set-PfaVvolVmStoragePolicy

Now to walk through how to use them. This post will talk about the basics and the replication cmdlets. The next post will talk about the profile cmdlets.

Continue reading “New vVol Replication PowerShell Cmdlets”

Setting the Windows Terminal Tab to vCenter Name with PowerShell

Quick one. Today, I was working on some PowerShell using one of my favorite new Windows tools, Windows Terminal.

I’ve written about it a bit in the recent past:

https://www.codyhosterman.com/2020/05/defaulting-windows-terminal-to-powershell-7-x-core/

I often will connect to multiple vCenters, but even more frequently will have multiple vCenters connected but in separate sessions or tabs:

Four tabs, four vCenters. And I never clicked on the one I meant to be cause they were all called PowerShell. In a fairly recent release, Windows terminal added the option to rename the tabs:

Continue reading “Setting the Windows Terminal Tab to vCenter Name with PowerShell”

Mounting a VVol Datastore with PowerCLI

I’ve been making a lot of updates to my PowerShell module around VVols recently and this was the last “table stakes” cmdlet I wanted to add. There are certainly more to come, but now we definitely have the basics. In 1.2.2.1 release of the PowerShell module I added a cmdlet called Mount-PfaVvolDatastore.

As of today we support a single VVol datastore–though we are working on adding support for more than one.

Continue reading “Mounting a VVol Datastore with PowerCLI”

Revamped PowerShell Module for Pure and VMware

About 6 months ago, my esteemed colleague Barkz blogged about our path forward with PowerShell. We have an official PowerShell SDK for managing the FlashArray–but it is limited to that: doing stuff to the FlashArray.

So to add value and make managing it within context of the layers you actually manage your infrastructure from (VMware, Microsoft, etc.) we created some value-add PowerShell modules to make it easier. Barkz talks about them here:

Continue reading “Revamped PowerShell Module for Pure and VMware”

PowerCLI and VVols Part VIII: Running a Failover–Planned Migration

In the previous post in this series I explored how to run a VVol-based test failover of a virtual machine. Now I will walk through running an actual failover.

There are two types of failovers; a planned migration (everything is up an running) and a disaster recovery failover (part or all of the original site is down).

For this post, I will start with running a planned migration.

Continue reading “PowerCLI and VVols Part VIII: Running a Failover–Planned Migration”

Updating a volume group name on the FlashArray for VVols

The FlashArray implementation of Virtual Volumes surfaces VMs on the FlashArray as standard volume groups. The volume group being named by the virtual machine name. Each VVol is then added and removed to the volume group as they are provisioned or deleted. These objects though are fairly flexible–we do not use the volume group as a unique identifier of the virtual machine–internally we use key/value tags for that.

The benefit of that design is that you can delete the volume groups, rename them, or add and remove other volumes to it. Giving you some flexibility to group related VMs or whatever your use case might be to move things around, without breaking our VVol implementation.

Continue reading “Updating a volume group name on the FlashArray for VVols”

PowerCLI and VVols Part VI: Running a Test Failover

This post I will talk about using PowerCLI to run a test failover for VVol-based virtual machines. One of the many nice things about VVols is that in the VASA 3.0 API this process is largely automated for you. The SRM-like workflow of a test failover is included–so the amount of storage-related PowerShell you have to manually write is fairly minimal.

Continue reading “PowerCLI and VVols Part VI: Running a Test Failover”

1.1.0.2 Release of the Pure Storage VMware PowerShell Module

I have released a new version of the VMware/Pure PowerShell module which can be automatically installed from the PowerShell Gallery.

Pure Storage PowerShell VMware Module

Updates in this release are focused on VVols. Creating VVol snapshots, copying them, creating new disks from them, retrieving them etc.

Version 1.1.0.2

I wrote a blog post below on using some of the new cmdlets:

PowerCLI and VVols Part V: Array Snapshots and VVols

Continue reading “1.1.0.2 Release of the Pure Storage VMware PowerShell Module”

PowerCLI and VVols Part V: Array Snapshots and VVols

Another post in my series on VVols and PowerCLI, for previous posts see these:

This post will be about managing one-off snapshots with VVols on the FlashArray with PowerCLI.

One of the still semi-valid reasons I have seen DBAs say “I dont want to virtualize because…” Is that they have simple snapshot/recovery scripts for their physical server that allows them to quickly restore DBs from snapshots. Doing this on VMFS requires A LOT of coordination with the VMware layer.

So they tell the VMware team–“okay I will virtualize but I want RDMs”. Well the VMware team says “well we’d rather die”

…and around in circles we go…

VVols provides the ability to provide this benefit (easy snapshot stuff) but still get the benefits of VMware stuff (vMotion, Storage vMotion, cloning, etc) without the downside of RDMs.

So let’s walk though that process.

Continue reading “PowerCLI and VVols Part V: Array Snapshots and VVols”