1 .\" Copyright (c) 1985, 1991 The Regents of the University of California.
2 .\" All rights reserved.
4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\" notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\" notice, this list of conditions and the following disclaimer in the
11 .\" documentation and/or other materials provided with the distribution.
12 .\" 3. All advertising materials mentioning features or use of this software
13 .\" must display the following acknowledgement:
14 .\" This product includes software developed by the University of
15 .\" California, Berkeley and its contributors.
16 .\" 4. Neither the name of the University nor the names of its contributors
17 .\" may be used to endorse or promote products derived from this software
18 .\" without specific prior written permission.
20 .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
21 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
22 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
23 .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
24 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
25 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
26 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
27 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
28 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
29 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
32 .\" from: @(#)inetd.8 6.7 (Berkeley) 3/16/91
33 .\" $Id: inetd.8,v 1.18 2000/07/30 23:56:58 dholland Exp $
37 .Os "Linux NetKit (0.17)"
45 .Op Fl q Ar queuelength
46 .Op Ar configuration file
49 should be run at boot time by
55 can respawn arbitrary daemons,
57 can be run from init instead; then init will restart it if it crashes.
62 from backgrounding itself, or init will become confused.
65 .Nm inetd listens for connections on certain
66 internet sockets. When a connection is found on one of its sockets,
67 it looks up what service the socket corresponds to, and invokes a
68 program to service the request. After the program is finished, it
69 will continue to listen on the socket, except in some special cases
70 which will be described below. Essentially,
72 allows running one daemon to invoke several others,
73 reducing load on the system.
75 The options available for
79 Turns on several kinds of debugging and make inetd behave if run in a
80 debugger. Also implies
83 Do not background; for running from
85 .It Fl q Ar queuelength
86 Sets the size of the socket listen queue to the specified
87 value. Default is 128.
92 reads its configuration information from a configuration
93 file which, by default, is
95 There must be an entry for each field of the configuration
96 file, with entries for each field separated by a tab or
97 a space. Comments are denoted by a ``#'' at the beginning
98 of a line. There must be an entry for each field. The
99 fields of the configuration file are as follows:
101 .Bd -unfilled -offset indent -compact
102 service name[@hostname]
108 server program arguments
113 based service, the entry would contain these fields.
115 .Bd -unfilled -offset indent -compact
116 service name/version[@hostname]
122 server program arguments
127 entry is the name of a valid service in
132 services (discussed below), the service
135 be the official name of the service (that is, the first entry in
136 .Pa /etc/services ) .
137 When used to specify a
139 based service, this field is a valid RPC service name in
142 The part on the right of the
144 is the RPC version number. This
145 can simply be a single numeric argument or a range of versions.
146 A range is bounded by the low version to the high version -
149 If a string of the form
151 is appended to the service, it causes inetd to bind to the port for
152 the service on only the specific IP address associated with
154 instead of listening on all available addresses. This can be done as
155 many times as desired for different addresses, which permits setting
156 up ``virtually hosted'' services. Note, however, that while you can
157 listen to as many specific addresses as you want, kernel restrictions
160 from listening to the same port on a specific address and the general
163 should be a resolvable hostname or an IP address associated with one
164 of the interfaces of the local system.
176 depending on whether the socket is a stream, datagram, raw,
177 reliably delivered message, or sequenced packet socket.
181 must be a valid protocol as given in
187 Rpc based services are specified with the
196 entry is applicable to datagram sockets only (other sockets should
199 entry in this space). If a datagram server connects
200 to its peer, freeing the socket so
202 can received further messages on the socket, it is said to be
205 server, and should use the
207 entry. For datagram servers which process all incoming datagrams
208 on a socket and eventually time out, the server is said to be
217 are both examples of the latter type of
220 is an exception; it is a datagram server that establishes pseudo-connections.
223 in order to avoid a race;
224 the server reads the first packet, creates a new socket,
225 and then forks and exits to allow
227 to check for new service requests to spawn new servers.
230 suffix (separated from
234 by a dot) specifies the maximum number of server instances that may be
237 within an interval of 60 seconds. When omitted,
243 entry should contain the user name of the user as whom the server
244 should run. This allows for servers to be given less permission
245 than root. An optional group name can be specified by appending a dot to
246 the user name followed by the group name. This allows for servers to run with
247 a different (primary) group id than specified in the password file. If a group
248 is specified and user is not root, the supplementary groups associated with
249 that user will still be set.
253 entry should contain the pathname of the program which is to be
256 when a request is found on its socket. If
258 provides this service internally, this entry should
263 .Em server program arguments
264 should be just as arguments
265 normally are, starting with argv[0], which is the name of
266 the program. If the service is provided internally, the
269 should take the place of this entry.
274 services internally by use of
275 routines within itself. These services are
279 (character generator),
281 (human readable time), and
283 (machine readable time,
284 in the form of the number of seconds since midnight, January
285 1, 1900). All of these services are tcp based. For
286 details of these services, consult the appropriate
288 from the Network Information Center.
291 rereads its configuration file when it receives a hangup signal,
293 Services may be added, deleted or modified when the configuration file
297 .Em /var/run/inetd.pid
298 that contains its process identifier.
315 based services is modelled after that