Skip to main content

POST – Collect BMC diagnostic Data

Use the POST method to collect BMC diagnostic Data.

Request URL

POST https://<BMC_IPADDR>/redfish/v1/Systems/1/LogServices/DiagnosticLog/Actions/LogService.CollectDiagnosticData

Request body

FieldTypeDescription

DiagosticDataType

String“Manager”

Response body

None

Status code

HTTP Status CodeError Message ID
500InternalError

Example

The following example is POST body.

{
"DiagnosticDataType" : "Manager"
}

This action returns a task on success. The following example JSON response is returned:

{
"StartTime": "2022-09-19T02:57:13+00:00",
"@odata.etag": "\"1663556233921\"",
"@odata.context": "/redfish/v1/$metadata#Task.Task",
"HidePayload": true,
"@odata.type": "#Task.v1_5_1.Task",
"Id": "34be0171-cfc9-4cf8-9d40-2c6224b0800e",
"TaskState": "New",
"Messages": [],
"Name": "Task 34be0171-cfc9-4cf8-9d40-2c6224b0800e",
"TaskMonitor": "/redfish/v1/TaskService/0f121786-b93a-4095-bc94-ab749ebe43ab",
"@odata.id": "/redfish/v1/TaskService/Tasks/34be0171-cfc9-4cf8-9d40-2c6224b0800e",
"Description": "This resource represents a task for a Redfish implementation."
}

This task will continue to monitor the progress of Diagnostic Data generation. User can get the progress, task state, and more detailed information by accessing the URI indicated in the returned property “TaskMonitor”. The following example JSON response is returned.

{
"StartTime": "2022-09-19T02:57:13+00:00",
"Id": "34be0171-cfc9-4cf8-9d40-2c6224b0800e",
"HidePayload": true,
"@odata.context": "/redfish/v1/$metadata#Task.Task",
"TaskStatus": "OK",
"@odata.etag": "\"1663556278229\"",
"@odata.type": "#Task.v1_5_1.Task",
"Messages": [
{
"Message": "The request completed successfully.",
"MessageId": "Base.1.12.Success",
"MessageSeverity": "OK",
"@odata.type": "#Message.v1_1_2.Message",
"MessageArgs": [],
"Resolution": "None"
},
{
"Message": "'FFDC' diagnostic data collected.",
"MessageId": "LogService.1.0.DiagnosticDataCollected",
"MessageSeverity": "OK",
"@odata.type": "#Message.v1_1_2.Message",
"Resolution": "None.",
"MessageArgs": [
"FFDC"
]
}
],
"EndTime": "2022-09-19T02:57:58+00:00",
"TaskState": "Completed",
"Name": "Task 34be0171-cfc9-4cf8-9d40-2c6224b0800e",
"TaskMonitor": "/redfish/v1/TaskService/0f121786-b93a-4095-bc94-ab749ebe43ab",
"@odata.id": "/redfish/v1/TaskService/Tasks/34be0171-cfc9-4cf8-9d40-2c6224b0800e",
"Description": "This resource represents a task for a Redfish implementation."
}

When the Task is complete, user can find the LogEntry resource path in the HTTP header “Location” of the returned task monitor. This LogEntry resource tells user the basic information of the achieved Diagnostics Data. With Redfish X-Auth-Token (refer to POST – Create a session), user can download it by the URI indicated in the property “AdditionalDataURI” via HTTPS. Below is an example of the corresponding LogEntry resource.

{
"OemRecordFormat": "Lenovo",
"AdditionalDataSizeBytes": 18521125,
"@odata.etag": "\"3bd1c929ad52266950f\"",
"@odata.context": "/redfish/v1/$metadata#LogEntry.LogEntry",
"Description": "This resource is used to represent a log entry for log services for a Redfish implementation.",
"DiagnosticDataType": "Manager",
"Name": "FFDC",
"Created": "2022-09-19T02:57:53+00:00",
"Id": "FFDC",
"EntryType": "Oem",
"@odata.type": "#LogEntry.v1_11_0.LogEntry",
"@odata.id": "/redfish/v1/Systems/1/LogServices/DiagnosticLog/Entries/FFDC",
"AdditionalDataURI": "/imm_dump/FFDC/7D72RCZ000_1234567890_xcc_220919-025717.tzz"
}

In this example, the achieved Diagnostics Data can be download by "https://<bmc_ip>/imm_dump/FFDC/7D72RCZ000_1234567890_xcc_220919-025717.tzz with Redfish X-Auth-Token."