Configuring Generic Header Parsing
This example assumes that the URL map, map1, has already been configured and shows how to
configure server load-balancing policies and associate them to virtual servers:
Router(config-slb-policy)# serverfarm pl_sticky
Router(config-slb-sfarm)# real 10.1.0.105
Router(config-slb-sfarm)# inservice
Router(config-slb-policy)# exit
Router(config-module-csm)# policy policy_sticky_ck
Router(config-slb-policy)# serverfarm pl_sticky
Router(config-slb-policy)# url-map map1
Router(config-slb-policy)# exit
Router(config-module-csm)# vserver vs_sticky_ck
Router(config-slb-vserver)# virtual 10.1.0.80 tcp 80
Router(config-slb-vserver)# slb-policy policy_sticky_ck
Router(config-slb-sfarm)# inservice
Router(config-slb-policy)# exit
Configuring Generic Header Parsing
In software release 2.1(1), the CSM supports generic HTTP request header parsing. The HTTP request
header contains fields that describe how content should be formatted to meet the user's requirements.
Understanding Generic Header Parsing
The CSM uses the information it learns by parsing and matching fields in the HTTP header along with
policy information to make load-balancing decisions. For example, by parsing the browser-type field in
the HTTP header, the CSM can determine if a user is accessing the content with a mobile browser and
can select a server that contains content formatted for a mobile browser.
An example of a HTTP Get request header record is as follows:
GET /?u HTTP/1.1<0D><0A>
Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg<0D><0A>
Referer: http://www.yahoo.com/<0D><0A>
Accept-Language: en-us<0D><0A>
Accept-Encoding: gzip, deflate<0D><0A>
User-Agent: Mozilla/4.0 (compatible; MSIE 5.0; Windows NT; DigExt)<0D><0A>
Host: finance.yahoo.com<0D><0A>
Connection: Keep-Alive<0D><0A>
Cookie: B=51g3cjstaq3vm; Y=1<0D><0A>
<0D><0A>
Generic Header Parsing Configuration
You configure generic header parsing by entering commands that instruct the CSM to perform policy
matching on fields in the HTTP header. These sections describe how to configure generic header parsing
on the CSM:
•
•
•
•
Catalyst 6500 Series Content Switching Module Configuration Note
6-12
Creating a Map for the HTTP Header, page 6-13
Specifying Header Fields and Match Values, page 6-14
Assigning an HTTP Header Map to a Policy, page 6-14
Assigning the Policy to a Virtual Server, page 6-15
Chapter 6
Configuring Virtual Servers, Maps, and Policies
OL-4612-01