Add ntpq probe management

The ntp package will not be managed in this role because it can break
the "ntp" on the system according to the choosen client (systemd,
chrony,…).
This commit is contained in:
Jeremy Gardais 2020-12-22 13:13:31 +01:00
parent f0af1328ea
commit 8aad270520
Signed by: jegardai
GPG Key ID: E759BAA22501AF32
4 changed files with 30 additions and 1 deletions

View File

@ -5,6 +5,7 @@
No backward compatibility with old variable naming! Update your configuration!
* Add megaraid probe management.
* Add net probe management.
* Add ntpq probe management.
* Add configuration file for `net` script (/etc/xymon/net.yaml) and
possibility to set your own template. Check [net documentation](net plugin doc).
* Remove unecessary netstats dependencies (due to a previous misunderstanding)

View File

@ -124,7 +124,7 @@ specific to your host(s) network configuration and override
#### Netstats
Variables for the Net/Netstats plugin from hobbit-plugins. The plugin check
Variables for the Netstats plugin from hobbit-plugins. The plugin check
network interface states.
* **xymon_cli__plug_netstats_state**: The state of plugin `netstats` [default: `false`].
@ -132,6 +132,16 @@ network interface states.
* **xymon_cli__plug_netstats_tpl**: Template used to generate the previous config file [default: `etc/xymon/clientlaunch.d/netstats.cfg.j2`].
* **xymon_cli__plug_netstats_interval**: Time between each run of the `netstats` plugin [default: `5m`].
#### Ntpq
Variables for the Ntpq plugin from hobbit-plugins. The plugin check
the ntpd daemon synchronization status (needs manual ntp installation).
* **xymon_cli__plug_ntpq_state**: The state of plugin `ntpq` [default: `false`].
* **xymon_cli__plug_ntpq_path**: Configuration file for the `ntpq` plugin [default: `/etc/xymon/clientlaunch.d/ntpq.cfg`].
* **xymon_cli__plug_ntpq_tpl**: Template used to generate the previous config file [default: `etc/xymon/clientlaunch.d/ntpq.cfg.j2`].
* **xymon_cli__plug_ntpq_interval**: Time between each run of the `ntpq` plugin [default: `5m`].
#### SGE
Variables for sge plugin from [ipr-cnrs.scripts][sge plugin source].

View File

@ -131,6 +131,13 @@ xymon_cli__plug_netstats_path: '/etc/xymon/clientlaunch.d/netstats.cfg'
xymon_cli__plug_netstats_tpl: 'etc/xymon/clientlaunch.d/netstats.cfg.j2'
xymon_cli__plug_netstats_interval: '5m'
## ]]]
## Plugin ntpq [[[
xymon_cli__plug_ntpq_state: true
xymon_cli__plug_ntpq_path: '/etc/xymon/clientlaunch.d/ntpq.cfg'
xymon_cli__plug_ntpq_tpl: 'etc/xymon/clientlaunch.d/ntpq.cfg.j2'
xymon_cli__plug_ntpq_interval: '5m'
## ]]]
## Plugin SGE [[[
### From https://git.ipr.univ-rennes1.fr/cellinfo/scripts/src/master/xymon/plugins/client/ext/sge.sh
@ -234,6 +241,9 @@ xymon_cli__plug_combined_clientlaunch:
- name: netstats
path: '{{ xymon_cli__plug_netstats_path }}'
template: '{{ xymon_cli__plug_netstats_tpl }}'
- name: ntpq
path: '{{ xymon_cli__plug_ntpq_path }}'
template: '{{ xymon_cli__plug_ntpq_tpl }}'
- name: sge
path: '{{ xymon_cli__plug_sge_path }}'
template: '{{ xymon_cli__plug_sge_tpl }}'

View File

@ -0,0 +1,8 @@
[ntpq]
# {{ ansible_managed }}
## From ipr-cnrs.xymon role
{{ '#DISABLED' if xymon_cli__plug_ntpq_state else 'DISABLED' }}
ENVFILE /etc/xymon/xymonclient.cfg
CMD $XYMONCLIENTHOME/ext/ntpq
LOGFILE /var/log/xymon/xymonclient.log
INTERVAL {{ xymon_cli__plug_ntpq_interval }}