Forum Discussion

Parothed_235521's avatar
Parothed_235521
Icon for Nimbostratus rankNimbostratus
Nov 24, 2015

Load Balancing/Failover Question

Let me preface this by saying that I have little experience with and a rudimentary F5 understanding. That said... We are using the F5 to load balance connections in a server pair and have run into a failover issue that we are being told is beyond the capability of the F5.

 

Here's the scenario (I'll try to be as clear/concise as I can...I've been know to ramble): We are directing 130 connected devices to a VIP for a server pair and are using the F5 to balance the 130 connections between Server A and Server B. The load balancing works perfectly.

 

We're also using the F5 for failover. We've taken Server B down and have seen the 65 connections move over to Server A and we see that all 130 connections are active. Here's the issue...when we bring Server B back up the 130 connections do not redistribute and the pair's no longer balanced. We're being told that the F5 does not have the capability to re-balance or redistribute the connections when the server comes back up.

 

I don't know if I've given you enough info to go on but would appreciate any input that I could get. I'm pretty sure that I can get details on the configuration of the switch if that would help.

 

1 Reply

  • BinaryCanary_19's avatar
    BinaryCanary_19
    Historic F5 Account

    I agree. The F5 does not re-balance the connections when a previously down server comes back up. Load balancing decision is made once for the life of a connection, and a new decision is only made when new connections are established.

     

    If you think about it, how does the F5 decide when and which connections to kill? Because assuming this is TCP, you will have to kill the connections, and hope that the end software will establish new connections, which will then get load-balanced. There is no way to silently migrate a TCP connection from one server to another (the other server will not have the context needed to transparently continue processing the migrated connection).

     

    If the connections are long-lived (as they seem to be) and have periods of inactivity (idleness), and the clients can reconnect transparently, then you can lower idle timeouts on your TCP profile so that reconnection attempts cause load-balancing to take place. The F5 will TCP RST a connection when the idle timeout is reached, and the client will if designed so, reconnect.

     

    Ultimately, with irules, almost anything is possible, but it will require a pretty clever and complex irule to accomplish this by reading pool member states, and randomly killing some connections if the desired pattern of pool member availability happens (your LB Method will need to be Least Connections)