Closed ilanni2460 closed 8 months ago
Can you provide the output from the following two commands?
curl -k https://192.168.47.103/redfish/v1/Systems/1/Storages
curl -k https://192.168.47.103/redfish/v1/Chassis/1
@mrlhansen
Thank you very much for your reply. The following is the result returned after I executed it.
curl -k https://192.168.47.103/redfish/v1/Systems/1/Storages |jq . { "error": "invalid System Name (Storages)", "code": 1453 }
curl -k https://192.168.47.103/redfish/v1/Chassis/1
{
"@odata.type": "#Chassis.v1_10_0.Chassis",
"Id": "1",
"Name": "Computer System Chassis",
"ChassisType": "RackMount",
"AssetTag": "XXXXX",
"Manufacturer": "Inspur",
"Model": "NF5270M6",
"SerialNumber": "XXXXX",
"PartNumber": "0",
"PowerState": "On",
"IndicatorLED": "Off",
"Status": {
"State": "Enabled",
"Health": "OK"
},
"Thermal": {
"@odata.id": "/redfish/v1/Chassis/1/Thermal"
},
"Power": {
"@odata.id": "/redfish/v1/Chassis/1/Power"
},
"NetworkAdapters": {
"@odata.id": "/redfish/v1/Chassis/1/NetworkAdapters"
},
"Oem": {
"Public": {
"DeviceMaxNum": {
"MemoryNum": 64,
"PCIeNum": 48,
"CPUNum": 2,
"DiskNum": 0,
"PowerSupplyNum": 2,
"FanNum": 6
},
"Mainboard": {
"BoardName": "XXXXX",
"SerialNumber": "XXXXXX",
"Manufacturer": "Inspur"
},
"ThresholdSensors": {
"@odata.id": "/redfish/v1/Chassis/1/ThresholdSensors"
},
"DiscreteSensors": {
"@odata.id": "/redfish/v1/Chassis/1/DiscreteSensors"
},
"Boards": {
"@odata.id": "/redfish/v1/Chassis/1/Boards"
}
}
},
"Links": {
"ComputerSystems": [
{
"@odata.id": "/redfish/v1/Systems/1"
}
],
"ManagedBy": [
{
"@odata.id": "/redfish/v1/Managers/1"
}
],
"Drives": [
{
"@odata.id": "/redfish/v1/Chassis/1/Drives/FP00HDD00"
},
{
"@odata.id": "/redfish/v1/Chassis/1/Drives/FP00HDD01"
},
{
"@odata.id": "/redfish/v1/Chassis/1/Drives/FP00HDD02"
},
{
"@odata.id": "/redfish/v1/Chassis/1/Drives/FP00HDD03"
},
{
"@odata.id": "/redfish/v1/Chassis/1/Drives/FP01HDD04"
},
{
"@odata.id": "/redfish/v1/Chassis/1/Drives/FP01HDD05"
}
]
},
"@odata.context": "/redfish/v1/$metadata#Chassis.Chassis",
"@odata.id": "/redfish/v1/Chassis/1",
"PCIeDevices": {
"@odata.id": "/redfish/v1/Chassis/1/PCIeDevices"
},
"Actions": {
"Oem": {
"Public": {
"#Chassis.UID": {
"target": "/redfish/v1/Chassis/1/Actions/UID",
"@Redfish.ActionInfo": "/redfish/v1/Chassis/1/Actions/UIDActionInfo"
}
}
}
}
}
@mrlhansen
The prompt information given by redfish of Inspur server is problematic. The correct URL is:
/redfish/v1/Systems/1/Storage
curl -k https://192.168.47.103/redfish/v1/Systems/1/Storage |jq .
{
"@odata.type": "#StorageCollection.StorageCollection",
"Name": "Storage Collection",
"Members@odata.count": 1,
"Members": [
{
"@odata.id": "/redfish/v1/Systems/1/Storage/PCIE0_RAID"
}
],
"@odata.context": "/redfish/v1/$metadata#StorageCollection.StorageCollection",
"@odata.id": "/redfish/v1/Systems/1/Storage"
}
This pdf was sent to me by Inspur’s technical staff.: 浪潮信息英信服务器_Redfish用户手册_V1.31708325222461.pdf
curl -k https://192.168.47.103/redfish/v1/Systems/1/Storage/PCIE0_RAID |jq .
{
"@odata.type": "#Storage.v1_7_1.Storage",
"Id": "PCIE0_RAID",
"Name": "PCIE0_RAID",
"Description": "LSI Logic / Symbios Logic RAID controlller",
"Status": {
"State": "Enabled",
"Health": "OK",
"HealthRollup": "OK"
},
"Oem": {},
"Drives@odata.count": 6,
"Volumes": {
"@odata.id": "/redfish/v1/Systems/1/Storage/PCIE0_RAID/Volumes"
},
"@odata.context": "/redfish/v1/$metadata#Storage.Storage",
"@odata.id": "/redfish/v1/Systems/1/Storage/PCIE0_RAID",
"Links": {
"Enclosures": [
{
"@odata.id": "/redfish/v1/Chassis/1"
}
]
},
"StorageControllers@odata.count": 1,
"StorageControllers": [
{
"@odata.id": "/redfish/v1/Systems/1/Storage/PCIE0_RAID#/StorageControllers/0",
"Status": {
"State": "Enabled",
"Health": "OK"
},
"Manufacturer": "Adaptec",
"Model": "PM8222-SHBA (0 )",
"SerialNumber": "SAN921E60450A10",
"PartNumber": "CT18754",
"FirmwareVersion": "5.32",
"CacheSummary": {
"TotalCacheSizeMiB": 128
},
"Identifiers": [
{
"DurableNameFormat": null,
"DurableName": null
}
],
"SupportedRAIDTypes": [
"RAID0",
"RAID1",
"RAID5",
"RAID6",
"RAID10",
"RAID50",
"RAID60"
],
"Oem": {},
"@odata.type": "#Storage.v1_6_0.StorageController",
"MemberId": "0",
"Name": "PCIE0_RAID"
}
],
"Drives": [
{
"@odata.id": "/redfish/v1/Systems/1/Storage/PCIE0_RAID/Drives/Disk_CN0-1-0"
},
{
"@odata.id": "/redfish/v1/Systems/1/Storage/PCIE0_RAID/Drives/Disk_CN0-1-1"
},
{
"@odata.id": "/redfish/v1/Systems/1/Storage/PCIE0_RAID/Drives/Disk_CN0-1-2"
},
{
"@odata.id": "/redfish/v1/Systems/1/Storage/PCIE0_RAID/Drives/Disk_CN0-1-3"
},
{
"@odata.id": "/redfish/v1/Systems/1/Storage/PCIE0_RAID/Drives/Disk_CN1-1-4"
},
{
"@odata.id": "/redfish/v1/Systems/1/Storage/PCIE0_RAID/Drives/Disk_CN1-1-5"
}
]
}
Use this url to see the hard disk information:
curl -k https://192.168.47.103/redfish/v1/Systems/1/Storage/PCIE0_RAID/Drives/Disk_CN0-1-0 |jq .
{
"@odata.context": "/redfish/v1/$metadata#Drive.Drive",
"@odata.id": "/redfish/v1/Systems/1/Storage/PCIE0_RAID/Drives/Disk_CN0-1-0",
"@odata.type": "#Drive.v1_7_0.Drive",
"Id": "0",
"Name": "Disk0",
"Model": "ATA SAMSUNG MZ7LH480HAHQ-00005",
"Revision": "HXT7904Q",
"CapacityBytes": 480103981056,
"Protocol": "SATA",
"MediaType": "SSD",
"Manufacturer": "SAMSUNG",
"SerialNumber": "S45PNC0T828333",
"CapableSpeedGbs": 6,
"NegotiatedSpeedGbs": 0,
"Status": {
"State": "Enabled",
"Health": "OK"
},
"Oem": {
"Public": {
"temperature": 27,
"Slot": 0,
"RaidName": "PCIE0_RAID",
"VolumeName": "Logical Disk0"
}
},
"Links": {
"Volumes": [
{
"@odata.id": "/redfish/v1/Systems/1/Storage/PCIE0_RAID/Volumes/LogicalDisk0"
}
]
}
}
Here is what I get with -verbose:
2024-02-19T15:17:05.853 INFO Build information: version=unknown revision= 2024-02-19T15:17:05.853 INFO Server listening on 0.0.0.0:9348 2024-02-19T15:17:30.134 DEBUG Handling request from 127.0.0.1:9348 for host 192.168.47.103 2024-02-19T15:17:30.135 DEBUG Querying url "https://192.168.47.103/redfish/v1" 2024-02-19T15:17:31.775 DEBUG Querying url "https://192.168.47.103/redfish/v1/Systems" 2024-02-19T15:17:34.126 DEBUG Querying url "https://192.168.47.103/redfish/v1/Chassis" 2024-02-19T15:17:35.621 DEBUG Querying url "https://192.168.47.103/redfish/v1/Chassis/1" 2024-02-19T15:17:38.110 DEBUG Querying url "https://192.168.47.103/redfish/v1/Systems/1" 2024-02-19T15:17:40.788 DEBUG Collecting metrics for host 192.168.47.103 2024-02-19T15:17:40.788 DEBUG Querying url "https://192.168.47.103/redfish/v1/Systems/1" 2024-02-19T15:17:42.410 DEBUG Querying url "https://192.168.47.103/redfish/v1/Chassis/1/Thermal" 2024-02-19T15:17:43.874 DEBUG Querying url "https://192.168.47.103/redfish/v1/Chassis/1/Power" 2024-02-19T15:17:45.200 DEBUG Querying url "https://192.168.47.103/redfish/v1/Managers/iDRAC.Embedded.1/Logs/Sel" 2024-02-19T15:17:45.381 DEBUG Query to url "https://192.168.47.103/redfish/v1/Managers/iDRAC.Embedded.1/Logs/Sel" returned unexpected status code: 404 (404 Not Found) 2024-02-19T15:17:45.381 DEBUG Querying url "https://192.168.47.103/redfish/v1/Systems/1/Storages" 2024-02-19T15:17:45.574 DEBUG Query to url "https://192.168.47.103/redfish/v1/Systems/1/Storages" returned unexpected status code: 404 (404 Not Found) 2024-02-19T15:17:45.574 DEBUG Querying url "https://192.168.47.103/redfish/v1/Systems/1/Memory" 2024-02-19T15:17:46.795 DEBUG Querying url "https://192.168.47.103/redfish/v1/Systems/1/Memory/CPU0_C0D0" 2024-02-19T15:17:48.015 DEBUG Metrics for host 192.168.47.103 collected
Okay, this looks like a simple bug in their Redfish implementation, where the reported URL contains Storages instead of Storage.
I can probably implement a vendor specific fix for this, but it might take a few days before I have time to do it.
Okay, this looks like a simple bug in their Redfish implementation, where the reported URL contains Storages instead of Storage.
I can probably implement a vendor specific fix for this, but it might take a few days before I have time to do it.
Thank you very much for your reply, can you tell where in which file to modify? I'll test it first and then wait for you to submit the latest code.
avg_over_time(idrac_power_control_avg_consumed_watts{instance=~"$instance",job="$job"}[$__rate_interval]) or avg_over_time(idrac_power_control_consumed_watts{instance=~"$instance",job="$job"}[$__rate_interval])
I pushed some changes that should fix the issue with the "storage" metrics. Let me know if it works.
The SKU is simply not reported via Redfish, so there is nothing to do.
For the "power" metrics most of the relevant information is also not available (this also applies to the H3C server in the other issue). In Grafana for the "Power Consumption" panel you can probably change the query to the following instead, which will help in some cases.
avg_over_time(idrac_power_control_avg_consumed_watts{instance=~"$instance",job="$job"}[$__rate_interval]) or avg_over_time(idrac_power_control_consumed_watts{instance=~"$instance",job="$job"}[$__rate_interval])
Thank you very much for your timely reply and problem fix. I have tested the latest code today, and the Inspur server and H3C server can obtain hard drive related information normally.
However, the H3C server still cannot obtain power-related information.
The logs of the debug H3C server are as follows:
2024-02-21T10:03:32.830 DEBUG Querying url "https://192.168.70.125/redfish/v1/Chassis/1/Power" 2024-02-21T10:03:35.064 DEBUG Error decoding response from url "https://192.168.70.125/redfish/v1/Chassis/1/Power": json: cannot unmarshal string into Go struct field .Voltages.LowerThresholdFatal of type float64
Inspur server obtains SKU, Disk, power supply and other information
Server model: NF5270M6
Firmware information: 7.04.00
No sku, idrac_drive*, idrac_power_control_avg_consumed_watts
Get relevant information through redfish:
curl -k https://192.168.47.103/redfish/v1/Systems/1 |jq .