Forum Discussion

David_Edwards_2's avatar
David_Edwards_2
Icon for Nimbostratus rankNimbostratus
Nov 09, 2006

Persistence with UDP

Hello, not sure if this is under the right section.

 

 

The problem we have is we need to loadbalance UDP connections across a pool of servers.

 

 

All UPD packets come from the same source address. Is there a way to persist the connection based on the source port number otherwise the clients connecting to the servers will get unkown packets.

 

 

For the time that the client is downloading data it needs to use the same server hence the connection needs to be persisted.

 

 

Can anyone help, have any ideas or can point me in the right direction.

 

 

I am new to configuring the BIGIP LTM and have only written a couple of basic irules routing on content.

 

 

Thanks in advance

 

 

Dave
  • You could try something like this:

    
    when CLIENT_ACCEPTED {
        set src_IP [IP::client_addr]
        if { [session lookup uie $src_IP] equals "" } {
          session add uie $src_IP [UDP::remote_port] 1800
          log local0. "added client port [session lookup uie $src_IP] for client ip $src_IP "
        } else {
          log local0. "existing client port [session lookup uie $src_IP] for client ip $src_IP"
        }
    }

    Untested, but it did pass the LTM syntax checker on 9.1.2.

    Jason
  • I will give it a try.

     

     

    When we move this into the production environment the soure IP addresses will be unique so then we can persist on source IP.

     

     

    Cheers

     

     

    Dave