From 6e5323b96892bd90f208f157cbdfad3724931bb3 Mon Sep 17 00:00:00 2001 From: Konrad Bucheli Date: Thu, 19 Dec 2024 10:08:30 +0100 Subject: [PATCH] improve Icinga2 custom check documentation --- admin-guide/configuration/monitoring/icinga2.md | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/admin-guide/configuration/monitoring/icinga2.md b/admin-guide/configuration/monitoring/icinga2.md index 1a9cdfba..63ebd931 100644 --- a/admin-guide/configuration/monitoring/icinga2.md +++ b/admin-guide/configuration/monitoring/icinga2.md @@ -4,7 +4,7 @@ Icinga2 is productive, but the checks are still getting added: - ✅ standard Linuxfabrik checks - 🏗️ support for automatically installed Icinga1 checks by Puppet ([see issue](https://git.psi.ch/linux-infra/issues/-/issues/419)) -- ❌ support for custom checks +- ✅ support for custom checks The overview of your nodes in Icinga2 you get at [monitoring.psi.ch](https://monitoring.psi.ch) and there you can handle the alerts and create service windows, etc. @@ -243,15 +243,17 @@ icinga2::custom_service: Possible commands are [`http`](https://icinga.com/docs/icinga-2/latest/doc/10-icinga-template-library/#plugin-check-command-http), [`tcp`](https://icinga.com/docs/icinga-2/latest/doc/10-icinga-template-library/#plugin-check-command-tcp), [`udp`](https://icinga.com/docs/icinga-2/latest/doc/10-icinga-template-library/#plugin-check-command-udp), [`ssl`](https://icinga.com/docs/icinga-2/latest/doc/10-icinga-template-library/#plugin-check-command-ssl), [`ssh`](https://icinga.com/docs/icinga-2/latest/doc/10-icinga-template-library/#plugin-check-command-ssh) or [`ftp`](https://icinga.com/docs/icinga-2/latest/doc/10-icinga-template-library/#plugin-check-command-ftp). ### Other Custom Checks -It is possible to create a very custom check. But note the command or service template used needs to be available/configured by some other means on the Icinga Master. The check plugin executed on the Icinga Satellite or by the Icinga agent needs also to be already available or distributed by other means. +It is possible to create a very custom check. But note the command or service template used needs to be available/configured by some other means on the Icinga Master. The check plugin executed on the Icinga Satellite or by the Icinga agent needs also to be already available or distributed by other means. So please reach out to the [Linux Team](mailto:linux-eng@psi.ch) to check how to do it best and to ensure that all is in place. ``` icinga2::custom_service: 'My Service Check 1': - template: st-agent-linux-fileage + template: st-agent-lf-file-size vars: criticality: 'B' - file_age_file: '/var/my/regular/activity/file' + file_size_filename: '/var/my/growing/file' + file_size_warning = '100M' + file_size_critical = '200M' 'My Service Check 1': command: 'tcp' agent: false @@ -263,7 +265,7 @@ icinga2::custom_service: Below `icinga2::custom_service` set the name of the service/service check as it will be seen in Icingaweb. Then the possible arguments are - `command` to issue a check command - `template` to inherit from given service template -- `agent` if `template` is not set, the agent base template is used, default is `true` +- `agent` shall the `command` run on the agent or the satellite, only if `themplate` is not set, default is `true` - `vars` hash with arguments for the service check - `perf_data` if performance data should be recorded and performance graph should be shown, default is `false`