-
Notifications
You must be signed in to change notification settings - Fork 19
Plugin loads successfully, but no metrics available #32
Comments
Hi @dgarth This plugin collects only per cgroup metrics. Do you have any cgroups in the system? If not, then, for testing, you may start some docker container, reload perfevents plugin and check if metrics become available. |
Hi @andrzej-k,
It seems that there is a problem in conjunction with the libvirt naming scheme for cgroups. |
hello @dgarth, I verified what happens and this error message:
that you received came from Snap's framework (see here; this error message was denifed in line 78). However, this checking was removed in snap/commit/e182c1cf and you should not receive this error any more for Snap in version 0.17 or higher. @dgarth, there were many changes since version: v0.16.1-beta. I highly recommend using the latest release Snap 1.0 for which this issue does not occur. What is more, I prepared the pull request #39 to remove the fragment of code which is no longer needed to make this plugin more aligned with the latest Snap. Also, your case has been added in medium tests to be sure that it works as expected. It was already merged, so you can just download the latest perfevents collector (ver9) |
Thanks @IzabellaRaulin, I can confirm that this bug does not occur in Snap 1.0. |
@dgarth, yes, this plugin discovers cgroups during loading and based on that exposes appropriate metrics - this the way how it works currently what causes that you need to create cgroups before loading the plugin. I cannot agree more that perfevents metrics should be exposed as dynamic metrics what means there is no cgroup discovery and metrics' namespaces contain a wildcard for a varied element. Therefore, even if some cgroups just appear (not matter when), metrics from them will be available and might be collected. I do not know how well acquainted you are with the concept of a dynamic metric in Snap, but https://github.com/intelsdi-x/snap-plugin-collector-docker is a good example of using it - docker container ID is defined as a dynamic element, so that allows monitoring all available docker containers existing on system, not only this one which was available before loading the plugin. This enhancement is addressed by issue #38 - I will put your comment also there to highlight how important is exposing dynamic metrics for this plugin. @dgarth, are you ok with closing this issue based on adding dynamic metrics is taken into account in #38? |
Thanks. |
Environment:
Perf list outputs
I started snap via:
And then in another session:
But after this
snapctl metric list
outputs no metrics related to this plugin:The text was updated successfully, but these errors were encountered: