ProLiant Servers (ML,DL,SL)

iLO Redfish question

 
BradV
Respected Contributor

iLO Redfish question

Trying to get signed certificates for our iLO interfaces.  I first extracted  list of hardware from OneView and put in a file.  I get session credentials from OneView and then run:

HARDW=hardware-list
for SERVER in server-r{1..3}-n{1..23}-ilo; do
   UUID=$(jq -r '.members[] | select(.name=="'${SERVER}'") | "\(.uuid)"' ${HARDW})
   read iLOSSO iLOAuth <<< $(curl --insecure --header "X-API-Version: ${currentVersion}" \
      --header "auth: ${sessionID}" \
      --request GET ${OneView}/rest/server-hardware/${UUID}/remoteConsoleUrl | \
      jq -r '.remoteConsoleUrl' | sed -e 's|hplcons|https|' -e 's|addr=||' \
      -e 's|^\(.*\)&sesionkey=\(.*\)$|\1 \2|'); CSR=$(curl --insecure --header "X-Auth-Token: ${iLOAuth}" |
      --header "Content-Type: application/json" \
      --data '{"City":"Myplace","CommonName":"'${SERVER}'","Country":"US","OrgName":"MYPlace","OrgUnit":"XXX,YYY,ZZZ","State":"MD","IncludeIP":"true"}' \
      --request POST ${iLOSSO}/redfish/v1/Managers/1/SecurityService/HttpsCert | \
      jq -r '.')
   echo "${SERVER},${CSR}"
done

   I'm getting back:  

{
  "error": {
    "code": "iLO.0.10.ExtendedInfo",
    "message": "See @Message.ExtendedInfo for more information.",
    "@Message.ExtendedInfo": {
      {
        "MessageArgs": [
          "Action"
        ],
      "MessageId": "Base.1.4.PropertyMissing"
     }
    }
  }
}

First, does anyone have an idea what I am missing?

Second, we normally provide three OrgUnit's when creating a CSR.  I tried putting "OrgUnit":"data" in three times, but it looks like it only took the last one.  Oh, can I do:  "OrgUnit": [ "XXX", "YYY", "ZZZ" ]  ?

1 REPLY 1
Suman_1978
HPE Pro

Re: iLO Redfish question

Hi,

May be these links will help you for "MessageId": "Base.1.4.PropertyMissing"

https://github.com/HewlettPackard/ilo-rest-api-docs/blob/master/source/includes/_ilo5_msgregs.md

https://hewlettpackard.github.io/iLOAmpPack-Redfish-API-Docs/

Base.1.4.PropertyMissing
Indicates that a required property was not supplied as part of the request.

Resolution: Ensure that the property is in the request body and has a valid value and resubmit the request if the operation failed.

Thanks


I work for HPE

Accept or Kudo