tests: Make ovsdb test more robust and faster.
[cascardo/ovs.git] / lib / daemon.man
1 The following options are valid on POSIX based platforms.
2 .TP
3 \fB\-\-pidfile\fR[\fB=\fIpidfile\fR]
4 Causes a file (by default, \fB\*(PN.pid\fR) to be created indicating
5 the PID of the running process.  If the \fIpidfile\fR argument is not
6 specified, or
7 if it does not begin with \fB/\fR, then it is created in
8 \fB@RUNDIR@\fR.
9 .IP
10 If \fB\-\-pidfile\fR is not specified, no pidfile is created.
11 .
12 .TP
13 \fB\-\-overwrite\-pidfile\fR
14 By default, when \fB\-\-pidfile\fR is specified and the specified pidfile 
15 already exists and is locked by a running process, \fB\*(PN\fR refuses 
16 to start.  Specify \fB\-\-overwrite\-pidfile\fR to cause it to instead 
17 overwrite the pidfile.
18 .IP
19 When \fB\-\-pidfile\fR is not specified, this option has no effect.
20 .
21 .IP \fB\-\-detach\fR
22 Runs \fB\*(PN\fR as a background process.  The process forks, and in
23 the child it starts a new session, closes the standard file
24 descriptors (which has the side effect of disabling logging to the
25 console), and changes its current directory to the root (unless
26 \fB\-\-no\-chdir\fR is specified).  After the child completes its
27 initialization, the parent exits.  \*(DD
28 .
29 .TP
30 \fB\-\-monitor\fR
31 Creates an additional process to monitor the \fB\*(PN\fR daemon.  If
32 the daemon dies due to a signal that indicates a programming error
33 (\fBSIGABRT\fR, \fBSIGALRM\fR, \fBSIGBUS\fR, \fBSIGFPE\fR,
34 \fBSIGILL\fR, \fBSIGPIPE\fR, \fBSIGSEGV\fR, \fBSIGXCPU\fR, or
35 \fBSIGXFSZ\fR) then the monitor process starts a new copy of it.  If
36 the daemon dies or exits for another reason, the monitor process exits.
37 .IP
38 This option is normally used with \fB\-\-detach\fR, but it also
39 functions without it.
40 .
41 .TP
42 \fB\-\-no\-chdir\fR
43 By default, when \fB\-\-detach\fR is specified, \fB\*(PN\fR 
44 changes its current working directory to the root directory after it 
45 detaches.  Otherwise, invoking \fB\*(PN\fR from a carelessly chosen 
46 directory would prevent the administrator from unmounting the file 
47 system that holds that directory.
48 .IP
49 Specifying \fB\-\-no\-chdir\fR suppresses this behavior, preventing
50 \fB\*(PN\fR from changing its current working directory.  This may be 
51 useful for collecting core files, since it is common behavior to write 
52 core dumps into the current working directory and the root directory 
53 is not a good directory to use.
54 .IP
55 This option has no effect when \fB\-\-detach\fR is not specified.
56 .
57 .TP
58 \fB\-\-no\-self\-confinement\fR
59 By default daemon will try to self-confine itself to work with
60 files under well-know, at build-time whitelisted directories.  It
61 is better to stick with this default behavior and not to use this
62 flag unless some other Access Control is used to confine daemon.
63 Note that in contrast to other access control implementations that
64 are typically enforced from kernel-space (e.g. DAC or MAC),
65 self-confinement is imposed from the user-space daemon itself and
66 hence should not be considered as a full confinement strategy, but
67 instead should be viewed as an additional layer of security.
68 .
69 .TP
70 \fB\-\-user\fR
71 Causes \fB\*(PN\fR to run as a different user specified in "user:group", thus
72 dropping most of the root privileges. Short forms "user" and ":group" are also
73 allowed, with current user or group are assumed respectively. Only daemons
74 started by the root user accepts this argument.
75 .IP
76 On Linux, daemons will be granted CAP_IPC_LOCK and CAP_NET_BIND_SERVICES
77 before dropping root privileges. Daemons interact with datapath,
78 such as ovs-vswitchd, will be granted two additional capabilities, namely
79 CAP_NET_ADMIN and CAP_NET_RAW. The capability change will apply even if
80 new user is "root".
81 .IP
82 On Windows, this option is not currently supported. For security reasons,
83 specifying this option will cause the daemon process not to start.