summaryrefslogtreecommitdiffstats
path: root/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'plugins')
-rw-r--r--plugins/check_radius.c3
-rw-r--r--plugins/check_real.c3
-rw-r--r--plugins/check_smtp.c9
-rw-r--r--plugins/check_ssh.c4
-rw-r--r--plugins/check_swap.c100
-rw-r--r--plugins/check_tcp.c110
-rw-r--r--plugins/check_time.c2
-rw-r--r--plugins/check_ups.c5
-rw-r--r--plugins/check_users.c5
-rw-r--r--plugins/negate.c2
-rw-r--r--plugins/urlize.c46
11 files changed, 173 insertions, 116 deletions
diff --git a/plugins/check_radius.c b/plugins/check_radius.c
index 8ee6dd4f..6d42e1d3 100644
--- a/plugins/check_radius.c
+++ b/plugins/check_radius.c
@@ -11,6 +11,9 @@
11* 11*
12* This file contains the check_radius plugin 12* This file contains the check_radius plugin
13* 13*
14* Tests to see if a radius server is accepting connections.
15*
16*
14* License Information: 17* License Information:
15* 18*
16* This program is free software; you can redistribute it and/or modify 19* This program is free software; you can redistribute it and/or modify
diff --git a/plugins/check_real.c b/plugins/check_real.c
index 7922bfa9..17331f92 100644
--- a/plugins/check_real.c
+++ b/plugins/check_real.c
@@ -11,6 +11,9 @@
11* 11*
12* This file contains the check_real plugin 12* This file contains the check_real plugin
13* 13*
14* This plugin tests the REAL service on the specified host.
15*
16*
14* License Information: 17* License Information:
15* 18*
16* This program is free software; you can redistribute it and/or modify 19* This program is free software; you can redistribute it and/or modify
diff --git a/plugins/check_smtp.c b/plugins/check_smtp.c
index e4da30ed..ee6d0cb7 100644
--- a/plugins/check_smtp.c
+++ b/plugins/check_smtp.c
@@ -11,6 +11,9 @@
11* 11*
12* This file contains the check_smtp plugin 12* This file contains the check_smtp plugin
13* 13*
14* This plugin will attempt to open an SMTP connection with the host.
15*
16*
14* License Information: 17* License Information:
15* 18*
16* This program is free software; you can redistribute it and/or modify 19* This program is free software; you can redistribute it and/or modify
@@ -778,8 +781,8 @@ void
778print_usage (void) 781print_usage (void)
779{ 782{
780 printf (_("Usage:")); 783 printf (_("Usage:"));
781 printf ("%s -H host [-p port] [-e expect] [-C command] [-f from addr]\n\ 784 printf ("%s -H host [-p port] [-e expect] [-C command] [-f from addr]", progname);
782 [-A authtype -U authuser -P authpass]\n\ 785 printf ("[-A authtype -U authuser -P authpass] [-w warn] [-c crit] [-t timeout]\n");
783 [-w warn] [-c crit] [-t timeout] [-S] [-D days] [-n] [-v] [-4|-6]\n", progname); 786 printf ("[-S] [-D days] [-n] [-v] [-4|-6]\n");
784} 787}
785 788
diff --git a/plugins/check_ssh.c b/plugins/check_ssh.c
index ba31df09..ce4c0848 100644
--- a/plugins/check_ssh.c
+++ b/plugins/check_ssh.c
@@ -11,6 +11,10 @@
11* 11*
12* This file contains the check_ssh plugin 12* This file contains the check_ssh plugin
13* 13*
14*
15* Try to connect to an SSH server at specified server and port
16*
17*
14* License Information: 18* License Information:
15* 19*
16* This program is free software; you can redistribute it and/or modify 20* This program is free software; you can redistribute it and/or modify
diff --git a/plugins/check_swap.c b/plugins/check_swap.c
index fa989746..db8ebf95 100644
--- a/plugins/check_swap.c
+++ b/plugins/check_swap.c
@@ -1,33 +1,40 @@
1/****************************************************************************** 1/******************************************************************************
2 * 2*
3 * Program: Swap space plugin for Nagios 3* Nagios check_disk plugin
4 * License: GPL 4*
5 * 5* License: GPL
6 * License Information: 6* Copyright (c) 2000 Karl DeBisschop (kdebisschop@users.sourceforge.net)
7 * 7* Copyright (c) 2000-2006 nagios-plugins team
8 * This program is free software; you can redistribute it and/or modify 8*
9 * it under the terms of the GNU General Public License as published by 9* Last Modified: $Date$
10 * the Free Software Foundation; either version 2 of the License, or 10*
11 * (at your option) any later version. 11* Description:
12 * 12*
13 * This program is distributed in the hope that it will be useful, 13* This file contains the check_disk plugin
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of 14*
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15* License Information:
16 * GNU General Public License for more details. 16*
17 * 17* This program is free software; you can redistribute it and/or modify
18 * You should have received a copy of the GNU General Public License 18* it under the terms of the GNU General Public License as published by
19 * along with this program; if not, write to the Free Software 19* the Free Software Foundation; either version 2 of the License, or
20 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 20* (at your option) any later version.
21 * 21*
22 * Copyright (c) 2000 Karl DeBisschop (kdebisschop@users.sourceforge.net) 22* This program is distributed in the hope that it will be useful,
23 * 23* but WITHOUT ANY WARRANTY; without even the implied warranty of
24 * $Id$ 24* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
25 * 25* GNU General Public License for more details.
26 *****************************************************************************/ 26*
27* You should have received a copy of the GNU General Public License
28* along with this program; if not, write to the Free Software
29* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
30*
31* $Id$
32*
33*****************************************************************************/
27 34
28const char *progname = "check_swap"; 35const char *progname = "check_swap";
29const char *revision = "$Revision$"; 36const char *revision = "$Revision$";
30const char *copyright = "2000-2004"; 37const char *copyright = "2000-2006";
31const char *email = "nagiosplug-devel@lists.sourceforge.net"; 38const char *email = "nagiosplug-devel@lists.sourceforge.net";
32 39
33#include "common.h" 40#include "common.h"
@@ -491,28 +498,29 @@ print_help (void)
491 498
492 printf (_(COPYRIGHT), copyright, email); 499 printf (_(COPYRIGHT), copyright, email);
493 500
494 printf (_("Check swap space on local machine.\n\n")); 501 printf ("%s\n", _("Check swap space on local machine."));
495 502
503 printf ("\n\n");
504
496 print_usage (); 505 print_usage ();
497 506
498 printf (_(UT_HELP_VRSN)); 507 printf (_(UT_HELP_VRSN));
499 508
500 printf (_("\n\ 509 printf (" %s\n", "-w, --warning=INTEGER");
501 -w, --warning=INTEGER\n\ 510 printf (" %s\n", _("Exit with WARNING status if less than INTEGER bytes of swap space are free"));
502 Exit with WARNING status if less than INTEGER bytes of swap space are free\n\ 511 printf (" %s\n", "-w, --warning=PERCENT%%");
503 -w, --warning=PERCENT%%\n\ 512 printf (" %s\n", _("Exit with WARNING status if less than PERCENT of swap space is free"));
504 Exit with WARNING status if less than PERCENT of swap space is free\n\ 513 printf (" %s\n", "-c, --critical=INTEGER");
505 -c, --critical=INTEGER\n\ 514 printf (" %s\n", _("Exit with CRITICAL status if less than INTEGER bytes of swap space are free"));
506 Exit with CRITICAL status if less than INTEGER bytes of swap space are free\n\ 515 printf (" %s\n", "-c, --critical=PERCENT%%");
507 -c, --critical=PERCENT%%\n\ 516 printf (" %s\n", _("Exit with CRITCAL status if less than PERCENT of swap space is free"));
508 Exit with CRITCAL status if less than PERCENT of swap space is free\n\ 517 printf (" %s\n", "-a, --allswaps");
509 -a, --allswaps\n\ 518 printf (" %s\n", _("Conduct comparisons for all swap partitions, one by one"));
510 Conduct comparisons for all swap partitions, one by one\n\ 519 printf (" %s\n", "-v, --verbose");
511 -v, --verbose\n\ 520 printf (" %s\n", _("Verbose output. Up to 3 levels"));
512 Verbose output. Up to 3 levels\n")); 521 printf ("\n");
513 522 printf ("%s\n", _("Notes:"));
514 printf (_("\n\ 523 printf (" %s\n", _("On AIX, if -a is specified, uses lsps -a, otherwise uses lsps -s.\n"));
515On AIX, if -a is specified, uses lsps -a, otherwise uses lsps -s.\n"));
516 524
517 printf (_(UT_SUPPORT)); 525 printf (_(UT_SUPPORT));
518} 526}
@@ -522,7 +530,7 @@ On AIX, if -a is specified, uses lsps -a, otherwise uses lsps -s.\n"));
522void 530void
523print_usage (void) 531print_usage (void)
524{ 532{
525 printf ("\ 533 printf (_("Usage:"));
526Usage: %s [-av] -w <percent_free>%% -c <percent_free>%%\n\ 534 printf ("%s [-av] -w <percent_free>%% -c <percent_free>%%\n",progname);
527 %s [-av] -w <bytes_free> -c <bytes_free>\n", progname, progname); 535 printf ("%s [-av] -w <bytes_free> -c <bytes_free>\n", progname);
528} 536}
diff --git a/plugins/check_tcp.c b/plugins/check_tcp.c
index bbb8d111..00105f9f 100644
--- a/plugins/check_tcp.c
+++ b/plugins/check_tcp.c
@@ -1,27 +1,40 @@
1/***************************************************************************** 1/*****************************************************************************
2 2*
3 This program is free software; you can redistribute it and/or modify 3* Nagios check_tcp plugin
4 it under the terms of the GNU General Public License as published by 4*
5 the Free Software Foundation; either version 2 of the License, or 5* License: GPL
6 (at your option) any later version. 6* Copyright (c) 1999-2006 nagios-plugins team
7 7*
8 This program is distributed in the hope that it will be useful, 8* Last Modified: $Date$
9 but WITHOUT ANY WARRANTY; without even the implied warranty of 9*
10 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 10* Description:
11 GNU General Public License for more details. 11*
12 12* This file contains the check_tcp plugin
13 You should have received a copy of the GNU General Public License 13*
14 along with this program; if not, write to the Free Software 14* License Information:
15 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 15*
16 16* This program is free software; you can redistribute it and/or modify
17 $Id$ 17* it under the terms of the GNU General Public License as published by
18 18* the Free Software Foundation; either version 2 of the License, or
19* (at your option) any later version.
20*
21* This program is distributed in the hope that it will be useful,
22* but WITHOUT ANY WARRANTY; without even the implied warranty of
23* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
24* GNU General Public License for more details.
25*
26* You should have received a copy of the GNU General Public License
27* along with this program; if not, write to the Free Software
28* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
29*
30* $Id$
31*
19*****************************************************************************/ 32*****************************************************************************/
20 33
21/* progname "check_tcp" changes depending on symlink called */ 34/* progname "check_tcp" changes depending on symlink called */
22char *progname; 35char *progname;
23const char *revision = "$Revision$"; 36const char *revision = "$Revision$";
24const char *copyright = "1999-2004"; 37const char *copyright = "1999-2006";
25const char *email = "nagiosplug-devel@lists.sourceforge.net"; 38const char *email = "nagiosplug-devel@lists.sourceforge.net";
26 39
27#include "common.h" 40#include "common.h"
@@ -589,35 +602,31 @@ print_help (void)
589 602
590 printf (_(UT_IPv46)); 603 printf (_(UT_IPv46));
591 604
592 printf (_("\ 605 printf (" %s\n", "-E, --escape");
593 -E, --escape\n\ 606 printf (" %s\n", _("Can use \\n, \\r, \\t or \\ in send or quit string."));
594 Can use \\n, \\r, \\t or \\ in send or quit string.\n\ 607 printf (" %s\n", _("Default: nothing added to send, \\r\\n added to end of quit"));
595 Default: nothing added to send, \\r\\n added to end of quit\n\ 608 printf (" %s\n", "-s, --send=STRING");
596 -s, --send=STRING\n\ 609 printf (" %s\n", _("String to send to the server"));
597 String to send to the server\n\ 610 printf (" %s\n", "-e, --expect=STRING");
598 -e, --expect=STRING\n\ 611 printf (" %s\n", _("String to expect in server response"));
599 String to expect in server response\n\ 612 printf (" %s\n", "-q, --quit=STRING");
600 -q, --quit=STRING\n\ 613 printf (" %s\n", _("String to send server to initiate a clean close of the connection"));
601 String to send server to initiate a clean close of the connection\n")); 614 printf (" %s\n", "-r, --refuse=ok|warn|crit");
602 615 printf (" %s\n", _("Accept tcp refusals with states ok, warn, crit (default: crit)"));
603 printf (_("\ 616 printf (" %s\n", "-M, --mismatch=ok|warn|crit");
604 -r, --refuse=ok|warn|crit\n\ 617 printf (" %s\n", _("Accept expected string mismatches with states ok, warn, crit (default: warn)"));
605 Accept tcp refusals with states ok, warn, crit (default: crit)\n\ 618 printf (" %s\n", "-j, --jail");
606 -M, --mismatch=ok|warn|crit\n\ 619 printf (" %s\n", _("Hide output from TCP socket"));
607 Accept expected string mismatches with states ok, warn, crit (default: warn)\n\ 620 printf (" %s\n", "-m, --maxbytes=INTEGER");
608 -j, --jail\n\ 621 printf (" %s\n", _("Close connection once more than this number of bytes are received"));
609 Hide output from TCP socket\n\ 622 printf (" %s\n", "-d, --delay=INTEGER");
610 -m, --maxbytes=INTEGER\n\ 623 printf (" %s\n", _("Seconds to wait between sending string and polling for response"));
611 Close connection once more than this number of bytes are received\n\
612 -d, --delay=INTEGER\n\
613 Seconds to wait between sending string and polling for response\n"));
614 624
615#ifdef HAVE_SSL 625#ifdef HAVE_SSL
616 printf (_("\ 626 printf (" %s\n", "-D, --certificate=INTEGER");
617 -D, --certificate=INTEGER\n\ 627 printf (" %s\n", _("Minimum number of days a certificate has to be valid."));
618 Minimum number of days a certificate has to be valid.\n\ 628 printf (" %s\n", "-S, --ssl");
619 -S, --ssl\n\ 629 printf (" %s\n", _("Use SSL for the connection."));
620 Use SSL for the connection.\n"));
621#endif 630#endif
622 631
623 printf (_(UT_WARN_CRIT)); 632 printf (_(UT_WARN_CRIT));
@@ -633,11 +642,10 @@ print_help (void)
633void 642void
634print_usage (void) 643print_usage (void)
635{ 644{
636 printf ("\ 645 printf (_("Usage:"));
637Usage: %s -H host -p port [-w <warning time>] [-c <critical time>]\n\ 646 printf ("%s -H host -p port [-w <warning time>] [-c <critical time>] [-s <send string>]\n",progname);
638 [-s <send string>] [-e <expect string>] [-q <quit string>]\n\ 647 printf ("[-e <expect string>] [-q <quit string>][-m <maximum bytes>] [-d <delay>]\n");
639 [-m <maximum bytes>] [-d <delay>] [-t <timeout seconds>]\n\ 648 printf ("[-t <timeout seconds>] [-r <refuse state>] [-M <mismatch state>] [-v] [-4|-6] [-j]\n");
640 [-r <refuse state>] [-M <mismatch state>] [-v] [-4|-6] [-j]\n\ 649 printf ("[-D <days to cert expiry>] [-S <use SSL>] [-E]\n");
641 [-D <days to cert expiry>] [-S <use SSL>] [-E]\n", progname);
642} 650}
643 651
diff --git a/plugins/check_time.c b/plugins/check_time.c
index 84cdcd53..ca420566 100644
--- a/plugins/check_time.c
+++ b/plugins/check_time.c
@@ -11,6 +11,8 @@
11* 11*
12* This file contains the check_time plugin 12* This file contains the check_time plugin
13* 13*
14* This plugin will check the time on the specified host.
15*
14* License Information: 16* License Information:
15* 17*
16* This program is free software; you can redistribute it and/or modify 18* This program is free software; you can redistribute it and/or modify
diff --git a/plugins/check_ups.c b/plugins/check_ups.c
index 110ea0a2..280b3fb6 100644
--- a/plugins/check_ups.c
+++ b/plugins/check_ups.c
@@ -14,6 +14,9 @@
14* 14*
15* This file contains Network UPS Tools plugin for Nagios 15* This file contains Network UPS Tools plugin for Nagios
16* 16*
17* This plugin tests the UPS service on the specified host.Network UPS Tools
18* from www.networkupstools.org must be running for thisplugin to work.
19*
17* License Information: 20* License Information:
18* 21*
19* This program is free software; you can redistribute it and/or modify 22* This program is free software; you can redistribute it and/or modify
@@ -36,7 +39,7 @@
36 39
37const char *progname = "check_ups"; 40const char *progname = "check_ups";
38const char *revision = "$Revision$"; 41const char *revision = "$Revision$";
39const char *copyright = "2000-2006"; 42const char *copyright = "2002-2006";
40const char *email = "nagiosplug-devel@lists.sourceforge.net"; 43const char *email = "nagiosplug-devel@lists.sourceforge.net";
41 44
42#include "common.h" 45#include "common.h"
diff --git a/plugins/check_users.c b/plugins/check_users.c
index 34d47752..0c62e3b1 100644
--- a/plugins/check_users.c
+++ b/plugins/check_users.c
@@ -3,7 +3,7 @@
3* Nagios check_users plugin 3* Nagios check_users plugin
4* 4*
5* License: GPL 5* License: GPL
6* Copyright (c) 2002-2006 nagios-plugins team 6* Copyright (c) 2000-2006 nagios-plugins team
7* 7*
8* Last Modified: $Date$ 8* Last Modified: $Date$
9* 9*
@@ -11,6 +11,9 @@
11* 11*
12* This file contains the check_users plugin 12* This file contains the check_users plugin
13* 13*
14* This plugin checks the number of users currently logged in on the local
15* system and generates an error if the number exceeds the thresholds specified.
16*
14* License Information: 17* License Information:
15* 18*
16* This program is free software; you can redistribute it and/or modify 19* This program is free software; you can redistribute it and/or modify
diff --git a/plugins/negate.c b/plugins/negate.c
index 76bb6bbb..45c03269 100644
--- a/plugins/negate.c
+++ b/plugins/negate.c
@@ -11,6 +11,8 @@
11* 11*
12* This file contains the negate plugin 12* This file contains the negate plugin
13* 13*
14* Negates the status of a plugin (returns OK for CRITICAL, and vice-versa)
15*
14* License Information: 16* License Information:
15* 17*
16* This program is free software; you can redistribute it and/or modify 18* This program is free software; you can redistribute it and/or modify
diff --git a/plugins/urlize.c b/plugins/urlize.c
index 5bff4b2f..7793e9a8 100644
--- a/plugins/urlize.c
+++ b/plugins/urlize.c
@@ -1,18 +1,36 @@
1/****************************************************************************** 1/******************************************************************************
2 2*
3 This program is free software; you can redistribute it and/or modify 3* Nagios urlize plugin
4 it under the terms of the GNU General Public License as published by 4*
5 the Free Software Foundation; either version 2 of the License, or 5* License: GPL
6 (at your option) any later version. 6* Copyright (c) 2000-2006 nagios-plugins team
7 7*
8 This program is distributed in the hope that it will be useful, 8* Last Modified: $Date$
9 but WITHOUT ANY WARRANTY; without even the implied warranty of 9*
10 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 10* Description:
11 GNU General Public License for more details. 11*
12 12* This file contains the urlize plugin
13 You should have received a copy of the GNU General Public License 13*
14 along with this program; if not, write to the Free Software 14* This plugin wraps the text output of another command (plugin)
15 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 15* in HTML <A> tags, thus displaying the plugin output in as a clickable link in
16* the Nagios status screen. The return status is the same as the invoked plugin.
17*
18* License Information:
19*
20* This program is free software; you can redistribute it and/or modify
21* it under the terms of the GNU General Public License as published by
22* the Free Software Foundation; either version 2 of the License, or
23* (at your option) any later version.
24*
25* This program is distributed in the hope that it will be useful,
26* but WITHOUT ANY WARRANTY; without even the implied warranty of
27* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
28* GNU General Public License for more details.
29*
30* You should have received a copy of the GNU General Public License
31* along with this program; if not, write to the Free Software
32* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
33*
16 34
17 $Id$ 35 $Id$
18 36