POST – HTTP Push update for firmware
This operation can perform an update of installed software component(s) by pushing a software image file to the URI referenced by UpdateService.HttpPushUri property.
Request URL
https://<SMM_IPADDR>/redfish/v1/UpdateService/update
Request body
The POST to this URI shall provide authentication with the same privilege as what is used to access the UpdateService.
- “X-Auth-Token” using the existing or new
- BASIC “Authorization” header to specify user’s credentials.
Response body
Http Push Update supports file upload that uses binary data posting (e.g., curl –data-binary option, assuming the content-encoding of the body is application/octet-stream). It also supports file upload with form POST method that is equivalent to doing “curl -F” operation which indicates the header “Content-Type: mulitpart/form-data”.
If the client uploads multiple files in the same POST request, only the first file will be accepted, and others will be ignored.
The client may optionally include the “Content-Length” header on the POST to indicate the POST body size. SMM checks this header and verify that the size is within the maximum supported file size for FW updates. If the file is larger than what the service supports, the service returns code 413 (Request Entity Too Large) with an error message indicating that the file size is too large.
The “Content-Length” given shall be within 0~2147483647 (0~0x7FFFFFFF) or HTTP 400 will be returned.
The client may optionally include HTTP multipart form data in the POST body data to specify the image file name, as defined in RFC2388. This is equivalent to doing “curl -F” operation. This is optional and the service must not require it. If the client uploads multiple files in the same POST request, the service shall return an HTTP 400 (Bad Request) with an error message indicating that the format is not supported.
If another POST to HttpPushUri firmware update is performed while the service is busy flashing the previous update, the service will accept the request and upload the file, and if updating is still in progress when file upload is completed the service will return ResourceInUse error in the Task resource indicating that the Update Service is busy and reject the Push Update.
Although being individual URIs, uploading a file via HttpPushUri may be rejected with 409 Confilict if a file upload via MultipartHttpPushUri is in progress, and vice versa.
Status code
| HTTP Status Code | Error Message ID |
|---|---|
| 401 | Unauthorized |
| 403 | Forbidden |
| 503 | Service Temporarily Unavailable |
| 500 | Internal Error |
| 202 | Accept |
Example
The example of push upload:
Push the firmware image to the URL in HttpPushUri property.
Sample curl command is below for HTTP push update request for UEFI.
curl -k -H <Authentication> -H "Content-Type: application/octet-stream" -T <firmware image>https://{SMM3 IP}:{SMM3 port}/redfish/v1/UpdateService/updateNote- <Authentication>
- BasicAuth (ex: -u user:password, or -H “X-Auth-Token: Basic <encoding string>")
- X-Auth-Token (ex: -H “X-Auth-Token: <token string>”)
- <firmware image>
- ex: “lnvgy_fw_smm3_q4sm01a-1.0.00_anyos_comp.uxz”