inetd Daemon Process
The/usr/sbin/inetd daemon provides Internet service management for the network.
The daemon can reduce system load by invoking other daemons only when needed, and by providing several simple Internet services internally without invoking other daemon processes.
start and refresh inetd
When the daemon starts, it reads its configuration information from the file specified in the Configuration file parameter. If this parameter is not specified, the inetd daemon will read its configuration information from the/etc/inetd.conf file.
Once started, the inetd daemon listens for a connection on a particular Internet socket in/etc/inetd.conf and, upon receiving a request on one of the sockets, chooses to process the service request itself or call the appropriate server.
You can update/etc/inetd.conf files by using the System Management Interface Tool (SMIT), System resource Controller (SRC), or edit/etc/inetd.conf.
If you use the SMIT change/etc/inetd.conf,inetd daemon will automatically refresh and read the new/etc/inetd.conf file. If you use the editor to change the file, run the refresh-s inetd or kill-1 inetdpid command to notify the inetd daemon of changes to its configuration file.
If you use the KILL-1 command, as shown in Figure 1, you will not receive a message.
Figure 1 Refreshing the inetd daemon with either refresh or kill
Sub-servers controlled by inetd
The inetd daemon is a subsystem that controls the following daemon processes (child servers):
Comsat Daemon Process
FTPD Daemon Process
Fingerd Daemon Process
Rlogind Daemon Process
REXECD Daemon Process
RSHD Daemon Process
TALKD Daemon Process
telnetd Daemon Process
TFTPD Daemon Process
UUCPD Daemon Process
The FTPD, Rlogind, REXECD, rshd, TALKD, telnetd, and UUCPD daemons start by default. The TFTPD, Fingerd, and Comsat daemons are not started by default.
To start any of these daemons, delete the # Word in the first column of the corresponding entry in the/etc/inetd.conf file. You can view the details of a child server that is started in inetd by using the Lssrc-ls command, as shown in Figure 2.
Figure 2 Sub-servers launched in inetd
/etc/services file
The/etc/services file contains information about known services that are used by inetd in the DARPA Internet network.
Each of the services listed in/etc/services runs on a specific communication port number in a specific format (for example, TCP or UDP).
Each service is listed separately on a single line, and its corresponding format is as follows:
ServiceName Portnumber/protocolname Aliases
|
The Example section in/etc/services might look like the following:
echo 7/tcp
echo 7/udp
discard 9/tcp sink null
discard 9/udp sink null
daytime
13/TCP Daytime 13 /UDP
chargen 19/tcp ttytst source
chargen 19/udp ttytst source
ftp 21/tcp time
37/tcp timeserver
Time 37/UDP Timeserver
|
If you are editing the/etc/services file, run the refresh-s inetd command to make your changes take effect.
Stop inetd
Use the command stopsrc-s inetd to stop the inetd daemon, as shown in Figure 3.
Figure 3 Stop inetd
The previously initiated child server process is not affected when the inetd daemon is stopped. However, new service requests for these child servers are no longer responding. If you try to connect to a server that is closed inetd by telnet or FTP, you will see the message shown in Figure 4.
Figure 4 Response to Telnet and FTP when the inetd on sv1166f is turned off
In other words, existing sessions are not affected when the inetd daemon is stopped, but new Telnet and FTP sessions cannot be established until the inetd daemon is restarted.