-1

I am working on building an inventory using Chef and ohai. The plan is to pull relevant data from ohai and build an inventory "spreadsheet" that gets published on a webpage. Chef and ohai are capable of returning the hostname and FQDN, but can they return a VM name? We use VM names to define security policies in VSG, so this information is important to many people in the organization. These VMs are running in an ESXi cluster with vCenter and all have VMWare tools installed.

D34DM347
  • 1,471
  • 2
  • 19
  • 32
  • 2
    `but can they return a VM name?` I don't know, can they? I'd suggest you try and come back if you have a more specific issue. – GregL Sep 07 '16 at 19:31

1 Answers1

1

https://github.com/chef/ohai/blob/master/lib/ohai/plugins/vmware.rb#L52-L62 shows the values we gather from the VMWare tools in Ohai. Nothing there sounds like a VM name so probably the answer is no. You can always run ohai | less on the node and look through the data to see if what you want is in there.

coderanger
  • 858
  • 4
  • 13