Red Hat sets the following fields in SMBIOS information, allowing us
to detect that it's the branded Red Hat hypervisor.
Manufacturer: Red Hat
Product Name: KVM
Version: RHEL 7.6.0 PC (i440FX + PIIX, 1996)
Note that "RHEL 7.6.0" there is the machine type, which is not the
same as the hypervisor version (although the two have a relationship).
Thanks: Timothy Smith at IBM, Karen Noel
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
output="$(PATH=../..:$PATH virt-what --test-root=. 2>&1)"
-expected="nutanix_ahv"
+expected="nutanix_ahv
+redhat"
if [ "$output" != "$expected" ]; then
echo "$0: test failed because output did not match expected"
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
output="$(PATH=../..:$PATH virt-what --test-root=. 2>&1)"
-expected="xen
+expected="redhat
+xen
xen-hvm"
if [ "$output" != "$expected" ]; then
output="$(PATH=../..:$PATH virt-what --test-root=. 2>&1)"
expected="rhev
+redhat
kvm"
if [ "$output" != "$expected" ]; then
echo google_cloud
fi
+# Red Hat's hypervisor.
+if echo "$dmi" | grep -q 'Manufacturer: Red Hat'; then
+ echo redhat
+fi
+
# Check for Xen.
if [ "$cpuid" = "XenVMMXenVMM" ] &&
Status: confirmed by RWMJ
+=item B<redhat>
+
+The guest is running on the Red Hat hypervisor.
+
+Status: confirmed by RWMJ
+
=item B<uml>
This is a User-Mode Linux (UML) guest.