Forum Discussion
Ken_50869
Nimbostratus
Aug 14, 2007Compress content by IP
Hello,
I've created the following iRULE to compress content based on the client's source IP address. However, as soon as I apply the iRULE to the virtual server, client's are no longer able to reach the application. Can anyone verify that my syntax is correct, or if anything else could be wrong?
Thanks in advance...
when HTTP_RESPONSE {
if {[IP::client_addr] eq "192.168.10.0/255.255.255.0"} {
COMPRESS::enable}
elseif {[IP::client_addr] eq "192.168.20.0/255.255.255.0" } {
COMPRESS::enable}
else {
COMPRESS::disable}
}
- hoolio
Cirrostratus
You can check the /var/log/ltm log file for TCL errors generated from your iRule. It's also viewable in the GUI under system >> logs >> local traffic.if {[IP::addr [IP::client_addr]/24 equals 192.168.10.0] \ or [IP::addr [IP::client_addr]/24 equals 192.168.20.0]}{ log local0. "matched for [IP::client_addr]" COMPRESS::enable } else { log local0. "didn't match for [IP::client_addr]" COMPRESS::disable }
- Ken_50869
Nimbostratus
Outstanding!
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