Add nova_status validation to queens
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
tripleo |
New
|
Undecided
|
Unassigned |
Bug Description
Backport nova status validation to queens to be used as a preupgrade validation. This is somewhat of a rewrite due to the newer structure being completely different.
- hosts: nova_api
vars:
metadata:
name: Nova Status Upgrade Check
description: |
Performs a release-specific readiness check before restarting services with
new code. This command expects to have complete configuration and access to
databases and services within a cell. For example, this check may query the
Nova API database and one or more cell databases. It may also make requests
to other services such as the Placement REST API via the Keystone service
catalog
The nova-status upgrade check command has three standard return codes:
0 -> All upgrade readiness checks passed successfully and there is nothing to do.
1 -> At least one check encountered an issue and requires further investigation. This is considered a warning but the upgrade may be OK.
2 -> There was an upgrade status check failure that needs to be investigated. This should be considered something that stops an upgrade.
groups:
- pre-upgrade
tasks:
- name: Set container_cli fact from the inventory
set_fact:
container
when: container_cli is not defined
- name: Check nova upgrade status
become: true
command: "{{ container_cli }} exec -u root nova_api nova-status upgrade check"
changed_when: false
register: nova_upgrade_check
- name: Warn if at least one check encountered an issue
warn:
msg: |
At least one check encountered an issue and requires further investigation.
This is considered a warning but the upgrade may be OK.
See the detail at https:/
when: "nova_upgrade_
- name: Fail if there was an upgrade status check failure
fail:
msg: |
There was an upgrade status check failure that needs to be investigated.
This should be considered something that stops an upgrade.
See the detail at https:/
when: "nova_upgrade_