How does the libvirt.xml file generate?

asked 2015-07-16 04:07:18 -0600

liyahua gravatar image

updated 2015-07-16 04:18:20 -0600

dbaxps gravatar image

When I migrate a VM instance, there will print an ERROR like this :

ERROR (BadRequest): Unacceptable CPU info: CPU doesn't have compatibility.
Refer to (HTTP 400) (Request-ID: req-1843fad8-903d-40f9-afd3-2344354112ec)
the  info of the cpu  is defined in the libvirt.xml file , I change the nova.conf .However it does not work.
edit retag flag offensive close merge delete


Which version of Openstack are you running ?

dbaxps gravatar imagedbaxps ( 2015-07-16 08:21:05 -0600 )edit

Juno based on ubuntu , is there a bug with this version?

liyahua gravatar imageliyahua ( 2015-07-16 08:57:52 -0600 )edit

Per it was fixed in Openstack Kilo 2015.1.
See my answer for suggestions.

dbaxps gravatar imagedbaxps ( 2015-07-16 09:20:08 -0600 )edit

WARNING nova.virt.libvirt.driver An error occurred trying to live migrate. Falling back to legacy live migrate flow. Error: unsupported configuration: guest and host CPU are not compatible: Host CPU does not provide required features: pdpe1gb, aes, pcid, smx, pclmul

liyahua gravatar imageliyahua ( 2015-07-17 02:51:52 -0600 )edit

I have changed the as you said , however still have trouble.

liyahua gravatar imageliyahua ( 2015-07-17 02:52:29 -0600 )edit

1 answer

Sort by ยป oldest newest most voted

answered 2015-07-16 08:22:38 -0600

dbaxps gravatar image

updated 2015-07-16 11:24:58 -0600

Seems like your issue is addressed here
If you are not on Kilo , I would test suggestions #26,#27
If it happens to you on Kilo in nova/virt/libvirt/ there is block

 # Compare CPU
        if not instance.vcpu_model or not instance.vcpu_model.model:
            source_cpu_info = src_compute_info['cpu_info']
            self._compare_cpu(None, source_cpu_info)
            self._compare_cpu(instance.vcpu_model, None)

You can make a copy of and attempt to disable comparison. Actually, this block should work for you.

Did you attempt on Juno or you did something different :-

1) Find lowest common denominator CPU model across all hypervisors using virsh capabilities / virsh cpu-baseline
2) Configure nova-compute.conf to include cpu_mode=custom, cpu_model=Westmere (in my case)
3) Disable the CPU check in nova/virt/libvirt/ (comment out line 4248)
    4246 # Compare CPU
    4247 source_cpu_info = src_compute_info['cpu_info']
    4248 self._compare_cpu(source_cpu_info)

Please , confirm.

edit flag offensive delete link more


I change the , and the error of cpu CPU doesn't have compatibility is missing. however , I still have trouble in migrating a vm . I debug the process of migration and find http 400, it is a bad request. NOW,the vm in lock in the state of migrating.

liyahua gravatar imageliyahua ( 2015-07-16 10:40:17 -0600 )edit

The ERROR is like this : File "/usr/lib/python2.7/dist-packages/nova/virt/libvirt/", line 5011, in check_can_live_migrate_destination\n if not instance.vcpu_model or not instance.vcpu_model.model:\n', "AttributeError: 'Instance' object has no attribute 'vcpu_model'\n"]

liyahua gravatar imageliyahua ( 2015-07-16 11:06:20 -0600 )edit

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower


Asked: 2015-07-16 04:07:18 -0600

Seen: 1,738 times

Last updated: Jul 16 '15