Quantcast
Channel: VMware Communities: Message List
Viewing all articles
Browse latest Browse all 247559

Re: Help required with the viproperty cmdlet

$
0
0

The Value parameter can be a code block.

Something like this

 

New-VIProperty-ObjectTypeDatastore-Name_DSDiskNames_-Valueparam($ds)    $disknames=$ds.ExtensionData.info.vmfs.extent|%{    $_.DiskName
  }  [string]::Join(',',$disknames) } -Force|Out-Null 
Get-Datastore
MyDS|SelectName,_DSDiskNames_

 

There are a couple of samples in VIProperties.


Viewing all articles
Browse latest Browse all 247559

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>