Module: check_mk
Branch: master
Commit: a3e17cf9e4c9b1a717854ca20644d4a286ec7182
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=a3e17cf9e4c9b1…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Thu Nov 4 16:13:15 2010 +0100
heartbeat_nodes: fix Linux agent for hostnames with upper case letters
---
ChangeLog | 2 ++
agents/check_mk_agent.linux | 2 +-
2 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index 107cbcb..24ae6b6 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -26,6 +26,8 @@
power-state of IBM Bladecenter blades
* win_dhcp_pools: Several cleanups in check
* heartbeat_rscstatus: Catching empty output from agent correctly
+ * heartbeat_nodes: fix Linux agent for hostname with upper case letters (thanks to
+ Thorsten Robers)
Multisite:
* The custom open/close states of custom links are now stored for each
diff --git a/agents/check_mk_agent.linux b/agents/check_mk_agent.linux
index c3c2f14..ebcf520 100755
--- a/agents/check_mk_agent.linux
+++ b/agents/check_mk_agent.linux
@@ -287,7 +287,7 @@ if which cl_status > /dev/null 2>&1; then
echo '<<<heartbeat_nodes>>>'
for NODE in $(cl_status listnodes); do
- if [ $NODE != $HOSTNAME ]; then
+ if [ $NODE != $(echo $HOSTNAME | tr 'A-Z' 'a-z') ]; then
STATUS=$(cl_status nodestatus $NODE)
echo -n "$NODE $STATUS"
for LINK in $(cl_status listhblinks $NODE 2>/dev/null); do