-Plugin Location Comment
---------------------------------------------------------------
-check_backup.pl hadeb07 checks backup on hadeb07.
- Runs status server to report
- status to Nagios.
+Plugin Location Comment
+--------------------------------------------------------------------
+check_backup.pl hadeb07 Remote script. Checks backup
+ on hadeb07. Runs status server
+ to report status to Nagios.
-check_archiver.pl lxg0434 checks archiving process of
- slow ctrl data to Oracle.
- Runs status server to report
- status to Nagios.
+check_archiver.pl lxg0434 Remote script. Checks archiving
+ process of slow ctrl data to
+ Oracle. Runs status server to
+ report status to Nagios.
-check_archivist.pl hadesdaq run by Nagios to check
- hades_archivist via
- TCP socket connection.
+check_archivist.pl hadesdaq Run by Nagios to check
+ hades_archivist via
+ TCP socket connection.
-check_lustre.pl lxhadesdaq checks Lustre mount. Checks
- used disk space on Lustre.
- Runs status server to report
- status to Nagios.
+check_lustre.pl lxhadesdaq Remote script. Checks Lustre
+ mount. Checks used disk space
+ on Lustre. Runs status server
+ to report status to Nagios.
-my_check_eblog.pl lxhadesdaq checks discarded events in
- eb_s.tcl written by EB.
- Runs status server to report
- status to Nagios.
+my_check_eblog.pl lxhadesdaq Remote script. Checks discarded
+ events in eb_s.tcl written by EB.
+ Runs status server to report
+ status to Nagios.
-my_check_proc_status.pl hadesdaq run by Nagios to receive
- status report from remote
- scripts.
+my_check_proc_status.pl hadesdaq Run by Nagios to receive
+ status report from remote
+ scripts.
-restart.pl restarts a program (daemon)
- given as an argument on a list
- of remote machines. For example
- used to restart check_lustre.pl
+my_check_dhcp.pl hadesdaq Run by Nagios. Checks if dhcp
+ daemon is running.
+
+restart.pl Restarts a program (daemon)
+ given as an argument on a list
+ of remote machines. For example
+ used to restart check_lustre.pl
#!/usr/bin/perl -w
-# ----------------------------------------------------------------------------
+# ------------------------------------------------------------------------------
# File Name: my_check_process.pl
# Author: Sergey Yurevich
# Date: 05/04/2007
# Version: 0.1
# Description: script will check if there is a process running
-# ----------------------------------------------------------------------------
+# ------------------------------------------------------------------------------
use strict;
use warnings;
#dhcping - check dhcp service
#-c 140.181.67.143 - from hadesdaq (140.181.67.143)
#-s 140.181.75.158 - on lxhadesdaq (140.181.75.158)
-#-h 00:40:9E:00:99:E2 - if one gets an answer from MAC address (00:40:9E:00:99:E2)
+#-h 00:30:48:58:c0:88 - if one gets an answer from MAC (hadeb06)
+# used to be MAC of hadc02 (00:40:9E:00:99:E2)
-my $answer = `dhcping -c 140.181.67.143 -s $ip -h 00:40:9E:00:99:E2`;
+my $answer = `dhcping -c 140.181.67.143 -s $ip -h 00:30:48:58:c0:88`;
chop($answer);
+#print "pids = $pids\n";
+#my @pid_list = split(' ',$pids);
+
my $state;
if($answer =~/Got answer from/){
+ #nagios exit code 0 = status OK = green
$state = $ERRORS{'OK'};
}
else{
+ #nagios exit code 2 = status CRITICAL = red
$state = $ERRORS{'CRITICAL'};
}
&checkArgs();
#--- on these PCs the script should be restarted:
-my @PCList = ('lxg0429','lxg0433','lxg0435','lxg0437','lxg0439','lxg0440','lxg0441','lxg0442','lxg0443','lxg0444','lxg0445','lxg0446','lxg0447','lxg0448','lxg0452','lxg0453','lxg0454','lxg0455');
-#my @PCList = ('lxg0447');
+#my @PCList = ('lxg0429','lxg0433','lxg0435','lxg0437','lxg0439','lxg0440','lxg0441','lxg0442','lxg0443','lxg0444','lxg0445','lxg0446','lxg0447','lxg0448','lxg0452','lxg0453','lxg0454','lxg0455');
+my @PCList = ('lxg0429');
my $args = "-d"; #- arguments of script to be restarted
&main();