CMK version: Enterprise 2.1.0p38 OS version: Ubuntu 20.04
(the deployed mk_jolokia agent is also 2.1.0p38 / Java is v 17)
I am working with an inherited Check_MK installation. The mk_jolokia data for JVM GC PS MarkSweep shows a baseline metric of 200 - 500%. When a JVM goes into cycles of full GC, this metric rises to more than 4000%.
Leaving aside the fact that the absolute value is nonsense, the relative values do reflect the underlying health. However Check_MK does not allow me to set a threshold greater than 101%.
Yes i got the same.
As i understand code, it not a absolute value, but a rate.
i understand like that
Garbage collections: 0.01/s mean that it does 0.01 GC collector/s more than last period (60s)
Time spent collecting garbage: 2.12 % mean it increase time in GC of 2.12% comparing to last period.
It explain why it can higher than 100%
But i still cannot use it as the wato doesnāt allow more than 100%.
I end up by writing a custom plugin for Garbage Collector
Iāve spend a bit more time on it, and i was wrong in interpretation on code.
There a still a bug in checkMk, but itās a absolute value
what they do
they calculate a rate for connection_time, express in ms/sec and convert in percent by *10, what is wrong
250ms/sec should be 25%, not 2500% as it calculated now
iāve closed other pull request, and create a new one to fix this
to be able to fix on current version, iāve done a mkp with just the file modified in the path
local/share/check_mk/checks/jolokia_jvm_garbagecollectors
I had already tried changing this (I went with / 10 rather than * 0.1) and it seemed to have no impact at all on the metrics reported, neither in the status message nor in the RRD graphs.
Yes itās working, iāve to put in
local/share/check_mk/checks/jolokia_jvm_garbagecollectors
restart checkMk.
i use a distributed system, it wouldnāt activate by default on all site, iāve to force a activate on all site by editing a user as workaround
I had already tried the same thing (apart from using / 10.0 rather than * 0.10) hence my reason for asking, I suspect there may be something wrong with how I deployed this:
First attempt
created a backup of var/check_mk/precompiled_checks/builtin/jolokia_jvm_garbagecollectors in the same dir (jolokia_jvm_garbagecollectors-YYYYMMDD)
edited jolokia_jvm_garbagecollectors to change calculation
removed corresponding file in var/check_mk/precompiled_checks/builtin/
This had no impact - on checking, the āpre-compiledā code appears to have been generated rom the backup file rather tha new fileā¦
Second attempt
As above, but I placed the backup file in /root. However the outcome was the same.
Third attempt
I put a copy of the modified file in local/share/check_mk/checks/, deleted var/check_mk/precompiled_checks/builtin/
This seems to have worked. Is there canonical documentation on how this should be done?
you donāt need to delete the original in var/ā¦
What you put in local overirde the default checkmk one, it seem to work for quite all plugin i overrided (service now, python and gc_collector)
Otherwise, i mostly read the code for the documentation.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed. Contact an admin if you think this should be re-opened.