You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
According to the documentation it is possible to connect to cataloged databases. If that's the case, hostname and port are omitted.
The check command should be rendered to:
The --hostname parameter is always used, thus its not possible to connect to cataloged databases as check_db2_health is using tcp/ip mode if --hostname is present.
The rendered check command is:
It should be possible to specify whether a cataloged database should be used or not. If that's the case, omit --hostname
Steps to Reproduce (for bugs)
Create service which uses db2_health command
Dont configure a hostname and port
Execute check
Context
With the current behaviour no checks of catalogued databases are possible.
Your Environment
Version used (icinga2 --version):
icinga01:~ # icinga2 --version
icinga2 - The Icinga 2 network monitoring daemon (version: r2.8.4-1)
Copyright (c) 2012-2017 Icinga Development Team (https://www.icinga.com/)
License GPLv2+: GNU GPL version 2 or later <http://gnu.org/licenses/gpl2.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Application information:
Installation root: /usr
Sysconf directory: /etc
Run directory: /run
Local state directory: /var
Package data directory: /usr/share/icinga2
State path: /var/lib/icinga2/icinga2.state
Modified attributes path: /var/lib/icinga2/modified-attributes.conf
Objects path: /var/cache/icinga2/icinga2.debug
Vars path: /var/cache/icinga2/icinga2.vars
PID path: /run/icinga2/icinga2.pid
System information:
Platform: SLES
Platform version: 12-SP3
Kernel: Linux
Kernel version: 4.4.126-94.22-default
Architecture: x86_64
Build information:
Compiler: GNU 4.8.5
Build host: hostname
Operating System and version:
icinga01:~ # cat /etc/SuSE-release
SUSE Linux Enterprise Server 12 (x86_64)
VERSION = 12
PATCHLEVEL = 3
# This file is deprecated and will be removed in a future service pack or release.
# Please check /etc/os-release for details about this release.
icinga01:~ # icinga2 daemon -C
information/cli: Icinga application loader (version: r2.8.4-1)
information/cli: Loading configuration file(s).
information/ConfigItem: Committing config item(s).
information/ApiListener: My API identity: icinga01.company.dmz
warning/ApplyRule: Apply rule 'mail-icingaadmin' (in /etc/icinga2/conf.d/notifications.conf: 11:1-11:45) for type 'Notification' does not match anywhere!
warning/ApplyRule: Apply rule 'mail-icingaadmin' (in /etc/icinga2/conf.d/notifications.conf: 23:1-23:48) for type 'Notification' does not match anywhere!
warning/ApplyRule: Apply rule 'Switch Interface Check' (in /var/lib/icinga2/api/packages/director/icinga01-1527235359-3/zones.d/director-global/service_apply.conf: 1:0-1:75) for type 'Service' does not match anywhere!
information/ConfigItem: Instantiated 1 ApiListener.
information/ConfigItem: Instantiated 3 Zones.
information/ConfigItem: Instantiated 1 Endpoint.
information/ConfigItem: Instantiated 1 FileLogger.
information/ConfigItem: Instantiated 3 ApiUsers.
information/ConfigItem: Instantiated 1 UserGroup.
information/ConfigItem: Instantiated 2 NotificationCommands.
information/ConfigItem: Instantiated 219 CheckCommands.
information/ConfigItem: Instantiated 1 IcingaApplication.
information/ConfigItem: Instantiated 848 Hosts.
information/ConfigItem: Instantiated 24 HostGroups.
information/ConfigItem: Instantiated 1 Downtime.
information/ConfigItem: Instantiated 3 TimePeriods.
information/ConfigItem: Instantiated 1 User.
information/ConfigItem: Instantiated 3 Comments.
information/ConfigItem: Instantiated 22 ServiceGroups.
information/ConfigItem: Instantiated 4977 Services.
information/ConfigItem: Instantiated 1 ScheduledDowntime.
information/ConfigItem: Instantiated 1 CheckerComponent.
information/ConfigItem: Instantiated 1 IdoMysqlConnection.
information/ConfigItem: Instantiated 1 LivestatusListener.
information/ConfigItem: Instantiated 1 NotificationComponent.
information/ScriptGlobal: Dumping variables to file '/var/cache/icinga2/icinga2.vars'
information/cli: Finished validating the configuration file(s).
If you run multiple Icinga 2 instances, the zones.conf file (or icinga2 object list --type Endpoint and icinga2 object list --type Zone) from all affected nodes.
The text was updated successfully, but these errors were encountered:
f0dbcab added a default value into the CheckCommand but it hasn't been documented at all. If we remove it, this likely breaks setups. Not sure where to head here.
Lazy as i was, i just copied the text from the plugin. But i will send PR soon, have allready an idea how to do it and not break existing setups. Just have to test it.
Expected Behavior
According to the documentation it is possible to connect to cataloged databases. If that's the case,
hostname
andport
are omitted.The check command should be rendered to:
So that there's no tcp/ip connection involved.
Current Behavior
The
--hostname
parameter is always used, thus its not possible to connect to cataloged databases ascheck_db2_health
is using tcp/ip mode if--hostname
is present.The rendered check command is:
Possible Solution
It should be possible to specify whether a cataloged database should be used or not. If that's the case, omit
--hostname
Steps to Reproduce (for bugs)
db2_health
commandContext
With the current behaviour no checks of catalogued databases are possible.
Your Environment
icinga2 --version
):icinga2 feature list
):icinga2 daemon -C
):zones.conf
file (oricinga2 object list --type Endpoint
andicinga2 object list --type Zone
) from all affected nodes.The text was updated successfully, but these errors were encountered: