Skip to content

Commit

Permalink
Update Nagios check to work with ctdb versions past 30 Aug 2011
Browse files Browse the repository at this point in the history
Because of commit a779d83a6213e2ba

Signed-off-by: Martin Schwenke <[email protected]>

(This used to be ctdb commit a4afe7af9c9391048d6f80135bbd5e15367770c7)
  • Loading branch information
sathieu authored and amitay committed Jul 11, 2013
1 parent ca13f28 commit 27c2c61
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion ctdb/utils/nagios/check_ctdb
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,11 @@ if ($info eq "scriptstatus") {
next if $. == 1; # Header
$script_count++;
chop;
my ($type, $name, $code, $status, $start, $end, @error) = split(":");
my ($col0, $type, $name, $code, $status, $start, $end, @error) = split(":");
if ($col0 ne '') {
# Old version, before 30 Aug 2011 and commit a779d83a6213
($type, $name, $code, $status, $start, $end, @error) = ($col0, $type, $name, $code, $status, $start, $end, @error);
}
my $error = join(':', @error);
if ($error ne "") {
$output = "$output ;; " if $output;
Expand Down

0 comments on commit 27c2c61

Please sign in to comment.