nerdexam
Linux_Foundation

LFCS · Question #772

Suppose that the command netstat a hangs for a long time without producing output. You might suspect:

The correct answer is B. a problem with DNS. The netstat -a command hangs because it attempts to resolve IP addresses to hostnames by default, and a slow or unresponsive DNS server can delay this process indefinitely.

Submitted by jordan8· Apr 18, 2026Networking

Question

Suppose that the command netstat a hangs for a long time without producing output. You might suspect:

Options

  • Aa problem with NFS.
  • Ba problem with DNS.
  • Ca problem with NIS.
  • Da problem with routing.
  • Ethat the netstat daemon has crashed.

How the community answered

(40 responses)
  • A
    3% (1)
  • B
    90% (36)
  • C
    5% (2)
  • E
    3% (1)

Why each option

The `netstat -a` command hangs because it attempts to resolve IP addresses to hostnames by default, and a slow or unresponsive DNS server can delay this process indefinitely.

Aa problem with NFS.

NFS problems typically affect file access, not the ability of `netstat` to list network connections, although NFS issues might show up in `netstat` output if connections are stuck.

Ba problem with DNS.Correct

The `netstat -a` command, when run without the `-n` option, attempts to resolve numeric IP addresses into human-readable hostnames for all active connections and listening ports. If the configured DNS server is unreachable or experiences significant latency, this name resolution process will time out, causing the `netstat` command to hang or take an extended period to produce output while it waits for DNS queries to complete.

Ca problem with NIS.

NIS issues relate to centralized user and group information, which does not directly cause `netstat` to hang when listing network connections.

Da problem with routing.

Routing problems would prevent network traffic from reaching its destination, but `netstat` can still display the connections it sees or attempts to make, without necessarily hanging due to routing itself.

Ethat the netstat daemon has crashed.

`netstat` is a command-line utility, not a daemon or background service, so it does not crash in the manner a daemon would; it simply executes and exits, or waits indefinitely if blocked.

Concept tested: Network troubleshooting with netstat and DNS

Source: https://man7.org/linux/man-pages/man8/netstat.8.html

Topics

#netstat command#DNS resolution#Network troubleshooting#Hanging processes

Community Discussion

No community discussion yet for this question.

Full LFCS Practice