跳到主要内容

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
500InternalError

示例

返回以下示例 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"
}