From 6db35a5230578e296d9f493b28e6330e22569c8f Mon Sep 17 00:00:00 2001 From: "Suren A. Chilingaryan" Date: Wed, 4 Sep 2019 22:06:01 +0200 Subject: Integrate also nagios-based monitoring here --- nagios/check_ | 6 ++++++ nagios/check_adei | 6 ++++++ nagios/check_adei_control | 1 + nagios/check_adei_source | 1 + nagios/check_adei_status | 1 + nagios/check_by_ssh | 12 ++++++++++++ nagios/check_mysql | 1 + nagios/check_ntp | 1 + nagios/check_ntp_win | 1 + nagios/check_ping | 1 + nagios/lib | 1 + nagios/scripts | 1 + nagios/security | 1 + nagios/setup | 1 + 14 files changed, 35 insertions(+) create mode 100755 nagios/check_ create mode 100755 nagios/check_adei create mode 120000 nagios/check_adei_control create mode 120000 nagios/check_adei_source create mode 120000 nagios/check_adei_status create mode 100755 nagios/check_by_ssh create mode 120000 nagios/check_mysql create mode 120000 nagios/check_ntp create mode 120000 nagios/check_ntp_win create mode 120000 nagios/check_ping create mode 120000 nagios/lib create mode 120000 nagios/scripts create mode 120000 nagios/security create mode 120000 nagios/setup (limited to 'nagios') diff --git a/nagios/check_ b/nagios/check_ new file mode 100755 index 0000000..839e9c1 --- /dev/null +++ b/nagios/check_ @@ -0,0 +1,6 @@ +#! /bin/bash + +. $(dirname $0)/lib/nagios/nagios.sh + +nagios_run "$@" + diff --git a/nagios/check_adei b/nagios/check_adei new file mode 100755 index 0000000..ba0a34f --- /dev/null +++ b/nagios/check_adei @@ -0,0 +1,6 @@ +#!/bin/bash + +. $(dirname $0)/lib/nagios/nagios.sh + +[ -n "$debug" ] && echo "$(date) adei/$(basename $0).sh" "$@" >> /tmp/nagios.log +nagios_parse "adei/$(basename $0).sh" "$@" diff --git a/nagios/check_adei_control b/nagios/check_adei_control new file mode 120000 index 0000000..c07768e --- /dev/null +++ b/nagios/check_adei_control @@ -0,0 +1 @@ +check_adei \ No newline at end of file diff --git a/nagios/check_adei_source b/nagios/check_adei_source new file mode 120000 index 0000000..c07768e --- /dev/null +++ b/nagios/check_adei_source @@ -0,0 +1 @@ +check_adei \ No newline at end of file diff --git a/nagios/check_adei_status b/nagios/check_adei_status new file mode 120000 index 0000000..c07768e --- /dev/null +++ b/nagios/check_adei_status @@ -0,0 +1 @@ +check_adei \ No newline at end of file diff --git a/nagios/check_by_ssh b/nagios/check_by_ssh new file mode 100755 index 0000000..1a488b2 --- /dev/null +++ b/nagios/check_by_ssh @@ -0,0 +1,12 @@ +#! /bin/bash + +. $(dirname $0)/lib/nagios/nagios.sh + + +port=$(nagios_find_host_param "ssh_ports" 22 "$@") +user=$(nagios_find_host_param "ssh_users" root "$@") + +local port=$(cat setup/ssh_ports.txt | grep -P "^$host" | awk '{ print $2 }') + +#echo "$@" -o " -p $port -l $user UserKnownHostsFile=/dev/null" -o "StrictHostKeyChecking=no" >> /tmp/xxx +nagios_run "$@" -p $port -l $user -o "UserKnownHostsFile=/dev/null" -o "StrictHostKeyChecking=no" diff --git a/nagios/check_mysql b/nagios/check_mysql new file mode 120000 index 0000000..74fe9a3 --- /dev/null +++ b/nagios/check_mysql @@ -0,0 +1 @@ +check_ \ No newline at end of file diff --git a/nagios/check_ntp b/nagios/check_ntp new file mode 120000 index 0000000..74fe9a3 --- /dev/null +++ b/nagios/check_ntp @@ -0,0 +1 @@ +check_ \ No newline at end of file diff --git a/nagios/check_ntp_win b/nagios/check_ntp_win new file mode 120000 index 0000000..74fe9a3 --- /dev/null +++ b/nagios/check_ntp_win @@ -0,0 +1 @@ +check_ \ No newline at end of file diff --git a/nagios/check_ping b/nagios/check_ping new file mode 120000 index 0000000..74fe9a3 --- /dev/null +++ b/nagios/check_ping @@ -0,0 +1 @@ +check_ \ No newline at end of file diff --git a/nagios/lib b/nagios/lib new file mode 120000 index 0000000..5bf80bf --- /dev/null +++ b/nagios/lib @@ -0,0 +1 @@ +../lib/ \ No newline at end of file diff --git a/nagios/scripts b/nagios/scripts new file mode 120000 index 0000000..adb0a1d --- /dev/null +++ b/nagios/scripts @@ -0,0 +1 @@ +../scripts/ \ No newline at end of file diff --git a/nagios/security b/nagios/security new file mode 120000 index 0000000..9ab7f9c --- /dev/null +++ b/nagios/security @@ -0,0 +1 @@ +../security/ \ No newline at end of file diff --git a/nagios/setup b/nagios/setup new file mode 120000 index 0000000..f4c6f52 --- /dev/null +++ b/nagios/setup @@ -0,0 +1 @@ +../setup/ \ No newline at end of file -- cgit v1.2.3