From bcce3bdc6b33c8d6f0721eac024ebff61de1e2db Mon Sep 17 00:00:00 2001 From: mpardhi23 Date: Tue, 14 May 2019 07:53:31 -0400 Subject: [PATCH] Check LCStatus instead of MessageID to determine if an iDRAC is ready We are currently checking the MessageID to determine if an iDRAC is ready. This patch is to check the value of LCStatus instead of MessageID. If the value of LCStatus is "0", then the iDRAC is considered ready. Change-Id: I3426c226c4bb3cdcc95b98e9b203f100bb6777d5 --- dracclient/client.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/dracclient/client.py b/dracclient/client.py index 34d4aec..ff15ba1 100644 --- a/dracclient/client.py +++ b/dracclient/client.py @@ -33,7 +33,7 @@ from dracclient.resources import uris from dracclient import utils from dracclient import wsman -IDRAC_IS_READY = "LC061" +IDRAC_IS_READY = "0" LOG = logging.getLogger(__name__) @@ -1231,11 +1231,11 @@ class WSManClient(wsman.Client): expected_return_value=utils.RET_SUCCESS, wait_for_idrac=False) - message_id = utils.find_xml(result, - 'MessageID', - uris.DCIM_LCService).text + lc_status = utils.find_xml(result, + 'LCStatus', + uris.DCIM_LCService).text - return message_id == IDRAC_IS_READY + return lc_status == IDRAC_IS_READY def wait_until_idrac_is_ready(self, retries=None, retry_delay=None): """Waits until the iDRAC is in a ready state