Skip to content

Add new fields to metric_desc map for tool-mlxreg#186

Merged
HughNhan merged 1 commit into
masterfrom
cdm-hnhan-dev
May 18, 2026
Merged

Add new fields to metric_desc map for tool-mlxreg#186
HughNhan merged 1 commit into
masterfrom
cdm-hnhan-dev

Conversation

@HughNhan
Copy link
Copy Markdown
Contributor

Synopsis: Add "device" , "sensor_index", and "sensor_name" fields.

Test:

[root@dhcp-10-26-9-237 ~]# crucible get metric --source mlxreg --type power-watts --period 3DDD384E-4CBF-11F1-8193-FECD10CC4134 --breakout hostname,metric
*** NOTICE: Crucible is at least 1 commits behind.  See 'crucible repo info' for details. ***

Checking for httpd...appears to be running
Checking for OpenSearch...appears to be running
Resolving cdmq dependencies...
up to date in 697ms

Metric data retrieved from API server: http://localhost:3000/api/v1/metric-data

Available breakouts:  benchmark-name,benchmark-role,csid,cstype,device,endpoint-label,engine-id,engine-role,engine-type,hosted-by,osruntime,sensor_index,sensor_name,tool-name,userenv                                                                                                                                     

                                                                         10-05-2026
 source        type                                 hostname      metric   22:04:56
-----------------------------------------------------------------------------------
 mlxreg power-watts nvd-srv-22.nvidia.eng.rdu2.dc.redhat.com total-power     124.00
 mlxreg power-watts nvd-srv-22.nvidia.eng.rdu2.dc.redhat.com   vr0-power      17.03
 mlxreg power-watts nvd-srv-22.nvidia.eng.rdu2.dc.redhat.com   vr1-power      28.00
 mlxreg power-watts nvd-srv-23.nvidia.eng.rdu2.dc.redhat.com total-power     124.00
 mlxreg power-watts nvd-srv-23.nvidia.eng.rdu2.dc.redhat.com   vr0-power      18.00

@HughNhan
Copy link
Copy Markdown
Contributor Author

@atheurer - Please give a look when you have a chance. Thanks

Comment thread queries/cdmq/cdm.js
Comment thread queries/cdmq/cdm.js
@atheurer
Copy link
Copy Markdown
Contributor

atheurer commented May 18, 2026

adding new mappings to existing indices:

curl -k -u elastic:changeme -X PUT http://localhost:9200/cdm-v9dev-metric_desc@2026.05/_mapping \
  -H 'Content-Type: application/json' \
  -d '{
    "properties": {
      "metric_desc": {
        "properties": {
          "names": {
            "properties": {
              "device": { "type": "keyword" },
              "sensor_index": { "type": "keyword" },
              "sensor_name": { "type": "keyword" }
            }
          }
        }
      }
    }
  }'

@HughNhan HughNhan merged commit 64b2969 into master May 18, 2026
35 checks passed
@github-project-automation github-project-automation Bot moved this from In Progress to Done in Crucible Tracking May 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

3 participants