Skip to content

how to return multiple values? Error creating exporter: value_label must be defined for metric with multiple values #458

Closed Answered by burningalchemist
castlesnow asked this question in Q&A
Discussion options

You must be logged in to vote

Hey @castlesnow,

as suggested in the error, you'd need to define a value_label parameter like in the example below:

  #
  # Collected from sys.dm_os_sys_memory
  #
  - metric_name: mssql_os_memory
    type: gauge
    help: 'OS physical memory, used and available.'
    value_label: 'state'
    values: [used, available]
    query: |
      SELECT
        (total_physical_memory_kb - available_physical_memory_kb) * 1024 AS used,
        available_physical_memory_kb * 1024 AS available
      FROM sys.dm_os_sys_memory

  - metric_name: mssql_os_page_file
    type: gauge
    help: 'OS page file, used and available.'
    value_label: 'state'
    values: [used, available]
    query: |
      SELECT
…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by burningalchemist
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants