Comment 2 for bug 1281014

Revision history for this message
Wang Bo (chestack) wrote :

1.yes, I also came into this issue. The worse problem is, the response code of is still 202 even when NoValidHost exception raised. It could be reproduced by run command "nova --debug resize". The response code of NoValidHost shoud be 500, I'm curious why the result is 202.

2.I create another flavor to test if the number of vcpus is too many.
"flavor": {
              "vcpus": 1000,
              "ram": 1024,
              "disk": 20
}
Then I run "nova resize" with above flavorid. I found that /nova/filters.py method "get_filtered_objects" does not check the vcpu resource. (I mean even the requested vcpus is too many, it does not raise the NoValidHost exception.)
(Pdb) pp filter_classes
[<class 'nova.scheduler.filters.retry_filter.RetryFilter'>,
 <class 'nova.scheduler.filters.availability_zone_filter.AvailabilityZoneFilter'>,
 <class 'nova.scheduler.filters.ram_filter.RamFilter'>,
 <class 'nova.scheduler.filters.compute_filter.ComputeFilter'>,
 <class 'nova.scheduler.filters.compute_capabilities_filter.ComputeCapabilitiesFilter'>,
 <class 'nova.scheduler.filters.image_props_filter.ImagePropertiesFilter'>]

Could someone help answer my question 2? Thanks a lot!