NFV-VIM: fails when USM API returns incorrect response code for software deploy host failed

Bug #2093792 reported by Joshua Kraitberg
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
StarlingX
Fix Released
Low
Joshua Kraitberg

Bug Description

Brief Description
-----------------
Software deploy host step did not notice host failed.

Severity
--------
Minor

Steps to Reproduce
------------------
Fresh install 24.09.1
sw-manager sw-deploy-strategy create WRCP-24.09.2 --alarm-restrictions relaxed --worker-apply-type parallel

Expected Behavior
------------------
VIM fails because host-deploy-failed

Actual Behavior
----------------
VIM doesn't notice host-deploy-failed and fails trying to unlock host

Reproducibility
---------------
100%

System Configuration
--------------------
Any

Branch/Pull Time/Commit
-----------------------
Jan 10, 2025

Last Pass
---------
Couple weeks ago

Timestamp/Logs
--------------
sysadmin@controller-0:~$ sudo software --debug deploy host controller-1
Password:
connect: (127.0.0.1, 5493) ************
send: b'POST /v1/deploy_host/controller-1 HTTP/1.1\r\nHost: 127.0.0.1:5493\r\nContent-Length: 0\r\ncontent-type: application/json\r\naccept: application/json\r\nuser-agent: Python-httplib2/0.18.1 (gzip)\r\naccept-encoding: gzip, deflate\r\n\r\n'
reply: 'HTTP/1.0 200 OK\r\n'
header: Date: Fri, 10 Jan 2025 21:44:50 GMT
header: Server: WSGIServer/0.2 CPython/3.9.2
header: Content-Length: 128
header: Content-Type: application/json
{
    "error": "Host deployment failed on controller-1.\n",
    "info": "Host deployment request sent to controller-1.\n",
    "warning": ""
}
Error:
Host deployment failed on controller-1.

Test Activity
-------------
Feature Testing

Workaround
----------
No work around required. This issue only causes confusion for the user regarding the true cause of why the strategy failed.

Changed in starlingx:
assignee: nobody → Joshua Kraitberg (jkraitbe-wr)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to nfv (master)

Fix proposed to branch: master
Review: https://review.opendev.org/c/starlingx/nfv/+/938965

Changed in starlingx:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nfv (master)

Reviewed: https://review.opendev.org/c/starlingx/nfv/+/938965
Committed: https://opendev.org/starlingx/nfv/commit/a8d6da428ee78daed264a8752473442031eaadaf
Submitter: "Zuul (22348)"
Branch: master

commit a8d6da428ee78daed264a8752473442031eaadaf
Author: Joshua Kraitberg <email address hidden>
Date: Fri Jan 10 16:54:49 2025 -0500

    Always verify status of software deploy host

    Currently, the HTTP response code from software deploy host is used to
    determine if the command was successfully. However, a recent change has
    caused failed deploy hosts to return 200 tricking VIM into thinking they
    worked.

    This change forces VIM to always check the deploy host status instead of
    using the HTTP code.

    TEST PLAN:
    PASS: AIO-SX minor upgrade
    * No impact when deploy host succeeds
    PASS: AIO-SX major upgrade
    * No impact when deploy host succeeds
    PASS: Standard minor upgrade
    * deploy-host-failed detected correctly

    Closes-Bug: 2093792
    Change-Id: I9c8150b56296f2907e8340382f05a482dfb9bc38
    Signed-off-by: Joshua Kraitberg <email address hidden>

Changed in starlingx:
status: In Progress → Fix Released
Ghada Khalil (gkhalil)
Changed in starlingx:
importance: Undecided → Low
tags: added: stx.11.0 stx.nfv
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.