VMware Cloud Community
Flapoly
Contributor
Contributor
Jump to solution

Change multipath setting for VM RDM disk

Hi,

I'm looking a way to automatically change the multipath setting of all RDM disks (of all VMs)

Do you know how to acheive this.

Reply
0 Kudos
1 Solution

Accepted Solutions
LucD
Leadership
Leadership
Jump to solution

You could try this

# Get all RDMs
$RDMs = Get-VM | Get-HardDisk | where{$_.DiskType -like "Raw*"} | %{$_.ScsiCanonicalName}

# Set multipath to fixed (can also be RoundRobin or MostRecentlyUsed
Get-VMHost | Get-ScsiLun | where {$RDMS -contains $_.CanonicalName} | Set-ScsiLun -MultipathPolicy "Fixed"

____________

Blog: LucD notes

Twitter: lucd22


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

View solution in original post

Reply
0 Kudos
1 Reply
LucD
Leadership
Leadership
Jump to solution

You could try this

# Get all RDMs
$RDMs = Get-VM | Get-HardDisk | where{$_.DiskType -like "Raw*"} | %{$_.ScsiCanonicalName}

# Set multipath to fixed (can also be RoundRobin or MostRecentlyUsed
Get-VMHost | Get-ScsiLun | where {$RDMS -contains $_.CanonicalName} | Set-ScsiLun -MultipathPolicy "Fixed"

____________

Blog: LucD notes

Twitter: lucd22


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

Reply
0 Kudos