reference: https://github.com/Percona-Lab/pmm-custom-queries/blob/master/mysql/innodb-index-stats.yml
only get mysql_innodb_index_stats_leaf_pages_size_bytes metrics and can’t get mysql_innodb_index_stats_size_bytes metrics.
when i change the first mysql_innodb_index_stats name to another,such as mysql_innodb_index_stats1, it’s ok.
the prefix mysql_innodb_index_stats cannot be the same?
pmm-admin version:
ProjectName: pmm-admin
Version: 2.12.0
PMMVersion: 2.12.0
Timestamp: 2020-12-01 11:57:04 (UTC)
FullCommit: e81fe912b1029095f310945f831abc71c824e139
mysql_innodb_index_stats:
query: “select database_name as schema_name,table_name,index_name,stat_value*@@innodb_page_size as size_bytes from mysql.innodb_index_stats where stat_name=‘size’;”
metrics:
- table_name:
usage: “LABEL”
description: “Table name”
- size_bytes:
usage: “GAUGE”
description: “Index Size in Bytes”
- schema_name:
usage: “LABEL”
description: “Schema Name”
- index_name:
usage: “LABEL”
description: “Index name”
mysql_innodb_index_stats:
query: “select database_name as schema_name,table_name,index_name,stat_value*@@innodb_page_size as leaf_pages_size_bytes from mysql.innodb_index_stats where stat_name=‘n_leaf_pages’;”
metrics:
- table_name:
usage: “LABEL”
description: “Table name”
- leaf_pages_size_bytes:
usage: “GAUGE”
description: “Leaf Pages Size in Bytes”
- schema_name:
usage: “LABEL”
description: “Schema Name”
- index_name:
usage: “LABEL”
description: “Index name”