Penguin
Annotated edit history of inetd(8) version 4, including all changes. View license author blame.
Rev Author # Line
1 perry 1 ----
2 __NAME__
3
4
5 inetd - internet ``super-server''
6 __SYNOPSIS__
7
8
9 inetd [[-d] [[-q queuelength] [[configuration
10 file]
11 __DESCRIPTION__
12
13
14 Inetd should be run at boot time by
15 /etc/init.d/inetd (or /etc/rc.local on some
16 systems). It then listens for connec- tions on certain
17 internet sockets. When a connection is found on one of its
18 sockets, it decides what service the socket corresponds to,
19 and invokes a program to service the request. After the
20 program is finished, it continues to listen on the socket
21 (except in some cases which will be described below).
22 Essentially, inetd allows running one daemon to invoke
23 several others, reducing load on the sys- tem.
24
25
26 The options available for inetd:
27 -d Turns on debugging.
28
29
30 -q queuelengthSets the size of the socket listen queue to the spec-ified value. Default is 128.Upon execution, inetd reads its configuration informationfrom a configuration file which, by default, is/etc/inetd.conf. There must be an entry for each field of the configuration file, with entries for each field sepa- rated by a tab or a space. Comments are denoted by a ``#'' at the beginning of a line. There must be an entry for each field. The fields of the configuration file are as follows:
31
32
33 service name
34 socket type
35 protocol
36 wait/nowait[[.max]
37 user[[.group]
38 server program
39 server program arguments
40
41
42 To specify an ''Sun-RPC'' based service, the entry would
43 contain these fields.
44
45
46 service name/version
47 socket type
48 rpc/protocol
49 wait/nowait[[.max]
50 user[[.group]
51 server program
52 server program arguments
53 The ''service-name'' entry is the name of a valid service in the file /etc/services. For ``internal'' services (discussed below), the service name ''must'' be the official name of the service (that is, the first entry in /etc/services). When used to specify a ''Sun-RPC'' based service, this field is a valid RPC service name in the file /etc/rpc. The part on the right of the ``/'' is the RPC version number. This can simply be a single numeric argument or a range of versions. A range is bounded by the low version to the high version - ``rusers/1-3''.
54
55
56 The ''socket-type'' should be one of ``stream'',
57 ``dgram'', ``raw'', ``rdm'', or ``seqpacket'', depending on
58 whether the socket is a stream, datagram, raw, reliably
59 delivered mes- sage, or sequenced packet
60 socket.
61
62
63 The ''protocol'' must be a valid protocol as given in
64 /etc/protocols. Examples might be ``tcp'' or
65 ``udp''. Rpc based services are specified with the
66 ``rpc/tcp'' or ``rpc/udp'' service type.
67
68
69 The ''wait/nowait'' entry is applicable to datagram
70 sockets only (other sockets should have a ``nowait'' entry
71 in this space). If a datagram server connects to its peer,
72 freeing the socket so inetd can received further messages on
73 the socket, it is said to be a ``multi-threaded'' server,
74 and should use the ``nowait'' entry. For datagram servers
75 which process all incoming datagrams on a socket and
76 eventually time out, the server is said to be
77 ``single-threaded'' and should use a ``wait'' entry.
3 AristotlePagaltzis 78 comsat(8) (biff(1)) and talkd(8)
1 perry 79 are both examples of the latter type of datagram server.
4 AristotlePagaltzis 80 tftpd(8) is an exception; it is a datagram server
1 perry 81 that establishes pseudo-connections. It must be listed as
82 ``wait'' in order to avoid a race; the server reads the
83 first packet, creates a new socket, and then forks and exits
84 to allow inetd to check for new service requests to spawn
85 new servers. The optional ``max'' suffix (separated from
86 ``wait'' or ``nowait'' by a dot) specifies the maximum num-
87 ber of server instances that may be spawned from inetd
88 within an interval of 60 seconds. When omitted, ``max''
89 defaults to 40.
90
91
92 The ''user'' entry should contain the user name of the
93 user as whom the server should run. This allows for servers
94 to be given less permission than root. An optional group
95 name can be specified by appending a dot to the user name
96 followed by the group name. This allows for servers to run
97 with a dif- ferent (primary) group id than specified in the
98 password file. If a group is specified and user is not root,
99 the sup- plementary groups associated with that user will
100 still be set.
101
102
103 The ''server-program'' entry should contain the pathname
104 of the program which is to be executed by inetd when a
105 request is found on its socket. If inetd provides this
106 service inter- nally, this entry should be
107 ``internal''.
108
109
110 The ''server program arguments'' should be just as
111 arguments normally are, starting with argv[[0], which is the
112 name of the program. If the service is provided internally,
113 the word ``internal'' should take the place of this
114 entry.
115
116
117 Inetd provides several ``trivial'' services internally by
118 use of routines within itself. These services are ``echo'',
119 ``discard'', ``chargen'' (character generator), ``daytime''
120 (human readable time), and ``time'' (machine readable time,
121 in the form of the number of seconds since midnight, January
122 1, 1900). All of these services are tcp based. For details
123 of these services, consult the appropriate
124 RFC from the Net- work Information
125 Center.
126
127
128 Inetd rereads its configuration file when it receives a
129 hangup signal, SIGHUP. Services may be added,
130 deleted or modified when the configuration file is reread.
131 Inetd cre- ates a file ''/var/run/inetd.pid'' that
132 contains its process identifier.
133 __SEE ALSO__
134
135
136 comsat(8), fingerd(8), ftpd(8),
137 rexecd(8), rlogind(8), rshd(8),
138 telnetd(8), tftpd(8)
139 __HISTORY__
140
141
142 The inetd command appeared in 4.3 BSD .
143 Support for ''Sun-RPC'' based services is modelled after
144 that provided by ''SunOS 4.1''.
145
146
2 perry 147 Linux !NetKit 0.09 November 23, 1996 1
1 perry 148 ----
This page is a man page (or other imported legacy content). We are unable to automatically determine the license status of this page.