Forum Discussion
Mitch_Chen_5975
Aug 06, 2008Historic F5 Account
How to trigger GTM iRule
This is a GTM iRULE v9.4.3
I am trying to trigger GTM iRule after GTM load balanced decision had occoured with iRule below. But for it is not returning any A record answer from my eastcoast_test_pool.
The Wideip is configured with a Pool using RTT to select one of the GTM pool member. Base on the pool member subnet address, and I want anser A record from east or west_test pool.
Am I using the wrong event for GTM?
when LB_SELECTED {
if { [IP::addr [LB::server addr]/24 equals "69.63.184.0"] } {
pool "eastcoast_test_pool"
} else {
pool "westcoast_test_pool"
}
}
4 Replies
- Nicolas_Menant
Employee
To check if it is triggered you can insert some logging into your iRule, it should show you if you face a problem with the pool command or the event (if no logging appear at all).
If this is the pool command, do you see any weird messages in /var/log/ltm when the iRule is triggered? - Mitch_Chen_5975Historic F5 AccountI did some more testing and found out LB_selected event works. Pool command does not work in GTM irule.
I switch from pool command to cname commands and the iRule works.
What is the expected behavior for pool GTM iRule command? Should it re-load balance again after LB_selected?
when LB_SELECTED {
if { [IP::addr [LB::server addr]/24 equals "10.10.10.0"] } {
pool eastcoast_test_pool
} else {
pool westcoast_test_pool
}
} - Mitch_Chen_5975Historic F5 AccountThanks nmenant!
Switching to DNS_REQUEST fixed the problem. - Nicolas_Menant
Employee
it worked Oo ?
i removed this part of my message since i saw you were looking for the server IP address. Doesn't really make sense you can have the Server ip address here Oo
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
DevCentral Quicklinks
* 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
Discover DevCentral Connects