Module: check_mk
Branch: master
Commit: 8b40c176d4443e2738f6aabe2597e58e777777cf
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=8b40c176d4443e…
Author: Andreas Boesl <ab(a)mathias-kettner.de>
Date: Fri Nov 13 16:02:48 2015 +0100
#2790 FIX check_dns: now able to configure milliseconds as expected response time
The response time was already configurable in milliseconds through WATO.
However, during the command line generation the decimal places got discarded.
---
.werks/2790 | 11 +++++++++++
ChangeLog | 1 +
checks/check_dns | 5 +++--
3 files changed, 15 insertions(+), 2 deletions(-)
diff --git a/.werks/2790 b/.werks/2790
new file mode 100644
index 0000000..c42ab51
--- /dev/null
+++ b/.werks/2790
@@ -0,0 +1,11 @@
+Title: check_dns: now able to configure milliseconds as expected response time
+Level: 1
+Component: checks
+Compatible: compat
+Version: 1.2.7i4
+Date: 1447426874
+Class: fix
+
+The response time was already configurable in milliseconds through WATO.
+However, during the command line generation the decimal places got discarded.
+
diff --git a/ChangeLog b/ChangeLog
index 2b7786e..648b39a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -80,6 +80,7 @@
* 2776 FIX: apache_status: fix crash for Apache versions with yet unhandled status
fields
* 2836 FIX: pandacom_psu: fixed handling of not available power supplies
* 2766 FIX: juniper_fru: Don't discover devices reported as "empty"...
+ * 2790 FIX: check_dns: now able to configure milliseconds as expected response
time...
Multisite:
* 2684 Added icons for downloading agent data / walks of hosts...
diff --git a/checks/check_dns b/checks/check_dns
index 8ea2887..1494358 100644
--- a/checks/check_dns
+++ b/checks/check_dns
@@ -46,8 +46,9 @@ def check_dns_arguments(params):
args += ' -A'
if "response_time" in settings:
- args += ' -w %d' % int(settings["response_time"][0])
- args += ' -c %d' % int(settings["response_time"][1])
+ args += ' -w %f' % float(settings["response_time"][0])
+ args += ' -c %f' % float(settings["response_time"][1])
+
if "timeout" in settings:
args += ' -t %d' % int(settings['timeout'])