VMware Cloud Community
jason_davis
Enthusiast
Enthusiast
Jump to solution

How to get list of Guest OS/Version using vSphere Automation SDK

I am interested to find the API(s) that can give me the complete list of Guest OS and associated Version #'s installed in my DataCenter.  See the attached for a screen capture from vCenter that shows such information.

Reply
0 Kudos
1 Solution

Accepted Solutions
Alex_Romeo
Leadership
Leadership
Jump to solution

Hi,

Yes correct.

You must construct the command in Powercli.

Alternatively you can check your version in "Guest OS Compatibility Guide"

VMware Compatibility Guide - Guest/Host Search

https://www.vmware.com/resources/compatibility/pdf/VMware_GOS_Compatibility_Guide.pdf

Alessandro Romeo

---------------------------------------------------------------------------------------------------------

Was it helpful? Let us know by completing this short survey here.

Blog: https://www.aleadmin.it/

View solution in original post

Reply
0 Kudos
3 Replies
jason_davis
Enthusiast
Enthusiast
Jump to solution

Hi Alessandro,

Thanks for the advice.  Yes I can see that this API can read the configured OS for a given vm

vm.Guest.GuestFullName

However what I was looking for was a list of strings representing all of the possible supported OS in my given VMware version.  It seems there is no such API to query that from VMware.  So instead I suppose I need to create that list in my program by studying my specific version of VMware.  And then if needed I can programmatically map these strings to the enum associated with vm.Guest.GuestId.

Does that seem right?

Reply
0 Kudos
Alex_Romeo
Leadership
Leadership
Jump to solution

Hi,

Yes correct.

You must construct the command in Powercli.

Alternatively you can check your version in "Guest OS Compatibility Guide"

VMware Compatibility Guide - Guest/Host Search

https://www.vmware.com/resources/compatibility/pdf/VMware_GOS_Compatibility_Guide.pdf

Alessandro Romeo

---------------------------------------------------------------------------------------------------------

Was it helpful? Let us know by completing this short survey here.

Blog: https://www.aleadmin.it/
Reply
0 Kudos