Invalid engine server resource validation does not work with nova Noopquotadriver

Bug #1310710 reported by Vladimir Kuklin on 2014-04-21
20
This bug affects 3 people
Affects Status Importance Assigned to Milestone
Fuel for OpenStack
High
Max Rasskazov
Murano
Undecided
Unassigned
OpenStack Heat
Fix Released
High
Dmitry Borodaenko
Icehouse
Fix Released
High
Dmitry Borodaenko

Bug Description

How to reproduce:

Deploy openstack with Nova configured to use NoopQuotaDriver.
Try to create simple stack, e.g. use this as template file contents:

{
  "AWSTemplateFormatVersion": "2010-09-09",
  "Outputs": {},
  "Description": "Hadoop Cluster by Sahara",
  "Resources": {
    "instance1": {
      "Type": "OS::Nova::Server",
      "Properties": {
        "name": "instance1",
        "flavor": "1",
        "image": "af72cf5c-02f5-4260-a181-da7331b58ca2"
      }
    }
  }
}

The problem is for example here:

https://github.com/openstack/heat/blob/stable/icehouse/heat/engine/resources/server.py#L945-L949

It is easy to see that in case of '-1's returned by nova NoopQuotaDriver, even empty values will exceed the quota.

The workaround is to either change the quota driver to DbQuotaDriver or to comment out these checks.

Changed in fuel:
status: New → Triaged
milestone: none → 5.0
assignee: nobody → Fuel Library Team (fuel-library)
importance: Undecided → High
Changed in fuel:
assignee: Fuel Library Team (fuel-library) → Fuel OSCI Team (fuel-osci)
Roman Vyalov (r0mikiam) on 2014-04-22
Changed in fuel:
assignee: Fuel OSCI Team (fuel-osci) → Max Rasskazov (mrasskazov)

Looks like we can fix this issue only in Heat and after that use the correct Heat version to fix this issue in other components.
Can we remove Murano from the list of related projects?

Changed in murano:
importance: Undecided → High

This bug will be fixed in Heat and Murano will use new version of Heat. No changes in Murano needed to fix this issue.

Changed in murano:
importance: High → Undecided
status: New → Invalid
Changed in heat:
status: New → Confirmed
Max Rasskazov (mrasskazov) wrote :
Changed in fuel:
status: Triaged → In Progress
Sergey Lukjanov (slukjanov) wrote :

It's not related to Sahara.

no longer affects: sahara
Max Rasskazov (mrasskazov) wrote :
Changed in fuel:
status: In Progress → Fix Committed
Roman Vyalov (r0mikiam) on 2014-04-29
Changed in heat:
status: Confirmed → Fix Committed
status: Fix Committed → New
status: New → Confirmed
Clint Byrum (clint-fewbar) wrote :

Note that I believe this bug was caused by unclear Nova docs.

https://bugs.launchpad.net/openstack-api-site/+bug/1316381

Reviewed: https://review.openstack.org/89389
Committed: https://git.openstack.org/cgit/openstack/heat/commit/?id=ea5285fd5080e5fec20a8763ef98e6ffa9c7dea1
Submitter: Jenkins
Branch: master

commit ea5285fd5080e5fec20a8763ef98e6ffa9c7dea1
Author: Vladimir Kuklin <email address hidden>
Date: Mon Apr 21 21:42:14 2014 +0400

    Ignore nova limits set to '-1'

    In case nova server has quotas turned off, e.g. when it uses
    NoopQuotaDriver, nova-api returns '-1' for corresponding resources which
    obviously means 'INFINITY'. In this case we should not check resource
    template for any limits and should pass resource creation as-is.

    Change-Id: Idaf485719e384f3a613031c7ff272d55798e6e77
    Closes-Bug: #1310710
    Co-Authored-By: Dmitry Borodaenko <email address hidden>

Changed in heat:
status: Confirmed → Fix Committed
Alan Pevec (apevec) on 2014-05-29
Changed in heat:
importance: Undecided → High
assignee: nobody → Dmitry Borodaenko (dborodaenko)

Reviewed: https://review.openstack.org/89388
Committed: https://git.openstack.org/cgit/openstack/heat/commit/?id=937ac5a0894719af21cfac24e218a980307fceed
Submitter: Jenkins
Branch: stable/icehouse

commit 937ac5a0894719af21cfac24e218a980307fceed
Author: Vladimir Kuklin <email address hidden>
Date: Mon Apr 21 21:42:14 2014 +0400

    Ignore nova limits set to '-1'

    In case nova server has quotas turned off, e.g. when it uses
    NoopQuotaDriver, nova-api returns '-1' for corresponding resources which
    obviously means 'INFINITY'. In this case we should not check resource
    template for any limits and should pass resource creation as-is.

    Change-Id: Idaf485719e384f3a613031c7ff272d55798e6e77
    Closes-Bug: #1310710
    Co-Authored-By: Dmitry Borodaenko <email address hidden>

Thierry Carrez (ttx) on 2014-06-11
Changed in heat:
milestone: none → juno-1
status: Fix Committed → Fix Released
Thierry Carrez (ttx) on 2014-10-16
Changed in heat:
milestone: juno-1 → 2014.2
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers