summaryrefslogtreecommitdiffstats
path: root/plugins/check_pgsql.c
diff options
context:
space:
mode:
authorBenoit Mortier <opensides@users.sourceforge.net>2006-06-17 12:28:43 +0000
committerBenoit Mortier <opensides@users.sourceforge.net>2006-06-17 12:28:43 +0000
commitcbbfed30eb01a702b2e61c0abcb64c834e73d654 (patch)
treeb9d050fa415733f80306530e1ed028ef3ce9759a /plugins/check_pgsql.c
parente5324624caefb201439012d795bebdf46966ec9c (diff)
downloadmonitoring-plugins-cbbfed30eb01a702b2e61c0abcb64c834e73d654.tar.gz
cleaning up help and usage
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1433 f882894a-f735-0410-b71e-b25c423dba1c
Diffstat (limited to 'plugins/check_pgsql.c')
-rw-r--r--plugins/check_pgsql.c54
1 files changed, 27 insertions, 27 deletions
diff --git a/plugins/check_pgsql.c b/plugins/check_pgsql.c
index 8cfc1ab5..f258708c 100644
--- a/plugins/check_pgsql.c
+++ b/plugins/check_pgsql.c
@@ -20,7 +20,7 @@
20 20
21const char *progname = "check_pgsql"; 21const char *progname = "check_pgsql";
22const char *revision = "$Revision$"; 22const char *revision = "$Revision$";
23const char *copyright = "1999-2004"; 23const char *copyright = "1999-2006";
24const char *email = "nagiosplug-devel@lists.sourceforge.net"; 24const char *email = "nagiosplug-devel@lists.sourceforge.net";
25 25
26#include "common.h" 26#include "common.h"
@@ -391,7 +391,9 @@ print_help (void)
391 391
392 printf (COPYRIGHT, copyright, email); 392 printf (COPYRIGHT, copyright, email);
393 393
394 printf (_("Test whether a PostgreSQL Database is accepting connections.\n\n")); 394 printf (_("Test whether a PostgreSQL Database is accepting connections."));
395
396 printf ("\n\n");
395 397
396 print_usage (); 398 print_usage ();
397 399
@@ -401,13 +403,13 @@ print_help (void)
401 403
402 printf (_(UT_IPv46)); 404 printf (_(UT_IPv46));
403 405
404 printf (_("\ 406 printf (" %s\n", "-d, --database=STRING");
405 -d, --database=STRING\n\ 407 printf (" %s", _("Database to check "));
406 Database to check (default: %s)\n\ 408 printf (_("(default: %s)"), DEFAULT_DB);
407 -l, --logname = STRING\n\ 409 printf (" %s\n", "-l, --logname = STRING");
408 Login name of user\n\ 410 printf (" %s\n", _("Login name of user"));
409 -p, --password = STRING\n\ 411 printf (" %s\n", "-p, --password = STRING");
410 Password (BIG SECURITY ISSUE)\n"), DEFAULT_DB); 412 printf (" %s\n", _("Password (BIG SECURITY ISSUE)"));
411 413
412 printf (_(UT_WARN_CRIT)); 414 printf (_(UT_WARN_CRIT));
413 415
@@ -415,21 +417,19 @@ print_help (void)
415 417
416 printf (_(UT_VERBOSE)); 418 printf (_(UT_VERBOSE));
417 419
418 printf (_("\nAll parameters are optional.\n\ 420 printf ("\n");
419\n\ 421 printf (" %s\n", _("All parameters are optional."));
420This plugin tests a PostgreSQL DBMS to determine whether it is active and\n\ 422 printf (" %s\n", _("This plugin tests a PostgreSQL DBMS to determine whether it is active and"));
421accepting queries. In its current operation, it simply connects to the\n\ 423 printf (" %s\n", _("accepting queries. In its current operation, it simply connects to the"));
422specified database, and then disconnects. If no database is specified, it\n\ 424 printf (" %s\n", _("specified database, and then disconnects. If no database is specified, it"));
423connects to the template1 database, which is present in every functioning \n\ 425 printf (" %s\n", _("connects to the template1 database, which is present in every functioning"));
424PostgreSQL DBMS.\n")); 426 printf (" %s\n\n", _("PostgreSQL DBMS."));
425 printf (_("\n\ 427 printf (" %s\n", _("The plugin will connect to a local postmaster if no host is specified. To"));
426The plugin will connect to a local postmaster if no host is specified. To\n\ 428 printf (" %s\n", _("connect to a remote host, be sure that the remote postmaster accepts TCP/IP"));
427connect to a remote host, be sure that the remote postmaster accepts TCP/IP\n\ 429 printf (" %s\n\n", _("connections (start the postmaster with the -i option)."));
428connections (start the postmaster with the -i option).\n")); 430 printf (" %s\n", _("Typically, the nagios user (unless the --logname option is used) should be"));
429 printf (_("\n\ 431 printf (" %s\n", _("able to connect to the database without a password. The plugin can also send"));
430Typically, the nagios user (unless the --logname option is used) should be\n\ 432 printf (" %s\n", _("a password, but no effort is made to obsure or encrypt the password."));
431able to connect to the database without a password. The plugin can also send\n\
432a password, but no effort is made to obsure or encrypt the password.\n"));
433 433
434 printf (_(UT_SUPPORT)); 434 printf (_(UT_SUPPORT));
435} 435}
@@ -439,7 +439,7 @@ a password, but no effort is made to obsure or encrypt the password.\n"));
439void 439void
440print_usage (void) 440print_usage (void)
441{ 441{
442 printf ("\ 442 printf (_("Usage:"));
443Usage: %s [-H <host>] [-P <port>] [-c <critical time>] [-w <warning time>]\n\ 443 printf ("%s [-H <host>] [-P <port>] [-c <critical time>] [-w <warning time>]\n", progname);
444 [-t <timeout>] [-d <database>] [-l <logname>] [-p <password>]\n", progname); 444 printf (" [-t <timeout>] [-d <database>] [-l <logname>] [-p <password>]\n");
445} 445}