Is it possible to get or set up a public IP address that is load-balanced between multiple physical locations or sites? It may be something like a virtual IP address (VIP), which points to multiple IP addresses, and incoming traffic is load-balanced between multiple sites, each site having a different ISP IP address?

The purpose is to have multiple locations service the incoming user requests, and if one of the sites shuts down, the users continue to be serviced from the remaining sites.

Load-balancing DNS can achieve something similar, but I want to know if the load-balancing can be done at the IP address level.

  • Do you mean something like anycast?
    – Ron Maupin
    Commented Feb 14, 2018 at 17:10

2 Answers 2


Based on your edit, it sounds like you want anycast. This is a common among large, global companies. You advertise the same network from multiple places, and routing will take traffic to the closest (from a network perspective) site advertising that network. When one site goes down, routing will automatically take traffic to the next closest location.

Basically, you leverage the routing protocol (BGP on the Internet) to automatically handle it.

  • Thanks Ron. Yes, Anycast seems to be the solution. Is Anycast service available from most ISPs? So far, I have heard of DNS application using Anycast, but can it be used for HTTP traffic and VPN tunnels as well.
    – kzia
    Commented Feb 14, 2018 at 18:21
  • Yes, it works at IP, so any traffic destined to an IP address is routed accordingly. One problem is that an established connection will be broken when a site goes down, but that happens anyway. It is a simple matter to establish a new connection to the next closest site. If you are dealing with multiple ISPs, then you need to have provider-independent addressing so that multiple ISPs will advertise your networks.
    – Ron Maupin
    Commented Feb 14, 2018 at 18:27

As Ron mentioned you are probably looking for anycast. Be aware that on the Internet you need at least a /24 (IPv4) or /48 (IPv6) many (all) providers will filter larger prefixes to save valuable memory on their Routers.

The most popular use case for anycast on the Internet is probably DNS. Most of the root DNS servers are anycasted, e.g. there are 157 instances of l.root-servers.net (see http://www.root-servers.org/) reachable under the same IPv4 and IPv6 address.

To setup such a service your service, a routing protocol daemon (on the inernet something that speaks BGP) and a peace of software that monitors your services and removes this instance from the routing table in case of failure. One example is https://github.com/unixsurfer/anycast_healthchecker

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.