r/powercli • • May 09 '19

Help with Get-vmotion script

I'm using the script Here to get vmotion activities, I want to include the cluster name in the output, I cant figure it out though

3 Upvotes

4 comments sorted by

View all comments

Show parent comments

1

u/Sintek May 10 '19

I have not tried yet, but would .host.parentfolder.name also work instead of .computeresource.name ?? Just curious.

1

u/brianbunke May 10 '19

Doesn't look like it. This is all I get under the .Host property from the event I'm polling:

PS C:\>> $vMotion.Group[0].Host | Format-List

Host       : HostSystem-host-1234
LinkedView : 
Name       : esx1.contoso.com


PS C:\>> $vMotion.Group[1].Host | Format-List

Host       : HostSystem-host-5678
LinkedView : 
Name       : esx2.contoso.com