Wednesday, May 13, 2015

derby ram or find a vm's ip address programmatically

 i can't figure out my vm's ip address. to which i respond:  
   
 as i was going to derby, 'twas on a market day,   
 i met the finest ram, sirs, that ever was fed upon hay.  
   
 that's a lie, that's a lie  
 that's a lie, a lie, a lie!  
   
 this ram and i got drunk, sir, as drunk as drunk could be,   
 and when we sobered up, sir, we were far away out on the sea.  
   
 ahem...  
   
 Connect-VIServer vmwareesxserver  
 Get-VM | Select Name, @{N="IP Address";E={@($_.guest.IPAddress[0])}}  
   
 and there you go:  
 name tab tab ip address.  
   
 you need power cli installed.  

No comments: