fixes init script for non ipv6 enabled systems #472755
[packages/xinetd.git] / xinetd / xinetd.man
1 .\"(c) Copyright 1992 by Panagiotis Tsirigotis
2 .\"(c) Sections Copyright 1998-2001 by Rob Braun
3 .\"All rights reserved.  The file named COPYRIGHT specifies the terms 
4 .\"and conditions for redistribution.
5 .\"
6 .\" $Id: xinetd.man,v 1.3 2003/05/30 15:10:57 steveg Exp $
7 .TH XINETD 8 "14 June 2001"
8 .\" *************************** NAME *********************************
9 .SH NAME
10 xinetd \- the extended Internet services daemon
11 .\" *************************** SYNOPSIS *********************************
12 .SH SYNOPSIS
13 .B xinetd
14 [\fIoptions\fP]
15 .\" *************************** DESCRIPTION *********************************
16 .SH DESCRIPTION
17 \fBxinetd\fP performs the same function as \fBinetd\fP: it starts
18 programs that provide Internet services.  Instead of having such
19 servers started at system initialization time, and be dormant until a
20 connection request arrives, \fBxinetd\fP is the only daemon process
21 started and it listens on all service ports for the services listed in
22 its configuration file. When a request comes in, \fBxinetd\fP starts
23 the appropriate server.  Because of the way it operates, \fBxinetd\fP
24 (as well as \fBinetd\fP) is also referred to as a super-server.
25 .LP
26 The services listed in \fBxinetd\fP's configuration file can be
27 separated into two groups.  Services in the first group are called
28 .I "multi-threaded"
29 and they require the forking of a new server process for each new
30 connection request.  The new server then handles that connection.  For
31 such services, \fBxinetd\fP keeps listening for new requests so that it
32 can spawn new servers.  On the other hand, the second group includes
33 services for which the service daemon is responsible for handling all
34 new connection requests.  Such services are called
35 .I "single-threaded"
36 and \fBxinetd\fP will stop handling new requests for them until the
37 server dies.  Services in this group are usually datagram-based.
38 .LP
39 So far, the only reason for the existence of a super-server was to
40 conserve system resources by avoiding to fork a lot of processes which
41 might be dormant for most of their lifetime.  While fulfilling this
42 function, \fBxinetd\fP takes advantage of the idea of a super-server to
43 provide features such as access control and logging.  Furthermore,
44 \fBxinetd\fP is not limited to services listed in
45 .I /etc/services.
46 Therefore, anybody can use \fBxinetd\fP to start special-purpose
47 servers.
48 .\" *************************** OPTIONS *********************************
49 .SH OPTIONS
50 .TP
51 .BR \-d
52 Enables debug mode. This produces a lot of debugging output, and it
53 makes it possible to use a debugger on \fBxinetd\fP.
54 .TP
55 .BI \-syslog " syslog_facility"
56 This option enables syslog logging of \fBxinetd\fP-produced messages
57 using the specified syslog facility.
58 The following facility names are supported:
59 .I daemon,
60 .I auth,
61 .I user,
62 .I "local[0-7]"
63 (check \fIsyslog.conf(5)\fP for their meanings).
64 This option is ineffective in debug mode since all relevant messages are sent
65 to the terminal.
66 .TP
67 .BI \-filelog " logfile"
68 \fBxinetd\fP-produced messages will be placed in the specified file.
69 Messages are always appended to the file.
70 If the file does not exist, it will be created.
71 This option is ineffective in debug mode since all relevant messages are sent
72 to the terminal.
73 .TP
74 .BI \-f " config_file"
75 Determines the file that \fBxinetd\fP uses for configuration. The
76 default is \fI/etc/xinetd.conf\fP.
77 .TP
78 .BR \-pidfile " pid_file"
79 .br
80 The process ID is written to the file. This option is ineffective in debug mode. 
81 .TP
82 .BI \-dontfork 
83 Tells xinetd to stay in the foreground rather than detaching itself, to
84 support being run from init or daemontools. This option automatically sets 
85 .B \-stayalive
86 (see below).
87 .TP
88 .BI \-stayalive 
89 Tells xinetd to stay running even if no services are specified.
90 .TP
91 .BI \-limit " proc_limit"
92 This option places a limit on the number of concurrently running processes
93 that can be started by
94 .B xinetd.
95 Its purpose is to prevent process table overflows.
96 .TP
97 .BI \-logprocs " limit"
98 This option places a limit on the number of concurrently running servers
99 for remote userid acquisition.
100 .TP
101 .BI \-version
102 This option causes xinetd to print out its version information.
103 .TP
104 .BI \-inetd_compat
105 This option causes xinetd to read /etc/inetd.conf in addition to the
106 standard xinetd config files.  /etc/inetd.conf is read after the
107 standard xinetd config files.
108 .TP
109 .BI \-cc " interval"
110 This option instructs
111 .B xinetd
112 to perform periodic consistency checks on its internal state every
113 .I interval
114 seconds.
115 .LP
116 The \fIsyslog\fP and \fIfilelog\fP options are mutually exclusive.
117 If none is specified, the default is syslog using the
118 .I daemon
119 facility.
120 You should not confuse \fBxinetd\fP messages with messages related to
121 service logging. The latter are logged only if this is specified
122 via the configuration file.
123 .\" *********************** CONTROLLING XINETD ****************************
124 .SH "CONTROLLING XINETD"
125 .LP
126 \fBxinetd\fP performs certain actions when it receives certain signals.
127 The actions associated with the specific signals can be redefined
128 by editing \fIconfig.h\fP and recompiling.
129 .TP 15
130 .B SIGHUP
131 causes a hard reconfiguration, which means that \fBxinetd\fP re-reads 
132 the configuration file and terminates the servers for services that 
133 are no longer available. Access control is performed again on 
134 running servers by checking the remote location, access times and 
135 server instances. If the number of server instances is lowered, some 
136 arbitrarily picked servers will be killed to satisfy the limit; this 
137 will happen \fIafter\fP any servers are terminated because of failing 
138 the remote location or access time checks.
139 Also, if the
140 .B INTERCEPT
141 flag was clear and is set, any running servers for that service will
142 be terminated;
143 \fIthe purpose of this is to ensure that after a hard reconfiguration
144 there will be no running servers that can accept packets from addresses
145 that do not meet the access control criteria\fP.
146 .TP
147 .B SIGQUIT
148 causes program termination.
149 .TP
150 .B SIGTERM
151 terminates all running servers before terminating \fBxinetd\fP.
152 .TP
153 .B SIGUSR1
154 causes an internal state dump (the default dump file is
155 \fI/var/run/xinetd.dump\fP;
156 to change the filename, edit \fIconfig.h\fP and recompile).
157 .TP
158 .B SIGIOT
159 causes an internal consistency check to verify that the data structures
160 used by the program have not been corrupted.
161 When the check is completed
162 .B xinetd
163 will generate a message that says if the check was successful or not.
164 .LP
165 On reconfiguration the log files are closed and reopened. This allows
166 removal of old log files.
167 .\" *********************** FILES ****************************
168 .SH FILES
169 .LP
170 .PD .1v
171 .TP 20
172 .B /etc/xinetd.conf
173 default configuration file
174 .TP
175 .B /var/run/xinetd.dump
176 default dump file
177 .PD
178 .\" *********************** SEE ALSO ****************************
179 .SH "SEE ALSO"
180 .I "inetd(8),"
181 .LP
182 .I "xinetd.conf(5),"
183 .LP
184 .I "xinetd.log(5)"
185 .LP
186 .I "http://cr.yp.to/daemontools.html"
187 .\" *********************** AUTHOR ****************************
188 .SH AUTHOR
189 Panos Tsirigotis, CS Dept, University of Colorado, Boulder
190 Rob Braun
191 .\" *********************** PRONUNCIATION ****************************
192 .SH PRONUNCIATION
193 zy-net-d
194