Bug 1874238 - During idrac-virtualmedia install, ironic does not boot up the servers due to not including Location: in header _set_boot_device
Summary: During idrac-virtualmedia install, ironic does not boot up the servers due to...
Keywords:
Status: CLOSED DUPLICATE of bug 1873487
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Bare Metal Hardware Provisioning
Version: 4.6
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: ---
Assignee: Derek Higgins
QA Contact: Amit Ugol
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2020-08-31 18:41 UTC by rlopez
Modified: 2020-09-16 06:33 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-09-01 16:35:18 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description rlopez 2020-08-31 18:41:09 UTC
Description of problem:

RedFish virtualmedia with Dell servers using the idrac-virtualmedia option does not power on the systems due to missing location in header when setting boot device. 

The error:

2020-08-27 13:26:35.295 1 DEBUG ironic.drivers.modules.drac.boot [req-e258500d-b366-455c-8636-020f076a9117 - - - - -] Sushy OEM extension Python package 'sushy-oem-idrac' failed to set virtual boot device with system 4c4c4544-0048-3610-8056-b3c04f505832 manager 3258504f-c0b3-5680-3610-00484c4c4544 for node 170f99b8-82bb-4de5-8374-821f55f61865. Will try next manager, if available. Error: Sushy Extension Error: Response 202 to HTTP POST with args ('/redfish/v1/Managers/iDRAC.Embedded.1/Actions/Oem/EID_674_Manager.ImportSystemConfiguration',), kwargs {'data': {'ShareParameters': {'Target': 'ALL'}, 'ImportBuffer': '<SystemConfiguration><Component FQDD="iDRAC.Embedded.1"><Attribute Name="ServerBoot.1#BootOnce">Enabled</Attribute><Attribute Name="ServerBoot.1#FirstBootDevice">VCD-DVD</Attribute></Component></SystemConfiguration>'}} does not include Location: in header _set_boot_device /usr/lib/python3.6/site-packages/ironic/drivers/modules/drac/boot.py:144^[[00m


I've confirmed the workaround provided by Derek that modifying the following file within the ironic-conductor container fixes the issue in that it allows the Dell systems to power on. 

diff --git a/sushy_oem_idrac/asynchronous.py b/sushy_oem_idrac/asynchronous.py
index 4cfa763..881860d 100644
--- a/sushy_oem_idrac/asynchronous.py
+++ b/sushy_oem_idrac/asynchronous.py
@@ -42,8 +42,9 @@ def http_call(conn, method, *args, **kwargs):
     LOG.debug('Finished HTTP %s with args %s %s, response is '
               '%d', method, args or '', kwargs, response.status_code)
 
+    location = None
     while response.status_code == 202:
-        location = response.headers.get('location')
+        location = response.headers.get('location', location)
         if not location:
             raise sushy.exceptions.ExtensionError(
                 error='Response %d to HTTP %s with args %s, kwargs %s '

Comment 1 Beth White 2020-09-01 16:35:18 UTC

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


Note You need to log in before you can comment on or make changes to this bug.