Hacker News new | ask | show | jobs
by manigandham 3389 days ago
> anycast to determine location and then send the closest server IPs

Anycast doesn't determine location or send the closet IPs, it's all the same IP address announced using BGP (border gateway protocol) to automatically route to the closest (in network travel) server.

1 comments

Of course. Let me clarify - they use anycast DNS to send the closest CF caching proxy's IP.
That's not how it works. Both their DNS and reverse proxy servers use anycast IPs without any DNS-based routing.

They did recently release some features called traffic manager that lets you control the origin server based on geo. If you just need geo-balanced DNS though, AWS Route 53, Azure Traffic Manager, and NSOne offer DNS based routing.

Really? I didn't think they'd do anycast on their reverse proxy servers, that seems risky to me (ie: a TCP connection changes from one server to another due to a BGP change), but I suppose the odds are fairly low.

I seem to remember getting different IPs from different locations, but it could just be random or I could be mistaken.

EDIT: Tried now and it seems I'm getting the same IPs from Canada and Australia, so you are indeed correct.

Yes, they have a big address space and announce all ips from every location: https://blog.cloudflare.com/cloudflares-architecture-elimina...

Pretty much all major CDNs use anycast today for load balancing, rolling downtime and security/ddos protection. Http/tcp connections are usually short-lived, relatively cheap to setup (since it's an edge network anyway) and BGP route updates don't happen that often.

LinkedIn switched to anycast too after testing: https://engineering.linkedin.com/network-performance/tcp-ove...