Verify Connectivity and Display Round-Trip Statistics: Linux+ Exam XK0-004 | CompTIA

Verify Connectivity and Display Round-Trip Statistics

Question

A junior Linux administrator is trying to verify connectivity to the remote host host1 and display round-trip statistics for ten ICMP requests.

Which of the following commands should the administrator execute?

Answers

Explanations

Click on the arrows to vote for the correct answer

A. B. C. D.

A.

https://shapeshed.com/unix-ping/

The command that the junior Linux administrator should execute to verify connectivity to the remote host host1 and display round-trip statistics for ten ICMP requests is:

A. ping -c 10 host1

Explanation: The ping command is used to test the connectivity between two hosts by sending ICMP echo request packets to the remote host and waiting for ICMP echo reply packets in return. By default, ping sends an infinite number of requests until the user interrupts it with Ctrl-C. However, to limit the number of requests to 10, the -c option followed by the number of requests (10 in this case) should be used. The command should also include the hostname or IP address of the remote host to be tested (host1 in this case).

Option B, traceroute -c 10 host1, is used to trace the route that packets take from the local host to the remote host, showing the IP addresses of the routers along the way. The -c option is used to limit the number of hops to 10, not the number of requests.

Option C, netstat host1, displays the network connections and statistics for the local host, not for the remote host.

Option D, pathping -c 10 host1, is not a valid Linux command. It is a Windows command that combines the features of ping and traceroute.