GET – 服务器网络接口
使用 GET 方法检索 Redfish 服务的网络接口中的属性。
请求 URL
GET https://<BMC_IPADDR>/redfish/v1/Systems/1/NetworkInterfaces/{1-N}
请求正文
无
响应正文
响应是包含以下参数的 JSON 对象:
| 字段 | 类型 | 描述 | |||
|---|---|---|---|---|---|
| Id | 字符串 | 索引 | |||
| Description | 字符串 | “A NetworkInterface contains references linking NetworkAdapter, NetworkPort, and NetworkDeviceFunction resources and represents the functionality available to the containing system.” | |||
| Name | 字符串 | 网络接口 X(X=1-N) | |||
| Status | 对象 | 展开 | |||
| State | 字符串 | Enabled | |||
| Health | 字符串 | OK | |||
| Links | 对象 | 展开 | |||
| NetworkAdapter | 链接 | 相关 NetworkAdapter 的链接。 | |||
| NetworkPorts | 链接 | 相关 NetworkPortCollection 的链接。 | |||
| NetworkDeviceFunctions | 链接 | 相关 NetworkDeviceFunctionCollection 的链接。 | |||
状态代码
| HTTP 状态代码 | 错误消息 ID |
|---|---|
| 500 | InternalError |
示例
返回以下示例 JSON 响应:
{
"@odata.context" : "/redfish/v1/$metadata#NetworkInterface.NetworkInterface",
"Id" : "1",
"Status" : {
"Health" : "OK",
"State" : "Enabled"
},
"NetworkPorts" : {
"@odata.id" : "/redfish/v1/Chassis/1/NetworkAdapters/ob-1/NetworkPorts"
},
"Links" : {
"NetworkAdapter" : {
"@odata.id" : "/redfish/v1/Chassis/1/NetworkAdapters/ob-1"
}
},
"NetworkDeviceFunctions" : {
"@odata.id" : "/redfish/v1/Chassis/1/NetworkAdapters/ob-1/NetworkDeviceFunctions"
},
"@odata.etag" : "\"dc20bec25dc27d97279c8bada95185d6\"",
"@odata.id" : "/redfish/v1/Systems/1/NetworkInterfaces/1",
"@odata.type" : "#NetworkInterface.v1_1_1.NetworkInterface",
"Description" : "A NetworkInterface contains references linking NetworkAdapter, NetworkPort, and
NetworkDeviceFunction resources and represents the functionality available to the
containing system.",
"Name" : "Network Interface 1"
}
提供反馈