FacterLinux: when run as root, facter currently uses detects vmware with virt-what, which can find it via 1) the cpuid instruction or 2) the DMI manufacturer. Without root, facter will use the {{ vmware}} executable to figure this out. If that somehow fails, which seems adequate it can detect vmware via tha product_name fact (DMI) as well.
Solaris: facter runs /usr/sbin/prtdiag and attempts to match several product names (including vmware) to each line of output until it finds something useful.
Windows: via wmi
Mac OS: facter looks for vmware in the the sp_machine_model fact
Linux: when run as root, facter currently detects vmware with virt-what, which can find it via 1) the cpuid instruction or 2) the DMI manufacturer. Without root, facter will use the {{vmware}} executable to figure this out. If that somehow fails, it can detect vmware via tha the product_name fact (DMI) as well.
Solaris: facter runs {{ /usr/sbin/prtdiag}} and attempts to match several product names (including vmware) to each line of output until it finds something useful.
Windows: via wmi
Mac OS: facter looks for vmware in the the sp_machine_model fact
Linux: when run as root, facter currently detects vmware with virt-what, which can find it via 1) the cpuid instruction or 2) the DMI manufacturer. Without root, facter will use the {{vmware}} executable to figure this out. If that somehow fails, it can detect vmware via the product_name fact (DMI) as well.
Solaris: facter runs {{/usr/sbin/prtdiag}} and attempts to match several product names (including vmware) to each line of output until it finds something useful.
Windows: via wmi
Mac OS: facter looks for vmware in the the {{ sp_machine_model}} fact (which itself comes from system_profiler's {{model_identifier}})
Linux: when run as root, facter currently detects vmware with virt-what, which can find it via 1) the cpuid instruction or 2) the DMI manufacturer. Without root, facter will use the {{vmware}} executable to figure this out. If that somehow fails, it can detect vmware via the product_name fact (DMI) as well.
Solaris: facter runs {{/usr/sbin/prtdiag}} and attempts to match several product names (including vmware) to each line of output until it finds something useful.
Windows: via wmi
Mac OS: facter looks for vmware in the the {{sp_machine_model}} fact (which itself comes from system_profiler's {{model_identifier}})
[This repo|https://github.com/DE-IBH/imvirt/blob/master/helper/vmware.c] has a great example of how to detect the product name (ESXi, Workstation, etc), which looks like it does a better job than the current VMware detector as built for FACT-1717. I think it might be nice to split out the product name and version as separate pieces of metadata, like this tool does.