diff options
| author | Thomas Guyot-Sionnest <dermoth@users.sourceforge.net> | 2008-04-27 14:35:26 +0000 |
|---|---|---|
| committer | Thomas Guyot-Sionnest <dermoth@users.sourceforge.net> | 2008-04-27 14:35:26 +0000 |
| commit | ed62784a0b68959fd13fe5bc53a5aef4f17fbffa (patch) | |
| tree | f479a5b8ad8cac8d6dcc506ba61aa5ec3fbb5bb3 /plugins | |
| parent | 140a93ce6bce63df2d70841f2f78aa968ea997d6 (diff) | |
| download | monitoring-plugins-ed62784a0b68959fd13fe5bc53a5aef4f17fbffa.tar.gz | |
--help output cleanup (plus removal of spaces on blank lines)
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1984 f882894a-f735-0410-b71e-b25c423dba1c
Diffstat (limited to 'plugins')
33 files changed, 184 insertions, 159 deletions
diff --git a/plugins/check_apt.c b/plugins/check_apt.c index 02653933..bd59c706 100644 --- a/plugins/check_apt.c +++ b/plugins/check_apt.c | |||
| @@ -3,7 +3,7 @@ | |||
| 3 | * Nagios check_apt plugin | 3 | * Nagios check_apt plugin |
| 4 | * | 4 | * |
| 5 | * License: GPL | 5 | * License: GPL |
| 6 | * Copyright (c) 2006-2007 Nagios Plugins Development Team | 6 | * Copyright (c) 2006-2008 Nagios Plugins Development Team |
| 7 | * | 7 | * |
| 8 | * Original author: Sean Finney | 8 | * Original author: Sean Finney |
| 9 | * | 9 | * |
| @@ -35,7 +35,7 @@ | |||
| 35 | 35 | ||
| 36 | const char *progname = "check_apt"; | 36 | const char *progname = "check_apt"; |
| 37 | const char *revision = "$Revision$"; | 37 | const char *revision = "$Revision$"; |
| 38 | const char *copyright = "2006-2007"; | 38 | const char *copyright = "2006-2008"; |
| 39 | const char *email = "nagiosplug-devel@lists.sourceforge.net"; | 39 | const char *email = "nagiosplug-devel@lists.sourceforge.net"; |
| 40 | 40 | ||
| 41 | #include "common.h" | 41 | #include "common.h" |
| @@ -402,9 +402,9 @@ void | |||
| 402 | print_help (void) | 402 | print_help (void) |
| 403 | { | 403 | { |
| 404 | print_revision(progname, revision); | 404 | print_revision(progname, revision); |
| 405 | 405 | ||
| 406 | printf(_(COPYRIGHT), copyright, email); | 406 | printf(_(COPYRIGHT), copyright, email); |
| 407 | 407 | ||
| 408 | printf("%s\n", _("This plugin checks for software updates on systems that use")); | 408 | printf("%s\n", _("This plugin checks for software updates on systems that use")); |
| 409 | printf("%s\n", _("package management systems based on the apt-get(8) command")); | 409 | printf("%s\n", _("package management systems based on the apt-get(8) command")); |
| 410 | printf("%s\n", _("found in Debian GNU/Linux")); | 410 | printf("%s\n", _("found in Debian GNU/Linux")); |
| @@ -412,11 +412,11 @@ print_help (void) | |||
| 412 | printf ("\n\n"); | 412 | printf ("\n\n"); |
| 413 | 413 | ||
| 414 | print_usage(); | 414 | print_usage(); |
| 415 | 415 | ||
| 416 | printf(_(UT_HELP_VRSN)); | 416 | printf(_(UT_HELP_VRSN)); |
| 417 | 417 | ||
| 418 | printf(_(UT_TIMEOUT), timeout_interval); | 418 | printf(_(UT_TIMEOUT), timeout_interval); |
| 419 | 419 | ||
| 420 | printf (" %s\n", "-U, --upgrade=OPTS"); | 420 | printf (" %s\n", "-U, --upgrade=OPTS"); |
| 421 | printf (" %s\n", _("[Default] Perform an upgrade. If an optional OPTS argument is provided,")); | 421 | printf (" %s\n", _("[Default] Perform an upgrade. If an optional OPTS argument is provided,")); |
| 422 | printf (" %s\n", _("apt-get will be run with these command line options instead of the")); | 422 | printf (" %s\n", _("apt-get will be run with these command line options instead of the")); |
| @@ -445,17 +445,19 @@ print_help (void) | |||
| 445 | printf (" %s\n", _("upgrades for Debian and Ubuntu:")); | 445 | printf (" %s\n", _("upgrades for Debian and Ubuntu:")); |
| 446 | printf (" \t\%s\n", SECURITY_RE); | 446 | printf (" \t\%s\n", SECURITY_RE); |
| 447 | printf (" %s\n", _("Note that the package must first match the include list before its")); | 447 | printf (" %s\n", _("Note that the package must first match the include list before its")); |
| 448 | printf (" %s\n\n\n", _("information is compared against the critical list.")); | 448 | printf (" %s\n\n", _("information is compared against the critical list.")); |
| 449 | 449 | ||
| 450 | printf ("%s\n\n", _("The following options require root privileges and should be used with care:")); | 450 | printf ("%s\n\n", _("The following options require root privileges and should be used with care:")); |
| 451 | printf (" %s\n", "-u, --update=OPTS"); | 451 | printf (" %s\n", "-u, --update=OPTS"); |
| 452 | printf (" %s\n", _("First perform an 'apt-get update'. An optional OPTS parameter overrides")); | 452 | printf (" %s\n", _("First perform an 'apt-get update'. An optional OPTS parameter overrides")); |
| 453 | printf (" %s\n", _("the default options. Note: you may also need to adjust the global")); | 453 | printf (" %s\n", _("the default options. Note: you may also need to adjust the global")); |
| 454 | printf (" %s\n", _("timeout (with -t) to prevent the plugin from timing out if apt-get")); | 454 | printf (" %s\n", _("timeout (with -t) to prevent the plugin from timing out if apt-get")); |
| 455 | printf (" %s\n", _("upgrade is expected to take longer than the default timeout.")); | 455 | printf (" %s\n", _("upgrade is expected to take longer than the default timeout.")); |
| 456 | |||
| 457 | printf(_(UT_SUPPORT)); | ||
| 456 | } | 458 | } |
| 457 | 459 | ||
| 458 | 460 | ||
| 459 | /* simple usage heading */ | 461 | /* simple usage heading */ |
| 460 | void | 462 | void |
| 461 | print_usage(void) | 463 | print_usage(void) |
diff --git a/plugins/check_by_ssh.c b/plugins/check_by_ssh.c index 9b38506f..37874bf8 100644 --- a/plugins/check_by_ssh.c +++ b/plugins/check_by_ssh.c | |||
| @@ -3,7 +3,7 @@ | |||
| 3 | * Nagios check_by_ssh plugin | 3 | * Nagios check_by_ssh plugin |
| 4 | * | 4 | * |
| 5 | * License: GPL | 5 | * License: GPL |
| 6 | * Copyright (c) 2000-2007 Nagios Plugins Development Team | 6 | * Copyright (c) 2000-2008 Nagios Plugins Development Team |
| 7 | * | 7 | * |
| 8 | * Last Modified: $Date$ | 8 | * Last Modified: $Date$ |
| 9 | * | 9 | * |
| @@ -28,10 +28,10 @@ | |||
| 28 | * $Id$ | 28 | * $Id$ |
| 29 | * | 29 | * |
| 30 | *****************************************************************************/ | 30 | *****************************************************************************/ |
| 31 | 31 | ||
| 32 | const char *progname = "check_by_ssh"; | 32 | const char *progname = "check_by_ssh"; |
| 33 | const char *revision = "$Revision$"; | 33 | const char *revision = "$Revision$"; |
| 34 | const char *copyright = "2000-2007"; | 34 | const char *copyright = "2000-2008"; |
| 35 | const char *email = "nagiosplug-devel@lists.sourceforge.net"; | 35 | const char *email = "nagiosplug-devel@lists.sourceforge.net"; |
| 36 | 36 | ||
| 37 | #include "common.h" | 37 | #include "common.h" |
| @@ -345,7 +345,7 @@ print_help (void) | |||
| 345 | printf (_("This plugin uses SSH to execute commands on a remote host")); | 345 | printf (_("This plugin uses SSH to execute commands on a remote host")); |
| 346 | 346 | ||
| 347 | printf ("\n\n"); | 347 | printf ("\n\n"); |
| 348 | 348 | ||
| 349 | print_usage (); | 349 | print_usage (); |
| 350 | 350 | ||
| 351 | printf (_(UT_HELP_VRSN)); | 351 | printf (_(UT_HELP_VRSN)); |
| @@ -382,6 +382,8 @@ print_help (void) | |||
| 382 | printf (" %s\n", _("Tell ssh to suppress warning and diagnostic messages [optional]")); | 382 | printf (" %s\n", _("Tell ssh to suppress warning and diagnostic messages [optional]")); |
| 383 | printf (_(UT_WARN_CRIT)); | 383 | printf (_(UT_WARN_CRIT)); |
| 384 | printf (_(UT_TIMEOUT), DEFAULT_SOCKET_TIMEOUT); | 384 | printf (_(UT_TIMEOUT), DEFAULT_SOCKET_TIMEOUT); |
| 385 | printf (_(UT_VERBOSE)); | ||
| 386 | printf("\n"); | ||
| 385 | printf (" %s\n", _("The most common mode of use is to refer to a local identity file with")); | 387 | printf (" %s\n", _("The most common mode of use is to refer to a local identity file with")); |
| 386 | printf (" %s\n", _("the '-i' option. In this mode, the identity pair should have a null")); | 388 | printf (" %s\n", _("the '-i' option. In this mode, the identity pair should have a null")); |
| 387 | printf (" %s\n", _("passphrase and the public key should be listed in the authorized_keys")); | 389 | printf (" %s\n", _("passphrase and the public key should be listed in the authorized_keys")); |
| @@ -389,6 +391,7 @@ print_help (void) | |||
| 389 | printf (" %s\n", _("only one command on the remote server. If the remote SSH server tracks")); | 391 | printf (" %s\n", _("only one command on the remote server. If the remote SSH server tracks")); |
| 390 | printf (" %s\n", _("invocation arguments, the one remote program may be an agent that can")); | 392 | printf (" %s\n", _("invocation arguments, the one remote program may be an agent that can")); |
| 391 | printf (" %s\n", _("execute additional commands as proxy")); | 393 | printf (" %s\n", _("execute additional commands as proxy")); |
| 394 | printf("\n"); | ||
| 392 | printf (" %s\n", _("To use passive mode, provide multiple '-C' options, and provide")); | 395 | printf (" %s\n", _("To use passive mode, provide multiple '-C' options, and provide")); |
| 393 | printf (" %s\n", _("all of -O, -s, and -n options (servicelist order must match '-C'options)")); | 396 | printf (" %s\n", _("all of -O, -s, and -n options (servicelist order must match '-C'options)")); |
| 394 | printf ("\n"); | 397 | printf ("\n"); |
| @@ -398,8 +401,8 @@ print_help (void) | |||
| 398 | printf (" %s\n", "[1080933700] PROCESS_SERVICE_CHECK_RESULT;flint;c1;0; up 2 days"); | 401 | printf (" %s\n", "[1080933700] PROCESS_SERVICE_CHECK_RESULT;flint;c1;0; up 2 days"); |
| 399 | printf (" %s\n", "[1080933700] PROCESS_SERVICE_CHECK_RESULT;flint;c2;0; up 2 days"); | 402 | printf (" %s\n", "[1080933700] PROCESS_SERVICE_CHECK_RESULT;flint;c2;0; up 2 days"); |
| 400 | printf (" %s\n", "[1080933700] PROCESS_SERVICE_CHECK_RESULT;flint;c3;0; up 2 days"); | 403 | printf (" %s\n", "[1080933700] PROCESS_SERVICE_CHECK_RESULT;flint;c3;0; up 2 days"); |
| 401 | printf (_(UT_VERBOSE)); | 404 | |
| 402 | printf (_(UT_SUPPORT)); | 405 | printf(_(UT_SUPPORT)); |
| 403 | } | 406 | } |
| 404 | 407 | ||
| 405 | 408 | ||
diff --git a/plugins/check_cluster.c b/plugins/check_cluster.c index c67573a3..ac3eeceb 100644 --- a/plugins/check_cluster.c +++ b/plugins/check_cluster.c | |||
| @@ -256,12 +256,9 @@ print_help(void) | |||
| 256 | 256 | ||
| 257 | printf("\n"); | 257 | printf("\n"); |
| 258 | printf("%s\n", _("Notes:")); | 258 | printf("%s\n", _("Notes:")); |
| 259 | printf(" %s\n", _("See:")); | 259 | printf(_(UT_THRESHOLDS_NOTES)); |
| 260 | printf(" %s\n", ("http://nagiosplug.sourceforge.net/developer-guidelines.html#THRESHOLDFORMAT")); | ||
| 261 | printf(" %s\n", _("for THRESHOLD format and examples.")); | ||
| 262 | 260 | ||
| 263 | printf(_(UT_SUPPORT)); | 261 | printf(_(UT_SUPPORT)); |
| 264 | printf("\n"); | ||
| 265 | } | 262 | } |
| 266 | 263 | ||
| 267 | 264 | ||
diff --git a/plugins/check_dig.c b/plugins/check_dig.c index 72dd5992..d7e1f579 100644 --- a/plugins/check_dig.c +++ b/plugins/check_dig.c | |||
| @@ -3,7 +3,7 @@ | |||
| 3 | * Nagios check_dig plugin | 3 | * Nagios check_dig plugin |
| 4 | * | 4 | * |
| 5 | * License: GPL | 5 | * License: GPL |
| 6 | * Copyright (c) 2002-2007 Nagios Plugins Development Team | 6 | * Copyright (c) 2002-2008 Nagios Plugins Development Team |
| 7 | * | 7 | * |
| 8 | * Last Modified: $Date$ | 8 | * Last Modified: $Date$ |
| 9 | * | 9 | * |
| @@ -37,7 +37,7 @@ | |||
| 37 | 37 | ||
| 38 | const char *progname = "check_dig"; | 38 | const char *progname = "check_dig"; |
| 39 | const char *revision = "$Revision$"; | 39 | const char *revision = "$Revision$"; |
| 40 | const char *copyright = "2002-2007"; | 40 | const char *copyright = "2002-2008"; |
| 41 | const char *email = "nagiosplug-devel@lists.sourceforge.net"; | 41 | const char *email = "nagiosplug-devel@lists.sourceforge.net"; |
| 42 | 42 | ||
| 43 | #include "common.h" | 43 | #include "common.h" |
| @@ -331,9 +331,12 @@ print_help (void) | |||
| 331 | printf (_(UT_WARN_CRIT)); | 331 | printf (_(UT_WARN_CRIT)); |
| 332 | printf (_(UT_TIMEOUT), DEFAULT_SOCKET_TIMEOUT); | 332 | printf (_(UT_TIMEOUT), DEFAULT_SOCKET_TIMEOUT); |
| 333 | printf (_(UT_VERBOSE)); | 333 | printf (_(UT_VERBOSE)); |
| 334 | |||
| 335 | printf("\n"); | ||
| 334 | printf ("%s\n", _("Examples:")); | 336 | printf ("%s\n", _("Examples:")); |
| 335 | printf (" %s\n", "check_dig -H DNSSERVER -l www.example.com -A \"+tcp\""); | 337 | printf (" %s\n", "check_dig -H DNSSERVER -l www.example.com -A \"+tcp\""); |
| 336 | printf (" %s\n", "This will send a tcp query to DNSSERVER for www.example.com"); | 338 | printf (" %s\n", "This will send a tcp query to DNSSERVER for www.example.com"); |
| 339 | |||
| 337 | printf (_(UT_SUPPORT)); | 340 | printf (_(UT_SUPPORT)); |
| 338 | } | 341 | } |
| 339 | 342 | ||
diff --git a/plugins/check_disk.c b/plugins/check_disk.c index 44c154fc..7048a561 100644 --- a/plugins/check_disk.c +++ b/plugins/check_disk.c | |||
| @@ -220,7 +220,7 @@ main (int argc, char **argv) | |||
| 220 | 220 | ||
| 221 | temp_list = temp_list->name_next; | 221 | temp_list = temp_list->name_next; |
| 222 | } | 222 | } |
| 223 | 223 | ||
| 224 | /* Process for every path in list */ | 224 | /* Process for every path in list */ |
| 225 | for (path = path_select_list; path; path=path->name_next) { | 225 | for (path = path_select_list; path; path=path->name_next) { |
| 226 | 226 | ||
| @@ -254,7 +254,7 @@ main (int argc, char **argv) | |||
| 254 | 254 | ||
| 255 | for (temp_list = path_select_list; temp_list; temp_list=temp_list->name_next) { | 255 | for (temp_list = path_select_list; temp_list; temp_list=temp_list->name_next) { |
| 256 | if (temp_list->group && ! (strcmp(temp_list->group, path->group))) { | 256 | if (temp_list->group && ! (strcmp(temp_list->group, path->group))) { |
| 257 | 257 | ||
| 258 | stat_path(path); | 258 | stat_path(path); |
| 259 | get_fs_usage (temp_list->best_match->me_mountdir, temp_list->best_match->me_devname, &tmpfsp); | 259 | get_fs_usage (temp_list->best_match->me_mountdir, temp_list->best_match->me_devname, &tmpfsp); |
| 260 | 260 | ||
| @@ -267,7 +267,7 @@ main (int argc, char **argv) | |||
| 267 | fsp.fsu_bavail += (tmpfsp.fsu_bavail > tmpfsp.fsu_bfree ? 0 : tmpfsp.fsu_bavail); /* Free blocks available to non-superuser. */ | 267 | fsp.fsu_bavail += (tmpfsp.fsu_bavail > tmpfsp.fsu_bfree ? 0 : tmpfsp.fsu_bavail); /* Free blocks available to non-superuser. */ |
| 268 | fsp.fsu_files += tmpfsp.fsu_files; /* Total file nodes. */ | 268 | fsp.fsu_files += tmpfsp.fsu_files; /* Total file nodes. */ |
| 269 | fsp.fsu_ffree += tmpfsp.fsu_ffree; /* Free file nodes. */ | 269 | fsp.fsu_ffree += tmpfsp.fsu_ffree; /* Free file nodes. */ |
| 270 | 270 | ||
| 271 | if (verbose > 3) | 271 | if (verbose > 3) |
| 272 | printf("Group %s: add %llu blocks (%s) \n", path->group, tmpfsp.fsu_bavail, temp_list->name); | 272 | printf("Group %s: add %llu blocks (%s) \n", path->group, tmpfsp.fsu_bavail, temp_list->name); |
| 273 | /* printf("Group %s: add %u blocks (%s)\n", temp_list->name); *//* path->group, tmpfsp.fsu_bavail, temp_list->name); */ | 273 | /* printf("Group %s: add %u blocks (%s)\n", temp_list->name); *//* path->group, tmpfsp.fsu_bavail, temp_list->name); */ |
| @@ -318,7 +318,7 @@ main (int argc, char **argv) | |||
| 318 | me->me_mountdir, total, available, available_to_root, used, fsp.fsu_files, fsp.fsu_ffree); | 318 | me->me_mountdir, total, available, available_to_root, used, fsp.fsu_files, fsp.fsu_ffree); |
| 319 | 319 | ||
| 320 | dused_pct = calculate_percent( used, used + available ); /* used + available can never be > uintmax */ | 320 | dused_pct = calculate_percent( used, used + available ); /* used + available can never be > uintmax */ |
| 321 | 321 | ||
| 322 | dfree_pct = 100 - dused_pct; | 322 | dfree_pct = 100 - dused_pct; |
| 323 | dused_units = used*fsp.fsu_blocksize/mult; | 323 | dused_units = used*fsp.fsu_blocksize/mult; |
| 324 | dfree_units = available*fsp.fsu_blocksize/mult; | 324 | dfree_units = available*fsp.fsu_blocksize/mult; |
| @@ -683,7 +683,7 @@ process_arguments (int argc, char **argv) | |||
| 683 | while (temp_list) { | 683 | while (temp_list) { |
| 684 | if (temp_list->best_match) { | 684 | if (temp_list->best_match) { |
| 685 | if (np_regex_match_mount_entry(temp_list->best_match, &re)) { | 685 | if (np_regex_match_mount_entry(temp_list->best_match, &re)) { |
| 686 | 686 | ||
| 687 | if (verbose >=3) | 687 | if (verbose >=3) |
| 688 | printf("ignoring %s matching regex\n", temp_list->name); | 688 | printf("ignoring %s matching regex\n", temp_list->name); |
| 689 | 689 | ||
| @@ -722,7 +722,7 @@ process_arguments (int argc, char **argv) | |||
| 722 | regerror (err, &re, errbuf, MAX_INPUT_BUFFER); | 722 | regerror (err, &re, errbuf, MAX_INPUT_BUFFER); |
| 723 | die (STATE_UNKNOWN, "DISK %s: %s - %s\n",_("UNKNOWN"), _("Could not compile regular expression"), errbuf); | 723 | die (STATE_UNKNOWN, "DISK %s: %s - %s\n",_("UNKNOWN"), _("Could not compile regular expression"), errbuf); |
| 724 | } | 724 | } |
| 725 | 725 | ||
| 726 | for (me = mount_list; me; me = me->me_next) { | 726 | for (me = mount_list; me; me = me->me_next) { |
| 727 | if (np_regex_match_mount_entry(me, &re)) { | 727 | if (np_regex_match_mount_entry(me, &re)) { |
| 728 | fnd = TRUE; | 728 | fnd = TRUE; |
| @@ -776,7 +776,7 @@ process_arguments (int argc, char **argv) | |||
| 776 | crit_usedinodes_percent = NULL; | 776 | crit_usedinodes_percent = NULL; |
| 777 | warn_freeinodes_percent = NULL; | 777 | warn_freeinodes_percent = NULL; |
| 778 | crit_freeinodes_percent = NULL; | 778 | crit_freeinodes_percent = NULL; |
| 779 | 779 | ||
| 780 | path_selected = FALSE; | 780 | path_selected = FALSE; |
| 781 | group = NULL; | 781 | group = NULL; |
| 782 | break; | 782 | break; |
| @@ -875,7 +875,7 @@ INPUT ERROR: C_DF (%lu) should be less than W_DF (%lu) and both should be greate | |||
| 875 | print_path (mypath); | 875 | print_path (mypath); |
| 876 | return ERROR; | 876 | return ERROR; |
| 877 | } | 877 | } |
| 878 | 878 | ||
| 879 | return OK; | 879 | return OK; |
| 880 | } | 880 | } |
| 881 | 881 | ||
| @@ -964,6 +964,7 @@ print_help (void) | |||
| 964 | printf (" %s\n", _("are grouped which means the freespace thresholds are applied to all disks together")); | 964 | printf (" %s\n", _("are grouped which means the freespace thresholds are applied to all disks together")); |
| 965 | printf (" %s\n", "check_disk -w 100M -c 50M -C -w 1000M -c 500M -p /foo -C -w 5% -c 3% -p /bar"); | 965 | printf (" %s\n", "check_disk -w 100M -c 50M -C -w 1000M -c 500M -p /foo -C -w 5% -c 3% -p /bar"); |
| 966 | printf (" %s\n", _("Checks /foo for 1000M/500M and /bar for 5/3%. All remaining volumes use 100M/50M")); | 966 | printf (" %s\n", _("Checks /foo for 1000M/500M and /bar for 5/3%. All remaining volumes use 100M/50M")); |
| 967 | |||
| 967 | printf (_(UT_SUPPORT)); | 968 | printf (_(UT_SUPPORT)); |
| 968 | } | 969 | } |
| 969 | 970 | ||
diff --git a/plugins/check_dns.c b/plugins/check_dns.c index 276dad82..f8dbb4dc 100644 --- a/plugins/check_dns.c +++ b/plugins/check_dns.c | |||
| @@ -124,7 +124,7 @@ main (int argc, char **argv) | |||
| 124 | addresses = malloc(sizeof(*addresses)*10); | 124 | addresses = malloc(sizeof(*addresses)*10); |
| 125 | else if (!(n_addresses % 10)) | 125 | else if (!(n_addresses % 10)) |
| 126 | addresses = realloc(addresses,sizeof(*addresses) * (n_addresses + 10)); | 126 | addresses = realloc(addresses,sizeof(*addresses) * (n_addresses + 10)); |
| 127 | 127 | ||
| 128 | if (verbose) | 128 | if (verbose) |
| 129 | puts(chld_out.line[i]); | 129 | puts(chld_out.line[i]); |
| 130 | 130 | ||
| @@ -148,7 +148,7 @@ main (int argc, char **argv) | |||
| 148 | /* Strip leading spaces */ | 148 | /* Strip leading spaces */ |
| 149 | for (; *temp_buffer != '\0' && *temp_buffer == ' '; temp_buffer++) | 149 | for (; *temp_buffer != '\0' && *temp_buffer == ' '; temp_buffer++) |
| 150 | /* NOOP */; | 150 | /* NOOP */; |
| 151 | 151 | ||
| 152 | strip(temp_buffer); | 152 | strip(temp_buffer); |
| 153 | if (temp_buffer==NULL || strlen(temp_buffer)==0) { | 153 | if (temp_buffer==NULL || strlen(temp_buffer)==0) { |
| 154 | die (STATE_CRITICAL, | 154 | die (STATE_CRITICAL, |
| @@ -451,13 +451,13 @@ print_help (void) | |||
| 451 | printf ("%s\n", _("This plugin uses the nslookup program to obtain the IP address for the given host/domain query.")); | 451 | printf ("%s\n", _("This plugin uses the nslookup program to obtain the IP address for the given host/domain query.")); |
| 452 | printf ("%s\n", _("An optional DNS server to use may be specified.")); | 452 | printf ("%s\n", _("An optional DNS server to use may be specified.")); |
| 453 | printf ("%s\n", _("If no DNS server is specified, the default server(s) specified in /etc/resolv.conf will be used.")); | 453 | printf ("%s\n", _("If no DNS server is specified, the default server(s) specified in /etc/resolv.conf will be used.")); |
| 454 | 454 | ||
| 455 | printf ("\n\n"); | 455 | printf ("\n\n"); |
| 456 | 456 | ||
| 457 | print_usage (); | 457 | print_usage (); |
| 458 | 458 | ||
| 459 | printf (_(UT_HELP_VRSN)); | 459 | printf (_(UT_HELP_VRSN)); |
| 460 | 460 | ||
| 461 | printf (" -H, --hostname=HOST\n"); | 461 | printf (" -H, --hostname=HOST\n"); |
| 462 | printf (" %s\n", _("The name or address you want to query")); | 462 | printf (" %s\n", _("The name or address you want to query")); |
| 463 | printf (" -s, --server=HOST\n"); | 463 | printf (" -s, --server=HOST\n"); |
diff --git a/plugins/check_dummy.c b/plugins/check_dummy.c index a29407ce..372aaff8 100644 --- a/plugins/check_dummy.c +++ b/plugins/check_dummy.c | |||
| @@ -106,11 +106,11 @@ print_help (void) | |||
| 106 | printf (COPYRIGHT, copyright, email); | 106 | printf (COPYRIGHT, copyright, email); |
| 107 | 107 | ||
| 108 | printf ("%s\n", _("This plugin will simply return the state corresponding to the numeric value")); | 108 | printf ("%s\n", _("This plugin will simply return the state corresponding to the numeric value")); |
| 109 | 109 | ||
| 110 | printf ("%s\n", _("of the <state> argument with optional text")); | 110 | printf ("%s\n", _("of the <state> argument with optional text")); |
| 111 | 111 | ||
| 112 | printf ("\n\n"); | 112 | printf ("\n\n"); |
| 113 | 113 | ||
| 114 | print_usage (); | 114 | print_usage (); |
| 115 | 115 | ||
| 116 | printf (_(UT_HELP_VRSN)); | 116 | printf (_(UT_HELP_VRSN)); |
diff --git a/plugins/check_fping.c b/plugins/check_fping.c index 5a24ab45..8617871a 100644 --- a/plugins/check_fping.c +++ b/plugins/check_fping.c | |||
| @@ -204,7 +204,7 @@ textscan (char *buf) | |||
| 204 | die (status, _("FPING %s - %s (loss=%.0f%% )|%s\n"), | 204 | die (status, _("FPING %s - %s (loss=%.0f%% )|%s\n"), |
| 205 | state_text (status), server_name, loss , | 205 | state_text (status), server_name, loss , |
| 206 | perfdata ("loss", (long int)loss, "%", wpl_p, wpl, cpl_p, cpl, TRUE, 0, TRUE, 100)); | 206 | perfdata ("loss", (long int)loss, "%", wpl_p, wpl, cpl_p, cpl, TRUE, 0, TRUE, 100)); |
| 207 | 207 | ||
| 208 | } | 208 | } |
| 209 | else { | 209 | else { |
| 210 | status = max_state (status, STATE_WARNING); | 210 | status = max_state (status, STATE_WARNING); |
| @@ -371,11 +371,11 @@ print_help (void) | |||
| 371 | printf (COPYRIGHT, copyright, email); | 371 | printf (COPYRIGHT, copyright, email); |
| 372 | 372 | ||
| 373 | printf ("%s\n", _("This plugin will use the fping command to ping the specified host for a fast check")); | 373 | printf ("%s\n", _("This plugin will use the fping command to ping the specified host for a fast check")); |
| 374 | 374 | ||
| 375 | printf ("%s\n", _("Note that it is necessary to set the suid flag on fping.")); | 375 | printf ("%s\n", _("Note that it is necessary to set the suid flag on fping.")); |
| 376 | 376 | ||
| 377 | printf ("\n\n"); | 377 | printf ("\n\n"); |
| 378 | 378 | ||
| 379 | print_usage (); | 379 | print_usage (); |
| 380 | 380 | ||
| 381 | printf (_(UT_HELP_VRSN)); | 381 | printf (_(UT_HELP_VRSN)); |
| @@ -392,9 +392,9 @@ print_help (void) | |||
| 392 | printf (" %s\n", _("number of ICMP packets to send (default: %d)"),PACKET_COUNT); | 392 | printf (" %s\n", _("number of ICMP packets to send (default: %d)"),PACKET_COUNT); |
| 393 | printf (_(UT_VERBOSE)); | 393 | printf (_(UT_VERBOSE)); |
| 394 | printf ("\n"); | 394 | printf ("\n"); |
| 395 | printf (" %s\n", _("THRESHOLD is <rta>,<pl>%% where <rta> is the round trip average travel time (ms)")); | 395 | printf (" %s\n", _("THRESHOLD is <rta>,<pl>%% where <rta> is the round trip average travel time (ms)")); |
| 396 | printf (" %s\n", _("which triggers a WARNING or CRITICAL state, and <pl> is the percentage of")); | 396 | printf (" %s\n", _("which triggers a WARNING or CRITICAL state, and <pl> is the percentage of")); |
| 397 | printf (" %s\n", _("packet loss to trigger an alarm state.")); | 397 | printf (" %s\n", _("packet loss to trigger an alarm state.")); |
| 398 | printf (_(UT_SUPPORT)); | 398 | printf (_(UT_SUPPORT)); |
| 399 | } | 399 | } |
| 400 | 400 | ||
diff --git a/plugins/check_game.c b/plugins/check_game.c index aede055d..0e4120dd 100644 --- a/plugins/check_game.c +++ b/plugins/check_game.c | |||
| @@ -78,7 +78,7 @@ main (int argc, char **argv) | |||
| 78 | setlocale (LC_ALL, ""); | 78 | setlocale (LC_ALL, ""); |
| 79 | bindtextdomain (PACKAGE, LOCALEDIR); | 79 | bindtextdomain (PACKAGE, LOCALEDIR); |
| 80 | textdomain (PACKAGE); | 80 | textdomain (PACKAGE); |
| 81 | 81 | ||
| 82 | if (process_arguments (argc, argv) == ERROR) | 82 | if (process_arguments (argc, argv) == ERROR) |
| 83 | usage_va(_("Could not parse arguments")); | 83 | usage_va(_("Could not parse arguments")); |
| 84 | 84 | ||
| @@ -87,7 +87,7 @@ main (int argc, char **argv) | |||
| 87 | /* create the command line to execute */ | 87 | /* create the command line to execute */ |
| 88 | asprintf (&command_line, "%s -raw %s -%s %s", | 88 | asprintf (&command_line, "%s -raw %s -%s %s", |
| 89 | PATH_TO_QSTAT, QSTAT_DATA_DELIMITER, game_type, server_ip); | 89 | PATH_TO_QSTAT, QSTAT_DATA_DELIMITER, game_type, server_ip); |
| 90 | 90 | ||
| 91 | if (port) | 91 | if (port) |
| 92 | asprintf (&command_line, "%s:%-d", command_line, port); | 92 | asprintf (&command_line, "%s:%-d", command_line, port); |
| 93 | 93 | ||
| @@ -298,11 +298,11 @@ print_help (void) | |||
| 298 | printf (_("This plugin tests game server connections with the specified host.")); | 298 | printf (_("This plugin tests game server connections with the specified host.")); |
| 299 | 299 | ||
| 300 | printf ("\n\n"); | 300 | printf ("\n\n"); |
| 301 | 301 | ||
| 302 | print_usage (); | 302 | print_usage (); |
| 303 | 303 | ||
| 304 | printf (_(UT_HELP_VRSN)); | 304 | printf (_(UT_HELP_VRSN)); |
| 305 | 305 | ||
| 306 | printf (" %s\n", "-p"); | 306 | printf (" %s\n", "-p"); |
| 307 | printf (" %s\n", _("Optional port of which to connect")); | 307 | printf (" %s\n", _("Optional port of which to connect")); |
| 308 | printf (" %s\n", "gf"); | 308 | printf (" %s\n", "gf"); |
| @@ -314,13 +314,11 @@ print_help (void) | |||
| 314 | 314 | ||
| 315 | printf (_(UT_TIMEOUT), DEFAULT_SOCKET_TIMEOUT); | 315 | printf (_(UT_TIMEOUT), DEFAULT_SOCKET_TIMEOUT); |
| 316 | 316 | ||
| 317 | printf ("\n"); | ||
| 317 | printf ("%s\n", _("Notes:")); | 318 | printf ("%s\n", _("Notes:")); |
| 318 | 319 | printf (" %s\n", _("This plugin uses the 'qstat' command, the popular game server status query tool.")); | |
| 319 | printf ("%s\n", _("This plugin uses the 'qstat' command, the popular game server status query tool .")); | 320 | printf (" %s\n", _("If you don't have the package installed, you will need to download it from")); |
| 320 | 321 | printf (" %s\n", _("http://www.activesw.com/people/steve/qstat.html before you can use this plugin.")); | |
| 321 | printf ("%s\n", _("If you don't have the package installed, you will need to download it from")); | ||
| 322 | |||
| 323 | printf ("%s\n", _("http://www.activesw.com/people/steve/qstat.html before you can use this plugin.")); | ||
| 324 | 322 | ||
| 325 | printf (_(UT_SUPPORT)); | 323 | printf (_(UT_SUPPORT)); |
| 326 | } | 324 | } |
diff --git a/plugins/check_hpjd.c b/plugins/check_hpjd.c index 6bcffae6..e20a76d9 100644 --- a/plugins/check_hpjd.c +++ b/plugins/check_hpjd.c | |||
| @@ -393,7 +393,7 @@ print_help (void) | |||
| 393 | printf ("%s\n", _("Net-snmp must be installed on the computer running the plugin.")); | 393 | printf ("%s\n", _("Net-snmp must be installed on the computer running the plugin.")); |
| 394 | 394 | ||
| 395 | printf ("\n\n"); | 395 | printf ("\n\n"); |
| 396 | 396 | ||
| 397 | print_usage (); | 397 | print_usage (); |
| 398 | 398 | ||
| 399 | printf (_(UT_HELP_VRSN)); | 399 | printf (_(UT_HELP_VRSN)); |
| @@ -402,6 +402,7 @@ print_help (void) | |||
| 402 | printf (" %s", _("The SNMP community name ")); | 402 | printf (" %s", _("The SNMP community name ")); |
| 403 | printf (_("(default=%s)"), DEFAULT_COMMUNITY); | 403 | printf (_("(default=%s)"), DEFAULT_COMMUNITY); |
| 404 | 404 | ||
| 405 | printf ("\n"); | ||
| 405 | printf (_(UT_SUPPORT)); | 406 | printf (_(UT_SUPPORT)); |
| 406 | } | 407 | } |
| 407 | 408 | ||
diff --git a/plugins/check_http.c b/plugins/check_http.c index 82cd1d9c..81071d75 100644 --- a/plugins/check_http.c +++ b/plugins/check_http.c | |||
| @@ -774,7 +774,7 @@ check_http (void) | |||
| 774 | } else { | 774 | } else { |
| 775 | asprintf (&buf, "%sContent-Type: application/x-www-form-urlencoded\r\n", buf); | 775 | asprintf (&buf, "%sContent-Type: application/x-www-form-urlencoded\r\n", buf); |
| 776 | } | 776 | } |
| 777 | 777 | ||
| 778 | asprintf (&buf, "%sContent-Length: %i\r\n\r\n", buf, (int)strlen (http_post_data)); | 778 | asprintf (&buf, "%sContent-Length: %i\r\n\r\n", buf, (int)strlen (http_post_data)); |
| 779 | asprintf (&buf, "%s%s%s", buf, http_post_data, CRLF); | 779 | asprintf (&buf, "%s%s%s", buf, http_post_data, CRLF); |
| 780 | } | 780 | } |
| @@ -936,7 +936,7 @@ check_http (void) | |||
| 936 | } /* end if (http_status >= 300) */ | 936 | } /* end if (http_status >= 300) */ |
| 937 | 937 | ||
| 938 | } /* end else (server_expect_yn) */ | 938 | } /* end else (server_expect_yn) */ |
| 939 | 939 | ||
| 940 | if (maximum_age >= 0) { | 940 | if (maximum_age >= 0) { |
| 941 | check_document_dates (header); | 941 | check_document_dates (header); |
| 942 | } | 942 | } |
| @@ -1048,7 +1048,7 @@ redir (char *pos, char *status_line) | |||
| 1048 | addr = malloc (MAX_IPV4_HOSTLENGTH + 1); | 1048 | addr = malloc (MAX_IPV4_HOSTLENGTH + 1); |
| 1049 | if (addr == NULL) | 1049 | if (addr == NULL) |
| 1050 | die (STATE_UNKNOWN, _("HTTP UNKNOWN - Could not allocate addr\n")); | 1050 | die (STATE_UNKNOWN, _("HTTP UNKNOWN - Could not allocate addr\n")); |
| 1051 | 1051 | ||
| 1052 | url = malloc (strcspn (pos, "\r\n")); | 1052 | url = malloc (strcspn (pos, "\r\n")); |
| 1053 | if (url == NULL) | 1053 | if (url == NULL) |
| 1054 | die (STATE_UNKNOWN, _("HTTP UNKNOWN - Could not allocate url\n")); | 1054 | die (STATE_UNKNOWN, _("HTTP UNKNOWN - Could not allocate url\n")); |
| @@ -1322,7 +1322,7 @@ print_help (void) | |||
| 1322 | printf (" %s\n", _("When the certificate of 'www.verisign.com' is valid for more than 14 days,")); | 1322 | printf (" %s\n", _("When the certificate of 'www.verisign.com' is valid for more than 14 days,")); |
| 1323 | printf (" %s\n", _("a STATE_OK is returned. When the certificate is still valid, but for less than")); | 1323 | printf (" %s\n", _("a STATE_OK is returned. When the certificate is still valid, but for less than")); |
| 1324 | printf (" %s\n", _("14 days, a STATE_WARNING is returned. A STATE_CRITICAL will be returned when")); | 1324 | printf (" %s\n", _("14 days, a STATE_WARNING is returned. A STATE_CRITICAL will be returned when")); |
| 1325 | printf (" %s\n\n", _("the certificate is expired.")); | 1325 | printf (" %s\n", _("the certificate is expired.")); |
| 1326 | #endif | 1326 | #endif |
| 1327 | 1327 | ||
| 1328 | printf (_(UT_SUPPORT)); | 1328 | printf (_(UT_SUPPORT)); |
diff --git a/plugins/check_ide_smart.c b/plugins/check_ide_smart.c index c6ea2843..937f84c5 100644 --- a/plugins/check_ide_smart.c +++ b/plugins/check_ide_smart.c | |||
| @@ -484,13 +484,13 @@ print_help (void) | |||
| 484 | printf (COPYRIGHT, copyright, email); | 484 | printf (COPYRIGHT, copyright, email); |
| 485 | 485 | ||
| 486 | printf (_("This plugin checks a local hard drive with the (Linux specific) SMART interface [http://smartlinux.sourceforge.net/smart/index.php].")); | 486 | printf (_("This plugin checks a local hard drive with the (Linux specific) SMART interface [http://smartlinux.sourceforge.net/smart/index.php].")); |
| 487 | 487 | ||
| 488 | printf ("\n\n"); | 488 | printf ("\n\n"); |
| 489 | 489 | ||
| 490 | print_usage (); | 490 | print_usage (); |
| 491 | 491 | ||
| 492 | printf (_(UT_HELP_VRSN)); | 492 | printf (_(UT_HELP_VRSN)); |
| 493 | 493 | ||
| 494 | printf (" %s\n", "-d, --device=DEVICE"); | 494 | printf (" %s\n", "-d, --device=DEVICE"); |
| 495 | printf (" %s\n", _("Select device DEVICE")); | 495 | printf (" %s\n", _("Select device DEVICE")); |
| 496 | printf (" %s\n", _("Note: if the device is selected with this option, _no_ other options are accepted")); | 496 | printf (" %s\n", _("Note: if the device is selected with this option, _no_ other options are accepted")); |
| @@ -503,7 +503,7 @@ print_help (void) | |||
| 503 | printf (" %s\n", "-0, --auto-off"); | 503 | printf (" %s\n", "-0, --auto-off"); |
| 504 | printf (" %s\n", _("Turn off automatic offline tests")); | 504 | printf (" %s\n", _("Turn off automatic offline tests")); |
| 505 | printf (" %s\n", "-n, --nagios"); | 505 | printf (" %s\n", "-n, --nagios"); |
| 506 | printf (" %s\n\n", _("Output suitable for Nagios")); | 506 | printf (" %s\n", _("Output suitable for Nagios")); |
| 507 | printf (_(UT_SUPPORT)); | 507 | printf (_(UT_SUPPORT)); |
| 508 | } | 508 | } |
| 509 | 509 | ||
diff --git a/plugins/check_ldap.c b/plugins/check_ldap.c index 582f9cc1..74ca3b0c 100644 --- a/plugins/check_ldap.c +++ b/plugins/check_ldap.c | |||
| @@ -393,7 +393,7 @@ print_help (void) | |||
| 393 | printf (COPYRIGHT, copyright, email); | 393 | printf (COPYRIGHT, copyright, email); |
| 394 | 394 | ||
| 395 | printf ("\n\n"); | 395 | printf ("\n\n"); |
| 396 | 396 | ||
| 397 | print_usage (); | 397 | print_usage (); |
| 398 | 398 | ||
| 399 | printf (_(UT_HELP_VRSN)); | 399 | printf (_(UT_HELP_VRSN)); |
| @@ -429,12 +429,12 @@ print_help (void) | |||
| 429 | 429 | ||
| 430 | printf (_(UT_VERBOSE)); | 430 | printf (_(UT_VERBOSE)); |
| 431 | 431 | ||
| 432 | printf ("\n%s\n", _("Note:")); | 432 | printf ("\n%s\n", _("Notes:")); |
| 433 | printf ("%s\n", _("If this plugin is called via 'check_ldaps', method 'STARTTLS' will be")); | 433 | printf (" %s\n", _("If this plugin is called via 'check_ldaps', method 'STARTTLS' will be")); |
| 434 | printf (_("implied (using default port %i) unless --port=636 is specified. In that case %s"), DEFAULT_PORT, "\n"); | 434 | printf (_(" implied (using default port %i) unless --port=636 is specified. In that case %s"), DEFAULT_PORT, "\n"); |
| 435 | printf ("%s\n", _("'SSL on connect' will be used no matter how the plugin was called.")); | 435 | printf (" %s\n", _("'SSL on connect' will be used no matter how the plugin was called.")); |
| 436 | printf ("%s\n", _("This detection is deprecated, please use 'check_ldap' with the '--starttls' or '--ssl' flags")); | 436 | printf (" %s\n", _("This detection is deprecated, please use 'check_ldap' with the '--starttls' or '--ssl' flags")); |
| 437 | printf ("%s\n", _("to define the behaviour explicitly instead.")); | 437 | printf (" %s\n", _("to define the behaviour explicitly instead.")); |
| 438 | 438 | ||
| 439 | printf (_(UT_SUPPORT)); | 439 | printf (_(UT_SUPPORT)); |
| 440 | } | 440 | } |
diff --git a/plugins/check_load.c b/plugins/check_load.c index a60858fa..f4faa31b 100644 --- a/plugins/check_load.c +++ b/plugins/check_load.c | |||
| @@ -303,7 +303,7 @@ print_help (void) | |||
| 303 | printf (_("This plugin tests the current system load average.")); | 303 | printf (_("This plugin tests the current system load average.")); |
| 304 | 304 | ||
| 305 | printf ("\n\n"); | 305 | printf ("\n\n"); |
| 306 | 306 | ||
| 307 | print_usage (); | 307 | print_usage (); |
| 308 | 308 | ||
| 309 | printf (_(UT_HELP_VRSN)); | 309 | printf (_(UT_HELP_VRSN)); |
diff --git a/plugins/check_mrtg.c b/plugins/check_mrtg.c index 158bb8f9..cf77f8bf 100644 --- a/plugins/check_mrtg.c +++ b/plugins/check_mrtg.c | |||
| @@ -323,7 +323,7 @@ print_help (void) | |||
| 323 | printf ("%s\n", _("two variables recorded in an MRTG log file.")); | 323 | printf ("%s\n", _("two variables recorded in an MRTG log file.")); |
| 324 | 324 | ||
| 325 | printf ("\n\n"); | 325 | printf ("\n\n"); |
| 326 | 326 | ||
| 327 | print_usage (); | 327 | print_usage (); |
| 328 | 328 | ||
| 329 | printf (_(UT_HELP_VRSN)); | 329 | printf (_(UT_HELP_VRSN)); |
| @@ -346,25 +346,27 @@ print_help (void) | |||
| 346 | printf (" %s\n", _("Option units label for data (Example: Packets/Sec, Errors/Sec,")); | 346 | printf (" %s\n", _("Option units label for data (Example: Packets/Sec, Errors/Sec,")); |
| 347 | printf (" %s\n", _("\"Bytes Per Second\", \"%% Utilization\")")); | 347 | printf (" %s\n", _("\"Bytes Per Second\", \"%% Utilization\")")); |
| 348 | 348 | ||
| 349 | printf ("%s\n", _("If the value exceeds the <vwl> threshold, a WARNING status is returned. If")); | 349 | printf ("\n"); |
| 350 | printf ("%s\n", _("the value exceeds the <vcl> threshold, a CRITICAL status is returned. If")); | 350 | printf (" %s\n", _("If the value exceeds the <vwl> threshold, a WARNING status is returned. If")); |
| 351 | printf ("%s\n", _("the data in the log file is older than <expire_minutes> old, a WARNING")); | 351 | printf (" %s\n", _("the value exceeds the <vcl> threshold, a CRITICAL status is returned. If")); |
| 352 | printf ("%s\n", _("status is returned and a warning message is printed.")); | 352 | printf (" %s\n", _("the data in the log file is older than <expire_minutes> old, a WARNING")); |
| 353 | printf (" %s\n", _("status is returned and a warning message is printed.")); | ||
| 353 | 354 | ||
| 354 | printf ("%s\n", _("This plugin is useful for monitoring MRTG data that does not correspond to")); | 355 | printf ("\n"); |
| 355 | printf ("%s\n", _("bandwidth usage. (Use the check_mrtgtraf plugin for monitoring bandwidth).")); | 356 | printf (" %s\n", _("This plugin is useful for monitoring MRTG data that does not correspond to")); |
| 356 | printf ("%s\n", _("It can be used to monitor any kind of data that MRTG is monitoring - errors,")); | 357 | printf (" %s\n", _("bandwidth usage. (Use the check_mrtgtraf plugin for monitoring bandwidth).")); |
| 357 | printf ("%s\n", _("packets/sec, etc. I use MRTG in conjuction with the Novell NLM that allows")); | 358 | printf (" %s\n", _("It can be used to monitor any kind of data that MRTG is monitoring - errors,")); |
| 358 | printf ("%s\n", _("me to track processor utilization, user connections, drive space, etc and")); | 359 | printf (" %s\n", _("packets/sec, etc. I use MRTG in conjuction with the Novell NLM that allows")); |
| 359 | printf ("%s\n\n", _("this plugin works well for monitoring that kind of data as well.")); | 360 | printf (" %s\n", _("me to track processor utilization, user connections, drive space, etc and")); |
| 361 | printf (" %s\n\n", _("this plugin works well for monitoring that kind of data as well.")); | ||
| 360 | 362 | ||
| 361 | printf ("%s\n", _("Notes:")); | 363 | printf ("%s\n", _("Notes:")); |
| 362 | printf (" %s\n", _("- This plugin only monitors one of the two variables stored in the MRTG log")); | 364 | printf (" %s\n", _("- This plugin only monitors one of the two variables stored in the MRTG log")); |
| 363 | printf (" %s\n", _(" file. If you want to monitor both values you will have to define two")); | 365 | printf (" %s\n", _("file. If you want to monitor both values you will have to define two")); |
| 364 | printf (" %s\n", _(" commands with different values for the <variable> argument. Of course,")); | 366 | printf (" %s\n", _("commands with different values for the <variable> argument. Of course,")); |
| 365 | printf (" %s\n", _("you can always hack the code to make this plugin work for you...")); | 367 | printf (" %s\n", _("you can always hack the code to make this plugin work for you...")); |
| 366 | printf (" %s\n", _("- MRTG stands for the Multi Router Traffic Grapher. It can be downloaded from")); | 368 | printf (" %s\n", _("- MRTG stands for the Multi Router Traffic Grapher. It can be downloaded from")); |
| 367 | printf (" %s\n", "http://ee-staff.ethz.ch/~oetiker/webtools/mrtg/mrtg.html"); | 369 | printf (" %s\n", "http://ee-staff.ethz.ch/~oetiker/webtools/mrtg/mrtg.html"); |
| 368 | 370 | ||
| 369 | printf (_(UT_SUPPORT)); | 371 | printf (_(UT_SUPPORT)); |
| 370 | } | 372 | } |
diff --git a/plugins/check_mrtgtraf.c b/plugins/check_mrtgtraf.c index 97627aa8..5ba5cdc0 100644 --- a/plugins/check_mrtgtraf.c +++ b/plugins/check_mrtgtraf.c | |||
| @@ -359,6 +359,7 @@ print_help (void) | |||
| 359 | printf (" %s\n", "-c, --critical"); | 359 | printf (" %s\n", "-c, --critical"); |
| 360 | printf (" %s\n", _("Critical threshold pair <incoming>,<outgoing>")); | 360 | printf (" %s\n", _("Critical threshold pair <incoming>,<outgoing>")); |
| 361 | 361 | ||
| 362 | printf ("\n"); | ||
| 362 | printf ("%s\n", _("Notes:")); | 363 | printf ("%s\n", _("Notes:")); |
| 363 | printf (" %s\n", _("- MRTG stands for Multi Router Traffic Grapher. It can be downloaded from")); | 364 | printf (" %s\n", _("- MRTG stands for Multi Router Traffic Grapher. It can be downloaded from")); |
| 364 | printf (" %s\n", " http://ee-staff.ethz.ch/~oetiker/webtools/mrtg/mrtg.html"); | 365 | printf (" %s\n", " http://ee-staff.ethz.ch/~oetiker/webtools/mrtg/mrtg.html"); |
diff --git a/plugins/check_mysql.c b/plugins/check_mysql.c index ad15a77c..ea2e30d2 100644 --- a/plugins/check_mysql.c +++ b/plugins/check_mysql.c | |||
| @@ -370,7 +370,7 @@ print_help (void) | |||
| 370 | printf ("%s\n", _("This program tests connections to a mysql server")); | 370 | printf ("%s\n", _("This program tests connections to a mysql server")); |
| 371 | 371 | ||
| 372 | printf ("\n\n"); | 372 | printf ("\n\n"); |
| 373 | 373 | ||
| 374 | print_usage (); | 374 | print_usage (); |
| 375 | 375 | ||
| 376 | printf (_(UT_HELP_VRSN)); | 376 | printf (_(UT_HELP_VRSN)); |
| @@ -391,8 +391,10 @@ print_help (void) | |||
| 391 | printf (" %s\n", _("Exit with WARNING status if slave server is more than INTEGER seconds behind master")); | 391 | printf (" %s\n", _("Exit with WARNING status if slave server is more than INTEGER seconds behind master")); |
| 392 | printf (" %s\n", "-c, --critical"); | 392 | printf (" %s\n", "-c, --critical"); |
| 393 | printf (" %s\n", _("Exit with CRITICAL status if slave server is more then INTEGER seconds behind master")); | 393 | printf (" %s\n", _("Exit with CRITICAL status if slave server is more then INTEGER seconds behind master")); |
| 394 | |||
| 395 | printf ("\n"); | ||
| 394 | printf (" %s\n", _("There are no required arguments. By default, the local database with")); | 396 | printf (" %s\n", _("There are no required arguments. By default, the local database with")); |
| 395 | printf (_("a server listening on MySQL standard port %d will be checked\n"), MYSQL_PORT); | 397 | printf (_(" a server listening on MySQL standard port %d will be checked\n"), MYSQL_PORT); |
| 396 | 398 | ||
| 397 | printf (_(UT_SUPPORT)); | 399 | printf (_(UT_SUPPORT)); |
| 398 | } | 400 | } |
diff --git a/plugins/check_mysql_query.c b/plugins/check_mysql_query.c index a1683066..8c6a96c6 100644 --- a/plugins/check_mysql_query.c +++ b/plugins/check_mysql_query.c | |||
| @@ -302,9 +302,8 @@ print_help (void) | |||
| 302 | printf (" ==> %s <==\n", _("IMPORTANT: THIS FORM OF AUTHENTICATION IS NOT SECURE!!!")); | 302 | printf (" ==> %s <==\n", _("IMPORTANT: THIS FORM OF AUTHENTICATION IS NOT SECURE!!!")); |
| 303 | 303 | ||
| 304 | printf ("\n"); | 304 | printf ("\n"); |
| 305 | 305 | printf (" %s\n", _("A query is required. The result from the query should be numeric.")); | |
| 306 | printf ("%s\n", _("A query is required. The result from the query should be numeric.")); | 306 | printf (" %s\n", _("For extra security, create a user with minimal access.")); |
| 307 | printf ("%s\n", _("For extra security, create a user with minimal access.")); | ||
| 308 | 307 | ||
| 309 | printf (_(UT_SUPPORT)); | 308 | printf (_(UT_SUPPORT)); |
| 310 | } | 309 | } |
diff --git a/plugins/check_nagios.c b/plugins/check_nagios.c index b3088a1d..1f8df33e 100644 --- a/plugins/check_nagios.c +++ b/plugins/check_nagios.c | |||
| @@ -285,7 +285,7 @@ print_help (void) | |||
| 285 | printf ("%s\n", _("It also checks the process table for a process matching the command argument.")); | 285 | printf ("%s\n", _("It also checks the process table for a process matching the command argument.")); |
| 286 | 286 | ||
| 287 | printf ("\n\n"); | 287 | printf ("\n\n"); |
| 288 | 288 | ||
| 289 | print_usage (); | 289 | print_usage (); |
| 290 | 290 | ||
| 291 | printf (_(UT_HELP_VRSN)); | 291 | printf (_(UT_HELP_VRSN)); |
| @@ -300,6 +300,7 @@ print_help (void) | |||
| 300 | printf ("\n"); | 300 | printf ("\n"); |
| 301 | printf ("%s\n", _("Examples:")); | 301 | printf ("%s\n", _("Examples:")); |
| 302 | printf (" %s\n", "check_nagios -e 5 -F /usr/local/nagios/var/status.log -C /usr/local/nagios/bin/nagios"); | 302 | printf (" %s\n", "check_nagios -e 5 -F /usr/local/nagios/var/status.log -C /usr/local/nagios/bin/nagios"); |
| 303 | |||
| 303 | printf (_(UT_SUPPORT)); | 304 | printf (_(UT_SUPPORT)); |
| 304 | } | 305 | } |
| 305 | 306 | ||
diff --git a/plugins/check_nt.c b/plugins/check_nt.c index 60d58fd0..681b842e 100644 --- a/plugins/check_nt.c +++ b/plugins/check_nt.c | |||
| @@ -157,7 +157,7 @@ int main(int argc, char **argv){ | |||
| 157 | return_code=STATE_OK; | 157 | return_code=STATE_OK; |
| 158 | temp_string = strdup (_("CPU Load")); | 158 | temp_string = strdup (_("CPU Load")); |
| 159 | temp_string_perf = strdup (" "); | 159 | temp_string_perf = strdup (" "); |
| 160 | 160 | ||
| 161 | /* loop until one of the parameters is wrong or not present */ | 161 | /* loop until one of the parameters is wrong or not present */ |
| 162 | while (lvalue_list[0+offset]> (unsigned long)0 && | 162 | while (lvalue_list[0+offset]> (unsigned long)0 && |
| 163 | lvalue_list[0+offset]<=(unsigned long)17280 && | 163 | lvalue_list[0+offset]<=(unsigned long)17280 && |
| @@ -185,7 +185,7 @@ int main(int argc, char **argv){ | |||
| 185 | asprintf(&temp_string_perf,"%s%s",temp_string_perf,perfdata); | 185 | asprintf(&temp_string_perf,"%s%s",temp_string_perf,perfdata); |
| 186 | offset+=3; /* move across the array */ | 186 | offset+=3; /* move across the array */ |
| 187 | } | 187 | } |
| 188 | 188 | ||
| 189 | if (strlen(temp_string)>10) { /* we had at least one loop */ | 189 | if (strlen(temp_string)>10) { /* we had at least one loop */ |
| 190 | output_message = strdup (temp_string); | 190 | output_message = strdup (temp_string); |
| 191 | perfdata = temp_string_perf; | 191 | perfdata = temp_string_perf; |
| @@ -640,7 +640,7 @@ void print_help(void) | |||
| 640 | printf ("%s\n", _("Windows NT/2000/XP/2003 server.")); | 640 | printf ("%s\n", _("Windows NT/2000/XP/2003 server.")); |
| 641 | 641 | ||
| 642 | printf ("\n\n"); | 642 | printf ("\n\n"); |
| 643 | 643 | ||
| 644 | print_usage(); | 644 | print_usage(); |
| 645 | 645 | ||
| 646 | printf (_(UT_HELP_VRSN)); | 646 | printf (_(UT_HELP_VRSN)); |
| @@ -720,14 +720,17 @@ void print_help(void) | |||
| 720 | printf (" %s\n", _(" configuration files.")); | 720 | printf (" %s\n", _(" configuration files.")); |
| 721 | printf (" %s\n", _("Some examples:")); | 721 | printf (" %s\n", _("Some examples:")); |
| 722 | printf (" %s\n\n", _("check_nt -H 192.168.1.1 -p 1248 -v INSTANCES -l Process")); | 722 | printf (" %s\n\n", _("check_nt -H 192.168.1.1 -p 1248 -v INSTANCES -l Process")); |
| 723 | printf (_("Notes:")); | 723 | |
| 724 | printf ("%s\n", _("Notes:")); | ||
| 724 | printf (" %s\n", _("- The NSClient service should be running on the server to get any information")); | 725 | printf (" %s\n", _("- The NSClient service should be running on the server to get any information")); |
| 725 | printf (" %s\n", "(http://nsclient.ready2run.nl)."); | 726 | printf (" %s\n", "(http://nsclient.ready2run.nl)."); |
| 726 | printf (" %s\n", _("- Critical thresholds should be lower than warning thresholds")); | 727 | printf (" %s\n", _("- Critical thresholds should be lower than warning thresholds")); |
| 727 | printf (" %s\n", _("- Default port 1248 is sometimes in use by other services. The error")); | 728 | printf (" %s\n", _("- Default port 1248 is sometimes in use by other services. The error")); |
| 728 | printf (" %s\n", _("output when this happens contains \"Cannot map xxxxx to protocol number\".")); | 729 | printf (" %s\n", _("output when this happens contains \"Cannot map xxxxx to protocol number\".")); |
| 729 | printf (" %s\n", _("One fix for this is to change the port to something else on check_nt ")); | 730 | printf (" %s\n", _("One fix for this is to change the port to something else on check_nt ")); |
| 730 | printf (" %s\n", _("and on the client service it\'s connecting to.")); | 731 | printf (" %s\n", _("and on the client service it\'s connecting to.")); |
| 732 | |||
| 733 | printf (_(UT_SUPPORT)); | ||
| 731 | } | 734 | } |
| 732 | 735 | ||
| 733 | 736 | ||
diff --git a/plugins/check_ntp.c b/plugins/check_ntp.c index 28a8f899..ec8cd13d 100644 --- a/plugins/check_ntp.c +++ b/plugins/check_ntp.c | |||
| @@ -872,7 +872,6 @@ void print_help(void){ | |||
| 872 | 872 | ||
| 873 | printf (_(UT_SUPPORT)); | 873 | printf (_(UT_SUPPORT)); |
| 874 | 874 | ||
| 875 | printf("\n"); | ||
| 876 | printf ("%s\n", _("WARNING: check_ntp is deprecated. Please use check_ntp_peer or")); | 875 | printf ("%s\n", _("WARNING: check_ntp is deprecated. Please use check_ntp_peer or")); |
| 877 | printf ("%s\n\n", _("check_ntp_time istead.")); | 876 | printf ("%s\n\n", _("check_ntp_time istead.")); |
| 878 | } | 877 | } |
diff --git a/plugins/check_ntp_peer.c b/plugins/check_ntp_peer.c index 536883d5..f6c33d61 100644 --- a/plugins/check_ntp_peer.c +++ b/plugins/check_ntp_peer.c | |||
| @@ -602,7 +602,7 @@ int main(int argc, char *argv[]){ | |||
| 602 | asprintf(&result_line, "%s %s,", result_line, _("Server not synchronized")); | 602 | asprintf(&result_line, "%s %s,", result_line, _("Server not synchronized")); |
| 603 | else if(li_alarm) | 603 | else if(li_alarm) |
| 604 | asprintf(&result_line, "%s %s,", result_line, _("Server has the LI_ALARM bit set")); | 604 | asprintf(&result_line, "%s %s,", result_line, _("Server has the LI_ALARM bit set")); |
| 605 | 605 | ||
| 606 | if(offset_result == STATE_UNKNOWN){ | 606 | if(offset_result == STATE_UNKNOWN){ |
| 607 | asprintf(&result_line, "%s %s", result_line, _("Offset unknown")); | 607 | asprintf(&result_line, "%s %s", result_line, _("Offset unknown")); |
| 608 | asprintf(&perfdata_line, ""); | 608 | asprintf(&perfdata_line, ""); |
diff --git a/plugins/check_nwstat.c b/plugins/check_nwstat.c index a1a3f35a..3c8d5b96 100644 --- a/plugins/check_nwstat.c +++ b/plugins/check_nwstat.c | |||
| @@ -518,14 +518,14 @@ main(int argc, char **argv) { | |||
| 518 | result=STATE_OK; | 518 | result=STATE_OK; |
| 519 | else | 519 | else |
| 520 | result=STATE_WARNING; | 520 | result=STATE_WARNING; |
| 521 | 521 | ||
| 522 | close(sd); | 522 | close(sd); |
| 523 | my_tcp_connect (server_address, server_port, &sd); | 523 | my_tcp_connect (server_address, server_port, &sd); |
| 524 | 524 | ||
| 525 | send_buffer = strdup ("S13\r\n"); | 525 | send_buffer = strdup ("S13\r\n"); |
| 526 | result=send_tcp_request(sd,send_buffer,recv_buffer,sizeof(recv_buffer)); | 526 | result=send_tcp_request(sd,send_buffer,recv_buffer,sizeof(recv_buffer)); |
| 527 | temp_buffer=strtok(recv_buffer,"\r\n"); | 527 | temp_buffer=strtok(recv_buffer,"\r\n"); |
| 528 | 528 | ||
| 529 | asprintf (&output_message,_("Directory Services Database is %s (DS version %s)"),(result==STATE_OK)?"open":"closed",temp_buffer); | 529 | asprintf (&output_message,_("Directory Services Database is %s (DS version %s)"),(result==STATE_OK)?"open":"closed",temp_buffer); |
| 530 | 530 | ||
| 531 | /* check to see if logins are enabled */ | 531 | /* check to see if logins are enabled */ |
| @@ -593,7 +593,7 @@ main(int argc, char **argv) { | |||
| 593 | return result; | 593 | return result; |
| 594 | 594 | ||
| 595 | max_packet_receive_buffers=atoi(recv_buffer); | 595 | max_packet_receive_buffers=atoi(recv_buffer); |
| 596 | 596 | ||
| 597 | percent_used_packet_receive_buffers=(unsigned long)(((double)used_packet_receive_buffers/(double)max_packet_receive_buffers)*100.0); | 597 | percent_used_packet_receive_buffers=(unsigned long)(((double)used_packet_receive_buffers/(double)max_packet_receive_buffers)*100.0); |
| 598 | 598 | ||
| 599 | if (vars_to_check==UPRB) { | 599 | if (vars_to_check==UPRB) { |
| @@ -607,7 +607,7 @@ main(int argc, char **argv) { | |||
| 607 | else if (check_warning_value==TRUE && percent_used_packet_receive_buffers >= warning_value) | 607 | else if (check_warning_value==TRUE && percent_used_packet_receive_buffers >= warning_value) |
| 608 | result=STATE_WARNING; | 608 | result=STATE_WARNING; |
| 609 | } | 609 | } |
| 610 | 610 | ||
| 611 | asprintf (&output_message,_("%lu of %lu (%lu%%) packet receive buffers used"),used_packet_receive_buffers,max_packet_receive_buffers,percent_used_packet_receive_buffers); | 611 | asprintf (&output_message,_("%lu of %lu (%lu%%) packet receive buffers used"),used_packet_receive_buffers,max_packet_receive_buffers,percent_used_packet_receive_buffers); |
| 612 | 612 | ||
| 613 | /* check SAP table entries */ | 613 | /* check SAP table entries */ |
| @@ -623,9 +623,9 @@ main(int argc, char **argv) { | |||
| 623 | result=send_tcp_request(sd,send_buffer,recv_buffer,sizeof(recv_buffer)); | 623 | result=send_tcp_request(sd,send_buffer,recv_buffer,sizeof(recv_buffer)); |
| 624 | if (result!=STATE_OK) | 624 | if (result!=STATE_OK) |
| 625 | return result; | 625 | return result; |
| 626 | 626 | ||
| 627 | sap_entries=atoi(recv_buffer); | 627 | sap_entries=atoi(recv_buffer); |
| 628 | 628 | ||
| 629 | if (check_critical_value==TRUE && sap_entries >= critical_value) | 629 | if (check_critical_value==TRUE && sap_entries >= critical_value) |
| 630 | result=STATE_CRITICAL; | 630 | result=STATE_CRITICAL; |
| 631 | else if (check_warning_value==TRUE && sap_entries >= warning_value) | 631 | else if (check_warning_value==TRUE && sap_entries >= warning_value) |
| @@ -811,9 +811,9 @@ main(int argc, char **argv) { | |||
| 811 | result=send_tcp_request(sd,send_buffer,recv_buffer,sizeof(recv_buffer)); | 811 | result=send_tcp_request(sd,send_buffer,recv_buffer,sizeof(recv_buffer)); |
| 812 | if (result!=STATE_OK) | 812 | if (result!=STATE_OK) |
| 813 | return result; | 813 | return result; |
| 814 | 814 | ||
| 815 | open_files=atoi(recv_buffer); | 815 | open_files=atoi(recv_buffer); |
| 816 | 816 | ||
| 817 | if (check_critical_value==TRUE && open_files >= critical_value) | 817 | if (check_critical_value==TRUE && open_files >= critical_value) |
| 818 | result=STATE_CRITICAL; | 818 | result=STATE_CRITICAL; |
| 819 | else if (check_warning_value==TRUE && open_files >= warning_value) | 819 | else if (check_warning_value==TRUE && open_files >= warning_value) |
| @@ -836,9 +836,9 @@ main(int argc, char **argv) { | |||
| 836 | result=send_tcp_request(sd,send_buffer,recv_buffer,sizeof(recv_buffer)); | 836 | result=send_tcp_request(sd,send_buffer,recv_buffer,sizeof(recv_buffer)); |
| 837 | if (result!=STATE_OK) | 837 | if (result!=STATE_OK) |
| 838 | return result; | 838 | return result; |
| 839 | 839 | ||
| 840 | abended_threads=atoi(recv_buffer); | 840 | abended_threads=atoi(recv_buffer); |
| 841 | 841 | ||
| 842 | if (check_critical_value==TRUE && abended_threads >= critical_value) | 842 | if (check_critical_value==TRUE && abended_threads >= critical_value) |
| 843 | result=STATE_CRITICAL; | 843 | result=STATE_CRITICAL; |
| 844 | else if (check_warning_value==TRUE && abended_threads >= warning_value) | 844 | else if (check_warning_value==TRUE && abended_threads >= warning_value) |
| @@ -860,9 +860,9 @@ main(int argc, char **argv) { | |||
| 860 | result=send_tcp_request(sd,send_buffer,recv_buffer,sizeof(recv_buffer)); | 860 | result=send_tcp_request(sd,send_buffer,recv_buffer,sizeof(recv_buffer)); |
| 861 | if (result!=STATE_OK) | 861 | if (result!=STATE_OK) |
| 862 | return result; | 862 | return result; |
| 863 | 863 | ||
| 864 | max_service_processes=atoi(recv_buffer); | 864 | max_service_processes=atoi(recv_buffer); |
| 865 | 865 | ||
| 866 | close(sd); | 866 | close(sd); |
| 867 | my_tcp_connect (server_address, server_port, &sd); | 867 | my_tcp_connect (server_address, server_port, &sd); |
| 868 | 868 | ||
| @@ -870,9 +870,9 @@ main(int argc, char **argv) { | |||
| 870 | result=send_tcp_request(sd,send_buffer,recv_buffer,sizeof(recv_buffer)); | 870 | result=send_tcp_request(sd,send_buffer,recv_buffer,sizeof(recv_buffer)); |
| 871 | if (result!=STATE_OK) | 871 | if (result!=STATE_OK) |
| 872 | return result; | 872 | return result; |
| 873 | 873 | ||
| 874 | current_service_processes=atoi(recv_buffer); | 874 | current_service_processes=atoi(recv_buffer); |
| 875 | 875 | ||
| 876 | if (check_critical_value==TRUE && current_service_processes >= critical_value) | 876 | if (check_critical_value==TRUE && current_service_processes >= critical_value) |
| 877 | result=STATE_CRITICAL; | 877 | result=STATE_CRITICAL; |
| 878 | else if (check_warning_value==TRUE && current_service_processes >= warning_value) | 878 | else if (check_warning_value==TRUE && current_service_processes >= warning_value) |
| @@ -1673,7 +1673,7 @@ void print_help(void) | |||
| 1673 | printf (" %s\n", _(" (available from http://www.engr.wisc.edu/~drews/mrtg/)")); | 1673 | printf (" %s\n", _(" (available from http://www.engr.wisc.edu/~drews/mrtg/)")); |
| 1674 | printf (" %s\n", _("- Values for critical thresholds should be lower than warning thresholds")); | 1674 | printf (" %s\n", _("- Values for critical thresholds should be lower than warning thresholds")); |
| 1675 | printf (" %s\n", _(" when the following variables are checked: VPF, VKF, LTCH, CBUFF, DCB, ")); | 1675 | printf (" %s\n", _(" when the following variables are checked: VPF, VKF, LTCH, CBUFF, DCB, ")); |
| 1676 | printf (" %s\n", _(" TCB, LRUS and LRUM.\n")); | 1676 | printf (" %s\n", _(" TCB, LRUS and LRUM.")); |
| 1677 | 1677 | ||
| 1678 | printf (_(UT_SUPPORT)); | 1678 | printf (_(UT_SUPPORT)); |
| 1679 | } | 1679 | } |
diff --git a/plugins/check_overcr.c b/plugins/check_overcr.c index 33003d97..6c3675bf 100644 --- a/plugins/check_overcr.c +++ b/plugins/check_overcr.c | |||
| @@ -447,13 +447,13 @@ print_help (void) | |||
| 447 | printf (_(UT_VERBOSE)); | 447 | printf (_(UT_VERBOSE)); |
| 448 | printf ("\n"); | 448 | printf ("\n"); |
| 449 | printf ("%s\n", _("Notes:")); | 449 | printf ("%s\n", _("Notes:")); |
| 450 | 450 | ||
| 451 | printf ("%s\n", _("For the available options, the critical threshold value should always be")); | 451 | printf (" %s\n", _("For the available options, the critical threshold value should always be")); |
| 452 | printf ("%s\n\n", _("higher than the warning threshold value, EXCEPT with the uptime variable")); | 452 | printf (" %s\n\n", _("higher than the warning threshold value, EXCEPT with the uptime variable")); |
| 453 | 453 | ||
| 454 | printf ("%s\n", _("This plugin requres that Eric Molitors' Over-CR collector daemon be")); | 454 | printf ("%s\n", _("This plugin requres that Eric Molitors' Over-CR collector daemon be")); |
| 455 | printf ("%s\n", _("running on the remote server.")); | 455 | printf ("%s\n", _("running on the remote server.")); |
| 456 | printf ("%s\n", " Over-CR can be downloaded from http://www.molitor.org/overcr"); | 456 | printf ("%s\n", _("Over-CR can be downloaded from http://www.molitor.org/overcr")); |
| 457 | printf ("%s\n", _("This plugin was tested with version 0.99.53 of the Over-CR collector")); | 457 | printf ("%s\n", _("This plugin was tested with version 0.99.53 of the Over-CR collector")); |
| 458 | 458 | ||
| 459 | printf (_(UT_SUPPORT)); | 459 | printf (_(UT_SUPPORT)); |
diff --git a/plugins/check_pgsql.c b/plugins/check_pgsql.c index 05633228..c721b07c 100644 --- a/plugins/check_pgsql.c +++ b/plugins/check_pgsql.c | |||
| @@ -438,9 +438,11 @@ print_help (void) | |||
| 438 | printf (" %s\n", _("specified database, and then disconnects. If no database is specified, it")); | 438 | printf (" %s\n", _("specified database, and then disconnects. If no database is specified, it")); |
| 439 | printf (" %s\n", _("connects to the template1 database, which is present in every functioning")); | 439 | printf (" %s\n", _("connects to the template1 database, which is present in every functioning")); |
| 440 | printf (" %s\n\n", _("PostgreSQL DBMS.")); | 440 | printf (" %s\n\n", _("PostgreSQL DBMS.")); |
| 441 | |||
| 441 | printf (" %s\n", _("The plugin will connect to a local postmaster if no host is specified. To")); | 442 | printf (" %s\n", _("The plugin will connect to a local postmaster if no host is specified. To")); |
| 442 | printf (" %s\n", _("connect to a remote host, be sure that the remote postmaster accepts TCP/IP")); | 443 | printf (" %s\n", _("connect to a remote host, be sure that the remote postmaster accepts TCP/IP")); |
| 443 | printf (" %s\n\n", _("connections (start the postmaster with the -i option).")); | 444 | printf (" %s\n\n", _("connections (start the postmaster with the -i option).")); |
| 445 | |||
| 444 | printf (" %s\n", _("Typically, the nagios user (unless the --logname option is used) should be")); | 446 | printf (" %s\n", _("Typically, the nagios user (unless the --logname option is used) should be")); |
| 445 | printf (" %s\n", _("able to connect to the database without a password. The plugin can also send")); | 447 | printf (" %s\n", _("able to connect to the database without a password. The plugin can also send")); |
| 446 | printf (" %s\n", _("a password, but no effort is made to obsure or encrypt the password.")); | 448 | printf (" %s\n", _("a password, but no effort is made to obsure or encrypt the password.")); |
diff --git a/plugins/check_ping.c b/plugins/check_ping.c index 214e23b0..ac43a0c4 100644 --- a/plugins/check_ping.c +++ b/plugins/check_ping.c | |||
| @@ -572,19 +572,17 @@ print_help (void) | |||
| 572 | 572 | ||
| 573 | printf (_(UT_TIMEOUT), DEFAULT_SOCKET_TIMEOUT); | 573 | printf (_(UT_TIMEOUT), DEFAULT_SOCKET_TIMEOUT); |
| 574 | 574 | ||
| 575 | printf ("\n"); | ||
| 575 | printf ("%s\n", _("THRESHOLD is <rta>,<pl>% where <rta> is the round trip average travel")); | 576 | printf ("%s\n", _("THRESHOLD is <rta>,<pl>% where <rta> is the round trip average travel")); |
| 576 | printf ("%s\n", _("time (ms) which triggers a WARNING or CRITICAL state, and <pl> is the")); | 577 | printf ("%s\n", _("time (ms) which triggers a WARNING or CRITICAL state, and <pl> is the")); |
| 577 | printf ("%s\n", _("percentage of packet loss to trigger an alarm state.")); | 578 | printf ("%s\n", _("percentage of packet loss to trigger an alarm state.")); |
| 578 | 579 | ||
| 579 | printf ("\n\n"); | 580 | printf ("\n"); |
| 580 | |||
| 581 | printf ("%s\n", _("This plugin uses the ping command to probe the specified host for packet loss")); | 581 | printf ("%s\n", _("This plugin uses the ping command to probe the specified host for packet loss")); |
| 582 | printf ("%s\n", _("(percentage) and round trip average (milliseconds). It can produce HTML output")); | 582 | printf ("%s\n", _("(percentage) and round trip average (milliseconds). It can produce HTML output")); |
| 583 | printf ("%s\n", _("linking to a traceroute CGI contributed by Ian Cass. The CGI can be found in")); | 583 | printf ("%s\n", _("linking to a traceroute CGI contributed by Ian Cass. The CGI can be found in")); |
| 584 | printf ("%s\n", _("the contrib area of the downloads section at http://www.nagios.org/")); | 584 | printf ("%s\n", _("the contrib area of the downloads section at http://www.nagios.org/")); |
| 585 | 585 | ||
| 586 | printf ("\n\n"); | ||
| 587 | |||
| 588 | printf (_(UT_SUPPORT)); | 586 | printf (_(UT_SUPPORT)); |
| 589 | } | 587 | } |
| 590 | 588 | ||
diff --git a/plugins/check_procs.c b/plugins/check_procs.c index d56d4571..816da1b7 100644 --- a/plugins/check_procs.c +++ b/plugins/check_procs.c | |||
| @@ -712,7 +712,7 @@ print_help (void) | |||
| 712 | printf ("%s\n", _("of processes. Search filters can be applied to limit the processes to check.")); | 712 | printf ("%s\n", _("of processes. Search filters can be applied to limit the processes to check.")); |
| 713 | 713 | ||
| 714 | printf ("\n\n"); | 714 | printf ("\n\n"); |
| 715 | 715 | ||
| 716 | print_usage (); | 716 | print_usage (); |
| 717 | 717 | ||
| 718 | printf ("%s\n", _("Required Arguments:")); | 718 | printf ("%s\n", _("Required Arguments:")); |
| @@ -781,7 +781,7 @@ be the total number of running processes\n\n")); | |||
| 781 | printf (" %s\n", "check_procs -w 50000 -c 100000 --metric=VSZ"); | 781 | printf (" %s\n", "check_procs -w 50000 -c 100000 --metric=VSZ"); |
| 782 | printf (" %s\n\n", _("Alert if vsz of any processes over 50K or 100K")); | 782 | printf (" %s\n\n", _("Alert if vsz of any processes over 50K or 100K")); |
| 783 | printf (" %s\n", "check_procs -w 10 -c 20 --metric=CPU"); | 783 | printf (" %s\n", "check_procs -w 10 -c 20 --metric=CPU"); |
| 784 | printf (" %s\n\n", _("Alert if cpu of any processes over 10%% or 20%%")); | 784 | printf (" %s\n", _("Alert if cpu of any processes over 10%% or 20%%")); |
| 785 | 785 | ||
| 786 | printf (_(UT_SUPPORT)); | 786 | printf (_(UT_SUPPORT)); |
| 787 | } | 787 | } |
diff --git a/plugins/check_radius.c b/plugins/check_radius.c index ed937873..2afe3c88 100644 --- a/plugins/check_radius.c +++ b/plugins/check_radius.c | |||
| @@ -333,7 +333,8 @@ print_help (void) | |||
| 333 | 333 | ||
| 334 | printf (_(UT_TIMEOUT), timeout_interval); | 334 | printf (_(UT_TIMEOUT), timeout_interval); |
| 335 | 335 | ||
| 336 | printf ("%s\n", _("This plugin tests a radius server to see if it is accepting connections.")); | 336 | printf ("\n"); |
| 337 | printf ("%s\n", _("This plugin tests a radius server to see if it is accepting connections.")); | ||
| 337 | printf ("%s\n", _("The server to test must be specified in the invocation, as well as a user")); | 338 | printf ("%s\n", _("The server to test must be specified in the invocation, as well as a user")); |
| 338 | printf ("%s\n", _("name and password. A configuration file may also be present. The format of")); | 339 | printf ("%s\n", _("name and password. A configuration file may also be present. The format of")); |
| 339 | printf ("%s\n", _("the configuration file is described in the radiusclient library sources.")); | 340 | printf ("%s\n", _("the configuration file is described in the radiusclient library sources.")); |
diff --git a/plugins/check_real.c b/plugins/check_real.c index 03fef82c..68a6c1e2 100644 --- a/plugins/check_real.c +++ b/plugins/check_real.c | |||
| @@ -433,6 +433,7 @@ print_help (void) | |||
| 433 | 433 | ||
| 434 | printf (_(UT_VERBOSE)); | 434 | printf (_(UT_VERBOSE)); |
| 435 | 435 | ||
| 436 | printf ("\n"); | ||
| 436 | printf ("%s\n", _("This plugin will attempt to open an RTSP connection with the host.")); | 437 | printf ("%s\n", _("This plugin will attempt to open an RTSP connection with the host.")); |
| 437 | printf ("%s\n", _("Successul connects return STATE_OK, refusals and timeouts return")); | 438 | printf ("%s\n", _("Successul connects return STATE_OK, refusals and timeouts return")); |
| 438 | printf ("%s\n", _("STATE_CRITICAL, other errors return STATE_UNKNOWN. Successful connects,")); | 439 | printf ("%s\n", _("STATE_CRITICAL, other errors return STATE_UNKNOWN. Successful connects,")); |
diff --git a/plugins/check_snmp.c b/plugins/check_snmp.c index 0406ae43..b9435651 100644 --- a/plugins/check_snmp.c +++ b/plugins/check_snmp.c | |||
| @@ -993,27 +993,30 @@ print_help (void) | |||
| 993 | 993 | ||
| 994 | printf (_(UT_VERBOSE)); | 994 | printf (_(UT_VERBOSE)); |
| 995 | 995 | ||
| 996 | printf ("%s\n", _("This plugin uses the 'snmpget' command included with the NET-SNMP package.")); | 996 | printf ("\n"); |
| 997 | printf ("%s\n", _("This plugin uses the 'snmpget' command included with the NET-SNMP package.")); | ||
| 997 | printf ("%s\n", _("if you don't have the package installed, you will need to download it from")); | 998 | printf ("%s\n", _("if you don't have the package installed, you will need to download it from")); |
| 998 | printf ("%s\n", _("http://net-snmp.sourceforge.net before you can use this plugin.")); | 999 | printf ("%s\n", _("http://net-snmp.sourceforge.net before you can use this plugin.")); |
| 999 | 1000 | ||
| 1000 | printf ("%s\n", _("- Multiple OIDs may be indicated by a comma- or space-delimited list (lists with")); | 1001 | printf ("\n"); |
| 1001 | printf ("%s\n", _(" internal spaces must be quoted) [max 8 OIDs]")); | 1002 | printf ("%s\n", _("Notes:")); |
| 1002 | 1003 | printf (" %s\n", _("- Multiple OIDs may be indicated by a comma- or space-delimited list (lists with")); | |
| 1003 | printf ("%s\n", _("- Ranges are inclusive and are indicated with colons. When specified as")); | 1004 | printf (" %s\n", _("internal spaces must be quoted) [max 8 OIDs]")); |
| 1004 | printf ("%s\n", _(" 'min:max' a STATE_OK will be returned if the result is within the indicated")); | 1005 | |
| 1005 | printf ("%s\n", _(" range or is equal to the upper or lower bound. A non-OK state will be")); | 1006 | printf (" %s\n", _("- Ranges are inclusive and are indicated with colons. When specified as")); |
| 1006 | printf ("%s\n", _(" returned if the result is outside the specified range.")); | 1007 | printf (" %s\n", _("'min:max' a STATE_OK will be returned if the result is within the indicated")); |
| 1007 | 1008 | printf (" %s\n", _("range or is equal to the upper or lower bound. A non-OK state will be")); | |
| 1008 | printf ("%s\n", _("- If specified in the order 'max:min' a non-OK state will be returned if the")); | 1009 | printf (" %s\n", _("returned if the result is outside the specified range.")); |
| 1009 | printf ("%s\n", _(" result is within the (inclusive) range.")); | 1010 | |
| 1010 | 1011 | printf (" %s\n", _("- If specified in the order 'max:min' a non-OK state will be returned if the")); | |
| 1011 | printf ("%s\n", _("- Upper or lower bounds may be omitted to skip checking the respective limit.")); | 1012 | printf (" %s\n", _("result is within the (inclusive) range.")); |
| 1012 | printf ("%s\n", _("- Bare integers are interpreted as upper limits.")); | 1013 | |
| 1013 | printf ("%s\n", _("- When checking multiple OIDs, separate ranges by commas like '-w 1:10,1:,:20'")); | 1014 | printf (" %s\n", _("- Upper or lower bounds may be omitted to skip checking the respective limit.")); |
| 1014 | printf ("%s\n", _("- Note that only one string and one regex may be checked at present")); | 1015 | printf (" %s\n", _("- Bare integers are interpreted as upper limits.")); |
| 1015 | printf ("%s\n", _("- All evaluation methods other than PR, STR, and SUBSTR expect that the value")); | 1016 | printf (" %s\n", _("- When checking multiple OIDs, separate ranges by commas like '-w 1:10,1:,:20'")); |
| 1016 | printf ("%s\n", _(" returned from the SNMP query is an unsigned integer.")); | 1017 | printf (" %s\n", _("- Note that only one string and one regex may be checked at present")); |
| 1018 | printf (" %s\n", _("- All evaluation methods other than PR, STR, and SUBSTR expect that the value")); | ||
| 1019 | printf (" %s\n", _("returned from the SNMP query is an unsigned integer.")); | ||
| 1017 | 1020 | ||
| 1018 | printf (_(UT_SUPPORT)); | 1021 | printf (_(UT_SUPPORT)); |
| 1019 | } | 1022 | } |
diff --git a/plugins/check_swap.c b/plugins/check_swap.c index c8b143c5..1c627ac7 100644 --- a/plugins/check_swap.c +++ b/plugins/check_swap.c | |||
| @@ -526,7 +526,7 @@ print_help (void) | |||
| 526 | printf ("%s\n", _("Check swap space on local machine.")); | 526 | printf ("%s\n", _("Check swap space on local machine.")); |
| 527 | 527 | ||
| 528 | printf ("\n\n"); | 528 | printf ("\n\n"); |
| 529 | 529 | ||
| 530 | print_usage (); | 530 | print_usage (); |
| 531 | 531 | ||
| 532 | printf (_(UT_HELP_VRSN)); | 532 | printf (_(UT_HELP_VRSN)); |
| @@ -542,9 +542,10 @@ print_help (void) | |||
| 542 | printf (" %s\n", "-a, --allswaps"); | 542 | printf (" %s\n", "-a, --allswaps"); |
| 543 | printf (" %s\n", _("Conduct comparisons for all swap partitions, one by one")); | 543 | printf (" %s\n", _("Conduct comparisons for all swap partitions, one by one")); |
| 544 | printf (_(UT_VERBOSE)); | 544 | printf (_(UT_VERBOSE)); |
| 545 | |||
| 545 | printf ("\n"); | 546 | printf ("\n"); |
| 546 | printf ("%s\n", _("Notes:")); | 547 | printf ("%s\n", _("Notes:")); |
| 547 | printf (" %s\n", _("On AIX, if -a is specified, uses lsps -a, otherwise uses lsps -s.\n")); | 548 | printf (" %s\n", _("On AIX, if -a is specified, uses lsps -a, otherwise uses lsps -s.")); |
| 548 | 549 | ||
| 549 | printf (_(UT_SUPPORT)); | 550 | printf (_(UT_SUPPORT)); |
| 550 | } | 551 | } |
diff --git a/plugins/check_ups.c b/plugins/check_ups.c index 73702f59..666485ee 100644 --- a/plugins/check_ups.c +++ b/plugins/check_ups.c | |||
| @@ -601,7 +601,7 @@ print_help (void) | |||
| 601 | printf ("Copyright (c) 2004 Arnaud Quette <arnaud.quette@mgeups.com>\n"); | 601 | printf ("Copyright (c) 2004 Arnaud Quette <arnaud.quette@mgeups.com>\n"); |
| 602 | printf (COPYRIGHT, copyright, email); | 602 | printf (COPYRIGHT, copyright, email); |
| 603 | 603 | ||
| 604 | printf ("%s\n", _("This plugin tests the UPS service on the specified host.Network UPS Tools ")); | 604 | printf ("%s\n", _("This plugin tests the UPS service on the specified host. Network UPS Tools")); |
| 605 | printf ("%s\n", _("from www.networkupstools.org must be running for thisplugin to work.")); | 605 | printf ("%s\n", _("from www.networkupstools.org must be running for thisplugin to work.")); |
| 606 | 606 | ||
| 607 | printf ("\n\n"); | 607 | printf ("\n\n"); |
| @@ -628,22 +628,24 @@ print_help (void) | |||
| 628 | /* printf (_(UT_VERBOSE)); */ | 628 | /* printf (_(UT_VERBOSE)); */ |
| 629 | 629 | ||
| 630 | printf ("\n"); | 630 | printf ("\n"); |
| 631 | printf ("%s\n", _("Notes:")); | ||
| 632 | |||
| 633 | printf ("%s\n", _("This plugin attempts to determine the status of a UPS (Uninterruptible Power")); | 631 | printf ("%s\n", _("This plugin attempts to determine the status of a UPS (Uninterruptible Power")); |
| 634 | printf ("%s\n", _("Supply) on a local or remote host. If the UPS is online or calibrating, the")); | 632 | printf ("%s\n", _("Supply) on a local or remote host. If the UPS is online or calibrating, the")); |
| 635 | printf ("%s\n", _("plugin will return an OK state. If the battery is on it will return a WARNING")); | 633 | printf ("%s\n", _("plugin will return an OK state. If the battery is on it will return a WARNING")); |
| 636 | printf ("%s\n", _("state.If the UPS is off or has a low battery the plugin will return a CRITICAL")); | 634 | printf ("%s\n", _("state.If the UPS is off or has a low battery the plugin will return a CRITICAL")); |
| 637 | printf ("%s\n\n", _("state.")); | 635 | printf ("%s\n", _("state.")); |
| 638 | 636 | ||
| 639 | printf ("%s\n", _("You may also specify a variable to check [such as temperature, utility voltage,")); | 637 | printf ("\n"); |
| 640 | printf ("%s\n", _("battery load, etc.] as well as warning and critical thresholds for the value of")); | 638 | printf ("%s\n", _("Notes:")); |
| 641 | printf ("%s\n", _("that variable. If the remote host has multiple UPS that are being monitored you")); | 639 | printf (" %s\n", _("You may also specify a variable to check (such as temperature, utility voltage,")); |
| 642 | printf ("%s\n", _("will have to use the [ups] option to specify which UPS to check.")); | 640 | printf (" %s\n", _("battery load, etc.) as well as warning and critical thresholds for the value")); |
| 641 | printf (" %s\n", _("of that variable. If the remote host has multiple UPS that are being monitored")); | ||
| 642 | printf (" %s\n", _("you will have to use the --ups option to specify which UPS to check.")); | ||
| 643 | 643 | ||
| 644 | printf ("%s\n", _("This plugin requires that the UPSD daemon distributed with Russel Kroll's")); | 644 | printf ("\n"); |
| 645 | printf ("%s\n", _("Smart UPS Tools be installed on the remote host. If you do not have the")); | 645 | printf (" %s\n", _("This plugin requires that the UPSD daemon distributed with Russel Kroll's")); |
| 646 | printf ("%s\n", _("package installed on your system, you can download it from http://www.networkupstools.org")); | 646 | printf (" %s\n", _("Smart UPS Tools be installed on the remote host. If you do not have the")); |
| 647 | printf (" %s\n", _("package installed on your system, you can download it from")); | ||
| 648 | printf (" %s\n", _("http://www.networkupstools.org")); | ||
| 647 | 649 | ||
| 648 | printf (_(UT_SUPPORT)); | 650 | printf (_(UT_SUPPORT)); |
| 649 | } | 651 | } |
diff --git a/plugins/utils.h b/plugins/utils.h index bb99ee16..def89705 100644 --- a/plugins/utils.h +++ b/plugins/utils.h | |||
| @@ -173,10 +173,15 @@ char *fperfdata (const char *, | |||
| 173 | -t, --timeout=INTEGER\n\ | 173 | -t, --timeout=INTEGER\n\ |
| 174 | Seconds before connection times out (default: %d)\n" | 174 | Seconds before connection times out (default: %d)\n" |
| 175 | 175 | ||
| 176 | #define UT_THRESHOLDS_NOTES "\ | ||
| 177 | See:\n\ | ||
| 178 | http://nagiosplug.sourceforge.net/developer-guidelines.html#THRESHOLDFORMAT\n\ | ||
| 179 | for THRESHOLD format and examples.\n" | ||
| 180 | |||
| 176 | #define UT_SUPPORT "\n\ | 181 | #define UT_SUPPORT "\n\ |
| 177 | Send email to nagios-users@lists.sourceforge.net if you have questions\n\ | 182 | Send email to nagios-users@lists.sourceforge.net if you have questions\n\ |
| 178 | regarding use of this software. To submit patches or suggest improvements,\n\ | 183 | regarding use of this software. To submit patches or suggest improvements,\n\ |
| 179 | send email to nagiosplug-devel@lists.sourceforge.net\n" | 184 | send email to nagiosplug-devel@lists.sourceforge.net\n\n" |
| 180 | 185 | ||
| 181 | #define UT_NOWARRANTY "\n\ | 186 | #define UT_NOWARRANTY "\n\ |
| 182 | The nagios plugins come with ABSOLUTELY NO WARRANTY. You may redistribute\n\ | 187 | The nagios plugins come with ABSOLUTELY NO WARRANTY. You may redistribute\n\ |
