背景
当前openUBMC仅支持板内固件升级,不支持主备管理板同时升级,无法满足主管理板升级时主备管理板同时升级场景。为支持管理板主备固件升级功能,需要新增webrest接口、Redfish接口和资源协作接口,实现管理板主备串行/并行升级、升级进度查询、固件生效信息查询和一键触发生效等能力。
关联ISSUE
无
整体方案
管理板主备升级需要实现以下功能:
- 触发串行升级:支持通过Web页面触发管理板主备串行固件升级,主备管理板同时升级固件
- 触发并行升级:支持通过Web页面触发管理板主备并行固件升级,主备管理板同时升级固件
- 查询升级进度:支持通过Web页面获取管理板主备升级进度信息
- 查询待生效固件:支持通过Web页面获取管理板待生效固件列表及生效状态
- 生效固件:支持通过Web页面触发固件生效
评审点
本次评审项汇总:
| 评审点 | 标题 | 接口类型 |
|---|---|---|
| 评审点一 | 新增资源协作接口 bmc.kepler.Chassis.AggregationService.Update |
资源协作 |
| 评审点二 | 新增webrest接口 /UI/Rest/Chassis/AggregationService/Update/FirmwareInventory/:Id |
webrest |
| 评审点三 | 新增webrest接口 /UI/Rest/Chassis/AggregationService/Update/PendingFirmwares/:Id |
webrest |
| 评审点四 | 新增webrest接口 /UI/Rest/Chassis/AggregationService/Update/Actions/Update.StartActive |
webrest |
| 评审点五 | 新增Redfish接口 /redfish/v1/UpdateService/FirmwareInventory/Oem/{{OemIdentifier}}/FirmwareVersionAggregation |
Redfish |
| 评审点六 | 新增Redfish接口 /redfish/v1/UpdateService/Oem/{{OemIdentifier}}/UpdateProgress |
Redfish |
评审点一:新增资源协作接口 bmc.kepler.Chassis.AggregationService.Update
接口描述:框级固件升级接口,提供管理板固件串行/并行升级、升级进度查询、待生效固件查询、一键生效和固件版本信息查询能力。
资源树路径:/bmc/kepler/Chassis/AggregationService
接口:bmc.kepler.Chassis.AggregationService.Update
方法评审点
新增方法
| 方法名称 | 请求签名 | 请求参数描述 | 响应签名 | 响应参数描述 | 方法描述 | 访问权限 | |
|---|---|---|---|---|---|---|---|
| StartUpdate | ssa{ss} |
Id:签名为 s,表征本次升级单板IdFilePath:签名为 s,表征升级包路径AdditionalOptions:签名为 a{ss},表征固件升级可选参数,用于各种升级扩展场景 |
u |
TaskId:签名为 u,表征当前升级请求的任务标识 |
触发框内指定单板串行固件升级 | BasicSetting | |
| ParallelUpdate | sa{ss}a(sa{ss}) |
Id:签名为 s,表征本次升级单板IdUpdateOptions:签名为 a{ss},表征当前升级的扩展参数集合Packages:签名为 a(sa{ss}),表征当前升级请求的固件集合 |
uau |
TaskId:签名为 u,表征当前升级请求的任务标识SubTaskIds:签名为 au,表征当前升级请求中每个固件升级的子任务标识集合 |
触发框内指定单板并行固件升级 | BasicSetting | |
| GetUpdateProgress | as |
Ids:签名为 as,表征需要查询升级进度的单板Id集合 |
sa(a{ss}) |
UpdateMode:签名为 s,表征当前升级模式UpdateTasks:签名为 a(a{ss}),表征升级任务进度信息数组 |
获取单板固件升级进度 | ReadOnly | |
| GetPendingFirmwareList | s |
Id:签名为 s,表征本次查询待生效固件的单板Id |
a(a{ss}) |
PendingFirmwares:签名为 a(a{ss}),表征当前所有待生效固件的状态 |
获取指定单板待生效固件信息 | ReadOnly | |
| StartActiveWithPolicy | sia{ss} |
Id:签名为 s,表征触发生效的单板IdSystemId:签名为 i,多主机场景下生效指定hostActivePolicy:签名为 a{ss},固件生效扩展参数字典 |
u |
TaskId:签名为 u,表征生效任务标识 |
触发指定单板生效固件 | BasicSetting | |
| GetFirmwareInventory | s |
Id:签名为 s,表征需要查询固件信息的单板Id |
a(a{ss}) |
FirmwareInventory:签名为 a(a{ss}),表征固件版本信息数组,每个元素为字典格式 |
获取指定单板固件版本信息 | ReadOnly |
StartUpdate参数说明:
| 参数属性名称 | 参数属性取值 | 取值说明 |
|---|---|---|
| Id | String | 本次升级单板Id |
| FilePath | String | 升级包路径,如 /tmp/image.hpm |
ParallelUpdate参数说明:
| 参数属性名称 | 参数属性取值 | 取值说明 |
|---|---|---|
| Id | String | 本次升级单板Id |
ParallelUpdate - Packages结构体(sa{ss})说明:
| 签名 | 名称 | 取值 | 取值说明 | 取值样例 |
|---|---|---|---|---|
| s | FilePath | String | 本次升级固件的路径 | /tmp/image.hpm |
| a{ss} | AdditionalOptions | Dictionary | 本次更新请求的额外参数集合 | {ForceUpdate: “true”} |
GetUpdateProgress响应的UpdateTasks中每个元素(a{ss})的属性说明:
| 属性名称 | 属性签名 | 属性说明 |
|---|---|---|
| TaskName | s | 升级任务的名称 |
| Firmware | s | 升级固件的描述 |
| FirmwareInstance | s | 升级的固件实例 |
| FileName | s | 升级的固件包名 |
| Percentage | s | 升级进度百分比 |
| TaskState | s | 升级状态 |
| ErrorCode | s | 升级任务的错误码 |
| TaskId | s | 升级任务Id |
GetPendingFirmwareList响应的信息定义:
| 名称 | 取值 | 取值说明 | 取值样例 |
|---|---|---|---|
| SystemId | uint8 | 升级的设备归属的Host | 1 |
| Firmware | String | 升级的固件类型 | CPLD |
| FirmwareInstance | String | 升级的具体的固件名称 | MB_CPLD |
| ActiveStatus | String | 生效状态,取值:ToBeActivated/Activating/Activated | Activating |
| ActiveAction | String | 生效动作,取值:ResetBMC | ResetBMC |
| Version | String | 待生效固件的版本信息 | 1.03 |
StartActiveWithPolicy请求的ActivePolicy参数属性说明:
| 参数属性名称 | 参数属性取值 | 取值说明 |
|---|---|---|
| ActivationControl | “ResetBMC” | 生效控制方式 |
GetFirmwareInventory响应的字典(a{ss})属性说明:
| 属性名称 | 取值 | 取值说明 | 取值样例 |
|---|---|---|---|
| Name | String | 固件名称标识 | CpuBoard1 CPLD1 |
| Version | String | 固件版本号 | 1.05 |
| Type | String | 固件类型 | CpuBoard |
接口新增影响
| 路径 | 新增接口影响 | CSR配置影响 | 持久化影响 | 其他影响 | |
|---|---|---|---|---|---|
/bmc/kepler/Chassis/AggregationService |
对外提供管理板串行/并行升级、升级进度查询、待生效固件查询、一键生效和固件版本查询功能 | 不涉及重名属性,无影响 | 不涉及新增和废弃主键,无兼容性问题 | 需实现StartUpdate、ParallelUpdate、GetUpdateProgress、GetPendingFirmwareList、StartActiveWithPolicy和GetFirmwareInventory方法 |
评审点二:新增webrest接口,用于获取固件版本信息
uri:/UI/Rest/Chassis/AggregationService/Update/FirmwareInventory/:Id
变化类型:新增uri
操作类型:GET
应用场景:Web页面获取框内其他单板(如备管理板)固件版本信息用于展示
请求参数:{}
响应参数:见下表
操作权限:ReadOnly
| 属性名称 | 取值类型 | 说明 | 取值范围 | 默认值 | 是否允许为null | 约束 |
|---|---|---|---|---|---|---|
| FirmwareInventory | array | 固件版本信息列表 | json对象,具体见下表 | 空表 | 否 | 无 |
FirmwareInventory对象参数说明:
| 属性名称 | 取值类型 | 说明 | 取值范围 | 是否允许为null |
|---|---|---|---|---|
| Name | string | 固件名称标识 | “ActiveBMC”、“AvailableBMC”、“CpuBoard1 CPLD1” | 否 |
| Version | string | 固件版本号 | 合法版本号字符串 | 否 |
| Type | string | 固件类型 | “firmware”、“CpuBoard” | 否 |
样例展示:
URL: /UI/Rest/Chassis/AggregationService/Update/FirmwareInventory/HMM2
操作类型:GET
请求参数:{}
响应消息体举例:
{
"FirmwareInventory": [
{
"Name": "ActiveBMC",
"Version": "5.13.00.11",
"Type": "firmware"
},
{
"Name": "AvailableBMC",
"Version": "5.13.00.12",
"Type": "firmware"
},
{
"Name": "CpuBoard1 CPLD1",
"Version": "1.05",
"Type": "CpuBoard"
}
]
}
评审点三:新增webrest接口,用于查询固件待生效信息
uri:/UI/Rest/Chassis/AggregationService/Update/PendingFirmwares/:Id
变化类型:新增uri
操作类型: GET
应用场景:生效页面获取管理板待生效固件列表用于Web展示
请求参数:{}
响应参数:见下表
操作权限:ReadOnly
| 属性名称 | 取值类型 | 说明 | 取值范围 | 默认值 | 是否允许为null | 约束 |
|---|---|---|---|---|---|---|
| PendingFirmwares | array | 待生效的固件列表 | json对象,具体见下表 | 空表 | 否 | 无 |
PendingFirmwares对象参数说明如下:
| 属性名称 | 取值 | 中文 |
|---|---|---|
| SystemId | number(0~255) | 设备归属Host |
| FirmwareType | BMC/CPLD/BIOS/VRD/MCU | 固件类型 |
| ActiveStatus | ToBeActivated/Activating/Activated | 待生效/生效中/已生效 |
| ActiveAction | ResetBMC/PowerOff | 重启BMC/整机下电 |
| Version | string | 待生效固件版本信息 |
样例展示:
URL: /UI/Rest/Chassis/AggregationService/Update/PendingFirmwares/HMM1
操作类型:GET
请求参数:{}
响应消息体举例:
{
"PendingFirmwares": [
{
"SystemId": 1,
"FirmwareType": "CPLD",
"ActiveStatus": "ToBeActivated",
"ActiveAction": "ResetBMC",
"Version": "1.03"
}
]
}
评审点四:新增webrest接口,用于触发固件生效
uri:/UI/Rest/Chassis/AggregationService/Update/Actions/Update.StartActive
变化类型:新增uri
操作类型: POST
应用场景:统一生效页面一键触发生效
请求参数:见下表
操作权限:有"PowerOff"选项:BasicSetting与PowerMgmt;无"PowerOff"选项:BasicSetting
| 属性名称 | 取值类型 | 说明 | 取值范围 | 默认值 | 是否允许为null | 约束 |
|---|---|---|---|---|---|---|
| Id | string | 单板所在槽位号 | 合法槽位号字符串 | 无 | 否 | 无 |
| ActivationActions | array | 生效控制方式 | “ResetBMC” “PowerOff” |
空表 | 否 | 无 |
响应参数:通用任务uri
样例展示:
URL: /UI/Rest/Chassis/AggregationService/Update/Actions/Update.StartActive
操作类型:POST
请求参数:
{
"Id": "HMM1",
"ActivationActions": [
"ResetBMC",
"PowerOff"
]
}
响应消息体举例:
{"url":"/UI/Rest/Task/1"}
评审点五:新增Redfish接口,用于汇聚固件版本信息
资源URI:/redfish/v1/UpdateService/FirmwareInventory/Oem/{{OemIdentifier}}/FirmwareVersionAggregation
资源版本:FirmwareVersionAggregation.v1_0_0
变化类型:新增Redfish Oem资源
操作类型:GET
应用场景:主管理板获取备管理板固件信息
嵌套资源:本资源(FirmwareVersionAggregation)嵌套于 FirmwareInventory 资源的 Oem/{{OemIdentifier}}/FirmwareVersionAggregation 属性中
Link资源:本资源从属于 FirmwareInventory 资源,通过 FirmwareInventory 的 Oem.{{OemIdentifier}}.FirmwareVersionAggregation.@odata.id 导航发现
属性列表:
| 属性名 | 类型 | 示例/取值约束 | readonly | 易变属性 | 实现PATCH | 操作权限 | 描述 |
|---|---|---|---|---|---|---|---|
| FirmwareInventory | array | 见下方FirmwareVersion定义 | true | 否 | / | ReadOnly | 固件版本信息列表 |
| Name | string | “ActiveBMC”、“AvailableBMC”、"CpuBoard1 CPLD1"等 | true | 否 | / | ReadOnly | 固件名称标识 |
| Version | string | “5.13.00.11” | true | 否 | / | ReadOnly | 固件版本号 |
| Type | string | firmware、CpuBoard等 | true | 否 | / | ReadOnly | 固件类型 |
响应示例:
{
"@odata.context": "/redfish/v1/$metadata#FirmwareVersionAggregation.FirmwareVersionAggregation",
"@odata.id": "/redfish/v1/UpdateService/FirmwareInventory/Oem/{{OemIdentifier}}/FirmwareVersionAggregation",
"@odata.type": "#FirmwareVersionAggregation.v1_0_0.FirmwareVersionAggregation",
"Id": "FirmwareVersionAggregation",
"Name": "Firmware Version Aggregation",
"FirmwareInventory": [
{
"Name": "ActiveBMC",
"Version": "5.13.00.11",
"Type": "firmware"
},
{
"Name": "AvailableBMC",
"Version": "5.13.00.11",
"Type": "firmware"
},
{
"Name": "CpuBoard1 CPLD1",
"Version": "1.05",
"Type": "CpuBoard"
}
]
}
父资源导航:需在 /redfish/v1/UpdateService/FirmwareInventory 的 GET 响应体 Oem.{{OemIdentifier}} 中新增导航链接:
"FirmwareVersionAggregation": {
"@odata.id": "/redfish/v1/UpdateService/FirmwareInventory/Oem/{{OemIdentifier}}/FirmwareVersionAggregation"
}
Schema定义:需新增独立的FirmwareVersionAggregation Schema定义文件,包括索引文件和版本化定义文件
JSON Schema索引文件(firmwareversionaggregation.json):
{
"$schema": "http://redfish.dmtf.org/schemas/v1/redfish-schema.v1_1_0.json",
"title": "#FirmwareVersionAggregation.FirmwareVersionAggregation",
"$ref": "#/definitions/FirmwareVersionAggregation",
"definitions": {
"FirmwareVersionAggregation": {
"anyOf": [
{
"$ref": "http://redfish.dmtf.org/schemas/v1/odata.4.0.0.json#/definitions/idRef"
},
{
"$ref": "/redfish/v1/SchemaStore/en/FirmwareVersionAggregation.v1_0_0.json#/definitions/FirmwareVersionAggregation"
}
],
"updatable": false,
"insertable": false,
"deletable": false,
"uris": [
"/redfish/v1/UpdateService/FirmwareInventory/Oem/{{OemIdentifier}}/FirmwareVersionAggregation"
]
}
},
"copyright": "Copyright (c) {{OemIdentifier}} Technologies Co., Ltd. 2026. All rights reserved."
}
JSON Schema版本化定义文件(firmwareversionaggregation.v1_0_0.json):
{
"$schema": "http://redfish.dmtf.org/schemas/v1/redfish-schema.v1_1_0.json",
"title": "#FirmwareVersionAggregation.v1_0_0.FirmwareVersionAggregation",
"$ref": "#/definitions/FirmwareVersionAggregation",
"definitions": {
"FirmwareVersion": {
"type": "object",
"additionalProperties": false,
"properties": {
"Name": {
"description": "Firmware name identifier",
"longDescription": "The name identifier of the firmware, such as ActiveBMC, AvailableBMC, or CpuBoard1 CPLD1",
"type": "string",
"readonly": true
},
"Version": {
"description": "Firmware version number",
"longDescription": "The version number of the firmware",
"type": "string",
"readonly": true
},
"Type": {
"description": "Firmware type",
"longDescription": "The type of the firmware, such as firmware or CpuBoard",
"type": "string",
"readonly": true
}
},
"required": ["Name", "Version", "Type"]
},
"FirmwareVersionAggregation": {
"type": "object",
"additionalProperties": false,
"properties": {
"@odata.context": {
"$ref": "http://redfish.dmtf.org/schemas/v1/odata.4.0.0.json#/definitions/context"
},
"@odata.id": {
"$ref": "http://redfish.dmtf.org/schemas/v1/odata.4.0.0.json#/definitions/id"
},
"@odata.type": {
"$ref": "http://redfish.dmtf.org/schemas/v1/odata.4.0.0.json#/definitions/type"
},
"Id": {
"description": "Unique identifier",
"longDescription": "The unique identifier for this resource",
"type": "string",
"readonly": true
},
"Name": {
"description": "Resource name",
"longDescription": "The name of the resource",
"type": "string",
"readonly": true
},
"FirmwareInventory": {
"description": "Firmware version information list",
"longDescription": "The list of firmware version information for all firmware components",
"type": "array",
"items": {
"$ref": "#/definitions/FirmwareVersion"
},
"readonly": true
}
},
"required": ["Id", "Name", "FirmwareInventory"]
}
},
"copyright": "Copyright (c) {{OemIdentifier}} Technologies Co., Ltd. 2026. All rights reserved."
}
评审点六:新增Redfish接口,用于查询固件升级进度
资源URI:/redfish/v1/UpdateService/Oem/{{OemIdentifier}}/UpdateProgress
资源版本:UpdateProgress.v1_0_0
嵌套资源:本资源(UpdateProgress)嵌套于 UpdateService 资源的 Oem/{{OemIdentifier}}/UpdateProgress 属性中
Link资源:本资源从属于 UpdateService 资源,通过 UpdateService 的 Oem.{{OemIdentifier}}.UpdateProgress.@odata.id 导航发现
| 属性名 | 类型 | 示例/取值约束 | readonly | 易变属性 | 实现PATCH | 操作权限 | 描述 |
|---|---|---|---|---|---|---|---|
| UpgradeTasks | array | 见下方UpgradeTask定义 | true | 是 | / | ReadOnly | 固件升级任务列表 |
| TaskName | string | “CPLD Upgrade Task” | true | 否 | / | ReadOnly | 升级任务名称 |
| Percentage | integer | 取值范围:[0, 100] | true | 是 | / | ReadOnly | 升级进度百分比 |
| TaskState | string | 枚举值:New、Starting、Running、Suspended、Completed、Cancelled、Exception | true | 是 | / | ReadOnly | 升级状态 |
| ErrorCode | string | “0” | true | 否 | / | ReadOnly | 升级任务错误码,"0"表示成功 |
| Component | string | “CPLD” | true | 否 | / | ReadOnly | 升级固件描述 |
| FileName | string | “CPLD.hpm” | true | 否 | / | ReadOnly | 升级包名称 |
| EstimatedRemainingTime | integer | 75(秒) | true | 是 | / | ReadOnly | 预计剩余时间(秒) |
| TaskId | string | “1” | true | 否 | / | ReadOnly | 升级任务标识 |
Schema定义:需新增独立的UpdateProgress Schema定义文件,包括索引文件和版本化定义文件
JSON Schema索引文件(updateprogress.json):
{
"$schema": "http://redfish.dmtf.org/schemas/v1/redfish-schema.v1_1_0.json",
"title": "#UpdateProgress.UpdateProgress",
"$ref": "#/definitions/UpdateProgress",
"definitions": {
"UpdateProgress": {
"anyOf": [
{
"$ref": "http://redfish.dmtf.org/schemas/v1/odata.4.0.0.json#/definitions/idRef"
},
{
"$ref": "/redfish/v1/SchemaStore/en/UpdateProgress.v1_0_0.json#/definitions/UpdateProgress"
}
],
"updatable": false,
"insertable": false,
"deletable": false,
"uris": [
"/redfish/v1/UpdateService/Oem/{{OemIdentifier}}/UpdateProgress"
]
}
},
"copyright": "Copyright (c) {{OemIdentifier}} Technologies Co., Ltd. 2026. All rights reserved."
}
JSON Schema版本化定义文件(updateprogress.v1_0_0.json):
{
"$schema": "http://redfish.dmtf.org/schemas/v1/redfish-schema.v1_1_0.json",
"title": "#UpdateProgress.v1_0_0.UpdateProgress",
"$ref": "#/definitions/UpdateProgress",
"definitions": {
"UpgradeTask": {
"type": "object",
"additionalProperties": false,
"properties": {
"TaskName": {
"description": "Upgrade task name",
"longDescription": "The name of the upgrade task",
"type": "string",
"readonly": true
},
"Percentage": {
"description": "Upgrade progress percentage",
"longDescription": "The percentage of completion of the upgrade task, from 0 to 100",
"type": "integer",
"minimum": 0,
"maximum": 100,
"readonly": true
},
"TaskState": {
"description": "Upgrade task state",
"longDescription": "The state of the upgrade task",
"type": "string",
"enum": ["New", "Starting", "Running", "Suspended", "Completed", "Cancelled", "Exception"],
"readonly": true
},
"ErrorCode": {
"description": "Upgrade task error code",
"longDescription": "The error code of the upgrade task. '0' indicates success",
"type": "string",
"readonly": true
},
"Component": {
"description": "Upgrade firmware description",
"longDescription": "The description of the firmware being upgraded",
"type": "string",
"readonly": true
},
"FileName": {
"description": "Upgrade package name",
"longDescription": "The name of the upgrade package file",
"type": "string",
"readonly": true
},
"EstimatedRemainingTime": {
"description": "Estimated remaining time in seconds",
"longDescription": "The estimated remaining time for the upgrade task to complete, in seconds",
"type": "integer",
"readonly": true
},
"description": "Firmware activation mode",
"longDescription": "The activation mode required to apply the firmware update",
"type": "string",
"enum": ["NoAction", "ResetBMC", "PowerOff"],
"readonly": true
},
"TaskId": {
"description": "Upgrade task identifier",
"longDescription": "The unique identifier of the upgrade task",
"type": "string",
"readonly": true
},
},
"required": ["TaskName", "Percentage", "TaskState", "ErrorCode", "Component", "FileName", "TaskId"]
},
"UpdateProgress": {
"type": "object",
"additionalProperties": false,
"properties": {
"@odata.context": {
"$ref": "http://redfish.dmtf.org/schemas/v1/odata.4.0.0.json#/definitions/context"
},
"@odata.id": {
"$ref": "http://redfish.dmtf.org/schemas/v1/odata.4.0.0.json#/definitions/id"
},
"@odata.type": {
"$ref": "http://redfish.dmtf.org/schemas/v1/odata.4.0.0.json#/definitions/type"
},
"Id": {
"description": "Unique identifier",
"longDescription": "The unique identifier for this resource",
"type": "string",
"readonly": true
},
"Name": {
"description": "Resource name",
"longDescription": "The name of the resource",
"type": "string",
"readonly": true
},
"UpgradeTasks": {
"description": "Firmware upgrade task list",
"longDescription": "The list of firmware upgrade tasks and their progress",
"type": "array",
"items": {
"$ref": "#/definitions/UpgradeTask"
},
"readonly": true
}
},
"required": ["Id", "Name", "UpgradeTasks"]
}
},
"copyright": "Copyright (c) {{OemIdentifier}} Technologies Co., Ltd. 2026. All rights reserved."
}
响应示例:
{
"@odata.context": "/redfish/v1/$metadata#UpdateProgress.UpdateProgress",
"@odata.id": "/redfish/v1/UpdateService/Oem/{{OemIdentifier}}/UpdateProgress",
"@odata.type": "#UpdateProgress.v1_0_0.UpdateProgress",
"Id": "UpdateProgress",
"Name": "UpdateService UpdateProgress",
"UpgradeTasks": [
{
"TaskName": "CPLD Upgrade Task",
"Percentage": 5,
"TaskState": "Running",
"ErrorCode": "0",
"Component": "CPLD",
"FileName": "CPLD.hpm",
"EstimatedRemainingTime": 75,
"TaskId": "1"
}
]
}
父资源导航:需在 /redfish/v1/UpdateService 的 GET 响应体 Oem.{{OemIdentifier}} 中新增导航链接:
"UpdateProgress": {
"@odata.id": "/redfish/v1/UpdateService/Oem/{{OemIdentifier}}/UpdateProgress"
}
是否准备好AI预审
是
评审结论
遗留问题
无