Install PureStoragePowerShellSDK
Open PowerShell as an Administrator.
Install-module purestoragepowershellsdk -Force -Verbose
If not connected to the internet, download and copy to the Server1 share (D:\share) from: https://www.powershellgallery.com/packages/PureStoragePowerShellSDK
Install PureStoragePowerShellToolkit
Open PowerShell as an Administrator.
Install-module purestoragepowershelltoolkit -Force -Verbose
If not connected to the internet, download and copy to the Server1 share (D:\share) from: https://www.powershellgallery.com/packages/PureStoragePowerShellToolkit
Enable SMI-S on the FlashArray
Login to the management IP for the FlashArray. Select Settings and then enable both the SMI-S Provider and SLP.
Create a Pure Host or Host Group
Using the PureStoragePowerShellSDK create a host, assign WWN/IQN, and add to a Host, or Host Group if using Failover Clustering.
#connect to the FlashArray
$array = New-PfaArray -EndPoint <array IPAddress> -IgnoreCertificateError -username <user>
#find FC WWN
(Get-InitiatorPort).PortAddress
#if iSCSI find initiator address
(Get-IscsiSession).InitiatorNodeAddress
#create a host and add WWN if using FC
New-PfaHost -Array $array -Name host1 -WwnList <wwn>
#create a host and add IQN if using iSCSI
New-PfaHost -Array $array -Name host1 -IqnList <iqn>
#create a host and add IQN if using iSCSI
New-PfaHost -Array $Array -Name host1 -IqnList iqn.2015-06.com.example:pure-01
#create host group and add host to it if using a Failover Cluster
New-PfaHostGroup -Array $Array -Name hostGroup1 -Hosts Server1
Create a Pure Volume and attach to Host or Host Group
Using the PureStoragePowerShellSDK create a Pure Volume and connect it to a Host (or Host Group).
#connect to the FlashArray
$array = New-PfaArray -EndPoint <array IPAddress> -IgnoreCertificateError -username <user>
New-PfaVolume -Array $array -VolumeName myvolume -Size 30 -Unit G
#connect volume to Host if no Failover Cluster
New-PfaHostVolumeConnection -Array $array -VolumeName vol1 -HostName host1
#In the case of Failover Cluster, connect Volume to the Host Group instead
New-PfaHostGroupVolumeConnection -Array $array -VolumeName vol1 -HostGroupName hostGroup1
Find the Pure Volume on the Physical Server
- Find the Pure Volume and format, initialize, and assign a drive letter.
- On Server1 assign it the D letter and create an SMB share.
- On Server 2 & 3 format, initialize, and assign a drive letter.
- If a Failover Cluster make it a clustered disk, or alternately a cluster shared volume.
- If you have more than 1 Pure volume the following command will list them all and show you the disk number which can be used to get the signature.
- With the disk number, you can online the disk and initialize it
get-disk | where -property Manufacturer -match "PURE" - Once online and initialized you can assign a drive letter. One Server1 make it ‘D’.
set-disk -number 3 -isoffline $false Initialize-Disk -Number 3 -PartitionStyle GPT new-Partition -disknumber 3 -DriveLetter "d" -UseMaximumSize | format-volume - Once formatted create the ‘share’ folder and an SMB share.
New-Item -Path 'D:\share' -ItemType Directory New-SmbShare -Name "share" -Path "d:\share" -ChangeAccess "Users" -FullAccess "Administrators" - If it is a failover cluster (Server2 & Server3), add the disk the cluster
Get-Disk -Number 3 | Add-ClusterDisk -
(Optional) If you are not assigning the disk to a Cluster Role (such as a SQL Server FCI), and want a Cluster Shared Volume (CSV) to place VMs on, promote the clustered disk to a CSV. The “-name” parameter is what is assigned to the disk during the Add-ClusterDisk command.
Add-ClusterSharedVolume -Name "cluster disk 3" - Print out the path of the CSV and place your VMs there.
$volume = get-clustersharedvolume -name "cluster disk 3"
$volume.SharedVolumeInfo.FriendlyVolumeName