Guest

Cisco CSS 11000 Series Content Services Switches

Configuring Transparent Caching on the Cisco CSS 11000

Document ID: 12651

Updated: Dec 27, 2007

   Print

Introduction

The transparent cache sits between the user and the server. The Cisco CSS series content services switch is introduced between the user and the cache. The CSS works at Layer 5, which allows the switch to dynamically analyze content and determine if it is cacheable or not. If the content is cacheable, then the CSS directs it to the cache service. If the content is not cacheable, then the CSS sends it directly to the origin server. If the content is not cacheable, you do not take the performance hit of the non-cacheable object going to the cache only to have the cache redirect the request to the origin server.

There are several balancing methods available, depending on how you want to distribute data over the caches. For example, whole URL, URL string, whole domain name, domain string, and so on. The CSS also automatically builds a list of known cacheable objects. The list may be modified, but much of the work is reduced.

Prerequisites

Requirements

There are no specific requirements for this document.

Components Used

This document is not restricted to specific software and hardware versions.

The information in this document was created from the devices in a specific lab environment. All of the devices used in this document started with a cleared (default) configuration. If your network is live, make sure that you understand the potential impact of any command.

Conventions

For more information on document conventions, refer to the Cisco Technical Tips Conventions.

Background Information

The transparent caches are stocked with static data, for example, HTML, AVI, JPEG, and GIF files. Any files that are not cacheable, such as ASP, are passed directly to the server. Requests for cacheable content is balanced over the two cache servers based on the URL. In a real world scenario, they could also be balanced based on domain name. Fault tolerance is tested with one of the cache servers failing. If the configuration is being typed in, before creating the configuration, at the console prompt, type the script play eql-cacheable command, and the CSS automatically builds a list of cacheable objects in the configuration. There are also scripts for graphics and multimedia.

Configure

In this section, you are presented with the information to configure the features described in this document.

Note: To find additional information on the commands used in this document, use the Command Lookup Tool (registered customers only) .

Network Diagram

This document uses this network setup:

transparent_caching.gif

Configurations

Configuration
!Active version: ap0310029s

prompt TransCache

configure

!************************* INTERFACE *************************

interface ethernet-12  

!--- The Internet connection on port 1.


  bridge vlan 2

!************************** CIRCUIT **************************

circuit VLAN1
  ip address 10.1.1.254 255.255.255.0

circuit VLAN2
  ip address 192.168.1.254 255.255.255.0

!************************** SERVICE **************************

service Origin1                 



!--- Not required; included simply to show that the server is 
!--- up/down for testing keepalive frequency 60 purposes.


  ip address 10.1.1.1      
service TCacheServer1

  ip address 10.1.1.11
  type transparent-cache        


!--- The service is a transparent cache.


  port 80
  active

service TCacheServer2
  ip address 10.1.1.12
  type transparent-cache   

!--- The service is a transparent cache.

    
  port 80
  active

!**************************** EQL ****************************



!--- Created a single CLI command to save time typing.
!--- The list can be modified to suit individual requirements.


eql Cacheable
  description "This EQL contains extensions of cacheable content"
  extension pdf "Acrobat"
  extension fdf "Acrobat Forms Document"
  extension au "Sound audio/basic"
  extension bmp "Bitmap Image"
  extension z "Compressed data application/x-compress"
  extension gif "GIF Image image/gif"
  extension html "Hypertext Markup Language text/html"
  extension js "Java script application/x-javascript"
  extension mocha
  extension jpeg "JPEG image image/jpeg"
  extension jpg
  extension jpe
  extension jfif
  extension pjpeg
  extension pjp
  extension mp2 "MPEG Audio audio/x-mpeg"
  extension mpa
  extension abs
  extension mpeg "MPEG Video video/mpeg"
  extension mpg
  extension mpe
  extension mpv
  extension vbs
  extension m1v
  extension pcx "PCX Image"
  extension txt "Plain text text/plain"
  extension text
  extension mov "QuickTime video/quicktime"
  extension tiff "TIFF Image image/tiff"
  extension tar "Unix Tape Archive application/x-tar"
  extension pcx "PCX Image"
  extension txt "Plain text text/plain"
  extension text
  extension mov "QuickTime video/quicktime"
  extension tiff "TIFF Image image/tiff"
  extension tar "Unix Tape Archive application/x-tar"
  extension avi "Video for Windows video/x-msvideo"
  extension wav "Wave File audio/x-wav"
  extension gz "application/x-gzip"
  extension zip "ZIP file application/x-zip-compressed"



!*************************** OWNER ***************************

owner foo.com
  content L5_Transparent
    protocol tcp                        



!--- There is no VIP because the switch is transparent (not 
!--- visible to the client). Anything that is cacheable should be
!--- balanced using the URL and sent to the cache servers.  If they do not
!--- have it, they will request it from the server.



    port 80                           
    url "/*" eql Cacheable             
    balance urlhash                    
    add service TCacheServer1           
    add service TCacheServer2           
    active                             

Verify

This section provides information you can use to confirm your configuration is working properly.

Basic Transparent Test

Complete these steps to test basic transparency:

  1. Point a browser on the 192.168.1.0 network to http://10.1.1.1/video.html, and select the sample.avi video.

  2. Issue the show summary command. Note that the Cache Miss Bypass counter is increasing, which means that the cache is being populated

  3. Stock the cache by clicking on cup.avi and grinder.avi. The caches should have the AVI files cached.

  4. Clear the browser's cache, and select sample.avi. Note which transparent cache was hit.

  5. Repeat with cup.avi. The caches hits the other server due to URL load balancing of the caches.

  6. Repeat with grinder.avi, which hits the same cache as cup.avi.

  7. Clear the browser's cache, and repeat the test. The hit pattern is the same, showing that any user hits the same cache for the content.

  8. Point the browser to http://10.1.1.100/1.asp, which is not cacheable. Neither of the cache counters increment because the caches never see the request.

  9. Issue the show summary command. The No Rule Bypass counter incremented, which means that the request did not go to the caches.

Global Bypass Counters:
   No Rule Bypass Count:     20
   Acl Bypass Count:         0
   Cache Miss Bypass Count:  44

Owner            Content Rules    State     Services         Service Hits
foo.com          L5_Transparent   Active    TCacheServer1    42
                                            TCacheServer2    14

Fault Tolerance

Complete these steps to test fault tolerance:

  1. Unplug the origin server.

  2. Verify the server is down by issuing the show service summary command.

  3. Request a video file, which is serviced out of the cache.

  4. Plug the origin server back in and verify it is up.

  5. Unplug one of the cache servers, simulating an outage.

  6. Request the three AVI files. Note that they are all being cached by the remaining cache.

Troubleshoot

There is currently no specific troubleshooting information available for this configuration.

Related Information

Updated: Dec 27, 2007
Document ID: 12651