Bug 1578281
| Summary: | [RHOS-8] Allow to specify multiple granular CPU flags | |||
|---|---|---|---|---|
| Product: | Red Hat OpenStack | Reporter: | Kashyap Chamarthy <kchamart> | |
| Component: | openstack-nova | Assignee: | Kashyap Chamarthy <kchamart> | |
| Status: | CLOSED ERRATA | QA Contact: | OSP DFG:Compute <osp-dfg-compute> | |
| Severity: | medium | Docs Contact: | ||
| Priority: | unspecified | |||
| Version: | 8.0 (Liberty) | CC: | berrange, dasmith, eglynn, jhakimra, kchamart, nova-maint, sbauza, sferdjao, sgordon, srevivo, vromanso | |
| Target Milestone: | async | Keywords: | Triaged, ZStream | |
| Target Release: | 8.0 (Liberty) | |||
| Hardware: | Unspecified | |||
| OS: | Unspecified | |||
| Whiteboard: | ||||
| Fixed In Version: | openstack-nova-12.0.6-28.el7ost | Doc Type: | If docs needed, set a value | |
| Doc Text: | Story Points: | --- | ||
| Clone Of: | 1578016 | |||
| : | 1578292 (view as bug list) | Environment: | ||
| Last Closed: | 2018-05-22 02:07:13 UTC | Type: | Bug | |
| Regression: | --- | Mount Type: | --- | |
| Documentation: | --- | CRM: | ||
| Verified Versions: | Category: | --- | ||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | ||
| Cloudforms Team: | --- | Target Upstream Version: | ||
| Embargoed: | ||||
| Bug Depends On: | 1578016 | |||
| Bug Blocks: | 1578292 | |||
|
Description
Kashyap Chamarthy
2018-05-15 07:46:15 UTC
Verified by manually installing the rpms on the compute node.
Verification steps:
1. Add the following to nova.conf on the compute node:
[libvirt]
cpu_mode = custom
cpu_model = Haswell-noTSX
cpu_model_extra_flags = VMX, pdpe1gb
*Note* that VMX is written as all caps on purpose, to test case insensitivity.
2. Boot an instance
$ openstack server create --image cirros --flavor m1.tiny vm1
3. Check that the cpu model extra flags are available in the libvirt xml of the instance:
$ sudo virsh dumpxml instance-00000001
...
<cpu mode='custom' match='exact' check='full'>
<model fallback='forbid'>Haswell-noTSX</model>
<topology sockets='1' cores='1' threads='1'/>
<feature policy='disable' name='pdpe1gb'/>
<feature policy='disable' name='vmx'/>
<feature policy='require' name='vme'/>
<feature policy='require' name='f16c'/>
<feature policy='require' name='rdrand'/>
<feature policy='require' name='hypervisor'/>
<feature policy='require' name='arat'/>
<feature policy='disable' name='invpcid'/>
<feature policy='require' name='xsaveopt'/>
<feature policy='require' name='abm'/>
</cpu>
...
We can see that both pdpe1gb and vmx are included. Also note that vmx has been lowercased properly.
4. We check that the features are visible on the qemu command line args:
[heat-admin@compute-0 ~]$ ps -ef | grep qemu
qemu 23737 1 3 13:44 ? 00:00:32 /usr/libexec/qemu-kvm -name guest=instance-00000001,debug-threads=on -S -object secret,id=masterKey0,format=raw,file=/var/lib/libvirt/qemu/domain-2-instance-00000001/master-key.aes -machine pc-i440fx-rhel7.5.0,accel=kvm,usb=off,dump-guest-core=off -cpu Haswell-noTSX,pdpe1gb=on,vmx=on -m 512 -realtime mlock=off -smp 1,sockets=1,cores=1,threads=1 -uuid 49d791f2-8735-4eea-a818-6cd40bbd1926 -smbios type=1,manufacturer=Red Hat,product=OpenStack Compute,version=12.0.6-28.el7ost,serial=9945cf48-79a1-4459-8e98-9d1e3376f07e,uuid=49d791f2-8735-4eea-a818-6cd40bbd1926,family=Virtual Machine -no-user-config -nodefaults -chardev socket,id=charmonitor,path=/var/lib/libvirt/qemu/domain-2-instance-00000001/monitor.sock,server,nowait -mon chardev=charmonitor,id=monitor,mode=control -rtc base=utc,driftfix=slew -global kvm-pit.lost_tick_policy=delay -no-hpet -no-shutdown -boot strict=on -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 -drive file=/var/lib/nova/instances/49d791f2-8735-4eea-a818-6cd40bbd1926/disk,format=qcow2,if=none,id=drive-virtio-disk0,cache=none -device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x4,drive=drive-virtio-disk0,id=virtio-disk0,bootindex=1 -netdev tap,fd=27,id=hostnet0,vhost=on,vhostfd=29 -device virtio-net-pci,netdev=hostnet0,id=net0,mac=fa:16:3e:03:03:fe,bus=pci.0,addr=0x3 -add-fd set=2,fd=31 -chardev file,id=charserial0,path=/dev/fdset/2,append=on -device isa-serial,chardev=charserial0,id=serial0 -chardev pty,id=charserial1 -device isa-serial,chardev=charserial1,id=serial1 -device usb-tablet,id=input0,bus=usb.0,port=1 -vnc 0.0.0.0:0 -k en-us -device cirrus-vga,id=video0,bus=pci.0,addr=0x2 -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x5 -msg timestamp=on
Most relevant is the part `-cpu Haswell-noTSX,pdpe1gb=on,vmx=on`
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2018:1684 |