Forum Discussion
bman_12685
Nimbostratus
Oct 10, 2012GTM irule to return differnt pool
I have a gtm pair version 9.x and ltm versions 11.2.0, and want to have the gtm return differnt pool members based on internal or external ip for example I have internal and external mail vips with ...
bman_12685
Nimbostratus
Oct 10, 2012ok wrote an irule and tested it works this is my solution
---
substitute your values where needed
----
when RULE_INIT {
set ::TRACE 1
set DEBUG 1
}
when DNS_REQUEST {
if { [IP::addr [IP::client_addr] equals $dnsserver1_dc1 ] or [IP::addr [IP::client_addr] equals $dnsserver2_dc1 ] } {
log local0. "Connection from: [IP::client_addr] from internal DNS - attempting to send to mail internal pool"
cname mx-vip.domain.dc1.com
}
if { [IP::addr [IP::client_addr] equals $dnserver1_dc2 ] or [IP::addr [IP::client_addr] equals $dnsserver2_dc2 ] } {
cname mx-vip.domain.dc2.com
}
}
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