Redfish controller iDRAC returns 406 error
Bug #1842486 reported by
Chris Newcomer
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
MAAS |
Expired
|
Medium
|
Unassigned |
Bug Description
When using the MAAS GUI to control an iDRAC BMC (version 3.30.30.30) via the Redfish protocol, it dumps a stack trace in the rackd.log and returns a 406 error. This is believed to be due to an issue with the version of iDRAC that doesn't conform to the RFC:
If no Accept header field is present, then it is assumed that the client accepts all media types.
Q: Does MAAS explicitly set the 'Accept: application/json' header?
A similar issue reported in Ansible that was fixed by setting the header:
https:/
Changed in maas: | |
status: | New → Triaged |
importance: | Undecided → Medium |
To post a comment you must log in.
After reviewing the code in [2], it would appear that the proper headers are not being sent to the Redfish API, according to [1]:
GET_HEADERS = {'accept': 'application/json', 'OData-Version': '4.0'}
POST_HEADERS = {'content-type': 'application/json', 'accept': 'application/json', 'OData-Version': '4.0'}
PATCH_HEADERS = {'content-type': 'application/json', 'accept': 'application/json', 'OData-Version': '4.0'}
DELETE_HEADERS = {'accept': 'application/json', 'OData-Version': '4.0'}
Not sure the OData ones are needed, those are mostly for compliance, but others are definitely needed or it will fail in some hardware.
[1] https:/ /github. com/ansible/ ansible/ pull/55193 /git.launchpad. net/maas/ tree/src/ provisioningser ver/drivers/ power/redfish. py#n57
[2] https:/