Closed m0dular closed 1 year ago
Does it show anything if you run a test from the cli?
export INFLUX_TOKEN=<token>
telegraf --test --debug --config /etc/telegraf/telegraf.conf --config /etc/telegraf/telegraf.d/pcp_metrics.conf
There should be a measurement for mbean=default:name\=puppetlabs.pcp.connections
in the output.
Today I tested it in an environment with just a primary. telegraf outputs the metrics but grafana doesn't display anyhting. It is possible that the panel only displays data from compilers, not from primaries? I will test that tomorrow.
I did some testing as well, and for some reason the field is named puppetlabs.pcp.connections
and not default:name\=puppetlabs.pcp.connections
. I have no idea why that is, because the name returned by the metrics api is default:name=puppetlabs.pcp.connections
, which is also what shows up in the manual telegraf
test. I swear this worked for me before, but in my latest tests the field is indeed named puppetlabs.pcp.connections
in Influx, so that's what we need in the Grafana panel. I'll push an update.
I just confirmed this works in my test environment with a single primary,thanks alot! will test in another env with compilers as well.
@m0dular works fine for me even in bigger setups. Can you merge and release it?
@bastelfreak or @MartyEwings could you approve the PR for posterity?
ah sure, sorry that I forgot it!
@m0dular I see the "PCP Connections" panel, but it doesn't show data in my test environment. I will dig around a bit.