We found YouTub and other streaming media is the major share in the bandwidth conception. For a better performance, we decided to find ways to cache them. We did a search in google and found some useful links and we made a work out from this.

The squid.conf extra lines look like this.

YouTube options

acl youtube dstdomain .youtube.com .googlevideo.com video.google.com video.google.co.in acl youtubeip dst 74.125.15.0/24 64.15.0.0/16 cache allow youtube cache allow youtubeip refresh_pattern -i \.(flv)$ 20080 90% 999999 ignore-no-cache override-expire ignore-private refresh_pattern ^http://sjl-v[0-9]+.sjl.youtube.com 20080 90% 999999 ignore-no-cache override-expire ignore-private refresh_pattern get_video?video_id 20080 90% 999999 ignore-no-cache override-expire ignore-private refresh_pattern youtube.com/get_video? 20080 90% 999999 ignore-no-cache override-expire ignore-private

Google Earth

refresh_pattern -i m/^http:\/\/kh(.*?)\.google\.com(.*?)\/(.*?)$/ 20080 90% 999999 ignore-no-cache override-expire ignore-private

Problem

I don’t think the above given is effective, we need suggestions. If anyone have a better way around for this problem, please help us.

Reference

  1. Squid User Mailing list
  2. Technical Nuggest
  3. Squid Wiki