add a new commandline flag -v to enable verbose output
authorRonnie Sahlberg <ronniesahlberg@gmail.com>
Fri, 20 Aug 2010 01:28:24 +0000 (11:28 +1000)
committerRonnie Sahlberg <ronniesahlberg@gmail.com>
Fri, 20 Aug 2010 01:28:24 +0000 (11:28 +1000)
tools/ctdb.c

index 9f95d28b5221cee788cc15223f1817ce17865859..bc39674d5a56434981f90d1593af48a19685621f 100644 (file)
@@ -44,6 +44,7 @@ static struct {
        int timelimit;
        uint32_t pnn;
        int machinereadable;
+       int verbose;
        int maxruntime;
 } options;
 
@@ -4529,6 +4530,7 @@ static void usage(void)
 "Options:\n" \
 "   -n <node>          choose node number, or 'all' (defaults to local node)\n"
 "   -Y                 generate machinereadable output\n"
+"   -v                 generate verbose output\n"
 "   -t <timelimit>     set timelimit for control in seconds (default %u)\n", options.timelimit);
        printf("Controls:\n");
        for (i=0;i<ARRAY_SIZE(ctdb_commands);i++) {
@@ -4560,6 +4562,7 @@ int main(int argc, const char *argv[])
                { "timelimit", 't', POPT_ARG_INT, &options.timelimit, 0, "timelimit", "integer" },
                { "node",      'n', POPT_ARG_STRING, &nodestring, 0, "node", "integer|all" },
                { "machinereadable", 'Y', POPT_ARG_NONE, &options.machinereadable, 0, "enable machinereadable output", NULL },
+               { "verbose",    'v', POPT_ARG_NONE, &options.verbose, 0, "enable verbose output", NULL },
                { "maxruntime", 'T', POPT_ARG_INT, &options.maxruntime, 0, "die if runtime exceeds this limit (in seconds)", "integer" },
                POPT_TABLEEND
        };