User Guide
5. System Management
5.4 BMC Web GUI
curl -k -u USERNAME:PASSWORD -X POST -i -H Content-
Type:application/json
-d "{\"ImageURI\" : \"http://FILESERVER/RubyPeak-2Fan-2Cpu-
si-BMC_FW-Update.bin\", \"Targets\" : [\"/redfish/v1/
UpdateService/SoftwareInventory/BMC\"]}"
https://BMC IP Adress/redfish/v1/UpdateService/Actions/
UpdateService.SimpleUpdate
The structure of the POST command can be broken down into three components: the base
command with required headers, the data object containing the address to the firmware
update image, and the Redfish API target that will execute the command.
The base command and headers can be broken down as follows:
•
The
-k
modifier allows a connection to an unsecured server and can be omitted if the
user prefers to store the BMC firmware package on an SSL enabled server.
•
The
-u
modifer enables the Basic Auth requirement and is followed by the
USERNAME:PASSWORD of the account activating the upgrade.
Note:
The upgrade must come from an account the appropriate roles and
permissions to modify firmware code.
•
-X POST
specifies the type of REST command being entered. POST is required for
firmware upgrades.
•
-i
specifies that the HTTP response headers should be included in the response output.
•
-H
specifies a header to be sent with the response body. In this example the Content-
Type header is set to
application/json
to let the BMC know to expect a JSON
formatted request body.
The data object contains a JSON formatted request body that sets the address of the .bin
image on the host that stores it, and a "Target" that specifies which item in the Software
Inventory object to update. In this case that is set to the BMC.
The final component is the base target that initiates the SimpleUpdate action in the update
service.
Step 5 :
The BMC will commit the update and the response should looking something like the
following:
HTTP/1.1 303 See Other
Location: /redfish/v1/TaskMonit/deb1fde1-db8c-44c2-bba6-95d83f2c9e79
Content-Type: application/json
OData-Version: 4.0
Cache-Control: no-cache
Access-Control-Allow-Origin: *
Strict-Transport-Security: max-age=31536000; includeSubdomains; preload
X-UA-Compatible: IE=11
X-Frame-Options: SAMEORIGIN
X-XSS-Protection: 1; mode=block
Content-Length: 154
Date: Fri, 30 Nov 2018 17:16:24 GMT
Server: lighttpd/1.4.48
{"@odata.type":"#Message.v1_0_5.Message","MessageId":"Base.1.1.0.Success","Message":"Successfully
Completed Request","Severity":"OK","Resolution":"None"}
372