Interview Prep/Networking/Connectivity: refused, timed out, no route

A service is reachable by IP but not by hostname.

BeginnerTroubleshootingConnectivity: refused, timed out, no route
Answer

Likely causes → DNS problem, wrong /etc/hosts entry, or a virtual-host-based server returns a different site for the Host header.

Diagnose →

getent hosts app.example.com
dig app.example.com +short
curl -v --resolve app.example.com:443:203.0.113.10 https://app.example.com/

Fix → Fix the record or hosts file. If DNS is right but the response differs, check the server's server_name / vhost config.

Prevent → Monitor the public name, not just the IP.

All Networking questions Roadmap: Networking for DevOps

More on Connectivity: refused, timed out, no route