yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #60215
[Bug 1647316] Re: scheduler report client sends allocations with value of zero, violating min_unit
Marking this high as it's causing issues in the ceph jobs:
http://logs.openstack.org/14/414214/12/check/gate-tempest-dsvm-full-
devstack-plugin-ceph-ubuntu-
xenial/511c30e/logs/screen-n-cpu.txt.gz#_2017-01-03_23_17_44_657
2017-01-03 23:17:44.657 4254 DEBUG nova.scheduler.client.report [req-eced32b1-1b58-446a-bf57-02280b9f2b4d tempest-TenantUsagesTestJSON-1895317078 tempest-TenantUsagesTestJSON-1895317078] [instance: f83871cb-c77e-4c99-833f-186db97b38b1] Sending allocation for instance {'allocations': [{'resource_provider': {'uuid': 'f8ce7899-0b48-4294-8df2-057ac325f4d2'}, 'resources': {'MEMORY_MB': 64, 'VCPU': 1, 'DISK_GB': 0}}]} _allocate_for_instance /opt/stack/new/nova/nova/scheduler/client/report.py:505
2017-01-03 23:17:44.750 4254 WARNING nova.scheduler.client.report [req-eced32b1-1b58-446a-bf57-02280b9f2b4d tempest-TenantUsagesTestJSON-1895317078 tempest-TenantUsagesTestJSON-1895317078] Unable to submit allocation for instance f83871cb-c77e-4c99-833f-186db97b38b1 (409 409 Conflict
There was a conflict when trying to complete your request.
Unable to allocate inventory: Unable to create allocation for 'DISK_GB'
on resource provider 'f8ce7899-0b48-4294-8df2-057ac325f4d2'. The
requested amount would violate inventory constraints. )
** Changed in: nova
Importance: Medium => High
** Also affects: nova/newton
Importance: Undecided
Status: New
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1647316
Title:
scheduler report client sends allocations with value of zero,
violating min_unit
Status in OpenStack Compute (nova):
In Progress
Status in OpenStack Compute (nova) newton series:
New
Bug description:
When a VM boots using non-local disk, it tries to send an allocation of 'DISK_GB': 0. This violates the default min_unit of 1 and causes an error that looks like this:
[req-858cbed4-c113-45e8-94e3-1d8ee64f9de0 488c2b05a66b441199f4c1dca7accd5b 3fa5b55ecc154427b636119f0920d252 - default default] Bad inventory
Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/nova/api/openstack/placement/handlers/allocation.py", line 253, in set_allocations
allocations.create_all()
File "/usr/lib/python2.7/site-packages/oslo_versionedobjects/base.py", line 226, in wrapper
return fn(self, *args, **kwargs)
File "/usr/lib/python2.7/site-packages/nova/objects/resource_provider.py", line 1050, in create_all
self._set_allocations(self._context, self.objects)
File "/usr/lib/python2.7/site-packages/oslo_db/sqlalchemy/enginefacade.py", line 894, in wrapper
return fn(*args, **kwargs)
File "/usr/lib/python2.7/site-packages/nova/objects/resource_provider.py", line 1011, in _set_allocations
before_gens = _check_capacity_exceeded(conn, allocs)
File "/usr/lib/python2.7/site-packages/nova/objects/resource_provider.py", line 921, in _check_capacity_exceeded
resource_provider=rp_uuid)
InvalidAllocationConstraintsViolated: Unable to create allocation for 'DISK_GB' on resource provider 'f9398126-d0e8-4cf8-ae45-9103a88aa13d'. The requested amount would violate inventory constraints.
The causing code is at
https://github.com/openstack/nova/blob/474c2ef28234dacc658e9a78762cac66ef7fe334/nova/scheduler/client/report.py#L105
The correct fix is probably that whenever the value of any resource
class is zero, don't send that resource class in the dict.
To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1647316/+subscriptions
References