← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1790721] Re: nova-status upgrade check shows warnings when it shouldn't

 

Reviewed:  https://review.openstack.org/599744
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=63c10d2d536c3ffed68ccfb6bd393f317111d903
Submitter: Zuul
Branch:    master

commit 63c10d2d536c3ffed68ccfb6bd393f317111d903
Author: Matt Riedemann <mriedem.os@xxxxxxxxx>
Date:   Tue Sep 4 14:53:25 2018 -0400

    Configure placement DB context manager for nova-manage/status
    
    The create_incomplete_consumers online data migration was added in
    Rocky via change Id609789ef6b4a4c745550cde80dd49cabe03869a. That
    relies on hitting some tables in the API (or placement) database.
    The DB API code for that migration relies on a placement context
    manager which looks like it was regressed with change
    I2fff528060ec52a4a2e26a6484bdf18359b95f77 (also in Rocky). This
    results in a DB error trying to query the projects table but
    because of a generic try/except in _run_migration, the failure
    was missed in CI testing.
    
    Similarly, the nova-status upgrade check "_check_resource_providers"
    routine also uses the placement DB API context manager to count the
    number of compute resource providers in the API (or placement) DB,
    which is returning 0 because it's not using the proper DB connection.
    This was not caught in the nova-status CLI tests because they use
    the DatabaseFixture which *does* configure the global placement DB
    API context manager.
    
    This adds the configuration of the global placement DB API context
    manager so we can properly query the placement-related tables.
    The blanket problematic try/except from _run_migration is left
    as-is in this change but will be addressed in a separate patch.
    
    Integration testing of this fix is being performed with devstack:
    
      https://review.openstack.org/599847/
    
    Change-Id: I9d97b7a904e2b7d15c763e2a067cc5909cc6c9c5
    Closes-Bug: #1790701
    Closes-Bug: #1790721


** Changed in: nova
       Status: In Progress => Fix Released

-- 
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/1790721

Title:
  nova-status upgrade check shows warnings when it shouldn't

Status in OpenStack Compute (nova):
  Fix Released
Status in OpenStack Compute (nova) ocata series:
  In Progress
Status in OpenStack Compute (nova) pike series:
  In Progress
Status in OpenStack Compute (nova) queens series:
  In Progress
Status in OpenStack Compute (nova) rocky series:
  In Progress

Bug description:
  # nova-status upgrade check
  +-------------------------------------------------------------------+
  | Upgrade Check Results                                             |
  +-------------------------------------------------------------------+
  | Check: Cells v2                                                   |
  | Result: Success                                                   |
  | Details: None                                                     |
  +-------------------------------------------------------------------+
  | Check: Placement API                                              |
  | Result: Success                                                   |
  | Details: None                                                     |
  +-------------------------------------------------------------------+
  | Check: Resource Providers                                         |
  | Result: Warning                                                   |
  | Details: There are no compute resource providers in the Placement |
  |   service but there are 2 compute nodes in the deployment.        |
  |   This means no compute nodes are reporting into the              |
  |   Placement service and need to be upgraded and/or fixed.         |
  |   See                                                             |
  |   https://docs.openstack.org/nova/latest/user/placement.html      |
  |   for more details.                                               |
  +-------------------------------------------------------------------+
  | Check: Ironic Flavor Migration                                    |
  | Result: Success                                                   |
  | Details: None                                                     |
  +-------------------------------------------------------------------+
  | Check: API Service Version                                        |
  | Result: Success                                                   |
  | Details: None                                                     |
  +-------------------------------------------------------------------+
  | Check: Request Spec Migration                                     |
  | Result: Success                                                   |
  | Details: None                                                     |
  +-------------------------------------------------------------------+

  nova hypervisor-list
  +--------------------------------------+-----------------------------+-------+---------+
  | ID                                   | Hypervisor hostname         | State | Status  |
  +--------------------------------------+-----------------------------+-------+---------+
  | UUID1                                | node03.NOPE                 | up    | enabled |
  | UUID2                                | node02.NOPE                 | up    | enabled |
  +--------------------------------------+-----------------------------+-------+---------+

  openstack resource provider list
  +--------------------------------------+-----------------------------+------------+
  | uuid                                 | name                        | generation |
  +--------------------------------------+-----------------------------+------------+
  | UUID1                                | node02.NOPE                 |         76 |
  | UUID2                                | node03.NOPE                 |         34 |
  +--------------------------------------+-----------------------------+------------+

To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1790721/+subscriptions


References