From faa8cb0fb78df82b3f4a44f0f5e850a7f6acce71 Mon Sep 17 00:00:00 2001 From: Matheus Guilhermino Date: Thu, 20 Jun 2024 16:12:55 -0300 Subject: [PATCH] Disable 900.002 alarm 900.002 alarm is sometimes raised after install or host unlock on all deploy types. This is an intermittent behaviour that happens because sw-patch is malfunctioning as it is no longer supported and has been replaced by USM. The patch-alarm package provides the patch-alarm-manager service and the alarms raised by patch-alarm-manager are: FM_ALARM_ID_PATCH_IN_PROGRESS = 900.001 FM_ALARM_ID_PATCH_HOST_INSTALL_FAILED = 900.002 FM_ALARM_ID_PATCH_OBS_IN_SYSTEM = 900.003 FM_ALARM_ID_NONSTANDARD_CERT_PATCH = 500.101 Since sw-patch will no longer be supported and the mechanism for raising alarms on patch-alarm depends on the sw-patch endpoints, the 900.002 alarm will be disabled to avoid unexpected behaviour. USM does not have the same patch application mechanisms and some alarms have been implemented already: FM_ALARM_ID_USM_DEPLOY_HOST_SUCCESS_RR = 900.020 FM_ALARM_ID_USM_DEPLOY_HOST_FAILURE = 900.021 TODO: Investigate if the any of the legacy alarms should be adapted to work with USM patching. Test Plan: PASS: Successful AIO-DX deploy with no 900.002 alarm PASS: Multiple lock-unlock operations with no alarms Closes-bug: 2056295 Change-Id: I844311e538aec0bc8990645d6ac0d254cb1e4a3a Signed-off-by: Matheus Guilhermino --- .../patch-alarm/patch_alarm/patch_alarm_manager.py | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/patch-alarm/patch-alarm/patch_alarm/patch_alarm_manager.py b/patch-alarm/patch-alarm/patch_alarm/patch_alarm_manager.py index 6af8e1c8..17c755fc 100644 --- a/patch-alarm/patch-alarm/patch_alarm/patch_alarm_manager.py +++ b/patch-alarm/patch-alarm/patch_alarm/patch_alarm_manager.py @@ -213,18 +213,6 @@ class PatchAlarmDaemon(object): else: logging.info("Updating patch-host-install-failure alarm") - fault = fm_api.Fault(alarm_id=fm_constants.FM_ALARM_ID_PATCH_HOST_INSTALL_FAILED, - alarm_type=fm_constants.FM_ALARM_TYPE_5, - alarm_state=fm_constants.FM_ALARM_STATE_SET, - entity_type_id=fm_constants.FM_ENTITY_TYPE_HOST, - entity_instance_id=entity_instance_id, - severity=fm_constants.FM_ALARM_SEVERITY_MAJOR, - reason_text=reason_text, - probable_cause=fm_constants.ALARM_PROBABLE_CAUSE_65, - proposed_repair_action='Undo patching operation', - service_affecting=False) - self.fm_api.set_fault(fault) - elif patch_failed_alarm is not None: logging.info("Clearing patch-host-install-failure alarm") self.fm_api.clear_fault(fm_constants.FM_ALARM_ID_PATCH_HOST_INSTALL_FAILED,