Forum Discussion
Kamao
Nimbostratus
Apr 16, 2014FAILED selecting pool based on DNS reverse lookup result.
Hi,
I want to select pool based on DNS reverse lookup result for SMTP connection, but it not worked and following log appeared in /var/log/ltm.
iRUle:
when CLIENT_ACCEPTED {
NAME::lookup @ [IP...
nitass
Employee
Apr 16, 2014e.g.
config
[root@ve10:Active] config tmsh list ltm virtual bar
ltm virtual bar {
destination 172.28.24.9:http
ip-protocol tcp
mask 255.255.255.255
pool foo
profiles {
tcp { }
}
rules {
qux
}
snat automap
}
[root@ve10:Active] config tmsh list ltm rule qux
ltm rule qux {
when CLIENT_ACCEPTED {
8.8.8.8 is dns server
203.216.231.189 is yahoo.co.jp
NAME::lookup @8.8.8.8 inet -ptr 203.216.231.189
}
when NAME_RESOLVED {
if { [domain [NAME::response] 1] eq "jp" } {
log local0. "jp - do something"
} else {
log local0. "not jp - do something else"
}
}
}
log
[root@ve10:Active] config tail -f /var/log/ltm
Apr 16 15:49:45 local/tmm info tmm[4955]: Rule qux : jp - do something
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