This matches the option offered by some other Open vSwitch daemons. I
intend to use it in tests in an upcoming commit.
Signed-off-by: Ben Pfaff <blp@nicira.com>
Acked-by: Justin Pettit <jpettit@nicira.com>
lib/daemon.man \
lib/ofp-version.man \
lib/ssl.man \
lib/daemon.man \
lib/ofp-version.man \
lib/ssl.man \
lib/vconn-active.man \
lib/vlog.man
utilities/ovs-ofctl.8.in:
lib/vconn-active.man \
lib/vlog.man
utilities/ovs-ofctl.8.in:
lib/daemon.man:
lib/ofp-version.man:
lib/ssl.man:
lib/daemon.man:
lib/ofp-version.man:
lib/ssl.man:
lib/vconn-active.man:
lib/vlog.man:
lib/vconn-active.man:
lib/vlog.man:
\fBovs\-ofctl\fR detaches only when executing the \fBmonitor\fR or \
\fBsnoop\fR commands.
.so lib/daemon.man
\fBovs\-ofctl\fR detaches only when executing the \fBmonitor\fR or \
\fBsnoop\fR commands.
.so lib/daemon.man
.SS "Public Key Infrastructure Options"
.so lib/ssl.man
.so lib/vlog.man
.SS "Public Key Infrastructure Options"
.so lib/ssl.man
.so lib/vlog.man
* "snoop" command? */
static bool timestamp;
* "snoop" command? */
static bool timestamp;
+/* --unixctl-path: Path to use for unixctl server, for "monitor" and "snoop"
+ commands. */
+static char *unixctl_path;
+
/* --sort, --rsort: Sort order. */
enum sort_order { SORT_ASC, SORT_DESC };
struct sort_criterion {
/* --sort, --rsort: Sort order. */
enum sort_order { SORT_ASC, SORT_DESC };
struct sort_criterion {
OPT_TIMESTAMP,
OPT_SORT,
OPT_RSORT,
OPT_TIMESTAMP,
OPT_SORT,
OPT_RSORT,
DAEMON_OPTION_ENUMS,
OFP_VERSION_OPTION_ENUMS,
VLOG_OPTION_ENUMS
DAEMON_OPTION_ENUMS,
OFP_VERSION_OPTION_ENUMS,
VLOG_OPTION_ENUMS
{"timestamp", no_argument, NULL, OPT_TIMESTAMP},
{"sort", optional_argument, NULL, OPT_SORT},
{"rsort", optional_argument, NULL, OPT_RSORT},
{"timestamp", no_argument, NULL, OPT_TIMESTAMP},
{"sort", optional_argument, NULL, OPT_SORT},
{"rsort", optional_argument, NULL, OPT_RSORT},
+ {"unixctl", required_argument, NULL, OPT_UNIXCTL},
{"help", no_argument, NULL, 'h'},
DAEMON_LONG_OPTIONS,
OFP_VERSION_LONG_OPTIONS,
{"help", no_argument, NULL, 'h'},
DAEMON_LONG_OPTIONS,
OFP_VERSION_LONG_OPTIONS,
add_sort_criterion(SORT_DESC, optarg);
break;
add_sort_criterion(SORT_DESC, optarg);
break;
+ case OPT_UNIXCTL:
+ unixctl_path = optarg;
+ break;
+
DAEMON_OPTION_HANDLERS
OFP_VERSION_OPTION_HANDLERS
VLOG_OPTION_HANDLERS
DAEMON_OPTION_HANDLERS
OFP_VERSION_OPTION_HANDLERS
VLOG_OPTION_HANDLERS
" -t, --timeout=SECS give up after SECS seconds\n"
" --sort[=field] sort in ascending order\n"
" --rsort[=field] sort in descending order\n"
" -t, --timeout=SECS give up after SECS seconds\n"
" --sort[=field] sort in ascending order\n"
" --rsort[=field] sort in descending order\n"
+ " --unixctl=SOCKET set control socket name\n"
" -h, --help display this help message\n"
" -V, --version display version information\n");
exit(EXIT_SUCCESS);
" -h, --help display this help message\n"
" -V, --version display version information\n");
exit(EXIT_SUCCESS);
daemon_save_fd(STDERR_FILENO);
daemonize_start();
daemon_save_fd(STDERR_FILENO);
daemonize_start();
- error = unixctl_server_create(NULL, &server);
+ error = unixctl_server_create(unixctl_path, &server);
if (error) {
ovs_fatal(error, "failed to create unixctl server");
}
if (error) {
ovs_fatal(error, "failed to create unixctl server");
}