Bug 1965242

Summary: nova-status validaton fails during FFU (pre-upgrade group)
Product: Red Hat OpenStack Reporter: Michele Valsecchi <mvalsecc>
Component: openstack-tripleo-validationsAssignee: RHOS Maint <rhos-maint>
Status: CLOSED DUPLICATE QA Contact: nlevinki <nlevinki>
Severity: medium Docs Contact:
Priority: medium    
Version: 16.1 (Train)CC: drosenfe, gchamoul, jjoyce, jschluet, slinaber, tvignaud
Target Milestone: ---Keywords: Triaged
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-05-31 09:30:58 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version: Train
Embargoed:

Description Michele Valsecchi 2021-05-27 09:15:39 UTC
Description of problem:
nova-status command is malformed and Ansible fails to execute the correct command (docker).

As the command appears to have an empty space followed by the rest of the docker command.
I have not digged into the playbooks in details, I'd lean saying there might be some substitution error in the Ansible book (The same group of tasks does indeed check for the existence/lack of podman).

Version-Release number of selected component (if applicable):
16.1 (undercloud 16.1, overcloud node still 13.X as this happens _during_ FFU)

How reproducible:


Steps to Reproduce:
1. Complete undercloud upgrade
2. run openstack tripleo validator run --group pre-upgrade --python-interpreter /usr/libexec/platform-python
3. openstack tripleo validator show run <uuid-of-container-status-validator>

Actual results:

Ansible fails with the following log

(undercloud) [stack@openstackhostundercloud ~]$ openstack tripleo validator show run xxx
{
    "hosts": {
        "overcloud-controller-X": {
            "_ansible_no_log": false,
            "action": "command",
            "changed": false,
            "cmd": "exec -u root nova_api nova-status upgrade check", <=== note how no docker nor podman are present before "exec"
            "failed": true,
            "invocation": {
                "module_args": {
                    "_raw_params": " exec -u root nova_api nova-status upgrade check", <=== note how there is an empty space before "exec"
                    "_uses_shell": false,
                    "argv": null,
                    "chdir": null,
                    "creates": null,
                    "executable": null,
                    "removes": null,
                    "stdin": null,
                    "stdin_add_newline": true,
                    "strip_empty_ends": true,
                    "warn": true
                }
            },
            "msg": "[Errno 2] No such file or directory", <===
            "rc": 2
        }
    },
    "name": "Check nova upgrade status",
    "status": "FAILED"
}

Expected results:

Ansible should succeed and use docker for said check

Additional info:

Running manually the task completes successfully
~~~
(overcloud) [root@overcloud-controller-X ~]# sudo docker exec -it nova_api nova-status upgrade check
Option "os_interface" from group "placement" is deprecated. Use option "valid-interfaces" from group "placement".
Option "os_region_name" from group "placement" is deprecated. Use option "region-name" from group "placement".
+--------------------------------+
| Upgrade Check Results          |
+--------------------------------+
| Check: Cells v2                |
| Result: Success                |
| Details: None                  |
+--------------------------------+
| Check: Placement API           |
| Result: Success                |
| Details: None                  |
+--------------------------------+
| Check: Resource Providers      |
| Result: Success                |
| Details: None                  |
+--------------------------------+
| Check: Ironic Flavor Migration |
| Result: Success                |
| Details: None                  |
+--------------------------------+
| Check: API Service Version     |
| Result: Success                |
| Details: None                  |
+--------------------------------+
~~~

Comment 1 Gaƫl Chamoulaud 2021-05-31 09:30:58 UTC

*** This bug has been marked as a duplicate of bug 1963879 ***