Advanced

Anycast: Same IP, Multiple Locations

Two sites each run a DNS server at the same address, 10.99.0.53, and each site's router announces the network over BGP. The backbone sends queries to one site; cut that site off and the same address is answered by the other.

Open this lab

Free interactive lab. No signup. Runs in your browser.

The scenario

Client uses 10.99.0.53 as its DNS server. That address exists twice: DNS-East sits behind router Site-East (AS 65010) and DNS-West behind router Site-West (AS 65020), and both servers have 10.99.0.53 on the same network, 10.99.0.0/24, with the same records. Each site router announces 10.99.0.0/24 to the Backbone router (AS 65000) over eBGP. Backbone hears the network from both sites and installs one of the two routes, so every query from Client goes to one site. When that site's link fails, its BGP session drops, its announcement is withdrawn, and Backbone switches to the other site. Client's configuration never changes. No router has a static route and none runs OSPF: every path here is BGP's choice.

What you will work out

Understand anycast: one address announced from several places, how BGP picks which one you reach, and why losing a site does not change the address clients use.

Why this matters

Anycast lets a service keep one address while running in many places, so clients are served by whichever site routing picks and keep working when a site disappears, with no DNS change and no client reconfiguration. It is how large public resolvers and content networks are built. The same mechanism explains puzzles when it goes wrong: a site that keeps announcing while its service is broken draws traffic into a hole, and a routing change can quietly move users to a different, more distant site.

Running it

Anycast: Same IP, Multiple Locations opens on a canvas, already wired and addressed. Trace a packet through it hop by hop, or run the same topology live on real Linux network namespaces. How the two modes differ.

Open Anycast: Same IP, Multiple Locations

Runs in your browser. No install, no signup, and the simulation starts instantly.

Open the lab →