Skip to content

Files

Latest commit

5fb385a · May 24, 2022

History

History
80 lines (55 loc) · 3.39 KB

load-balancer-floating-ip.md

File metadata and controls

80 lines (55 loc) · 3.39 KB
title description services documentationcenter author ms.service ms.topic ms.tgt_pltfrm ms.workload ms.date ms.author
Azure Load Balancer Floating IP configuration
Overview of Azure Load Balancer Floating IP
load-balancer
na
greg-lindsay
load-balancer
how-to
na
infrastructure-services
12/2/2021
greglin

Azure Load Balancer Floating IP configuration

Load balancer provides several capabilities for both UDP and TCP applications.

Floating IP

Some application scenarios prefer or require the same port to be used by multiple application instances on a single VM in the backend pool. Common examples of port reuse include:

  • clustering for high availability
  • network virtual appliances
  • exposing multiple TLS endpoints without re-encryption.

If you want to reuse the backend port across multiple rules, you must enable Floating IP in the rule definition.

When Floating IP is enabled, Azure changes the IP address mapping to the Frontend IP address of the Load Balancer frontend instead of backend instance's IP.

Without Floating IP, Azure exposes the VM instances' IP. Enabling Floating IP changes the IP address mapping to the Frontend IP of the load Balancer to allow for more flexibility. Learn more here.

Floating IP can be configured on a Load Balancer rule via the Azure portal, REST API, CLI, PowerShell, or other client. In addition to the rule configuration, you must also configure your virtual machine's Guest OS in order to use Floating IP.

Floating IP Guest OS configuration

For each VM in the backend pool, run the following commands at a Windows Command Prompt.

To get the list of interface names you have on your VM, type this command:

netsh interface show interface 

For the VM NIC (Azure managed), type this command:

netsh interface ipv4 set interface “interfacename” weakhostreceive=enabled

(replace interfacename with the name of this interface)

For each loopback interface you added, repeat these commands:

netsh interface ipv4 set interface “interfacename” weakhostreceive=enabled 

(replace interfacename with the name of this loopback interface)

netsh interface ipv4 set interface “interfacename” weakhostsend=enabled 

(replace interfacename with the name of this loopback interface)

Important

The configuration of the loopback interfaces is performed within the guest OS. This configuration is not performed or managed by Azure. Without this configuration, the rules will not function.

Limitations

  • Floating IP is not currently supported on secondary IP configurations for Load Balancing scenarios. This does not apply to Public load balancers with dual-stack configurations or to architectures that utilize a NAT Gateway for outbound connectivity.

Next steps