Forum Discussion

Chris_Kindelber's avatar
Chris_Kindelber
Icon for Nimbostratus rankNimbostratus
Mar 17, 2005

Turning off compression based on client IP

We need to turn off compression based on a single client IP. What we find is that we get a 404 when the client hits the VIP when that rule is applied. In the tcpdump we see a reset being sent back to the client.

 

 

irule

 

 

when HTTP_REQUEST { if { [IP::remote_addr] eq "63.231.39.153" } { COMPRESS::disable } }

 

 

tcpdump

 

 

[root@wfbigip1-1:Active] config tcpdump host 63.231.39.153 -i external

 

tcpdump: listening on external

 

10:18:02.243598 63.231.39.153.17618 > 10.154.1.119.http: S 987716102:987716102(0

 

) win 65535 (DF)

 

10:18:02.243624 10.154.1.119.http > 63.231.39.153.17618: S 4062912198:4062912198

 

(0) ack 987716103 win 4380 (DF)

 

10:18:02.307661 63.231.39.153.17618 > 10.154.1.119.http: . ack 1 win 65535 (DF)

 

10:18:02.339532 63.231.39.153.17618 > 10.154.1.119.http: P 1:840(839) ack 1 win

 

65535 (DF)

 

10:18:02.339650 10.154.1.119.http > 63.231.39.153.17618: R 1:1(0) ack 840 win 79

 

21 (DF)

 

10:18:02.440000 63.231.39.153.17619 > 10.154.1.119.http: S 4004526726:4004526726

 

(0) win 65535 (DF)

 

10:18:02.440008 10.154.1.119.http > 63.231.39.153.17619: S 798396870:798396870(0

 

) ack 4004526727 win 4380 (DF)

 

10:18:02.494714 63.231.39.153.17619 > 10.154.1.119.http: . ack 1 win 65535 (DF)

 

10:18:02.526589 63.231.39.153.17619 > 10.154.1.119.http: P 1:840(839) ack 1 win

 

65535 (DF)

 

10:18:02.526627 10.154.1.119.http > 63.231.39.153.17619: R 1:1(0) ack 840 win 79

 

21 (DF)

 

10:18:10.421495 63.231.39.153.17620 > 10.154.1.119.http: S 685920037:685920037(0

 

) win 65535 (DF)

 

10:18:10.421521 10.154.1.119.http > 63.231.39.153.17620: S 190270245:190270245(0

 

) ack 685920038 win 4380 (DF)

 

10:18:10.485424 63.231.39.153.17620 > 10.154.1.119.http: . ack 1 win 65535 (DF)

 

10:18:10.516865 63.231.39.153.17620 > 10.154.1.119.http: P 1:840(839) ack 1 win

 

65535 (DF)

 

10:18:10.516981 10.154.1.119.http > 63.231.39.153.17620: R 1:1(0) ack 840 win 79

 

21 (DF)

 

10:18:10.603436 63.231.39.153.17621 > 10.154.1.119.http: S 1250104616:1250104616

 

(0) win 65535 (DF)

 

10:18:10.603444 10.154.1.119.http > 63.231.39.153.17621: S 3182434280:3182434280

 

(0) ack 1250104617 win 4380 (DF)

 

10:18:10.659594 63.231.39.153.17621 > 10.154.1.119.http: . ack 1 win 65535 (DF)

 

10:18:10.690887 63.231.39.153.17621 > 10.154.1.119.http: P 1:840(839) ack 1 win

 

65535 (DF)

 

10:18:10.690929 10.154.1.119.http > 63.231.39.153.17621: R 1:1(0) ack 840 win 79

 

21 (DF)

 

5 Replies

  • This works for every other client excpet the IP in the rule.

     

     

    by the way we are running 9.04.

     

     

    Thanks.
  • rapmaster_c_127's avatar
    rapmaster_c_127
    Historic F5 Account
    Please could you post the contents of the request? You can do this by posting the output of tcpdump -s 1600 -X. Also, does /var/log/ltm contain anything odd when you hit it from this client?

     

  • here is an entry from the ltm log.

     

     

    Mar 17 11:04:32 tmm tmm[683]: 01220001:3: TCL error: Rule Lancome_Rule - Error: Unknown error (line 1) invoked from within "COMPRESS::disable "

     

     

  • rapmaster_c_127's avatar
    rapmaster_c_127
    Historic F5 Account
    Ok, this is is something we fixed in 9.0.5 for usability reasons. Since architecturally compression occurs on the serverside of the full proxy, you need to trigger the rule on HTTP_RESPONSE. I know it's icky, so that's why we fixed it. So while you're on 9.0.4, try the following rule instead:

     
     when HTTP_RESPONSE {  
         if { [IP::client_addr] eq "63.231.39.153" } {  
             COMPRESS::disable 
         } 
     }  
     

    Sorry about that.