How to do HTTP cache-control modification inside F5 LTM for free

cache-control

What is HTTP cache-control and why it was relevant to our problem:-

One of the most important HTTP header field is cache-control.  And you guessed right that HTTP header fields are components of the Hypertext Transfer Protocol (HTTP) message header of requests and responses. Cache-control specify the operating parameters of an HTTP transaction. And since F5 takes care of the redirection, with IE 10 rolling out, we need to take this field into account.

Problem Description:-

With rollout of IE 10 to our project workstations we encounter a problem with redirection performed on F5 LTM. After opening website on one window when we open another tab , and type same website address Browser freezes and no redirection occurs.

Solution:-

After lots of investigation , talking to F5 and Microsoft experts , we finally agreed on the solution that to prevent this we need to add cache-control HTTP header to the redirection response with value “no-cache”.

Current Irule:

when HTTP_REQUEST {
switch -glob [string tolower [HTTP::host]] {
“afrozahmad.com” {
HTTP::respond 301 “Location” “http://www.afrozahmad.com/en/Pages”
}
}
}

Modified Irule:- We have added  { cache-control “no-cache” } .

when HTTP_REQUEST {
switch -glob [string tolower [HTTP::host]] {
“afrozahmad.com” {
HTTP::respond 301 “Location” “http://www.afrozahmad.com/en/Pages” Cache-Control “no-cache”
}
}
}

Useful Sites for more information:-

http://support.f5.com/kb/en-us/solutions/public/13000/200/sol13244.html?sr=38385738 > Overview of RAM cache

http://support.f5.com/kb/en-us/solutions/public/10000/200/sol10200.html?sr=38385738 > Clearing ram cache entries

http://www.mobify.com/blog/beginners-guide-to-http-cache-headers/  > A Beginner Guide to HTTP Cache headers

http://condor.depaul.edu/dmumaugh/readings/handouts/SE435/HTTP/node24.html  >

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.