Quantcast
Channel: VMware Communities : All Content - All Communities
Viewing all articles
Browse latest Browse all 175326

help needed stringing parameters together - powercli.

$
0
0

Hi,

I have this string that half works.

i am unable to sting together to get the .config and .guest and .guest.net all in one command string.

 

any suggestions.

 

> Get-VM -name "System1" | Sort | Get-View -Property @("Name", "Config.ChangeVersion", "guest.guestfullname", "Guest.hostname", "guest.ipaddress", "guest.gueststate", "guest.net.network") | Select -Property Name, @{N="ChangeVersion";E={$_.Config.ChangeVersion}}, @{N="Running OS";E={$_.Guest.GuestFullName}}, @{N="Hostname";E={$_.Guest.hostname}}, @{N="IP Address";E={$_.Guest.ipaddress}}, @{N="State";E={$_.Guest.gueststate}}, @{N="Network";E={$_.Guest.net.network}} | Format-Table -AutoSize

 

it should give me screen output of: but only give first three fields.

 

NameChangeVersion          Running OS                        Hostname IP Address State Network
-----------------          ----------                        -------- ---------- ----- -------

System1 2019-03-13T16:46:29.301502Z Microsoft Windows Server 2016 (64-bit)

 

goal to get

     name, changeVersion, guestfullname, hostname, ipaddress, gueststate, guest.net.network

 

thanks.


Viewing all articles
Browse latest Browse all 175326

Trending Articles



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