New Amazon AWS C5 instances are not recognised as a VM
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Landscape Client |
Fix Released
|
High
|
Simon Poirier | ||
landscape-client (Ubuntu) |
Fix Released
|
Medium
|
Eric Desrochers | ||
Trusty |
Fix Released
|
Medium
|
Eric Desrochers | ||
Xenial |
Fix Released
|
Medium
|
Eric Desrochers | ||
Artful |
Fix Released
|
Medium
|
Eric Desrochers | ||
Bionic |
Fix Released
|
Medium
|
Eric Desrochers |
Bug Description
[Impact]
The new Amazon AWS C5 instance type is not a recognised VM type in Landscape and thus won't allow use of a Virtual Guest asset to register with.
The C5 instance type is a new type that uses a KVM-family hypervisor instead of Xen (displaying "Amazon EC2" in sys_vendor which landscape-client doesn't recognise, thus cannot associate/map to kvm)
"AWS has revealed it has created a new hypervisor based on KVM, not the Xen hypervisor on which it has relied for years."
[Test Case]
Scenario #1
* Deploy an AWS C5 instance
* Look sys_vendor
$ cat /sys/class/
Amazon EC2
* Install landscape-client
* Register the client to the desired landscape-server
* Verify "VM Type" to be "kvm" under the computer info in landscape-server.
Scenario #2
* Deploy an AWS non KVM/non C5 instance (Example : t2.medium)
* Look sys_vendor
$ cat /sys/class/
Xen
* Install landscape-client
* Register the client to the desired landscape-server
* Verify "VM Type" to still be "xen" under the computer info in landscape-server.
[Regression Potential]
* No regression anticipated, the fix is only adding a new entry mapping to recognize C5 instance (Amazon EC2)
[Other Info]
* Upstream commit:
https:/
[Original Description]
The new Amazon AWS C5 instance type is not a recognised VM type in Landscape and thus won't allow use of a Virtual Guest asset to register with.
The C5 instance type is a new type that uses a KVM-family hypervisor instead of Xen:
"AWS has revealed it has created a new hypervisor based on KVM, not the Xen hypervisor on which it has relied for years."
============
ubuntu@
Amazon EC2
============
dmidecode output:
# dmidecode 3.0
Getting SMBIOS data from sysfs.
SMBIOS 2.7 present.
5 structures occupying 233 bytes.
Table at 0x000F9010.
Handle 0x0000, DMI type 0, 24 bytes
BIOS Information
Vendor: Amazon EC2
Version: 1.0
Release Date: 10/16/2017
Address: 0xF0000
Runtime Size: 64 kB
ROM Size: 64 kB
Characteristics:
PCI is supported
EDD is supported
ACPI is supported
System is a virtual machine
BIOS Revision: 1.0
Handle 0x0001, DMI type 1, 27 bytes
System Information
Manufacturer: Amazon EC2
Product Name: c5.large
Version: Not Specified
Serial Number: ec23cdb5-
UUID: EC23CDB5-
Wake-up Type: Power Switch
SKU Number: Not Specified
Family: Not Specified
Handle 0x0002, DMI type 2, 15 bytes
Base Board Information
Manufacturer: Amazon EC2
Product Name: Not Specified
Version: Not Specified
Serial Number: Not Specified
Asset Tag: i-09898bff0b7b55c35
Features: None
Location In Chassis: Not Specified
Chassis Handle: 0x0003
Type: Other
Contained Object Handles: 0
Handle 0x0003, DMI type 3, 21 bytes
Chassis Information
Manufacturer: Amazon EC2
Type: Other
Lock: Not Present
Version: Not Specified
Serial Number: Not Specified
Asset Tag: Amazon EC2
Boot-up State: Safe
Power Supply State: Safe
Thermal State: Safe
Security Status: None
OEM Information: 0x00000000
Height: Unspecified
Number Of Power Cords: 1
Contained Elements: 0
Handle 0x0004, DMI type 127, 4 bytes
End Of Table
============
contents of /proc/cpuinfo :
processor : 0
vendor_id : GenuineIntel
cpu family : 6
model : 85
model name : Intel(R) Xeon(R) Platinum 8124M CPU @ 3.00GHz
stepping : 3
microcode : 0x100013e
cpu MHz : 3000.000
cache size : 25344 KB
physical id : 0
siblings : 2
core id : 0
cpu cores : 1
apicid : 0
initial apicid : 0
fpu : yes
fpu_exception : yes
cpuid level : 13
wp : yes
flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ss ht syscall nx pdpe1gb rdtscp lm constant_tsc rep_good nopl xtopology nonstop_tsc aperfmperf eagerfpu pni pclmulqdq ssse3 fma cx16 pcid sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand hypervisor lahf_lm abm 3dnowprefetch fsgsbase tsc_adjust bmi1 hle avx2 smep bmi2 erms invpcid rtm mpx avx512f rdseed adx smap clflushopt clwb avx512cd xsaveopt xsavec xgetbv1 ida arat
bugs :
bogomips : 6000.00
clflush size : 64
cache_alignment : 64
address sizes : 46 bits physical, 48 bits virtual
power management:
processor : 1
vendor_id : GenuineIntel
cpu family : 6
model : 85
model name : Intel(R) Xeon(R) Platinum 8124M CPU @ 3.00GHz
stepping : 3
microcode : 0x100013e
cpu MHz : 3000.000
cache size : 25344 KB
physical id : 0
siblings : 2
core id : 0
cpu cores : 1
apicid : 1
initial apicid : 1
fpu : yes
fpu_exception : yes
cpuid level : 13
wp : yes
flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ss ht syscall nx pdpe1gb rdtscp lm constant_tsc rep_good nopl xtopology nonstop_tsc aperfmperf eagerfpu pni pclmulqdq ssse3 fma cx16 pcid sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand hypervisor lahf_lm abm 3dnowprefetch fsgsbase tsc_adjust bmi1 hle avx2 smep bmi2 erms invpcid rtm mpx avx512f rdseed adx smap clflushopt clwb avx512cd xsaveopt xsavec xgetbv1 ida arat
bugs :
bogomips : 6000.00
clflush size : 64
cache_alignment : 64
address sizes : 46 bits physical, 48 bits virtual
power management:
Changed in landscape: | |
status: | New → Confirmed |
importance: | Undecided → High |
assignee: | nobody → Simon Poirier (simpoir) |
Changed in landscape: | |
status: | Confirmed → In Progress |
information type: | Proprietary → Public |
Changed in landscape-client: | |
status: | New → In Progress |
importance: | Undecided → High |
assignee: | nobody → Simon Poirier (simpoir) |
no longer affects: | landscape |
Changed in landscape-client: | |
status: | In Progress → Fix Committed |
description: | updated |
Changed in landscape-client (Ubuntu Trusty): | |
status: | New → Confirmed |
Changed in landscape-client (Ubuntu Xenial): | |
status: | New → Confirmed |
Changed in landscape-client (Ubuntu Zesty): | |
status: | New → Confirmed |
Changed in landscape-client (Ubuntu Artful): | |
status: | New → Confirmed |
Changed in landscape-client (Ubuntu Bionic): | |
status: | New → Confirmed |
Changed in landscape-client (Ubuntu Trusty): | |
importance: | Undecided → Medium |
Changed in landscape-client (Ubuntu Xenial): | |
importance: | Undecided → Medium |
Changed in landscape-client (Ubuntu Zesty): | |
importance: | Undecided → Medium |
Changed in landscape-client (Ubuntu Artful): | |
importance: | Undecided → Medium |
Changed in landscape-client (Ubuntu Bionic): | |
importance: | Undecided → Medium |
description: | updated |
tags: | added: sts |
description: | updated |
Changed in landscape-client (Ubuntu Bionic): | |
assignee: | nobody → Eric Desrochers (slashd) |
Changed in landscape-client (Ubuntu Artful): | |
assignee: | nobody → Eric Desrochers (slashd) |
Changed in landscape-client (Ubuntu Zesty): | |
assignee: | nobody → Eric Desrochers (slashd) |
Changed in landscape-client (Ubuntu Xenial): | |
assignee: | nobody → Eric Desrochers (slashd) |
Changed in landscape-client (Ubuntu Trusty): | |
assignee: | nobody → Eric Desrochers (slashd) |
tags: | added: sts-sponsor-slashd |
tags: | added: patch |
Changed in landscape-client: | |
status: | Fix Committed → In Progress |
status: | In Progress → Fix Committed |
Changed in landscape-client (Ubuntu Bionic): | |
status: | In Progress → Fix Committed |
Changed in landscape-client: | |
milestone: | none → 18.01 |
no longer affects: | landscape-client (Ubuntu Zesty) |
Changed in landscape-client (Ubuntu Artful): | |
status: | Confirmed → In Progress |
Changed in landscape-client (Ubuntu Xenial): | |
status: | Confirmed → In Progress |
Changed in landscape-client (Ubuntu Trusty): | |
status: | Confirmed → In Progress |
description: | updated |
Changed in landscape-client: | |
status: | Fix Committed → Fix Released |
I wonder if this is just matter of adding a new entry in content_vendor_map specifically for "Amazon EC2" since it is not listed as a vendor in landscape yet.
# landscape/ lib/vm_ info.py by_vendor( sys_vendor_ path): sys_vendor_ path).lower( ) vendors_ map = (
("microsoft" , "hyperv"),
("openstack" , "kvm"), vendors_ map:
def _get_vm_
"""Return the VM type string (possibly empty) based on the vendor."""
vendor = read_file(
# Use lower-key string for vendors, since we do case-insentive match.
content_
("bochs", "kvm"),
("google", "gce"),
("innotek", "virtualbox"),
+ ("amazon ec2", "kvm"),
("qemu", "kvm"),
("vmware", "vmware"))
for name, vm_type in content_
if name in vendor:
return vm_type
return ""
We have tested using "virt-what" just for comparison and it displays "kvm" inside a C5 instance as $cpuid == KVMKVMKVM. (cpuid get populated via command "virt-what- cpuid-helper" which return "KVMKVMKVM")
if ! "$skip_qemu_kvm"; then
if [ "$cpuid" = "KVMKVMKVM" ]; then
echo kvm
I'll let Simon judge the best way to approach this.
- Eric