create telemetry metric report definition
Grobelny, Krzysztof
krzysztof.grobelny at linux.intel.com
Wed Jun 30 19:24:05 AEST 2021
Hello,
About your dbus call it should look like this:
busctl call xyz.openbmc_project.Telemetry
/xyz/openbmc_project/Telemetry/Reports
xyz.openbmc_project.Telemetry.ReportManager AddReport 'ssbbta(osss)'
'TelemetryService/ReportName' 'Periodic' true true 1000 1
'/xyz/openbmc_project/sensors/current/HSC_IOUT' 'SINGLE' 'MetricName'
'/redfish/v1/Chassis/Transformers_MotherBoard/Sensors/HSC_IOUT/Reading'
You are missing method signature 'ssbbta(osss)'
You are missing number of elements in array a(osss)
About your post request it works for me:
curl --user root:root --insecure --location --request POST
https://localhost:4443/redfish/v1/TelemetryService/MetricReportDefinitions
-d
'{"Id":"MyMetric","Metrics":[{"MetricId":"HSC_IOUT_reading","MetricProperties":["/redfish/v1/Chassis/Transformers_MotherBoard/Sensors/HSC_IOUT/Reading"]}],"MetricReportDefinitionType":"Periodic","ReportActions":["RedfishEvent","LogToMetricReportsCollection"],"Schedule":{"RecurrenceInterval":"PT1S"}}'
Are you sure your curl params are ok? Can you perform post with for
example invalid parameters to verify your request. You could change
RecurrenceInterval to something not recongnized or Id to contain invalid
characters like '@' and see if you get correct reponse from bmcweb.
BR, Krzysztof
On 2021-06-28 23:14, Mohammed.Habeeb ISV wrote:
> Hi
>
> How to create a telemetry metric report definition? I tried to set via dbus command as below, but got an error.
> busctl call xyz.openbmc_project.Telemetry /xyz/openbmc_project/Telemetry/Reports xyz.openbmc_project.Telemetry.ReportManager AddReport MyMetric Periodic 1 1 1000 "/xyz/openbmc_project/sensors/current/HSC_IOUT" "SINGLE" 1 "/redfish/v1/Chassis/Transformers_MotherBoard/Sensors/HSC_IOUT/Reading"
> Unknown signature type M.
>
> Tried to use redfish also, but got an internal service error. Please let me know if I miss anything here in both commands.
> habeeb at nsit-160:~/openbmc_nibu06$ curl -k -H "X-Auth-Token: $token" -X POST https://${bmc}/redfish/v1/TelemetryService/MetricReportDefinitions -d '{
> "Id":"MyMetric",
> "Metrics":[
> {
> "MetricId": "HSC_IOUT_reading",
> "MetricProperties":
> ["/redfish/v1/Chassis/Transformers_MotherBoard/Sensors/HSC_IOUT/Reading"]
> }
> ],
> "MetricReportDefinitionType": "Periodic",
> "ReportActions": ["RedfishEvent", "LogToMetricReportsCollection"],
> "Schedule": {
> "RecurrenceInterval": "PT1S"
> }
> }'
>
> {
> "error": {
> "@Message.ExtendedInfo": [
> {
> "@odata.type": "#Message.v1_1_1.Message",
> "Message": "The request failed due to an internal service error. The service is still operational.",
> "MessageArgs": [],
> "MessageId": "Base.1.8.1.InternalError",
> "MessageSeverity": "Critical",
> "Resolution": "Resubmit the request. If the problem persists, consider resetting the service."
> }
> ],
> "code": "Base.1.8.1.InternalError",
> "message": "The request failed due to an internal service error. The service is still operational."
> }
> }
> ---
> I see xyz.openbmc_project.Telemetry.ReportManager Interface is present.
> sysadmin at transformers:~# busctl tree --no-pager xyz.openbmc_project.Telemetry
> `-/xyz
> `-/xyz/openbmc_project
> `-/xyz/openbmc_project/Telemetry
> `-/xyz/openbmc_project/Telemetry/Reports
>
> Regards
> Habeeb
More information about the openbmc
mailing list