nerdexam
CompTIA

XK0-005 · Question #88

A Linux administrator implemented a new HTTP server using the default configuration. None of the users on the network can access the server. If there is no problem on the network or with the users'…

The correct answer is A. Run netstat to ensure the port is correctly bound, and configure the firewall to allow access on ports. To diagnose why an HTTP server is inaccessible, first verify it's listening on the correct port, then check and configure the firewall to permit inbound connections to that port.

Troubleshooting

Question

A Linux administrator implemented a new HTTP server using the default configuration. None of the users on the network can access the server. If there is no problem on the network or with the users' workstations, which of the following steps will BEST analyze and resolve the issue?

Options

  • ARun netstat to ensure the port is correctly bound, and configure the firewall to allow access on ports
  • BRun route to ensure the port is correctly bound, and configure the firewall to allow access on ports
  • CRun netcat to ensure the port is correctly bound, and configure a static route to the web to allow
  • DRun route to ensure the port is correctly bound, and configure SELinux to allow access on ports 80

How the community answered

(33 responses)
  • A
    79% (26)
  • B
    12% (4)
  • C
    6% (2)
  • D
    3% (1)

Why each option

To diagnose why an HTTP server is inaccessible, first verify it's listening on the correct port, then check and configure the firewall to permit inbound connections to that port.

ARun netstat to ensure the port is correctly bound, and configure the firewall to allow access on portsCorrect

Running `netstat -tulnp` (or `ss`) is crucial to confirm that the HTTP server process is actively listening on the standard HTTP port (typically 80 or 443) and is correctly bound to an IP address. If the server is listening, the next common culprit for inaccessibility is a firewall blocking incoming connections, so configuring the firewall to allow access on the relevant ports (e.g., 80 for HTTP) is the necessary resolution.

BRun route to ensure the port is correctly bound, and configure the firewall to allow access on ports

The `route` command displays or modifies the IP routing table, which is not used to check if a port is bound or for basic firewall configuration.

CRun netcat to ensure the port is correctly bound, and configure a static route to the web to allow

`netcat` is a versatile networking utility for reading and writing data across network connections, but `netstat` is more appropriate for checking listening ports, and configuring a static route is irrelevant for making a local web server accessible from the network.

DRun route to ensure the port is correctly bound, and configure SELinux to allow access on ports 80

While `SELinux` can block access, checking `netstat` for port binding is a more fundamental first step than `route`, and the question implies a default configuration issue that would more commonly involve the firewall before `SELinux` context if the server isn't even binding.

Concept tested: Linux HTTP server troubleshooting (port binding, firewall)

Source: https://www.redhat.com/sysadmin/netstat-command-linux

Topics

#netstat#Firewall configuration#Network troubleshooting#HTTP server access

Community Discussion

No community discussion yet for this question.

Full XK0-005 Practice