Module: check_mk
Branch: master
Commit: 85ad58757d3e10734bb738712e373e1aa3c825e3
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=85ad58757d3e10…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Tue Apr 19 11:22:43 2016 +0200
3386 FIX AIX agent: Cached local scripts / plugins need to be configured in seconds
When using cached executin of local scripts or agent plugins (putting scripts
in subdirectories named like the execution interval) with the AIX agent, the
directory names were interpreted as minutes which was not consistent with the
other agents.
This has now been changed to be consistently interpreted as seconds. You will
have to rename your directories to the current name multiplied with 60 to
execute the plugins again in the expected interval.
---
.werks/3386 | 16 ++++++++++++++++
ChangeLog | 2 ++
agents/check_mk_agent.aix | 4 +++-
3 files changed, 21 insertions(+), 1 deletion(-)
diff --git a/.werks/3386 b/.werks/3386
new file mode 100644
index 0000000..46fa75d
--- /dev/null
+++ b/.werks/3386
@@ -0,0 +1,16 @@
+Title: AIX agent: Cached local scripts / plugins need to be configured in seconds
+Level: 2
+Component: checks
+Compatible: incomp
+Version: 1.2.9i1
+Date: 1461057535
+Class: fix
+
+When using cached executin of local scripts or agent plugins (putting scripts
+in subdirectories named like the execution interval) with the AIX agent, the
+directory names were interpreted as minutes which was not consistent with the
+other agents.
+
+This has now been changed to be consistently interpreted as seconds. You will
+have to rename your directories to the current name multiplied with 60 to
+execute the plugins again in the expected interval.
diff --git a/ChangeLog b/ChangeLog
index 3dcd5bb..bd461ca 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -159,6 +159,8 @@
* 3399 FIX: statgrab_mem, hr_mem: Fix display of total installed memory in graph
* 3384 FIX: eltek_battery: Fixed broken check due to wrong spelled include file
* 3400 FIX: local: do not crash in P mode if performance data contains a unit of
measurement
+ * 3386 FIX: AIX agent: Cached local scripts / plugins need to be configured in
seconds...
+ NOTE: Please refer to the migration notes!
Multisite:
* 3187 notification view: new filter for log command via regex
diff --git a/agents/check_mk_agent.aix b/agents/check_mk_agent.aix
index db5e022..6dd5136 100755
--- a/agents/check_mk_agent.aix
+++ b/agents/check_mk_agent.aix
@@ -91,10 +91,12 @@ function waitmax
function run_cached {
NAME=$1
+ # Be aware: Maxage was expected to be given in minutes but this was
+ # confusing because all other agents use seconds here. So this has
+ # been changed to be compatible.
MAXAGE=$2
shift 2
CMDLINE=$*
- MAXAGE=$MAXAGE*60
if [ ! -e $MK_VARDIR/cache ] ; then mkdir -p $MK_VARDIR/cache ; fi
CACHE_FILE=$MK_VARDIR/cache/$NAME.cache