forked from infra/ansible
Nagios: remove nagios_client role, and remove it from playbooks
Signed-off-by: Greg Sutcliffe <fedora@emeraldreverie.org>
This commit is contained in:
parent
449ddd529b
commit
0b1267eb9b
117 changed files with 0 additions and 1566 deletions
|
|
@ -17,7 +17,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- hosts
|
||||
- openvpn/client
|
||||
- zabbix/zabbix_agent
|
||||
|
|
|
|||
|
|
@ -19,7 +19,6 @@
|
|||
- openvpn/server
|
||||
- zabbix/zabbix_agent
|
||||
- ipa/client
|
||||
- nagios_client
|
||||
- hosts
|
||||
- sudo
|
||||
- collectd/base
|
||||
|
|
|
|||
|
|
@ -16,7 +16,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- hosts
|
||||
- openvpn/client
|
||||
- zabbix/zabbix_agent
|
||||
|
|
|
|||
|
|
@ -35,7 +35,6 @@
|
|||
|
||||
roles:
|
||||
- base
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- collectd/base
|
||||
- hosts
|
||||
|
|
|
|||
|
|
@ -16,7 +16,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- hosts
|
||||
- { role: openvpn/client,
|
||||
when: env != "staging" }
|
||||
|
|
|
|||
|
|
@ -57,7 +57,6 @@
|
|||
roles:
|
||||
- copr/pre
|
||||
- base
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- copr/backend
|
||||
- role: messaging/base
|
||||
|
|
|
|||
|
|
@ -52,7 +52,6 @@
|
|||
roles:
|
||||
- copr/pre
|
||||
- base
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- copr/dist_git
|
||||
|
||||
|
|
|
|||
|
|
@ -52,6 +52,5 @@
|
|||
roles:
|
||||
- copr/pre
|
||||
- base
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- copr/frontend
|
||||
|
|
|
|||
|
|
@ -34,7 +34,6 @@
|
|||
- import_role: name=base
|
||||
- import_role: name=hosts
|
||||
- import_role: name=rkhunter
|
||||
- import_role: name=nagios_client
|
||||
- import_role: name=openvpn/client
|
||||
- import_role: name=zabbix/zabbix_agent
|
||||
- import_role: name=ipa/client
|
||||
|
|
|
|||
|
|
@ -55,6 +55,5 @@
|
|||
roles:
|
||||
- copr/pre
|
||||
- base
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- copr/keygen
|
||||
|
|
|
|||
|
|
@ -45,6 +45,5 @@
|
|||
|
||||
roles:
|
||||
- base
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- copr/rpmeta
|
||||
|
|
|
|||
|
|
@ -22,7 +22,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- hosts
|
||||
- ipa/client
|
||||
- collectd/base
|
||||
|
|
|
|||
|
|
@ -64,7 +64,6 @@
|
|||
- base
|
||||
- rkhunter
|
||||
# - {role: ipa/client, when: env == "staging"}
|
||||
# - nagios_client
|
||||
# - zabbix/zabbix_agent
|
||||
- hosts
|
||||
- postgresql_server
|
||||
|
|
|
|||
|
|
@ -19,7 +19,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- hosts
|
||||
- ipa/client
|
||||
|
|
|
|||
|
|
@ -19,7 +19,6 @@
|
|||
- base
|
||||
- hosts
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- { role: openvpn/client,
|
||||
when: datacenter != 'rdu3' }
|
||||
- zabbix/zabbix_agent
|
||||
|
|
|
|||
|
|
@ -32,7 +32,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- hosts
|
||||
- { role: openvpn/client, when: vpn == True }
|
||||
- zabbix/zabbix_agent
|
||||
|
|
|
|||
|
|
@ -16,7 +16,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- ipa/client
|
||||
- collectd/base
|
||||
|
|
|
|||
|
|
@ -16,7 +16,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- collectd/base
|
||||
- hosts
|
||||
|
|
|
|||
|
|
@ -39,7 +39,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- hosts
|
||||
- rsyncd
|
||||
|
|
|
|||
|
|
@ -17,7 +17,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- hosts
|
||||
- rsyncd
|
||||
|
|
|
|||
|
|
@ -27,7 +27,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- hosts
|
||||
- ipa/client
|
||||
|
|
|
|||
|
|
@ -19,7 +19,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- hosts
|
||||
- zabbix/zabbix_agent
|
||||
- ipa/client
|
||||
|
|
|
|||
|
|
@ -40,5 +40,4 @@
|
|||
- base
|
||||
- nvidia-cdi
|
||||
- logdetective
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
|
|
|
|||
|
|
@ -16,7 +16,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- hosts
|
||||
- openvpn/client
|
||||
|
|
|
|||
|
|
@ -20,7 +20,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- hosts
|
||||
- {role: openvpn/client,
|
||||
|
|
|
|||
|
|
@ -18,7 +18,6 @@
|
|||
- base
|
||||
- rkhunter
|
||||
- hosts
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- openvpn/client
|
||||
- ipa/client
|
||||
|
|
|
|||
|
|
@ -26,7 +26,6 @@
|
|||
- base
|
||||
- rkhunter
|
||||
- ipa/client
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- hosts
|
||||
- mariadb_server
|
||||
|
|
|
|||
|
|
@ -16,7 +16,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- hosts
|
||||
- ipa/client
|
||||
|
|
|
|||
|
|
@ -19,7 +19,6 @@
|
|||
- rkhunter
|
||||
- hosts
|
||||
- ipa/client
|
||||
- nagios_client
|
||||
- collectd/base
|
||||
- sudo
|
||||
- openvpn/client
|
||||
|
|
|
|||
|
|
@ -20,7 +20,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- hosts
|
||||
- { role: openvpn/client, when: env != "staging" }
|
||||
- zabbix/zabbix_agent
|
||||
|
|
|
|||
|
|
@ -17,7 +17,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- zabbix/oci_registry
|
||||
- hosts
|
||||
|
|
|
|||
|
|
@ -16,7 +16,6 @@
|
|||
roles:
|
||||
- { role: base, tags: ['base'] }
|
||||
- { role: rkhunter, tags: ['rkhunter'] }
|
||||
- { role: nagios_client, tags: ['nagios_client'] }
|
||||
- { role: hosts, tags: ['hosts']}
|
||||
- ipa/client
|
||||
- { role: collectd/base, tags: ['collectd_base'] }
|
||||
|
|
|
|||
|
|
@ -16,7 +16,6 @@
|
|||
roles:
|
||||
- { role: base, tags: ['base'] }
|
||||
- { role: rkhunter, tags: ['rkhunter'] }
|
||||
- { role: nagios_client, tags: ['nagios_client'] }
|
||||
- { role: hosts, tags: ['hosts']}
|
||||
- zabbix/zabbix_agent
|
||||
- { role: ipa/client, tags: ['ipa_client']}
|
||||
|
|
|
|||
|
|
@ -20,7 +20,6 @@
|
|||
roles:
|
||||
- { role: base, tags: ['base'] }
|
||||
- { role: rkhunter, tags: ['rkhunter'] }
|
||||
- { role: nagios_client, tags: ['nagios_client'] }
|
||||
- { role: hosts, tags: ['hosts']}
|
||||
- zabbix/zabbix_agent
|
||||
- ipa/client
|
||||
|
|
|
|||
|
|
@ -17,7 +17,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- hosts
|
||||
- ipa/client
|
||||
|
|
|
|||
|
|
@ -23,7 +23,6 @@
|
|||
- base
|
||||
- ipa/client
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- sudo
|
||||
- keepalived
|
||||
|
||||
|
|
|
|||
|
|
@ -16,7 +16,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- hosts
|
||||
- openvpn/client
|
||||
|
|
|
|||
|
|
@ -16,7 +16,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- hosts
|
||||
- openvpn/client
|
||||
|
|
|
|||
|
|
@ -66,7 +66,6 @@
|
|||
when: env != "staging"
|
||||
- ipa/client
|
||||
- hosts
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- rkhunter
|
||||
- rsyncd
|
||||
|
|
|
|||
|
|
@ -17,7 +17,6 @@
|
|||
- base
|
||||
- hosts
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- ipa/client
|
||||
- collectd/base
|
||||
|
|
|
|||
|
|
@ -46,7 +46,6 @@
|
|||
- base
|
||||
- rkhunter
|
||||
- ipa/client
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- hosts
|
||||
- postgresql_server
|
||||
|
|
|
|||
|
|
@ -25,7 +25,6 @@
|
|||
when: env != "staging"}
|
||||
- ipa/client
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- collectd/base
|
||||
- sudo
|
||||
|
|
|
|||
|
|
@ -19,7 +19,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- hosts
|
||||
- ipa/client
|
||||
|
|
|
|||
|
|
@ -35,7 +35,6 @@
|
|||
- hosts
|
||||
- ipa/client
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- collectd/base
|
||||
- sudo
|
||||
|
|
|
|||
|
|
@ -70,7 +70,6 @@
|
|||
- import_role: name=ipa/client
|
||||
when: env != 'staging'
|
||||
- import_role: name=rkhunter
|
||||
- import_role: name=nagios_client
|
||||
- import_role: name=zabbix/zabbix_agent
|
||||
- import_role: name=sudo
|
||||
|
||||
|
|
|
|||
|
|
@ -16,7 +16,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- hosts
|
||||
- zabbix/zabbix_agent
|
||||
- ipa/client
|
||||
|
|
|
|||
|
|
@ -28,7 +28,6 @@
|
|||
- zabbix/zabbix_agent
|
||||
- ipa/client
|
||||
- sudo
|
||||
- nagios_client
|
||||
- sigul/bridge
|
||||
- role: keytab/service
|
||||
service: sigul
|
||||
|
|
|
|||
|
|
@ -18,7 +18,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- hosts
|
||||
- { role: openvpn/client,
|
||||
when: env != "staging" }
|
||||
|
|
|
|||
|
|
@ -18,7 +18,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- hosts
|
||||
- { role: openvpn/client,
|
||||
when: env != "staging" }
|
||||
|
|
|
|||
|
|
@ -20,7 +20,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- hosts
|
||||
- {
|
||||
|
|
|
|||
|
|
@ -19,7 +19,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- hosts
|
||||
- zabbix/zabbix_agent
|
||||
- ipa/client
|
||||
|
|
|
|||
|
|
@ -17,7 +17,6 @@
|
|||
- base
|
||||
- hosts
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- openvpn/client
|
||||
- zabbix/zabbix_agent
|
||||
- ipa/client
|
||||
|
|
|
|||
|
|
@ -16,7 +16,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- hosts
|
||||
- {role: openvpn/client,
|
||||
|
|
|
|||
|
|
@ -40,7 +40,6 @@
|
|||
roles:
|
||||
- base
|
||||
- role: rkhunter
|
||||
- role: nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- hosts
|
||||
- {role: openvpn/client, when: vpn|bool}
|
||||
|
|
|
|||
|
|
@ -24,7 +24,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- hosts
|
||||
- { role: openvpn/client,
|
||||
|
|
|
|||
|
|
@ -18,7 +18,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- hosts
|
||||
- collectd/base
|
||||
- sudo
|
||||
|
|
|
|||
|
|
@ -24,7 +24,6 @@
|
|||
- base
|
||||
- basessh
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- hosts
|
||||
- ipa/client
|
||||
|
|
|
|||
|
|
@ -16,7 +16,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- zabbix/zabbix_agent
|
||||
- ipa/client
|
||||
- sudo
|
||||
|
|
|
|||
|
|
@ -33,7 +33,6 @@
|
|||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- nagios_client
|
||||
- collectd/base
|
||||
- sudo
|
||||
|
||||
|
|
|
|||
|
|
@ -1,36 +0,0 @@
|
|||
===================================
|
||||
Nagios 4 Configuration for Fedora
|
||||
===================================
|
||||
|
||||
The Fedora Infrastructure Nagios is built on a set of configurations
|
||||
originally written for Nagios 2 and then upgraded over time to Nagios
|
||||
3 and then 4.08. With additional changes made in the 4.2 series of
|
||||
Nagios this needed a better rewrite as various parts came from
|
||||
pre-puppet and then various puppet modules added on top.
|
||||
|
||||
In order to get this rewrite done, we will use as much of the original
|
||||
layout of the Fedora ansible nagios module but with rewrites to better
|
||||
match current Nagios configurations so that it can be maintained.
|
||||
|
||||
Role directory layout
|
||||
=====================
|
||||
The original layout branched out from
|
||||
|
||||
roles/nagios/client/
|
||||
roles/nagios/server/
|
||||
|
||||
With the usual trees below this. This breaks ansible best practices
|
||||
and how most new modules are set up so the rewrite uses:
|
||||
|
||||
roles/nagios_client/
|
||||
roles/nagios_server/
|
||||
|
||||
=====================
|
||||
Nagios Client Files
|
||||
=====================
|
||||
|
||||
For the most part the Nagios Client files seem to work from the
|
||||
original layout to the new site. Changes will only need to be made to
|
||||
playbooks for the initial changes.
|
||||
|
||||
|
||||
|
|
@ -1,52 +0,0 @@
|
|||
#!/usr/bin/env python
|
||||
# Nagios check for CRL expiry
|
||||
# Takes a path to a crl.pem, a number of days to warn on, and a number of days
|
||||
# to crit on.
|
||||
#
|
||||
# Rick Elrod <relrod@redhat.com>
|
||||
# MIT
|
||||
|
||||
import datetime
|
||||
import subprocess
|
||||
import sys
|
||||
|
||||
def crl_next_update(path):
|
||||
try:
|
||||
args = ['openssl', 'crl', '-in', path, '-nextupdate', '-noout']
|
||||
out = subprocess.check_output(args).decode('utf-8')
|
||||
except Exception:
|
||||
print('openssl call failed, unable to check CRL nextUpdate')
|
||||
sys.exit(1)
|
||||
|
||||
timestamp = out.split('=')[1]
|
||||
timestamp = timestamp.strip()
|
||||
dt = datetime.datetime.strptime(timestamp, '%b %d %X %Y GMT')
|
||||
return dt
|
||||
|
||||
def main():
|
||||
if len(sys.argv) != 4:
|
||||
print('Usage: check_crl.py /path/to/crl.pem warning_days crit_days')
|
||||
sys.exit(3) # UNKNOWN
|
||||
|
||||
path = sys.argv[1]
|
||||
wdays = int(sys.argv[2])
|
||||
cdays = int(sys.argv[3])
|
||||
|
||||
expiry = crl_next_update(path)
|
||||
now = datetime.datetime.now()
|
||||
delta = expiry - now
|
||||
|
||||
code = 0
|
||||
state = 'OK'
|
||||
if delta.days <= cdays:
|
||||
code = 2
|
||||
state = 'CRITICAL'
|
||||
elif delta.days <= wdays:
|
||||
code = 1
|
||||
state = 'WARNING'
|
||||
|
||||
print('%s: CRL nextUpdate is in %d days' % (state, delta.days))
|
||||
sys.exit(code)
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
|
|
@ -1,89 +0,0 @@
|
|||
#!/usr/bin/python3
|
||||
""" NRPE check for datanommer/fedora-messaging health.
|
||||
Given a category like 'bodhi', 'buildsys', or 'git', return an error if
|
||||
datanommer hasn't seen a message of that type in such and such time.
|
||||
You can alternatively provide a 'topic' which might look like
|
||||
org.fedoraproject.prod.bodhi.update.comment.
|
||||
|
||||
Requires: python-requests
|
||||
Requires: python-dateutil
|
||||
|
||||
Usage:
|
||||
|
||||
$ check_datanommer_timesince CATEGORY WARNING_THRESH CRITICAL_THRESH
|
||||
|
||||
:Author: Aurelien Bompard <abompard@fedoraproject.org>
|
||||
|
||||
"""
|
||||
|
||||
import sys
|
||||
from datetime import datetime, timezone
|
||||
|
||||
import requests
|
||||
import dateutil.parser
|
||||
|
||||
|
||||
DATAGREPPER_URL = "https://apps.fedoraproject.org/datagrepper"
|
||||
|
||||
|
||||
def query_messages(identifier, delta):
|
||||
params = {"delta": delta, "rows_per_page": 1, "page": 1}
|
||||
# If it has a '.', then assume it is a topic.
|
||||
if "." in identifier:
|
||||
params["topic"] = identifier
|
||||
else:
|
||||
params["category"] = identifier
|
||||
response = requests.get(f"{DATAGREPPER_URL}/v2/search", params=params)
|
||||
if not response.ok:
|
||||
print(
|
||||
f"UNKNOWN: Could not query {DATAGREPPER_URL}: error {response.status_code}"
|
||||
)
|
||||
sys.exit(3)
|
||||
result = response.json()
|
||||
return result
|
||||
|
||||
|
||||
def parse_args():
|
||||
def _usage():
|
||||
print(f"Usage: {sys.argv[0]} CATEGORY WARNING_THRESHOLD CRITICAL_THRESHOLD")
|
||||
sys.exit(3)
|
||||
|
||||
if len(sys.argv) != 4:
|
||||
_usage()
|
||||
try:
|
||||
int(sys.argv[2])
|
||||
int(sys.argv[3])
|
||||
except ValueError:
|
||||
_usage()
|
||||
if int(sys.argv[2]) > int(sys.argv[3]):
|
||||
_usage()
|
||||
return sys.argv[1], int(sys.argv[2]), int(sys.argv[3])
|
||||
|
||||
|
||||
def main():
|
||||
identifier, warning_threshold, critical_threshold = parse_args()
|
||||
result = query_messages(identifier, critical_threshold)
|
||||
|
||||
if result["total"] == 0:
|
||||
print(f"CRIT: no {identifier} messages in {critical_threshold} seconds")
|
||||
sys.exit(2)
|
||||
|
||||
last_timestamp = result["raw_messages"][0]["headers"]["sent-at"]
|
||||
last_timestamp = dateutil.parser.parse(last_timestamp)
|
||||
seconds_since = int((datetime.now(timezone.utc) - last_timestamp).total_seconds())
|
||||
reason = f"last {identifier} message was {seconds_since} seconds ago"
|
||||
|
||||
if seconds_since > warning_threshold:
|
||||
print(f"WARN: {reason}")
|
||||
sys.exit(1)
|
||||
|
||||
print(f"OK: {reason}")
|
||||
sys.exit(0)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
try:
|
||||
main()
|
||||
except Exception as e:
|
||||
print(f"UNKNOWN: {e}")
|
||||
sys.exit(3)
|
||||
|
|
@ -1,25 +0,0 @@
|
|||
#!/usr/bin/python
|
||||
from __future__ import print_function
|
||||
from builtins import str
|
||||
import sys
|
||||
|
||||
try:
|
||||
import retask.queue
|
||||
|
||||
queue = retask.queue.Queue('fedora-packages')
|
||||
queue.connect()
|
||||
|
||||
items = queue.length
|
||||
if items > 500:
|
||||
print("CRITICAL: %i tasks in fcomm queue" % items)
|
||||
sys.exit(2)
|
||||
elif items > 250:
|
||||
print("WARNING: %i tasks in fcomm queue" % items)
|
||||
sys.exit(1)
|
||||
else:
|
||||
print("OK: %i tasks in fcomm queue" % items)
|
||||
sys.exit(0)
|
||||
|
||||
except Exception as e:
|
||||
print("UNKNOWN:", str(e))
|
||||
sys.exit(3)
|
||||
|
|
@ -1,76 +0,0 @@
|
|||
#!/usr/bin/python3
|
||||
""" Nagios check for haproxy over-subscription.
|
||||
|
||||
fedmsg-gateway is the primary concern as it can eat up a ton of simultaneous
|
||||
connections.
|
||||
|
||||
:Author: Ralph Bean <rbean@redhat.com>
|
||||
"""
|
||||
|
||||
import socket
|
||||
import sys
|
||||
|
||||
|
||||
def _numeric(value):
|
||||
""" Type casting utility """
|
||||
try:
|
||||
return int(value)
|
||||
except ValueError:
|
||||
try:
|
||||
return float(value)
|
||||
except ValueError:
|
||||
return value
|
||||
|
||||
|
||||
def query(sockname):
|
||||
""" Read stats from the haproxy socket and return a dict """
|
||||
sock = socket.socket(socket.AF_UNIX, socket.SOCK_STREAM)
|
||||
sock.connect(sockname)
|
||||
send_string = 'show info\n'
|
||||
sock.send(send_string.encode())
|
||||
try:
|
||||
response = sock.recv(2048).strip().decode()
|
||||
lines = response.split('\n')
|
||||
data = dict(map(str.strip, line.split(':')) for line in lines)
|
||||
data = {k:_numeric(v) for (k, v) in data.items()}
|
||||
return data
|
||||
except Exception as err:
|
||||
print(str(err))
|
||||
finally:
|
||||
sock.close()
|
||||
|
||||
return None
|
||||
|
||||
|
||||
def nagios_check(data):
|
||||
""" Print warnings and return nagios exit codes. """
|
||||
current = data['CurrConns']
|
||||
maxconn = data['Maxconn']
|
||||
percent = 100 * float(current) / float(maxconn)
|
||||
details = "%.2f%% subscribed. %i current of %i maxconn." % (
|
||||
percent, current, maxconn,
|
||||
)
|
||||
|
||||
if percent < 50:
|
||||
print("HAPROXY SUBS OK: " + details)
|
||||
return 0
|
||||
|
||||
if percent < 75:
|
||||
print("HAPROXY SUBS WARN: " + details)
|
||||
return 1
|
||||
|
||||
if percent <= 100:
|
||||
print("HAPROXY SUBS CRIT: " + details)
|
||||
return 2
|
||||
|
||||
print("HAPROXY SUBS UNKNOWN: " + details)
|
||||
return 3
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
try:
|
||||
data = query(sockname="/var/run/haproxy-stat")
|
||||
except Exception as err:
|
||||
print("HAPROXY SUBS UNKNOWN: " + str(err))
|
||||
sys.exit(3)
|
||||
sys.exit(nagios_check(data))
|
||||
|
|
@ -1,128 +0,0 @@
|
|||
#!/usr/bin/env python3
|
||||
|
||||
"""
|
||||
Check for available IDs in IPA's ID ranges.
|
||||
|
||||
See pagure.io/fedora-infrastructure/issue/12641
|
||||
|
||||
Author: abompard@fedoraproject.org
|
||||
"""
|
||||
|
||||
import os
|
||||
import sys
|
||||
from argparse import ArgumentParser
|
||||
from configparser import ConfigParser
|
||||
|
||||
import ldap
|
||||
|
||||
|
||||
STATUS_OK = 0
|
||||
STATUS_WARNING = 1
|
||||
STATUS_CRITICAL = 2
|
||||
STATUS_UNKNOWN = 3
|
||||
|
||||
|
||||
def get_config():
|
||||
config = ConfigParser(interpolation=None)
|
||||
config.read("/etc/ipa/default.conf")
|
||||
return {key: config.get("global", key) for key in ("host", "basedn")}
|
||||
|
||||
|
||||
def get_ldap_connection(config):
|
||||
ldap.set_option(ldap.OPT_REFERRALS, 0)
|
||||
conn = ldap.ldapobject.SimpleLDAPObject(f"ldaps://{config['host']}")
|
||||
conn.protocol_version = 3
|
||||
conn.timeout = 10
|
||||
conn.sasl_gssapi_bind_s()
|
||||
return conn
|
||||
|
||||
|
||||
def get_free_ids(config, connection):
|
||||
results = connection.search_s(
|
||||
base=f"cn=posix-ids,cn=dna,cn=ipa,cn=etc,{config['basedn']}",
|
||||
scope=ldap.SCOPE_ONELEVEL,
|
||||
filterstr="(dnaPortNum=389)",
|
||||
attrlist=["dnaHostname", "dnaRemainingValues"],
|
||||
)
|
||||
free_ids = {}
|
||||
for dn, attrs in results:
|
||||
hostname = attrs["dnaHostname"][0].decode("ascii")
|
||||
value = int(attrs["dnaRemainingValues"][0].decode("ascii"))
|
||||
free_ids[hostname] = value
|
||||
return free_ids
|
||||
|
||||
|
||||
def get_nagios_result(free_ids, thresholds):
|
||||
# Testcases:
|
||||
# free_ids={"host1": 0, "host2": 0, "host3": 20}
|
||||
# free_ids={"host1": 10, "host2": 0, "host3": 20}
|
||||
# free_ids={"host1": 10000, "host2": 10000, "host3": 20}
|
||||
# free_ids={}
|
||||
|
||||
perfdata = " ".join(f"{host}={free_ids[host]}" for host in sorted(free_ids))
|
||||
|
||||
msg = "OK: there are free IDs left"
|
||||
exit_code = 0
|
||||
|
||||
for threshold, threshold_exit_code in thresholds:
|
||||
if any(value < threshold for value in free_ids.values()):
|
||||
bad_servers = [host for host in sorted(free_ids) if free_ids[host] < threshold]
|
||||
msg = " ".join(
|
||||
[
|
||||
str(len(bad_servers)),
|
||||
"server has" if len(bad_servers) == 1 else "servers have",
|
||||
"less than",
|
||||
str(threshold),
|
||||
"free IDs left:",
|
||||
", ".join(bad_servers),
|
||||
]
|
||||
)
|
||||
exit_code = threshold_exit_code
|
||||
break
|
||||
return f"{msg}|{perfdata}", exit_code
|
||||
|
||||
|
||||
def exit_nagios(output, exit_code):
|
||||
print(output)
|
||||
sys.exit(exit_code)
|
||||
|
||||
|
||||
def parse_args():
|
||||
parser = ArgumentParser()
|
||||
parser.add_argument("-w", "--warning", type=int, default=1000, help="warning threshold")
|
||||
parser.add_argument("-c", "--critical", type=int, default=1, help="critical threshold")
|
||||
parser.add_argument(
|
||||
"-k", "--keytab", help="use this keytab for GSSAPI authentication"
|
||||
)
|
||||
return parser.parse_args()
|
||||
|
||||
|
||||
def main():
|
||||
args = parse_args()
|
||||
if args.keytab:
|
||||
os.environ["KRB5_CLIENT_KTNAME"] = args.keytab
|
||||
config = get_config()
|
||||
try:
|
||||
connection = get_ldap_connection(config)
|
||||
free_ids = get_free_ids(config, connection)
|
||||
except ldap.LOCAL_ERROR as e:
|
||||
exit_nagios(
|
||||
f"Can't read the free IDs in LDAP: {e.args[0].get('info')}", STATUS_UNKNOWN
|
||||
)
|
||||
|
||||
if not free_ids:
|
||||
current_user = connection.whoami_s()
|
||||
exit_nagios(
|
||||
f"No IPA server found in LDAP, check the permissions for user {current_user!r}",
|
||||
STATUS_UNKNOWN,
|
||||
)
|
||||
|
||||
thresholds = (
|
||||
(args.critical, STATUS_CRITICAL),
|
||||
(args.warning, STATUS_WARNING),
|
||||
)
|
||||
exit_nagios(*get_nagios_result(free_ids, thresholds))
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
|
|
@ -1,69 +0,0 @@
|
|||
#!/usr/bin/python
|
||||
# Source: https://github.com/opinkerfi/nagios-plugins/blob/master/check_ipa/check_ipa_replication
|
||||
# Copyright 2013, Tomas Edwardsson
|
||||
# Copyright 2016, Patrick Uiterwijk
|
||||
#
|
||||
# This script 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 3 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
# This script 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, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
import ldap, sys
|
||||
import argparse
|
||||
parser = argparse.ArgumentParser()
|
||||
parser.add_argument('-u', help="ldap uri", dest="uri")
|
||||
parser.add_argument('-D', help="bind DN", dest="binddn")
|
||||
parser.add_argument('-w', help="bind password", dest="bindpw")
|
||||
opt = parser.parse_args()
|
||||
|
||||
if not opt.uri:
|
||||
parser.error('-u (uri) argument is required')
|
||||
|
||||
try:
|
||||
l = ldap.initialize(opt.uri)
|
||||
|
||||
if opt.binddn:
|
||||
l.bind_s(opt.binddn, opt.bindpw)
|
||||
|
||||
replication = l.search_s('cn=config',
|
||||
ldap.SCOPE_SUBTREE,
|
||||
'(objectclass=nsds5replicationagreement)',
|
||||
['nsDS5ReplicaHost', 'nsds5replicaLastUpdateStatus'])
|
||||
except Exception as e:
|
||||
# critical
|
||||
print(f"CRITICAL - Unable to initialize ldap connection: {e}")
|
||||
sys.exit(2)
|
||||
|
||||
# Loop through replication agreements
|
||||
for rhost in replication:
|
||||
status = rhost[1]['nsds5replicaLastUpdateStatus'][0].decode('utf-8')
|
||||
code = status[:2]
|
||||
if status.startswith('Error ('):
|
||||
# IPA >=4.4.0
|
||||
code = status[status.find('(')+1:status.find(')')]
|
||||
else:
|
||||
# IPA <4.4.0
|
||||
code = status[:status.find(' ')]
|
||||
|
||||
if code == '0':
|
||||
print(f"OK - Replica Status: {(rhost[1]['nsDS5ReplicaHost'][0], rhost[1]['nsds5replicaLastUpdateStatus'][0])}")
|
||||
sys.exit(0)
|
||||
elif code == '1':
|
||||
# Busy Replica is not an error, its "unknown" (but its "ok" for now)
|
||||
print(f"OK - Replica Status: {(rhost[1]['nsDS5ReplicaHost'][0], rhost[1]['nsds5replicaLastUpdateStatus'][0])}")
|
||||
sys.exit(0)
|
||||
else:
|
||||
sys.exit(2)
|
||||
|
||||
if not len(replication):
|
||||
print(f"Warning - No replicas found")
|
||||
sys.exit(1)
|
||||
|
||||
|
|
@ -1,19 +0,0 @@
|
|||
#!/usr/bin/python
|
||||
|
||||
from __future__ import print_function
|
||||
import fcntl
|
||||
import sys
|
||||
|
||||
try:
|
||||
f = open('/mnt/koji/.nagios_test', 'r')
|
||||
f.close()
|
||||
f = open('/mnt/koji/.nagios_test', 'w')
|
||||
except IOError as e:
|
||||
print(e)
|
||||
print("Could not create file")
|
||||
sys.exit(2)
|
||||
|
||||
fcntl.flock(f, fcntl.LOCK_EX)
|
||||
f.close()
|
||||
print("File Locked Successfully")
|
||||
sys.exit(0)
|
||||
|
|
@ -1,123 +0,0 @@
|
|||
#! /usr/bin/perl -w
|
||||
|
||||
# check_lock_file_age.pl Copyright (C) 2010 Ricky Elrod <codeblock@fedoraproject.org>
|
||||
#
|
||||
# Fork of check_file_age.pl
|
||||
#
|
||||
# Checks a lock file's size and modification time to make sure it's not empty
|
||||
# and that it's sufficiently recent.
|
||||
#
|
||||
#
|
||||
# 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 (or with Nagios); if not, write to the
|
||||
# Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
||||
# Boston, MA 02111-1307, USA
|
||||
|
||||
use strict;
|
||||
use English;
|
||||
use Getopt::Long;
|
||||
use File::stat;
|
||||
use vars qw($PROGNAME);
|
||||
use lib "/usr/lib64/nagios/plugins";
|
||||
use utils qw (%ERRORS &print_revision &support);
|
||||
|
||||
sub print_help ();
|
||||
sub print_usage ();
|
||||
|
||||
my ($opt_c, $opt_f, $opt_w, $opt_h, $opt_V);
|
||||
my ($result, $message, $age, $size, $st);
|
||||
|
||||
$PROGNAME="check_lock_file_age";
|
||||
|
||||
$opt_w = 1;
|
||||
$opt_c = 5;
|
||||
$opt_f = "";
|
||||
|
||||
Getopt::Long::Configure('bundling');
|
||||
GetOptions(
|
||||
"V" => \$opt_V, "version" => \$opt_V,
|
||||
"h" => \$opt_h, "help" => \$opt_h,
|
||||
"f=s" => \$opt_f, "file" => \$opt_f,
|
||||
"w=f" => \$opt_w, "warning-age=f" => \$opt_w,
|
||||
"c=f" => \$opt_c, "critical-age=f" => \$opt_c);
|
||||
|
||||
if ($opt_V) {
|
||||
print_revision($PROGNAME, '1.4.14');
|
||||
exit $ERRORS{'OK'};
|
||||
}
|
||||
|
||||
if ($opt_h) {
|
||||
print_help();
|
||||
exit $ERRORS{'OK'};
|
||||
}
|
||||
|
||||
if (($opt_c and $opt_w) and ($opt_c < $opt_w)) {
|
||||
print "Warning time must be less than Critical time.\n";
|
||||
exit $ERRORS{'UNKNOWN'};
|
||||
}
|
||||
|
||||
$opt_f = shift unless ($opt_f);
|
||||
|
||||
if (! $opt_f) {
|
||||
print "LOCK_FILE_AGE UNKNOWN: No file specified\n";
|
||||
exit $ERRORS{'UNKNOWN'};
|
||||
}
|
||||
|
||||
# Check that file exists (can be directory or link)
|
||||
unless (-e $opt_f) {
|
||||
print "LOCK_FILE_AGE OK: File not found (Lock file removed) - $opt_f\n";
|
||||
exit $ERRORS{'OK'};
|
||||
}
|
||||
|
||||
$st = File::stat::stat($opt_f);
|
||||
$age = time - $st->mtime;
|
||||
|
||||
$result = 'OK';
|
||||
|
||||
# Convert minutes to seconds
|
||||
if($opt_c) { $opt_c *= 60; }
|
||||
if($opt_w) { $opt_w *= 60; }
|
||||
|
||||
if ($opt_c and $age > $opt_c) {
|
||||
$result = 'CRITICAL';
|
||||
}
|
||||
elsif ($opt_w and $age > $opt_w) {
|
||||
$result = 'WARNING';
|
||||
}
|
||||
|
||||
# If the age is higher than 2 minutes, convert seconds -> minutes
|
||||
# If it's higher than a day, use days.
|
||||
# Just a nicety, to make people not have to do math ;)
|
||||
if($age > 86400) { $age = int(($age/86400))." days"; }
|
||||
elsif($age > 120) { $age = int(($age/60))." minutes"; }
|
||||
else { $age = "$age seconds"; }
|
||||
|
||||
print "LOCK_FILE_AGE $result: $opt_f is $age old.\n";
|
||||
exit $ERRORS{$result};
|
||||
|
||||
sub print_usage () {
|
||||
print "Usage:\n";
|
||||
print " $PROGNAME [-w <secs>] [-c <secs>] -f <file>\n";
|
||||
print " $PROGNAME [-h | --help]\n";
|
||||
print " $PROGNAME [-V | --version]\n";
|
||||
}
|
||||
|
||||
sub print_help () {
|
||||
print_revision($PROGNAME, '1.4.14');
|
||||
print "Copyright (c) 2010 Ricky Elrod\n\n";
|
||||
print_usage();
|
||||
print "\n";
|
||||
print " <mins> File must be no more than this many minutes old (default: warn 1m, crit 5m)\n";
|
||||
print "\n";
|
||||
support();
|
||||
}
|
||||
|
|
@ -1,24 +0,0 @@
|
|||
#!/bin/bash
|
||||
#
|
||||
# 2014-11-19
|
||||
# Author: Ralph Bean <rbean@redhat.com>
|
||||
|
||||
# exit codes
|
||||
ok=0
|
||||
warn=1
|
||||
crit=2
|
||||
unkn=3
|
||||
|
||||
# Right now we just check to see if we can even run this command without
|
||||
# hanging and timing out. In the future, we could parse stdout for more
|
||||
# fine-grained information.
|
||||
echo stats | nc 127.0.0.1 11211 > /dev/null
|
||||
status=$?
|
||||
|
||||
if [ $status -ne 0 ]; then
|
||||
echo "CRIT: stats command got status code $status"
|
||||
exit $crit
|
||||
else
|
||||
echo "OK: stats command got status code $status"
|
||||
exit $ok
|
||||
fi
|
||||
|
|
@ -1,14 +0,0 @@
|
|||
#!/usr/bin/python
|
||||
|
||||
import requests
|
||||
import sys
|
||||
|
||||
r = requests.get("https://localhost:8443/", verify=False)
|
||||
|
||||
if 'paths' in r.json().keys():
|
||||
print "OK: OSBS API endpoint is responding with path data"
|
||||
sys.exit(0)
|
||||
else:
|
||||
print "CRITICAL: OSBS API not responding properly"
|
||||
sys.exit(2)
|
||||
|
||||
|
|
@ -1,49 +0,0 @@
|
|||
#!/bin/bash
|
||||
#
|
||||
# 19-07-2010
|
||||
# Author: Cherwin Nooitmeer <cherwin@gmail.com>
|
||||
#
|
||||
|
||||
# exit codes
|
||||
e_ok=0
|
||||
e_warning=1
|
||||
e_critical=2
|
||||
e_unknown=3
|
||||
|
||||
# regular expression that matches queue IDs (e.g. D71EF7AC80F8)
|
||||
queue_id='^[A-F0-9][A-F0-9][A-F0-9][A-F0-9][A-F0-9][A-F0-9][A-F0-9][A-F0-9][A-F0-9][A-F0-9]'
|
||||
|
||||
usage="Invalid command line usage"
|
||||
|
||||
if [ -z $1 ]; then
|
||||
echo $usage
|
||||
exit $e_unknown
|
||||
fi
|
||||
|
||||
while getopts ":w:c:" options
|
||||
do
|
||||
case $options in
|
||||
w ) warning=$OPTARG ;;
|
||||
c ) critical=$OPTARG ;;
|
||||
* ) echo $usage
|
||||
exit $e_unknown ;;
|
||||
esac
|
||||
done
|
||||
|
||||
# determine queue size
|
||||
qsize=$(mailq | egrep -c $queue_id)
|
||||
if [ -z $qsize ]
|
||||
then
|
||||
exit $e_unknown
|
||||
fi
|
||||
|
||||
if [ $qsize -ge $critical ]; then
|
||||
retval=$e_critical
|
||||
elif [ $qsize -ge $warning ]; then
|
||||
retval=$e_warning
|
||||
elif [ $qsize -lt $warning ]; then
|
||||
retval=$e_ok
|
||||
fi
|
||||
|
||||
echo "$qsize mail(s) in queue | mail_queue=$qsize"
|
||||
exit $retval
|
||||
|
|
@ -1,69 +0,0 @@
|
|||
#!/usr/bin/python3
|
||||
|
||||
import subprocess
|
||||
import json
|
||||
import argparse
|
||||
import sys
|
||||
|
||||
from datetime import datetime
|
||||
|
||||
parser = argparse.ArgumentParser()
|
||||
parser.add_argument('domain', help="Required. Domain to check")
|
||||
parser.add_argument('-c', '--critical', dest='critical', type=int, default=50,
|
||||
help="Critical threshold")
|
||||
parser.add_argument('-w', '--warning', dest='warning', type=int, default=20,
|
||||
help="Warning threshold")
|
||||
parser.add_argument('-L', '--lower', dest='lower', type=int, default=5,
|
||||
help="ignore queues ages lower than x minutes (default: 5)")
|
||||
parser.add_argument('-H', '--higher', dest='higher', type=int, default=1440,
|
||||
help="ignore queues ages higher than x minutes (default: 1440)")
|
||||
args = parser.parse_args()
|
||||
|
||||
|
||||
now = datetime.now()
|
||||
p = subprocess.Popen(['/usr/sbin/postqueue', '-j'],
|
||||
stdin=subprocess.PIPE,
|
||||
stdout=subprocess.PIPE,
|
||||
stderr=subprocess.STDOUT)
|
||||
output = str(p.stdout.read(), "utf-8").splitlines()
|
||||
mail_queue = 0
|
||||
|
||||
|
||||
if args.domain == 'all':
|
||||
mail_queue = len(output)
|
||||
else:
|
||||
for line in output:
|
||||
j = json.loads(line)
|
||||
if j["queue_name"] == 'active':
|
||||
# Ignore Active queue
|
||||
continue
|
||||
|
||||
queue_old = now - datetime.fromtimestamp(j["arrival_time"])
|
||||
if (queue_old.total_seconds() / 60 < args.lower
|
||||
or queue_old.total_seconds() / 60 > args.higher):
|
||||
# Not old enough
|
||||
continue
|
||||
|
||||
for recipient in j['recipients']:
|
||||
if recipient['address'].endswith(args.domain):
|
||||
mail_queue += 1
|
||||
break
|
||||
|
||||
|
||||
ret_val = 0
|
||||
msg = ("OK: Queue length for %s destination < %s (%s)"
|
||||
% (args.domain, args.warning, mail_queue))
|
||||
|
||||
if mail_queue > args.warning:
|
||||
msg = ("WARNING: Queue length for %s destination > %s (%s)"
|
||||
% (args.domain, args.warning, mail_queue))
|
||||
ret_val = 1
|
||||
|
||||
if mail_queue > args.critical:
|
||||
msg = ("CRITICAL: Queue length for %s destination > %s (%s)"
|
||||
% (args.domain, args.critical, mail_queue))
|
||||
ret_val = 2
|
||||
|
||||
|
||||
print(msg)
|
||||
sys.exit(ret_val)
|
||||
|
|
@ -1,43 +0,0 @@
|
|||
#!/usr/bin/python
|
||||
#
|
||||
# very simple python script to parse out /proc/mdstat
|
||||
# and give results for nagios to monitor
|
||||
#
|
||||
|
||||
import sys
|
||||
|
||||
devices = []
|
||||
|
||||
try:
|
||||
mdstat = open('/proc/mdstat').read().split('\n')
|
||||
except IOError:
|
||||
# seems we have no software raid on this machines
|
||||
sys.exit(0)
|
||||
|
||||
error = ""
|
||||
i = 0
|
||||
for line in mdstat:
|
||||
if line[0:2] == 'md':
|
||||
device = line.split()[0]
|
||||
devices.append(device)
|
||||
status = mdstat[i+1].split()[-1]
|
||||
if status.count("_"):
|
||||
# see if we can figure out what's going on
|
||||
err = mdstat[i+2].split()
|
||||
msg = "device=%s status=%s" % (device, status)
|
||||
if len(err) > 0:
|
||||
msg = msg + " rebuild=%s" % err[0]
|
||||
|
||||
if not error:
|
||||
error = msg
|
||||
else:
|
||||
error = error + ", " + msg
|
||||
i = i + 1
|
||||
|
||||
if not error:
|
||||
print("DEVICES %s OK" % " ".join(devices))
|
||||
sys.exit(0)
|
||||
|
||||
else:
|
||||
print(error)
|
||||
sys.exit(2)
|
||||
|
|
@ -1,84 +0,0 @@
|
|||
#!/bin/bash
|
||||
|
||||
# check_readonlyfs: Check for readonly filesystems
|
||||
# Copyright (C) 2010 Davide Madrisan <davide.madrisan@gmail.com>
|
||||
|
||||
PROGNAME=`/bin/basename $0`
|
||||
PROGPATH=`echo $0 | sed -e 's,[\\/][^\\/][^\\/]*$,,'`
|
||||
REVISION=`echo '$Revision: 1 $' | sed -e 's/[^0-9.]//g'`
|
||||
|
||||
. $PROGPATH/utils.sh
|
||||
|
||||
print_usage() {
|
||||
echo "Usage: $PROGNAME --no-network-fs"
|
||||
echo "Usage: $PROGNAME --help"
|
||||
echo "Usage: $PROGNAME --version"
|
||||
}
|
||||
|
||||
print_help() {
|
||||
print_revision $PROGNAME $REVISION
|
||||
echo ""
|
||||
print_usage
|
||||
echo ""
|
||||
echo "readonly filesystem checker plugin for Nagios"
|
||||
echo ""
|
||||
support
|
||||
}
|
||||
|
||||
NETFS=1
|
||||
|
||||
# Grab the command line arguments
|
||||
|
||||
exitstatus=$STATE_WARNING #default
|
||||
|
||||
while test -n "$1"; do
|
||||
case "$1" in
|
||||
--help|-h)
|
||||
print_help
|
||||
exit $STATE_OK
|
||||
;;
|
||||
--version|-V)
|
||||
print_revision $PROGNAME $REVISION
|
||||
exit $STATE_OK
|
||||
;;
|
||||
--no-network-fs|-n)
|
||||
NETFS="0"
|
||||
;;
|
||||
*)
|
||||
echo "Unknown argument: $1"
|
||||
print_usage
|
||||
exit $STATE_UNKNOWN
|
||||
;;
|
||||
esac
|
||||
shift
|
||||
done
|
||||
|
||||
[ -r /proc/mounts ] || { echo "cannot read /proc/mounts!"; exit $STATE_UNKNOWN; }
|
||||
|
||||
nerr=0
|
||||
IFS_SAVE="$IFS"
|
||||
|
||||
rofs_list=""
|
||||
while read dev mp fs mopt ignore; do
|
||||
[ "$dev" = none ] && continue
|
||||
case $fs in binfmt_misc|devpts|iso9660|proc|selinuxfs|rpc_pipefs|sysfs|tmpfs|usbfs)
|
||||
continue ;;
|
||||
esac
|
||||
case $fs in autofs|nfs|nfs4|smbfs)
|
||||
# skip the network filesystems
|
||||
[ "$NETFS" = 0 ] && continue ;;
|
||||
esac
|
||||
|
||||
IFS=","; set -- $mopt; IFS="$IFS_SAVE"
|
||||
while :; do
|
||||
case "$1" in
|
||||
ro) rofs_list="$rofs_list $mp"; nerr=$(( $nerr + 1 )) ;;
|
||||
"") shift; break ;;
|
||||
esac
|
||||
shift
|
||||
done
|
||||
done < <(LC_ALL=C /bin/cat /proc/mounts 2>/dev/null)
|
||||
|
||||
[ $nerr -eq 0 ] && { echo OK; exit $STATE_OK; } || echo "$rofs_list: read only fs"
|
||||
|
||||
exit $exitstatus
|
||||
|
|
@ -1,23 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
. /usr/lib64/nagios/plugins/utils.sh
|
||||
|
||||
if [[ "$#" -ne 3 ]]; then
|
||||
echo "Arguments: key warn crit"
|
||||
exit $STATE_UNKNOWN
|
||||
fi
|
||||
|
||||
tasks="$(redis-cli llen "$1" | awk '{print $1}')"
|
||||
|
||||
check_range $tasks $2:$3
|
||||
status=$?
|
||||
|
||||
if [[ "$status" == "$STATE_OK" ]]; then
|
||||
echo "OK: $1 queue has $tasks tasks"
|
||||
elif [[ "$status" == "$STATE_WARNING" ]]; then
|
||||
echo "WARNING: $1 queue has $tasks tasks"
|
||||
elif [[ "$status" == "$STATE_CRITICAL" ]]; then
|
||||
echo "CRITICAL: $1 queue has $tasks tasks"
|
||||
fi
|
||||
|
||||
exit $status
|
||||
|
|
@ -1,47 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
# Description : script to check the status of systemd units
|
||||
# if they failed, try to restart the service once !!
|
||||
|
||||
# Author : Seddik Alaoui Ismaili
|
||||
# Version : 1.0
|
||||
|
||||
|
||||
# Exits code
|
||||
warning_exit="1"
|
||||
ok_exit="0"
|
||||
|
||||
# Unit list
|
||||
unit_list=(pagure_ci
|
||||
pagure_ev
|
||||
pagure_fast_worker
|
||||
pagure_loadjson
|
||||
pagure_logcom
|
||||
pagure_medium_worker
|
||||
pagure_milter
|
||||
pagure_mirror
|
||||
pagure_slow_worker
|
||||
pagure_webhook
|
||||
pagure_worker
|
||||
pagure_mirror_project_in.timer)
|
||||
|
||||
#Element's arrays
|
||||
failed_array=()
|
||||
active_array=()
|
||||
|
||||
# Check units's status
|
||||
for element in ${unit_list[@]}; do
|
||||
status=$(systemctl status ${element} |grep -E "Active:" | awk '{ print $2 }')
|
||||
if [ $status == failed ]; then
|
||||
systemctl restart ${element} && active_array+=($element) || failed_array+=($element)
|
||||
fi
|
||||
done
|
||||
|
||||
# check the lenght of array and print result/exit code for nagios
|
||||
if [ ${#failed_array[@]} -ne "0" ]; then
|
||||
echo -e "UNITS WARNING: Failed systemd units after restart : ${failed_array[@]}"
|
||||
exit ${warning_exit}
|
||||
elif [ ${#failed_array[@]} -eq "0" ]; then
|
||||
echo -e "UNITS OK: Systemd units are active"
|
||||
exit ${ok_exit}
|
||||
fi
|
||||
|
|
@ -1,19 +0,0 @@
|
|||
#!/bin/bash
|
||||
|
||||
RUNNING_VMS=`testcloud instance list | grep -i 'running' | wc -l`
|
||||
CRITICAL=20
|
||||
WARNING=15
|
||||
|
||||
|
||||
if [ $RUNNING_VMS -gt $CRITICAL ]
|
||||
then
|
||||
echo "Testcloud: CRITICAL Number of VMs running: $RUNNING_VMS"
|
||||
exit 2
|
||||
elif [ $RUNNING_VMS -gt $WARNING ]
|
||||
then
|
||||
echo "Testcloud: WARNING Number of VMs running: $RUNNING_VMS"
|
||||
exit 1
|
||||
else
|
||||
echo "Testcloud: OK Number of VMs running: $RUNNING_VMS"
|
||||
exit 0
|
||||
fi
|
||||
|
|
@ -1,43 +0,0 @@
|
|||
#!/usr/bin/env python
|
||||
|
||||
# Takes a path to a file and a delta. The file must simply contain an epoch
|
||||
# timestamp. It can be an integer or a float, as can the delta.
|
||||
#
|
||||
# Alerts critical if (now - timestamp contained in file) > delta.
|
||||
#
|
||||
# Rick Elrod <relrod@redhat.com>
|
||||
# MIT
|
||||
|
||||
import sys
|
||||
import time
|
||||
|
||||
if len(sys.argv) != 3:
|
||||
print('UNKNOWN: Pass path to file and delta as parameters')
|
||||
sys.exit(3)
|
||||
|
||||
filename = sys.argv[1]
|
||||
delta = float(sys.argv[2])
|
||||
|
||||
timestamp = None
|
||||
|
||||
try:
|
||||
with open(filename, 'r') as f:
|
||||
timestamp = float(f.read().strip())
|
||||
except Exception as e:
|
||||
print('UNKNOWN: Unable to open/read file path')
|
||||
sys.exit(3)
|
||||
|
||||
difference = round(time.time() - timestamp, 2)
|
||||
if difference > delta:
|
||||
print(
|
||||
'CRITICAL: Timestamp in file (%.2f) exceeds delta (%.2f) by %.2f seconds' % (
|
||||
timestamp,
|
||||
delta,
|
||||
difference - delta))
|
||||
sys.exit(2)
|
||||
|
||||
print('OK: Timestamp in file (%.2f) is within delta (%.2f) of now, by %.2f seconds' % (
|
||||
timestamp,
|
||||
delta,
|
||||
abs(difference - delta)))
|
||||
sys.exit(0)
|
||||
Binary file not shown.
Binary file not shown.
|
|
@ -1,20 +0,0 @@
|
|||
module fi-nrpe 1.2;
|
||||
|
||||
require {
|
||||
type nagios_system_plugin_t;
|
||||
type nagios_admin_plugin_t;
|
||||
type nrpe_exec_t;
|
||||
type bin_t;
|
||||
type default_t;
|
||||
class file { getattr map execute };
|
||||
class lnk_file { read getattr };
|
||||
}
|
||||
|
||||
#============= nagios_system_plugin_t ==============
|
||||
allow nagios_system_plugin_t nrpe_exec_t:file getattr;
|
||||
|
||||
# This is needed for e.g. check_file_age, which is a perl script
|
||||
allow nagios_admin_plugin_t bin_t:file { map execute };
|
||||
|
||||
# Allow reading symlinks
|
||||
allow nagios_admin_plugin_t default_t:lnk_file read;
|
||||
Binary file not shown.
|
|
@ -1,15 +0,0 @@
|
|||
module mirrormanager_container 1.0;
|
||||
|
||||
require {
|
||||
type container_t;
|
||||
type container_file_t;
|
||||
type mirrormanager_log_t;
|
||||
type nrpe_t;
|
||||
class file { append getattr };
|
||||
}
|
||||
|
||||
# Allow mirrorlist to append to its log
|
||||
allow container_t mirrormanager_log_t:file append;
|
||||
# Allow nrpe to check file age of mirrorlist pkl files
|
||||
allow nrpe_t container_file_t:file getattr;
|
||||
|
||||
|
|
@ -1,3 +0,0 @@
|
|||
---
|
||||
- name: Restart nrpe
|
||||
service: name=nrpe state=restarted
|
||||
|
|
@ -1,87 +0,0 @@
|
|||
# nagios-client/nrpe
|
||||
|
||||
---
|
||||
- name: Nrpe service stop
|
||||
ansible.builtin.service:
|
||||
name: nrpe
|
||||
state: stopped
|
||||
enabled: false
|
||||
tags:
|
||||
- service
|
||||
- nagios_client
|
||||
|
||||
- name: Remove nrpe user with deterministic UID before nrpe.rpm creates it
|
||||
ansible.builtin.user:
|
||||
name: nrpe
|
||||
state: absent
|
||||
tags:
|
||||
- nagios_client
|
||||
|
||||
- name: Remove nagios client pkgs
|
||||
ansible.builtin.package:
|
||||
name: "{{ item }}"
|
||||
state: absent
|
||||
with_items:
|
||||
- nrpe
|
||||
- nagios-plugins
|
||||
- nagios-plugins-disk
|
||||
- nagios-plugins-file_age
|
||||
- nagios-plugins-users
|
||||
- nagios-plugins-procs
|
||||
- nagios-plugins-swap
|
||||
- nagios-plugins-load
|
||||
- nagios-plugins-ping
|
||||
- nagios-plugins-http
|
||||
tags:
|
||||
- packages
|
||||
- nagios_client
|
||||
|
||||
- name: Remove datanommer check packages
|
||||
ansible.builtin.package:
|
||||
name: "{{ item }}"
|
||||
state: present
|
||||
with_items:
|
||||
- python3-datanommer-commands
|
||||
when: inventory_hostname.startswith('noc01')
|
||||
tags:
|
||||
- packages
|
||||
- nagios_client
|
||||
|
||||
- name: Remove nagios tcp check for mirrorlist proxies
|
||||
ansible.builtin.package:
|
||||
name: nagios-plugins-tcp
|
||||
state: absent
|
||||
tags:
|
||||
- packages
|
||||
- nagios_client
|
||||
|
||||
- name: Remove local nrpe check scripts that are not packaged
|
||||
ansible.builtin.file:
|
||||
path: "{{ libdir }}/nagios/plugins"
|
||||
state: absent
|
||||
tags:
|
||||
- nagios_client
|
||||
|
||||
- name: Remove a directory exists for our custom selinux module
|
||||
ansible.builtin.file:
|
||||
path: /usr/share/nrpe
|
||||
state: absent
|
||||
tags:
|
||||
- config
|
||||
- nagios_client
|
||||
|
||||
- name: Remove /etc/nagios/nrpe.cfg
|
||||
ansible.builtin.file:
|
||||
path: /etc/nagios/nrpe.cfg
|
||||
state: absent
|
||||
tags:
|
||||
- config
|
||||
- nagios_client
|
||||
|
||||
- name: Remove nrpe client configs
|
||||
ansible.builtin.file:
|
||||
path: "/etc/nrpe.d"
|
||||
state: absent
|
||||
tags:
|
||||
- config
|
||||
- nagios_client
|
||||
|
|
@ -1 +0,0 @@
|
|||
command[check_celery_redis_queue]=/usr/lib64/nagios/plugins/check_redis_queue.sh celery 5 10
|
||||
|
|
@ -1,16 +0,0 @@
|
|||
# Raw DB Warn: 1d Crit: 2d
|
||||
command[check_countme_fedora_raw]={{ libdir }}/nagios/plugins/check_file_age -w 86400 -c 172800 -f /var/lib/countme/raw.db
|
||||
command[check_countme_centos_raw]={{ libdir }}/nagios/plugins/check_file_age -w 86400 -c 172800 -f /var/lib/countme/raw-centos.db
|
||||
|
||||
# Totals DB Warn: 7d Crit: 8d
|
||||
command[check_countme_fedora_tot]={{ libdir }}/nagios/plugins/check_file_age -w 604800 -c 691200 -f /var/lib/countme/totals.db
|
||||
command[check_countme_centos_tot]={{ libdir }}/nagios/plugins/check_file_age -w 604800 -c 691200 -f /var/lib/countme/totals-centos.db
|
||||
|
||||
# Web copied: Warn: 1d Crit: 2d
|
||||
# Web Generated: Warn: 7d Crit: 8d
|
||||
command[check_countme_fedora_web1]={{ libdir }}/nagios/plugins/check_file_age -w 86400 -c 172800 -f /var/www/html/csv-reports/countme/totals.db
|
||||
command[check_countme_centos_web1]={{ libdir }}/nagios/plugins/check_file_age -w 86400 -c 172800 -f /var/www/html/csv-reports/countme/totals-centos.db
|
||||
command[check_countme_fedora_web2]={{ libdir }}/nagios/plugins/check_file_age -w 604800 -c 691200 -f /var/www/html/csv-reports/countme/totals-countme.db.gz
|
||||
command[check_countme_centos_web2]={{ libdir }}/nagios/plugins/check_file_age -w 604800 -c 691200 -f /var/www/html/csv-reports/countme/totals-centos-countme.db.gz
|
||||
command[check_countme_fedora_web3]={{ libdir }}/nagios/plugins/check_file_age -w 604800 -c 691200 -f /var/www/html/csv-reports/countme/totals-unique.db.gz
|
||||
command[check_countme_centos_web3]={{ libdir }}/nagios/plugins/check_file_age -w 604800 -c 691200 -f /var/www/html/csv-reports/countme/totals-centos-unique.db.gz
|
||||
|
|
@ -1,4 +0,0 @@
|
|||
# Alert if CRL expires soon.
|
||||
# Usage is: /path/to/crl.pem <warn days> <crit days>
|
||||
# So here we warn at 7 days, crit at 2
|
||||
command[check_crl_next_update]={{ libdir }}/nagios/plugins/check_crl_next_update /etc/openvpn/server/crl.pem 7 2
|
||||
|
|
@ -1 +0,0 @@
|
|||
command[check_cron]={{ libdir }}/nagios/plugins/check_procs -c 1:15 -C 'crond' -u root
|
||||
|
|
@ -1,42 +0,0 @@
|
|||
# Checks on the datanommer history to make sure we're still receiving messages
|
||||
# of all types.
|
||||
#
|
||||
# The following are fedora messaging/datanommer checks.
|
||||
# They check for the time since the latest message in any particular category.
|
||||
# The first number is the seconds elapsed until we should raise a warning.
|
||||
# The second number is the seconds elapsed until we should raise an error.
|
||||
# For your reference:
|
||||
# 4 hours -> 14400
|
||||
# 1 day -> 86400
|
||||
# 3 days -> 259200
|
||||
# 1 week -> 604800
|
||||
# 3 weeks -> 1814400
|
||||
# 1 month -> 2628000
|
||||
# 3 months -> 7884000
|
||||
command[check_datanommer_anitya]={{libdir}}/nagios/plugins/check_datanommer_timesince.py anitya 604800 1814400
|
||||
command[check_datanommer_ansible]={{libdir}}/nagios/plugins/check_datanommer_timesince.py ansible 432000 604800
|
||||
command[check_datanommer_bodhi]={{libdir}}/nagios/plugins/check_datanommer_timesince.py bodhi 86400 604800
|
||||
command[check_datanommer_bodhi_composes]={{libdir}}/nagios/plugins/check_datanommer_timesince.py org.fedoraproject.prod.bodhi.compose.start 86400 90000
|
||||
command[check_datanommer_buildsys]={{libdir}}/nagios/plugins/check_datanommer_timesince.py buildsys 14400 86400
|
||||
command[check_datanommer_compose]={{libdir}}/nagios/plugins/check_datanommer_timesince.py compose 259200 1814400
|
||||
command[check_datanommer_copr]={{libdir}}/nagios/plugins/check_datanommer_timesince.py copr 21600 86400
|
||||
command[check_datanommer_fas]={{libdir}}/nagios/plugins/check_datanommer_timesince.py fas 1814400 2628000
|
||||
command[check_datanommer_badges]={{libdir}}/nagios/plugins/check_datanommer_timesince.py badges 86400 259200
|
||||
command[check_datanommer_fedocal]={{libdir}}/nagios/plugins/check_datanommer_timesince.py fedocal 7884000 23652000
|
||||
command[check_datanommer_fmn]={{libdir}}/nagios/plugins/check_datanommer_timesince.py fmn 604800 1814400
|
||||
command[check_datanommer_git]={{libdir}}/nagios/plugins/check_datanommer_timesince.py git 86400 604800
|
||||
command[check_datanommer_github]={{libdir}}/nagios/plugins/check_datanommer_timesince.py github 432000 604800
|
||||
command[check_datanommer_hotness]={{libdir}}/nagios/plugins/check_datanommer_timesince.py hotness 604800 1814400
|
||||
command[check_datanommer_kerneltest]={{libdir}}/nagios/plugins/check_datanommer_timesince.py kerneltest 604800 1814400
|
||||
command[check_datanommer_koschei]={{libdir}}/nagios/plugins/check_datanommer_timesince.py koschei 86400 604800
|
||||
command[check_datanommer_meetbot]={{libdir}}/nagios/plugins/check_datanommer_timesince.py meetbot 604800 2628000
|
||||
command[check_datanommer_pkgdb]={{libdir}}/nagios/plugins/check_datanommer_timesince.py pkgdb 1814400 2628000
|
||||
command[check_datanommer_planet]={{libdir}}/nagios/plugins/check_datanommer_timesince.py planet 2628000 7884000
|
||||
command[check_datanommer_resultsdb]=/usr/lib64/nagios/plugins/check_datanommer_timesince.py resultsdb 172800 172800
|
||||
command[check_datanommer_trac]={{libdir}}/nagios/plugins/check_datanommer_timesince.py trac 86400 259200
|
||||
command[check_datanommer_rpmsign]=/usr/lib64/nagios/plugins/check_datanommer_timesince.py org.fedoraproject.prod.buildsys.rpm.sign 10800 14400
|
||||
command[check_datanommer_wiki]={{libdir}}/nagios/plugins/check_datanommer_timesince.py wiki 259200 1814400
|
||||
|
||||
# These are not actually finished and deployed yet
|
||||
command[check_datanommer_mailman]={{libdir}}/nagios/plugins/check_datanommer_timesince.py mailman 14400 86400
|
||||
command[check_datanommer_bugzilla]={{libdir}}/nagios/plugins/check_datanommer_timesince.py bugzilla 86400 259200
|
||||
|
|
@ -1,23 +0,0 @@
|
|||
{% if inventory_hostname.startswith('openqa') %}
|
||||
command[check_disk_/]=/usr/lib64/nagios/plugins/check_disk -w 10% -c 5% -p /
|
||||
{% else %}
|
||||
command[check_disk_/]=/usr/lib64/nagios/plugins/check_disk -w 15% -c 10% -p /
|
||||
{% endif %}
|
||||
command[check_disk_/boot]=/usr/lib64/nagios/plugins/check_disk -w 20% -c 10% -p /boot
|
||||
command[check_disk_/git]=/usr/lib64/nagios/plugins/check_disk -w 20% -c 10% -p /git
|
||||
command[check_disk_/mnt/koji]=/usr/lib64/nagios/plugins/check_disk -w 10% -c 5% -p /mnt/koji
|
||||
command[check_disk_/postgreslogs]=/usr/lib64/nagios/plugins/check_disk -w 20% -c 10% -p /postgreslogs
|
||||
command[check_disk_/project/]=/usr/lib64/nagios/plugins/check_disk -w 5% -c 1% -p /project/
|
||||
command[check_disk_/srv]=/usr/lib64/nagios/plugins/check_disk -w 20% -c 10% -p /srv
|
||||
command[check_disk_huge_/srv]=/usr/lib64/nagios/plugins/check_disk -w 5% -c 1% -p /srv
|
||||
command[check_disk_/srv/buildmaster]=/usr/lib64/nagios/plugins/check_disk -w 20% -c 10% -p /srv/buildmaster
|
||||
command[check_disk_/srv/cache/lookaside]=/usr/lib64/nagios/plugins/check_disk -w 20% -c 10% -p /srv/cache/lookaside
|
||||
command[check_disk_/srv/diskimages]=/usr/lib64/nagios/plugins/check_disk -w 20% -c 10% -p /srv/diskimages
|
||||
command[check_disk_/srv/registry]=/usr/lib64/nagios/plugins/check_disk -w 20% -c 10% -p /srv/registry
|
||||
command[check_disk_/u01]=/usr/lib64/nagios/plugins/check_disk -w 15% -c 10% -p /u01
|
||||
command[check_disk_/var/lib/copr/public_html]=/usr/lib64/nagios/plugins/check_disk -w 8% -c 6% -K 10% -W 20% -p /var/lib/copr/public_html
|
||||
command[check_disk_/var/lib/dist-git]=/usr/lib64/nagios/plugins/check_disk -w 12% -c 6% -K 10% -W 20% -p /var/lib/dist-git -p /var/lib/copr-dist-git
|
||||
command[check_disk_/var/lib/copr-keygen]=/usr/lib64/nagios/plugins/check_disk -w 20% -c 10% -K 10% -W 20% -p /var/lib/copr-keygen
|
||||
command[check_disk_/srv/copr-fe]=/usr/lib64/nagios/plugins/check_disk -w 20% -c 10% -K 10% -W 20% -p /srv/copr-fe
|
||||
command[check_disk_/var/lib64/mock]=/usr/lib64/nagios/plugins/check_disk -w 20% -c 10% -p /var/lib/mock
|
||||
command[check_disk_/var/log]=/usr/lib64/nagios/plugins/check_disk -w 10% -c 5% -p /var/log
|
||||
|
|
@ -1,3 +0,0 @@
|
|||
command[check_fmn_worker_queue]={{ libdir }}/nagios/plugins/check_rabbitmq_size fmn.tasks.unprocessed_messages 5000 10000
|
||||
command[check_fmn_backend_irc_queue]={{ libdir }}/nagios/plugins/check_rabbitmq_size fmn.backends.irc 100 200
|
||||
command[check_fmn_backend_email_queue]={{ libdir }}/nagios/plugins/check_rabbitmq_size fmn.backends.email 100 200
|
||||
|
|
@ -1 +0,0 @@
|
|||
command[check_haproxy_conns]=/usr/lib64/nagios/plugins/check_haproxy_conns.py
|
||||
|
|
@ -1,2 +0,0 @@
|
|||
command[check_ipa_replication]={{ libdir }}/nagios/plugins/check_ipa_replication -u ldaps://localhost/
|
||||
command[check_ipa_free_ids]={{ libdir }}/nagios/plugins/check_ipa_free_ids.py -k /etc/krb5.monitoring_{{ ipa_server }}.keytab
|
||||
|
|
@ -1 +0,0 @@
|
|||
command[check_lock]={{ libdir }}/nagios/plugins/check_lock
|
||||
|
|
@ -1 +0,0 @@
|
|||
command[check_lock_file_age]={{ libdir }}/nagios/plugins/check_lock_file_age -w 1 -c 5 -f /var/lock/fedora-ca/lock
|
||||
|
|
@ -1 +0,0 @@
|
|||
command[check_mailman_api]=/usr/lib64/nagios/plugins/check_http -H localhost -p 8001 -u /3.0 -e 'HTTP/1.1 401 Unauthorized'
|
||||
|
|
@ -1,2 +0,0 @@
|
|||
command[check_memcache]=/usr/lib64/nagios/plugins/check_procs -c 1:1 -a '/usr/bin/memcached' -u memcached
|
||||
command[check_memcache_connect]=/usr/lib64/nagios/plugins/check_memcache_connect
|
||||
|
|
@ -1 +0,0 @@
|
|||
command[check_merged_file_age]=/usr/lib64/nagios/plugins/check_file_age -w 120 -c 300 /var/log/merged/messages.log
|
||||
|
|
@ -1,2 +0,0 @@
|
|||
command[check_mirrorlist1_cache]={{ libdir }}/nagios/plugins/check_file_age -w 14400 -c 129600 -f /srv/mirrorlist/data/mirrorlist1/mirrorlist_cache.proto
|
||||
command[check_mirrorlist2_cache]={{ libdir }}/nagios/plugins/check_file_age -w 14400 -c 129600 -f /srv/mirrorlist/data/mirrorlist2/mirrorlist_cache.proto
|
||||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue