LFCS · Question #481
Which of the following lines would you expect to see in the file /etc/protocols?
The correct answer is D. udp 17 UDP. The /etc/protocols file lists network protocol names and their corresponding protocol numbers, adhering to a specific format.
Question
Options
- Ain.tftpd: LOCAL
- Btftp dgram udp wait root /usr/sbin/tcpd in.tftpd
- Ctftp 69/udp
- Dudp 17 UDP
How the community answered
(24 responses)- B4% (1)
- C8% (2)
- D88% (21)
Why each option
The `/etc/protocols` file lists network protocol names and their corresponding protocol numbers, adhering to a specific format.
This format is incorrect for `/etc/protocols`; it resembles an entry that might be found in a configuration file like `/etc/services` or a service configuration.
This line describes an `inetd` or `xinetd` service configuration, specifying how a daemon should be invoked, and does not belong in `/etc/protocols`.
This line describes a service and its port/protocol, typically found in `/etc/services`, not `/etc/protocols`.
The line "udp 17 UDP" correctly lists the protocol name (udp), its assigned protocol number (17), and an alias (UDP), which is the standard format for entries in the `/etc/protocols` file. This file is used by network services to look up protocol information.
Concept tested: /etc/protocols file format
Topics
Community Discussion
No community discussion yet for this question.