Interview Prep/Networking/DNS & Service Discovery

What is split-horizon DNS and when do you need it?

IntermediateScenarioDNS & Service Discovery
Answer

Situation read → The same name returns different answers inside and outside the network.

What I'd do →

  1. Create a public hosted zone example.com with the public ALB and a private hosted zone with the same name associated to the VPC
  2. Inside the VPC app.example.com returns a private IP
  3. Outside it returns the public one
  4. Verify from an instance with dig app.example.com and from home with the same command
  5. Be careful: records missing in the private zone become NXDOMAIN inside the VPC

Why → Private zones shadow the public zone completely for associated VPCs, so every needed record must exist in both.

Interview tip → Name the failure mode: forgot to copy a record into the private zone.

All Networking questions Roadmap: Networking for DevOps

More on DNS & Service Discovery