diff --git a/doc/running.rst b/doc/running.rst index 496834ed95496e1155272213b85ee02b4a603241..0a80081e5c001fc1ffbd22698ed6c21d1b655e64 100644 --- a/doc/running.rst +++ b/doc/running.rst @@ -45,14 +45,13 @@ If you want to control the daemon directly, use ``SIGINT`` to quit the process o -f, --force Force operation - override some checks. -v, --verbose Verbose mode - additional runtime information. -V, --version Print knot server version. - -i, --interactive Interactive mode (do not daemonize). -h, --help Print help and usage. Actions: stop Stop server. reload Reload configuration and changed zones. refresh <zone> Refresh slave zone (all if not specified). - flush Flush journal and update zone files. + flush <zone> Flush journal and update zone files. (all if not specified) status Check if server is running. zonestatus Show status of configured zones. checkconf Check current server configuration. diff --git a/man/knotc.8.in b/man/knotc.8.in index badf20ad9f6b368c6e6d7386500861d16c98cd05..543b281d1032b41b6140ebba85b7ee9ac81d8571 100644 --- a/man/knotc.8.in +++ b/man/knotc.8.in @@ -32,9 +32,6 @@ Verbose mode \- additional runtime information. \fB\-V\fR, \fB\-\-version\fR Print version of the server. .TP -\fB\-i\fR, \fB\-\-interactive\fR -Interactive mode (do not daemonize). -.TP \fB\-h\fR, \fB\-\-help\fR Print help and usage. .SS "Actions:" @@ -42,11 +39,11 @@ Print help and usage. \fBstop\fR Stop server (no\-op if not running). .TP -\fBreload\fR -Reload configuration and changed zones. +\fBreload\fR [\fIzone\fR]... +Reload configuration and changed zones (all if not specified). .TP -\fBflush\fR -Flush journal and update zone files. +\fBflush\fR [\fIzone\fR]... +Flush journal and update zone files (all if not specified). .TP \fBstatus\fR Check if server is running. diff --git a/src/knot/ctl/knotc_main.c b/src/knot/ctl/knotc_main.c index d882106d7ddfc1d0c55650f56f26ed2af7d7e23c..ca6b25a20d9768ab51239a67cecaded7123f7b8a 100644 --- a/src/knot/ctl/knotc_main.c +++ b/src/knot/ctl/knotc_main.c @@ -42,8 +42,7 @@ enum knotc_flag_t { F_NULL = 0 << 0, F_FORCE = 1 << 0, F_VERBOSE = 1 << 1, - F_INTERACTIVE = 1 << 2, - F_NOCONF = 1 << 3, + F_NOCONF = 1 << 2 }; /*! \brief Check if flag is present. */ @@ -79,9 +78,9 @@ static int cmd_signzone(int argc, char *argv[], unsigned flags); /*! \brief Table of remote commands. */ knot_cmd_t knot_cmd_tbl[] = { {&cmd_stop, 0, "stop", "", "\t\tStop server."}, - {&cmd_reload, 0, "reload", "", "\tReload configuration and changed zones."}, + {&cmd_reload, 0, "reload", "<zone>", "\tReload configuration and changed zones."}, {&cmd_refresh, 0, "refresh", "<zone>", "\tRefresh slave zone (all if not specified). Flag '-f' forces retransfer."}, - {&cmd_flush, 0, "flush", "", "\t\tFlush journal and update zone files."}, + {&cmd_flush, 0, "flush", "<zone>", "\t\tFlush journal and update zone file (all if not specified)."}, {&cmd_status, 0, "status", "", "\tCheck if server is running."}, {&cmd_zonestatus, 0, "zonestatus", "", "\tShow status of configured zones."}, {&cmd_checkconf, 1, "checkconf", "", "\tCheck current server configuration."}, @@ -104,7 +103,6 @@ void help(void) " -f, --force \tForce operation - override some checks.\n" " -v, --verbose \tVerbose mode - additional runtime information.\n" " -V, --version \tPrint %s server version.\n" - " -i, --interactive \tInteractive mode (do not daemonize).\n" " -h, --help \tPrint help and usage.\n", RUN_DIR "/knot.sock", PACKAGE_NAME); printf("\nActions:\n"); @@ -434,7 +432,6 @@ int main(int argc, char **argv) {"force", no_argument, 0, 'f'}, {"config", required_argument, 0, 'c'}, {"verbose", no_argument, 0, 'v'}, - {"interactive", no_argument, 0, 'i'}, {"version", no_argument, 0, 'V'}, {"help", no_argument, 0, 'h'}, {"server", required_argument, 0, 's' }, @@ -444,7 +441,7 @@ int main(int argc, char **argv) {0, 0, 0, 0} }; - while ((c = getopt_long(argc, argv, "s:p:y:k:fc:viVh", opts, &li)) != -1) { + while ((c = getopt_long(argc, argv, "s:p:y:k:fc:vVh", opts, &li)) != -1) { switch (c) { case 's': r_addr = optarg; @@ -472,9 +469,6 @@ int main(int argc, char **argv) case 'v': flags |= F_VERBOSE; break; - case 'i': - flags |= F_INTERACTIVE; - break; case 'c': config_fn = optarg; break;