metal/mtce
Eric MacDonald 4f5bf78f55 Improve mtcAgent interrupted thread cleanup
A BMC command send will be rejected if its thread
is not in the IDLE state going into the call.

This issue is seen to occur over a reprovisioning action
while the bmc access alarmable condition exists.

Maintenance will do retries. So the only visible side affect
of this issue is a failure to provision to 'redfish' over a
provisioning switch to 'dynamic' (learn mode). Instead
ipmi is selected.

The non-return to idle can occur when the bmc handler FSM
is interrupted by a reprovisioning request while a bmc
command is in flight.

This update enhances the thread management module by
introducing a thread consumption utility that is called
by the bmc command send utility. If the send finds that
its thread is not in the IDLE state it will either kill
the thread if it is running or free a completed but-not-
consumed thread result.

Note: Maintenance only supports the execution of
a single thread per host per process at one time.

Test Plan:

PASS: Verify BMC provisioning change from ipmi to dynamic
      while the ipmi provisioning was failing prior to
      re-provisioning. Verify the previous error is cleaned
      up and the reprovisioning request succeeds as expected.

PASS: Verify thread 'execution timeout kill' cleanup handling.
PASS: Verify thread 'complete but not consumed' cleanup handling.
PASS: Verify logging during regression soaks

Regression:

PASS: Verify bmc protocol reprovisioning script soak
PASS: Verify sensor monitoring following BMC reprovisioning
PASS: Verify product verification mtce regression test suite

Change-Id: Ie5e9e89ed2f8db6888c0fc7de03d494c75517178
Closes-Bug: 1864906
Signed-off-by: Eric MacDonald <eric.macdonald@windriver.com>
2021-03-15 10:51:16 -04:00
..
centos Merge "Add /var/crash dump management to maintenance." 2020-10-18 04:34:31 +00:00
opensuse De-branding in starlingx/metal: Titanium Cloud -> StarlingX 2020-04-03 07:58:25 +02:00
src Improve mtcAgent interrupted thread cleanup 2021-03-15 10:51:16 -04:00
PKG-INFO Decouple Guest-server/agent from stx-metal 2018-09-18 17:15:08 -04:00