Forum Discussion
iRule on GTM
I was presented with this requirement" Please setup a f5 GTM with the following features: if the request comes in from BXB DNS server then always give back BXB LTM cluster. if the request comes in from any other DNS then giveback CHI LTM, if CHI LTM is down give BXB
if CHI mysql pool is down, then automaticaly take down the CHI charts pool behind xyz.gtm.intdata.com if BXB mysql pool is down, then automaticaly take down the BXB charts pool behind xyz.gtm.intdata.com "
I have started with this iRule (shown below) for the first two line of the requirement but do not know how to take down a particular pool on another virtual server (xyz.gtm.intdata.com). Any help is greatly appreciated.
when DNS_REQUEST { if { [matchregion ldns "BXB-IDMS-DNS"]} { if { [active_members pl_mysql-read.gtm.intdata.com_3306] > 0} { pl_mysql-read.gtm.intdata.com_3306 log local0. "Force PL MYSQL READ GTM INTDATA COM 3306 by BXB DNS [IP::client_addr]" } else { pl_chi-mysql-read.gtm.intdata.com_3306 log local0. "No Active members in MYSQL for BXB so use CHI MYSQL by DNS [IP::client_addr]" } } elseif { [matchregion ldns !"BXB-IDMS-DNS"] } { if { [active_members pl_chi-mysql-read.gtm.intdata.com_3306] > 0 } { pl_chi-mysql-read.gtm.intdata.com_3306 log local0. "Found PL CHI MYSQL READ GTM INTDATA COM by DNS [IP::client_addr]" } else { pl_mysql-read.gtm.intdata.com_3306 log local0. "No Active members in CHI MYSQL for CHI so use BXB MYSQL by DNS [IP::client_addr]" } } }
4 Replies
- shaggy_121467
Cumulonimbus
You may be able to use dependencies at the GTM servers | virtual-servers level. Just configure the CHI mysql VS as a dependency for the CHI chart VS, and likewise for BXB
check out "About virtual server dependency" at http://support.f5.com/kb/en-us/products/big-ip_gtm/manuals/product/gtm-concepts-11-5-0/1.html
- ReynaldoQ_14206
Nimbostratus
Hi shaggy...I will try the dependency setup. Rey
- shaggy
Nimbostratus
You may be able to use dependencies at the GTM servers | virtual-servers level. Just configure the CHI mysql VS as a dependency for the CHI chart VS, and likewise for BXB
check out "About virtual server dependency" at http://support.f5.com/kb/en-us/products/big-ip_gtm/manuals/product/gtm-concepts-11-5-0/1.html
- ReynaldoQ_14206
Nimbostratus
Hi shaggy...I will try the dependency setup. Rey
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
