[Pkg-nagios-changes] [pkg-icinga2] 01/01: Imported Upstream version 2.3.8
Markus Frosch
lazyfrosch at moszumanska.debian.org
Mon Jul 20 18:55:31 UTC 2015
This is an automated email from the git hooks/post-receive script.
lazyfrosch pushed a commit to branch upstream
in repository pkg-icinga2.
commit 8e56a74909c5c57d8d4f6ef17e1e684bf8094beb
Author: Markus Frosch <lazyfrosch at debian.org>
Date: Mon Jul 20 20:52:29 2015 +0200
Imported Upstream version 2.3.8
---
AUTHORS | 1 +
ChangeLog | 14 +++
RELEASE.md | 11 ++-
doc/1-about.md | 14 +++
icinga2.nuspec | 52 +++++------
icinga2.spec | 2 +-
itl/command-plugins-windows.conf | 2 +-
itl/command-plugins.conf | 2 +
lib/config/config_parser.yy | 2 +
lib/config/configtype.hpp | 180 +++++++++++++++++++--------------------
lib/db_ido/endpointdbobject.cpp | 22 -----
lib/db_ido/endpointdbobject.hpp | 3 -
lib/perfdata/opentsdbwriter.cpp | 17 ++--
plugins/check_ping.cpp | 4 +-
tools/chocolateyInstall.ps1 | 14 +--
15 files changed, 177 insertions(+), 163 deletions(-)
diff --git a/AUTHORS b/AUTHORS
index 93bf3a4..0cc3dee 100644
--- a/AUTHORS
+++ b/AUTHORS
@@ -27,6 +27,7 @@ Jan Andres <jan.andres at berenberg.de>
Jan Wagner <waja at cyconet.org>
Jason Young <jyoung15 at gmail.com>
Jean-Marcel Flach <jean-marcel.flach at netways.de>
+Jérôme Drouet <jerome.drouet at gmail.com>
Jesse Morgan <morgajel at gmail.com>
Johannes Meyer <johannes.meyer at netways.de>
Jonas Meurer <jonas at freesources.org>
diff --git a/ChangeLog b/ChangeLog
index fc1c00b..f1e8b12 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -4,6 +4,20 @@ Please check [doc/1-about.md].
## What's New
+### What's New in Version 2.3.8
+
+#### Changes
+
+* Bugfixes
+
+#### Bugfixes
+
+* Bug 9554: Don't allow "ignore where" for groups when there's no "assign where"
+* Bug 9634: DB IDO: Do not update endpointstatus table on config updates
+* Bug 9637: Wrong parameter for CheckCommand "ping-common-windows"
+* Bug 9665: Escaping does not work for OpenTSDB perfdata plugin
+* Bug 9666: checkcommand disk does not check free inode - check_disk
+
### What's New in Version 2.3.7
#### Changes
diff --git a/RELEASE.md b/RELEASE.md
index 222c1e1..903683b 100644
--- a/RELEASE.md
+++ b/RELEASE.md
@@ -62,8 +62,15 @@ Push the tag.
For major releases: Create a new "support" branch:
$ git checkout master
- $ git checkout -b support/2.x
- $ git push -u origin support/2.x
+ $ git checkout -b support/2.3
+ $ git push -u origin support/2.3
+
+For minor releases: Push the support branch and cherry-pick the release commit into master:
+
+ $ git push -u origin support/2.3
+ $ git checkout master
+ $ git cherry-pick support/2.3
+ $ git push origin master
# External Dependencies
diff --git a/doc/1-about.md b/doc/1-about.md
index cf77b35..6fd7ef8 100644
--- a/doc/1-about.md
+++ b/doc/1-about.md
@@ -54,6 +54,20 @@ More details in the [Icinga FAQ](https://www.icinga.org/icinga/faq/).
## <a id="whats-new"></a> What's New
+### What's New in Version 2.3.8
+
+#### Changes
+
+* Bugfixes
+
+#### Bugfixes
+
+* Bug [9554](https://dev.icinga.org/issues/9554 "Bug 9554"): Don't allow "ignore where" for groups when there's no "assign where"
+* Bug [9634](https://dev.icinga.org/issues/9634 "Bug 9634"): DB IDO: Do not update endpointstatus table on config updates
+* Bug [9637](https://dev.icinga.org/issues/9637 "Bug 9637"): Wrong parameter for CheckCommand "ping-common-windows"
+* Bug [9665](https://dev.icinga.org/issues/9665 "Bug 9665"): Escaping does not work for OpenTSDB perfdata plugin
+* Bug [9666](https://dev.icinga.org/issues/9666 "Bug 9666"): checkcommand disk does not check free inode - check_disk
+
### What's New in Version 2.3.7
#### Changes
diff --git a/icinga2.nuspec b/icinga2.nuspec
index b72e458..9ce1b9d 100755
--- a/icinga2.nuspec
+++ b/icinga2.nuspec
@@ -1,26 +1,26 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Do not remove this test for UTF-8: if ??? doesn?t appear as greek uppercase omega letter enclosed in quotation marks, you should use an editor that supports UTF-8, not this one. -->
-<!--package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd"-->
-<package xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
- <metadata>
- <!-- Read this before publishing packages to chocolatey.org: https://github.com/chocolatey/chocolatey/wiki/CreatePackages -->
- <id>icinga2</id>
- <title>Icinga2</title>
- <version>2.3.7</version>
- <authors>2015 - The Icinga Project</authors>
- <owners>Icinga Development Team</owners>
- <summary>icinga2 - Monitoring Agent for Windows</summary>
- <description>Icinga 2 is an open source monitoring platform which notifies users about host and service outages.</description>
- <projectUrl>http://www.icinga.org</projectUrl>
- <tags>icinga2 agent monitoring</tags>
- <licenseUrl>http://www.icinga.org/icinga/faq</licenseUrl>
- <requireLicenseAcceptance>false</requireLicenseAcceptance>
- <iconUrl>https://www.icinga.org/wp-content/uploads/2015/05/icinga_icon_128x128.png</iconUrl>
- <dependencies>
- <dependency id="DotNet3.5" />
- </dependencies>
- </metadata>
- <files>
- <file src="tools\chocolateyInstall.ps1" target="tools" />
- </files>
-</package>
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Do not remove this test for UTF-8: if ??? doesn?t appear as greek uppercase omega letter enclosed in quotation marks, you should use an editor that supports UTF-8, not this one. -->
+<!--package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd"-->
+<package xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
+ <metadata>
+ <!-- Read this before publishing packages to chocolatey.org: https://github.com/chocolatey/chocolatey/wiki/CreatePackages -->
+ <id>icinga2</id>
+ <title>Icinga2</title>
+ <version>2.3.8</version>
+ <authors>2015 - The Icinga Project</authors>
+ <owners>Icinga Development Team</owners>
+ <summary>icinga2 - Monitoring Agent for Windows</summary>
+ <description>Icinga 2 is an open source monitoring platform which notifies users about host and service outages.</description>
+ <projectUrl>http://www.icinga.org</projectUrl>
+ <tags>icinga2 agent monitoring</tags>
+ <licenseUrl>http://www.icinga.org/icinga/faq</licenseUrl>
+ <requireLicenseAcceptance>false</requireLicenseAcceptance>
+ <iconUrl>https://www.icinga.org/wp-content/uploads/2015/05/icinga_icon_128x128.png</iconUrl>
+ <dependencies>
+ <dependency id="DotNet3.5" />
+ </dependencies>
+ </metadata>
+ <files>
+ <file src="tools\chocolateyInstall.ps1" target="tools" />
+ </files>
+</package>
diff --git a/icinga2.spec b/icinga2.spec
index 4a40696..09782c8 100644
--- a/icinga2.spec
+++ b/icinga2.spec
@@ -66,7 +66,7 @@
Summary: Network monitoring application
Name: icinga2
-Version: 2.3.7
+Version: 2.3.8
Release: %{revision}%{?dist}
License: GPL-2.0+
Group: Applications/System
diff --git a/itl/command-plugins-windows.conf b/itl/command-plugins-windows.conf
index 055c453..be16fbf 100644
--- a/itl/command-plugins-windows.conf
+++ b/itl/command-plugins-windows.conf
@@ -156,7 +156,7 @@ template CheckCommand "ping-common-windows" {
value = "$ping_win_crta$,$ping_win_cpl$%"
description = "Warning threshold: RTA and package loss seperated by comma"
}
- "-n" = {
+ "-p" = {
value = "$ping_win_packets$"
description = "Number of packages to send"
}
diff --git a/itl/command-plugins.conf b/itl/command-plugins.conf
index 7f2e6a2..177612a 100644
--- a/itl/command-plugins.conf
+++ b/itl/command-plugins.conf
@@ -813,6 +813,8 @@ object CheckCommand "disk" {
vars.disk_wfree = "20%"
vars.disk_cfree = "10%"
+ vars.disk_inode_wfree = "20%"
+ vars.disk_inode_cfree = "10%"
vars.disk_megabytes = true
vars.disk_exclude_type = ["none", "tmpfs", "sysfs", "proc", "devtmpfs", "devfs", "mtmfs"]
}
diff --git a/lib/config/config_parser.yy b/lib/config/config_parser.yy
index 611dae1..80e06ec 100644
--- a/lib/config/config_parser.yy
+++ b/lib/config/config_parser.yy
@@ -498,6 +498,8 @@ object:
} else if (seen_ignore) {
if (!ObjectRule::IsValidSourceType(type))
BOOST_THROW_EXCEPTION(ScriptError("object rule 'ignore' cannot be used for type '" + type + "'", DebugInfoRange(@2, @4)));
+ else
+ BOOST_THROW_EXCEPTION(ScriptError("object rule 'ignore' is missing 'assign' for type '" + type + "'", DebugInfoRange(@2, @4)));
}
$$ = new ObjectExpression(abstract, type, $4, filter, context->GetZone(), $5, $6, DebugInfoRange(@2, @5));
diff --git a/lib/config/configtype.hpp b/lib/config/configtype.hpp
index d4a6356..264f622 100644
--- a/lib/config/configtype.hpp
+++ b/lib/config/configtype.hpp
@@ -1,90 +1,90 @@
-/******************************************************************************
- * Icinga 2 *
- * Copyright (C) 2012-2015 Icinga Development Team (http://www.icinga.org) *
- * *
- * This program is free software; you can redistribute it and/or *
- * modify it under the terms of the GNU General Public License *
- * as published by the Free Software Foundation; either version 2 *
- * of the License, or (at your option) any later version. *
- * *
- * This program is distributed in the hope that it will be useful, *
- * but WITHOUT ANY WARRANTY; without even the implied warranty of *
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
- * GNU General Public License for more details. *
- * *
- * You should have received a copy of the GNU General Public License *
- * along with this program; if not, write to the Free Software Foundation *
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. *
- ******************************************************************************/
-
-#ifndef CONFIGTYPE_H
-#define CONFIGTYPE_H
-
-#include "config/i2-config.hpp"
-#include "config/typerulelist.hpp"
-#include "config/typerule.hpp"
-#include "config/configitem.hpp"
-#include "base/array.hpp"
-#include "base/registry.hpp"
-
-namespace icinga
-{
-
-/**
- * A configuration type. Used to validate config objects.
- *
- * @ingroup config
- */
-class I2_CONFIG_API ConfigType : public Object {
-public:
- DECLARE_PTR_TYPEDEFS(ConfigType);
-
- ConfigType(const String& name, const DebugInfo& debuginfo);
-
- String GetName(void) const;
-
- String GetParent(void) const;
- void SetParent(const String& parent);
-
- TypeRuleList::Ptr GetRuleList(void) const;
-
- DebugInfo GetDebugInfo(void) const;
-
- void ValidateItem(const String& name, const Object::Ptr& object,
- const DebugInfo& debugInfo, const TypeRuleUtilities *utils);
-
- void Register(void);
- static ConfigType::Ptr GetByName(const String& name);
- static Registry<ConfigType, ConfigType::Ptr>::ItemMap GetTypes(void);
-
-private:
- String m_Name; /**< The type name. */
- String m_Parent; /**< The parent type. */
-
- TypeRuleList::Ptr m_RuleList;
- DebugInfo m_DebugInfo; /**< Debug information. */
-
- static void ValidateAttribute(const String& key, const Value& value,
- const std::vector<TypeRuleList::Ptr>& ruleLists, std::vector<String>& locations,
- const TypeRuleUtilities *utils);
- static void ValidateObject(const Object::Ptr& object,
- const std::vector<TypeRuleList::Ptr>& ruleLists, std::vector<String>& locations,
- const TypeRuleUtilities *utils);
- static void ValidateArray(const Array::Ptr& array,
- const std::vector<TypeRuleList::Ptr>& ruleLists, std::vector<String>& locations,
- const TypeRuleUtilities *utils);
-
- static String LocationToString(const std::vector<String>& locations);
-
- static void AddParentRules(std::vector<TypeRuleList::Ptr>& ruleLists, const ConfigType::Ptr& item);
-};
-
-class I2_CONFIG_API ConfigTypeRegistry : public Registry<ConfigTypeRegistry, ConfigType::Ptr>
-{
-public:
- static ConfigTypeRegistry *GetInstance(void);
-};
-
-}
-
-#endif /* CONFIGTYPE_H */
+/******************************************************************************
+ * Icinga 2 *
+ * Copyright (C) 2012-2015 Icinga Development Team (http://www.icinga.org) *
+ * *
+ * This program is free software; you can redistribute it and/or *
+ * modify it under the terms of the GNU General Public License *
+ * as published by the Free Software Foundation; either version 2 *
+ * of the License, or (at your option) any later version. *
+ * *
+ * This program is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
+ * GNU General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU General Public License *
+ * along with this program; if not, write to the Free Software Foundation *
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. *
+ ******************************************************************************/
+
+#ifndef CONFIGTYPE_H
+#define CONFIGTYPE_H
+
+#include "config/i2-config.hpp"
+#include "config/typerulelist.hpp"
+#include "config/typerule.hpp"
+#include "config/configitem.hpp"
+#include "base/array.hpp"
+#include "base/registry.hpp"
+
+namespace icinga
+{
+
+/**
+ * A configuration type. Used to validate config objects.
+ *
+ * @ingroup config
+ */
+class I2_CONFIG_API ConfigType : public Object {
+public:
+ DECLARE_PTR_TYPEDEFS(ConfigType);
+
+ ConfigType(const String& name, const DebugInfo& debuginfo);
+
+ String GetName(void) const;
+
+ String GetParent(void) const;
+ void SetParent(const String& parent);
+
+ TypeRuleList::Ptr GetRuleList(void) const;
+
+ DebugInfo GetDebugInfo(void) const;
+
+ void ValidateItem(const String& name, const Object::Ptr& object,
+ const DebugInfo& debugInfo, const TypeRuleUtilities *utils);
+
+ void Register(void);
+ static ConfigType::Ptr GetByName(const String& name);
+ static Registry<ConfigType, ConfigType::Ptr>::ItemMap GetTypes(void);
+
+private:
+ String m_Name; /**< The type name. */
+ String m_Parent; /**< The parent type. */
+
+ TypeRuleList::Ptr m_RuleList;
+ DebugInfo m_DebugInfo; /**< Debug information. */
+
+ static void ValidateAttribute(const String& key, const Value& value,
+ const std::vector<TypeRuleList::Ptr>& ruleLists, std::vector<String>& locations,
+ const TypeRuleUtilities *utils);
+ static void ValidateObject(const Object::Ptr& object,
+ const std::vector<TypeRuleList::Ptr>& ruleLists, std::vector<String>& locations,
+ const TypeRuleUtilities *utils);
+ static void ValidateArray(const Array::Ptr& array,
+ const std::vector<TypeRuleList::Ptr>& ruleLists, std::vector<String>& locations,
+ const TypeRuleUtilities *utils);
+
+ static String LocationToString(const std::vector<String>& locations);
+
+ static void AddParentRules(std::vector<TypeRuleList::Ptr>& ruleLists, const ConfigType::Ptr& item);
+};
+
+class I2_CONFIG_API ConfigTypeRegistry : public Registry<ConfigTypeRegistry, ConfigType::Ptr>
+{
+public:
+ static ConfigTypeRegistry *GetInstance(void);
+};
+
+}
+
+#endif /* CONFIGTYPE_H */
diff --git a/lib/db_ido/endpointdbobject.cpp b/lib/db_ido/endpointdbobject.cpp
index 504ba3f..db42f48 100644
--- a/lib/db_ido/endpointdbobject.cpp
+++ b/lib/db_ido/endpointdbobject.cpp
@@ -106,25 +106,3 @@ int EndpointDbObject::EndpointIsConnected(const Endpoint::Ptr& endpoint)
return is_connected;
}
-
-void EndpointDbObject::OnConfigUpdate(void)
-{
- /* update current status on config dump once */
- Endpoint::Ptr endpoint = static_pointer_cast<Endpoint>(GetObject());
-
- DbQuery query1;
- query1.Table = "endpointstatus";
- query1.Type = DbQueryInsert;
- query1.Category = DbCatConfig;
-
- Dictionary::Ptr fields1 = new Dictionary();
- fields1->Set("identity", endpoint->GetName());
- fields1->Set("node", IcingaApplication::GetInstance()->GetNodeName());
- fields1->Set("is_connected", EndpointIsConnected(endpoint));
- fields1->Set("status_update_time", DbValue::FromTimestamp(Utility::GetTime()));
- fields1->Set("endpoint_object_id", endpoint);
- fields1->Set("instance_id", 0); /* DbConnection class fills in real ID */
- query1.Fields = fields1;
-
- OnQuery(query1);
-}
diff --git a/lib/db_ido/endpointdbobject.hpp b/lib/db_ido/endpointdbobject.hpp
index febe64a..66f6555 100644
--- a/lib/db_ido/endpointdbobject.hpp
+++ b/lib/db_ido/endpointdbobject.hpp
@@ -44,9 +44,6 @@ public:
virtual Dictionary::Ptr GetConfigFields(void) const;
virtual Dictionary::Ptr GetStatusFields(void) const;
-protected:
- virtual void OnConfigUpdate(void);
-
private:
static void UpdateConnectedStatus(const Endpoint::Ptr& endpoint);
static int EndpointIsConnected(const Endpoint::Ptr& endpoint);
diff --git a/lib/perfdata/opentsdbwriter.cpp b/lib/perfdata/opentsdbwriter.cpp
index 20248af..9d450a9 100644
--- a/lib/perfdata/opentsdbwriter.cpp
+++ b/lib/perfdata/opentsdbwriter.cpp
@@ -106,16 +106,16 @@ void OpenTsdbWriter::CheckResultHandler(const Checkable::Ptr& checkable, const C
else
host = static_pointer_cast<Host>(checkable);
- String hostName = host->GetName();
-
String metric;
std::map<String, String> tags;
- tags["host"] = hostName;
+
+ String escaped_hostName = EscapeMetric(host->GetName());
+ tags["host"] = escaped_hostName;
if (service) {
String serviceName = service->GetShortName();
- EscapeMetric(serviceName);
- metric = "icinga.service." + serviceName;
+ String escaped_serviceName = EscapeMetric(serviceName);
+ metric = "icinga.service." + escaped_serviceName;
SendMetric(metric + ".state", tags, service->GetState());
} else {
@@ -134,8 +134,8 @@ void OpenTsdbWriter::CheckResultHandler(const Checkable::Ptr& checkable, const C
if (service) {
tags["type"] = "service";
String serviceName = service->GetShortName();
- EscapeTag(serviceName);
- tags["service"] = serviceName;
+ String escaped_serviceName = EscapeTag(serviceName);
+ tags["service"] = escaped_serviceName;
} else {
tags["type"] = "host";
}
@@ -169,8 +169,7 @@ void OpenTsdbWriter::SendPerfdata(const String& metric, const std::map<String, S
}
}
- String escaped_key = pdv->GetLabel();
- EscapeMetric(escaped_key);
+ String escaped_key = EscapeMetric(pdv->GetLabel());
boost::algorithm::replace_all(escaped_key, "::", ".");
SendMetric(metric + "." + escaped_key, tags, pdv->GetValue());
diff --git a/plugins/check_ping.cpp b/plugins/check_ping.cpp
index 96cc37e..cde32f2 100644
--- a/plugins/check_ping.cpp
+++ b/plugins/check_ping.cpp
@@ -194,8 +194,8 @@ INT parseArguments(INT ac, WCHAR **av, po::variables_map& vm, printInfoStruct& p
if (vm.count("timeout"))
printInfo.timeout = vm["timeout"].as<INT>();
- if (vm.count("count"))
- printInfo.num = vm["count"].as<INT>();
+ if (vm.count("packets"))
+ printInfo.num = vm["packets"].as<INT>();
if (vm.count("-6"))
printInfo.ipv4 = FALSE;
diff --git a/tools/chocolateyInstall.ps1 b/tools/chocolateyInstall.ps1
index 07b63a7..291b992 100755
--- a/tools/chocolateyInstall.ps1
+++ b/tools/chocolateyInstall.ps1
@@ -1,7 +1,7 @@
-$packageName = 'icinga2'
-$installerType = 'exe'
-$url = 'http://packages.icinga.org/windows/Icinga2-v2.3.7.exe'
-$silentArgs = '/S'
-$validExitCodes = @(0)
-
-Install-ChocolateyPackage "$packageName" "$installerType" "$silentArgs" "$url" -validExitCodes $validExitCodes
+$packageName = 'icinga2'
+$installerType = 'exe'
+$url = 'http://packages.icinga.org/windows/Icinga2-v2.3.8.exe'
+$silentArgs = '/S'
+$validExitCodes = @(0)
+
+Install-ChocolateyPackage "$packageName" "$installerType" "$silentArgs" "$url" -validExitCodes $validExitCodes
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-nagios/pkg-icinga2.git
More information about the Pkg-nagios-changes
mailing list