<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-GB">
	<id>http://vwiki.co.uk/index.php?action=history&amp;feed=atom&amp;title=Storage_PowerCLI_One-Liners</id>
	<title>Storage PowerCLI One-Liners - Revision history</title>
	<link rel="self" type="application/atom+xml" href="http://vwiki.co.uk/index.php?action=history&amp;feed=atom&amp;title=Storage_PowerCLI_One-Liners"/>
	<link rel="alternate" type="text/html" href="http://vwiki.co.uk/index.php?title=Storage_PowerCLI_One-Liners&amp;action=history"/>
	<updated>2026-05-02T23:36:32Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.43.6</generator>
	<entry>
		<id>http://vwiki.co.uk/index.php?title=Storage_PowerCLI_One-Liners&amp;diff=1773&amp;oldid=prev</id>
		<title>Sstrutt: /* Set LUN Multipathing */ Linked to RR IOPS</title>
		<link rel="alternate" type="text/html" href="http://vwiki.co.uk/index.php?title=Storage_PowerCLI_One-Liners&amp;diff=1773&amp;oldid=prev"/>
		<updated>2012-03-13T14:34:49Z</updated>

		<summary type="html">&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;Set LUN Multipathing: &lt;/span&gt; Linked to RR IOPS&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en-GB&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 14:34, 13 March 2012&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l30&quot;&gt;Line 30:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 30:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The above came from Troy Clavell&amp;#039;s post to be found at http://communities.vmware.com/thread/339480&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The above came from Troy Clavell&amp;#039;s post to be found at http://communities.vmware.com/thread/339480&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Note that you should also set the IOPS per path to 1 (default is 1000), there is some debate as to whether you should do this or not, HP recommend it for their SAN&#039;s, though some worry about the overhead on the ESX caused by switching paths for every IO.  The choice is yours, though for further reading &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;and how to do it&lt;/del&gt;...&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Note &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;that some SAN vendors recommend &lt;/ins&gt;that you should also set the IOPS per path to 1 (default is 1000), there is some debate as to whether you should do this or not, HP recommend it for their SAN&#039;s, though some worry about the overhead on the ESX caused by switching paths for every IO.  The choice is yours, though for further reading...&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;* [[Configuration_Considerations_(ESX)#Round_Robin_IOPS_Load_Balancing|Round Robin IOPS Load Balancing]]&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* http://h20195.www2.hp.com/V2/GetDocument.aspx?docname=4AA1-2185ENW&amp;amp;cc=us&amp;amp;lc=en - HP&amp;#039;s best practice&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* http://h20195.www2.hp.com/V2/GetDocument.aspx?docname=4AA1-2185ENW&amp;amp;cc=us&amp;amp;lc=en - HP&amp;#039;s best practice&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;* http://www.yellow-bricks.com/2010/03/30/whats-the-point-of-setting-iops1/ &lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt; &lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:PowerCLI]]&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:PowerCLI]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:Storage]]&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:Storage]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Sstrutt</name></author>
	</entry>
	<entry>
		<id>http://vwiki.co.uk/index.php?title=Storage_PowerCLI_One-Liners&amp;diff=1666&amp;oldid=prev</id>
		<title>Sstrutt: Initial creation - content from PowerCLI One-Liners page</title>
		<link rel="alternate" type="text/html" href="http://vwiki.co.uk/index.php?title=Storage_PowerCLI_One-Liners&amp;diff=1666&amp;oldid=prev"/>
		<updated>2012-01-26T14:44:34Z</updated>

		<summary type="html">&lt;p&gt;Initial creation - content from PowerCLI One-Liners page&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;== Get VMDKs ==&lt;br /&gt;
Get the virtual HD (VMDK) details for a particular VM&lt;br /&gt;
&amp;lt;source lang=&amp;quot;powershell&amp;quot;&amp;gt; Get-VM -Name &amp;quot;MyVM&amp;quot; | Get-HardDisk | Format-List &amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Get the VMDK details for a particular VM (as seen from within guest OS)&lt;br /&gt;
&amp;lt;source lang=&amp;quot;powershell&amp;quot;&amp;gt; (Get-VM -name &amp;quot;MyVM&amp;quot; | Get-VMGuest).Disks &amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Get the VMDK details for all VM’s in a folder (sorted by VMDK path)&lt;br /&gt;
&amp;lt;source lang=&amp;quot;powershell&amp;quot;&amp;gt; Get-VM -Location (Get-Folder -Name &amp;quot;MyFolder&amp;quot;) | Get-HardDisk | sort-object -Property Filename &amp;lt;/source&amp;gt; &lt;br /&gt;
&lt;br /&gt;
== List VM RDMs ==&lt;br /&gt;
List VM Raw Device Mapping (RDM) disks&lt;br /&gt;
&amp;lt;source lang=&amp;quot;powershell&amp;quot;&amp;gt; Get-VM | Get-HardDisk -DiskType &amp;quot;RawPhysical&amp;quot;,&amp;quot;RawVirtual&amp;quot; | Select Parent,Name,CapacityKB,Filename,ScsiCanonicalName,DeviceName &amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Create PowerShell drive ==&lt;br /&gt;
Create a PowerShell drive for the &amp;#039;&amp;#039;MyDatastore&amp;#039;&amp;#039; datastore&lt;br /&gt;
&amp;lt;source lang=&amp;quot;powershell&amp;quot;&amp;gt; New-PSDrive -Name DS -PSProvider ViMdatastore -Root &amp;#039;\&amp;#039; -location (Get-Datastore MyDatastore) &amp;lt;/source&amp;gt;  &lt;br /&gt;
&lt;br /&gt;
== Upload file to datastore ==&lt;br /&gt;
Upload file to datastore (a PowerShell drive needs to be create 1st - see above)&lt;br /&gt;
&amp;lt;source lang=&amp;quot;powershell&amp;quot;&amp;gt; Copy-DatastoreItem C:\Temp\FileToUpload.vmdk -Destination DS:\VMFolder\ &amp;lt;/source&amp;gt; &lt;br /&gt;
&lt;br /&gt;
== List LUN Multipathing ==&lt;br /&gt;
List all disk multipathing&lt;br /&gt;
&amp;lt;source lang=&amp;quot;powershell&amp;quot;&amp;gt; Get-VMHost | Get-ScsiLun | Select VMHost,Vendor,Model,LunType,CapacityMB,RuntimeName,MultipathPolicy,CanonicalName | Export-Csv lunpath.csv &amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Set LUN Multipathing ==&lt;br /&gt;
Set all SCSI disks to use round robin multipathing&lt;br /&gt;
&amp;lt;source lang=&amp;quot;powershell&amp;quot;&amp;gt; Get-VMHost | Get-ScsiLun -LunType disk |  Set-ScsiLun -MultipathPolicy &amp;quot;roundrobin&amp;quot; &amp;lt;/source&amp;gt;&lt;br /&gt;
The above came from Troy Clavell&amp;#039;s post to be found at http://communities.vmware.com/thread/339480&lt;br /&gt;
&lt;br /&gt;
Note that you should also set the IOPS per path to 1 (default is 1000), there is some debate as to whether you should do this or not, HP recommend it for their SAN&amp;#039;s, though some worry about the overhead on the ESX caused by switching paths for every IO.  The choice is yours, though for further reading and how to do it...&lt;br /&gt;
* http://h20195.www2.hp.com/V2/GetDocument.aspx?docname=4AA1-2185ENW&amp;amp;cc=us&amp;amp;lc=en - HP&amp;#039;s best practice&lt;br /&gt;
* http://www.yellow-bricks.com/2010/03/30/whats-the-point-of-setting-iops1/ &lt;br /&gt;
&lt;br /&gt;
[[Category:PowerCLI]]&lt;br /&gt;
[[Category:Storage]]&lt;/div&gt;</summary>
		<author><name>Sstrutt</name></author>
	</entry>
</feed>