0 Replies Latest reply on Aug 5, 2008 5:59 PM by c_shanklin

    Querying VC and ESX version and build numbers.


      I had a question about how to query VC and ESX for their version numbers, so I wanted to post the answer here.


      If you're connected directly to VC, use this to get the VC version number:


      # Version info about the system to which you are connected (VC or ESX).
      $si = get-view serviceinstance
      $si.content.about | select Version, Build, FullName



      If you want the versions of the servers managed by VC instead, use this:

      # When connected to VC, get info about the hosts managed by VC.
      function Get-VMHostVersions {
       get-vmhost | % { $server = $_ | get-view; $server.Config.Product | select { $server.Name }, Version, Build, FullName }
      Get-VMHostVersions | fl *