Welcome to the Microsoft Q&A Platform. Thank you for reaching out & I hope you are doing well.
I understand that you would like to configure Active-Passive set up for HA using Azure LB and a VIP
Please note that you should not be configuring this in the Azure LB, rather, you should configure this in the backend VMs.
- You have to use the IP of the LB (both Public or Private) as the VIP in each of the Backend VMs
- In Azure LB, you have to enable Floating IP (this tells the LB that the backend is using LB's IP as VIP) and LB does not change the destination IP to the actual IP of the VM, rather leaves it to be the IP of the LB (backends would see this as their VIP)
- Now, configuring the OS to support VIP depends on the OS you are using. The below section provides configuration for the following
- Now, you should configure the backends to be active-passive, i.e,
passive instance should not respond to health probes.
Thus, Azure LB will only send traffic to the Active instance.
During a switch over, the active instance will start to fail the health checks, and the passive instance will pass the health checks.
However, the traffic will go to the same IP (i.e, VIP which is configured in both the VMs )
In summary,
- The VIP will not move between the active and passive VMs, as we do in conventional load balancing.
- Instead, the VIP is always present in both the VMs
- The routing is based on the health check failure, whenever a VM fails the health check, LB marks it as passive and only sends traffic to the other one(active)
Kindly let us know if this helps or you need further assistance on this issue.
Thanks,
Kapil
Please don’t forget to close the thread by clicking "Accept the answer" wherever the information provided helps you, as this can be beneficial to other community members.