Load balancing

Hello, I set up a wide ip in a GTM with 2 pools as members. and with the following irule definition. In order for this irule to work what should be the load balancing method to use;

when DNS_REQUEST { if { [matchregion ldns “BXB-IDMS-DNS”]} { if { [active_members pl_bxb-idcmysql-read_3306] > 0} { pool pl_bxb-idcmysql-read_3306

}
    else {
        pool pl_chi-idcmysql-read_3306
        log local0. "No Active members in MYSQL for BXB so use CHI MYSQL by DNS [IP::client_addr]"
    } 
}
elseif { not [matchregion ldns "BXB-IDMS-DNS"] } {
    if {  [active_members pl_chi-idcmysql-read_3306] > 0 } {
            pool pl_chi-idcmysql-read_3306

    }
    else {
     pool pl_bxb-idcmysql-read_3306
     log local0.  "No Active members in CHI MYSQL for CHI so use BXB MYSQL by DNS [IP::client_addr]" 
    }
 }

}

Thanks for any help,

Hi

Looking in your irule you are matching LDNS it should be topology based . Any specific reason you are using irule it can be done through topology LB with help of rules defined in topology.inc and region.user

Thanks. Using irule because because that is what is being commonly used in out GTM and besides I am not yet familiar on how to setup Topology Lad balancing. Do you know a good info for me to read and how to set it up?

For topology loadbalancing here are some good links :