commit | 1da1ff5fc9d51096bd8cc6c6693d5a41629d861b | [log] [tgz] |
---|---|---|
author | Myung Bae <myungbae@us.ibm.com> | Tue Aug 20 11:34:59 2024 -0500 |
committer | George Liu <liuxiwei@ieisystem.com> | Sat May 24 03:05:00 2025 +0000 |
tree | 68224ae664fe19acd7758dee47bf608a2b5be045 | |
parent | 6b90272cda54bfb04a59062ce8bf20e89d244855 [diff] |
Implement LocationIndicatorActive for Fan Implement LocationIndicatorActive for Fan schema to set and get the status of the location LED for each Fan.[1] A client uses the `LocationIndicatorActive` property to physically identify or locate the processor. Uses the utility functions getLocationIndicatorActive() and setLocationIndicatorActive() to follow the association and get or set the LED value. [1] https://redfish.dmtf.org/schemas/v1/Fan.v1_5_2.json Tested: - Validator passes - Tested on p10bmc hardware simulator: 1. Get LocationIndicatorActive ``` curl -k -H "X-Auth-Token: $token" -X GET https://${bmc}/redfish/v1/Chassis/chassis/ThermalSubsystem/Fans/fan1 { "@odata.id": "/redfish/v1/Chassis/chassis/ThermalSubsystem/Fans/fan1", "@odata.type": "#Fan.v1_3_0.Fan", "Id": "fan1", ... "LocationIndicatorActive": false, ... } ``` 2. Set LocationIndicatorActive to true ``` curl -k -H "X-Auth-Token: $token" -H "Content-Type: application/json" -X PATCH -d '{"LocationIndicatorActive":true}' https://${bmc}/redfish/v1/Chassis/chassis/ThermalSubsystem/Fans/fan1 curl -k -H "X-Auth-Token: $token" -X GET https://${bmc}/redfish/v1/Chassis/chassis/ThermalSubsystem/Fans/fan1 { "@odata.id": "/redfish/v1/Chassis/chassis/ThermalSubsystem/Fans/fan1", "@odata.type": "#Fan.v1_3_0.Fan", "Id": "fan1", ... "LocationIndicatorActive": true, ... } ``` 3. Set LocationIndicatorActive to false ``` curl -k -H "X-Auth-Token: $token" -H "Content-Type: application/json" -X PATCH -d '{"LocationIndicatorActive":false}' https://${bmc}/redfish/v1/Chassis/chassis/ThermalSubsystem/Fans/fan1 curl -k -H "X-Auth-Token: $token" -X GET https://${bmc}/redfish/v1/Chassis/chassis/ThermalSubsystem/Fans/fan1 { "@odata.id": "/redfish/v1/Chassis/chassis/ThermalSubsystem/Fans/fan1", "@odata.type": "#Fan.v1_3_0.Fan", "Id": "fan1", ... "LocationIndicatorActive": false, ... } ``` 4. Error returned when trying to set the value to non-boolean ``` curl -k -H "X-Auth-Token: $token" -H "Content-Type: application/json" -X PATCH -d '{"LocationIndicatorActive":"badValue"}' https://${bmc}/redfish/v1/Chassis/chassis/ThermalSubsystem/Fans/fan1 { "LocationIndicatorActive@Message.ExtendedInfo": [ { "@odata.type": "#Message.v1_1_1.Message", "Message": "The value '\"badValue\"' for the property LocationIndicatorActive is not a type that the property can accept.", "MessageArgs": [ "\"badValue\"", "LocationIndicatorActive" ], "MessageId": "Base.1.19.PropertyValueTypeError", "MessageSeverity": "Warning", "Resolution": "Correct the value for the property in the request body and resubmit the request if the operation failed." } ] } ``` 5. Error returned when specifying an unknown Fan resource ``` curl -k -H "X-Auth-Token: $token" -X GET https://${bmc}/redfish/v1/Chassis/chassis/ThermalSubsystem/Fans/fan15 { "error": { "@Message.ExtendedInfo": [ { "@odata.type": "#Message.v1_1_1.Message", "Message": "The requested resource of type Fan named 'fan15' was not found.", "MessageArgs": [ "Fan", "fan15" ], "MessageId": "Base.1.19.ResourceNotFound", "MessageSeverity": "Critical", "Resolution": "Provide a valid resource identifier and resubmit the request." } ], "code": "Base.1.19.ResourceNotFound", "message": "The requested resource of type Fan named 'fan15' was not found." } } curl -k -H "X-Auth-Token: $token" -H "Content-Type: application/json" -X PATCH -d '{"LocationIndicatorActive":true}' https://${bmc}/redfish/v1/Chassis/chassis/ThermalSubsystem/Fans/fan15 { "error": { "@Message.ExtendedInfo": [ { "@odata.type": "#Message.v1_1_1.Message", "Message": "The requested resource of type Fan named 'fan15' was not found.", "MessageArgs": [ "Fan", "fan15" ], "MessageId": "Base.1.19.ResourceNotFound", "MessageSeverity": "Critical", "Resolution": "Provide a valid resource identifier and resubmit the request." } ], "code": "Base.1.19.ResourceNotFound", "message": "The requested resource of type Fan named 'fan15' was not found." } } ``` Signed-off-by: Albert Zhang <zhanghaodi@inspur.com> Signed-off-by: Lakshmi Yadlapati <lakshmiy@us.ibm.com> Signed-off-by: Myung Bae <myungbae@us.ibm.com> Signed-off-by: Janet Adkins <janeta@us.ibm.com> Change-Id: Ibc0da1714120b03c9a06241be1f721561b4d0d8b
This component attempts to be a "do everything" embedded webserver for OpenBMC.
The webserver implements a few distinct interfaces:
bmcweb at a protocol level supports http and https. TLS is supported through OpenSSL.
Bmcweb supports multiple authentication protocols:
Each of these types of authentication is able to be enabled or disabled both via runtime policy changes (through the relevant Redfish APIs) or via configure time options. All authentication mechanisms supporting username/password are routed to libpam, to allow for customization in authentication implementations.
All authorization in bmcweb is determined at routing time, and per route, and conform to the Redfish PrivilegeRegistry.
*Note: Non-Redfish functions are mapped to the closest equivalent Redfish privilege level.
bmcweb is configured per the meson build files. Available options are documented in meson_options.txt
meson setup builddir ninja -C builddir
If any of the dependencies are not found on the host system during configuration, meson will automatically download them via its wrap dependencies mentioned in bmcweb/subprojects
.
bmcweb relies on some on-system data for storage of persistent data that is internal to the process. Details on the exact data stored and when it is read/written can seen from the persistent_data
namespace.
When SSL support is enabled and a usable certificate is not found, bmcweb will generate a self-signed a certificate before launching the server. Please see the bmcweb source code for details on the parameters this certificate is built with.
bmcweb is capable of aggregating resources from satellite BMCs. Refer to AGGREGATION.md for more information on how to enable and use this feature.