- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
For the LUN UUID you might try the following.
For each VMHost, compile a lookup table containing the datastorename and the datastore's UUID (VMFS only)
...
$VMHost = $cluster | Get-VMHost | select -First 1
# Create DS-UUID lookup table $lunUUIDTab = @{} $storSys = Get-View $esx.ExtensionData.ConfigManager.StorageSystem
$storSys.FileSystemVolumeInfo.MountInfo | where {$_.Volume.Type -eq "VMFS"} | %{ $lunUUIDTab.Add($_.Volume.Name,$_.Volume.Uuid) }
Later in the script fetch the UUID like this
# Fetch the UUID $row.LUNUUID = $lunUUIDTab[$_.Name]
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference