[The University of Melbourne]

[Top] [Contents]
[Prev: 2. Squid]
[Next: Appendix A: Redirectors]


Web Caching

3. Samples


Contents:
3.1. Single User Setup
3.2. University Sized Squid

3.1. Single User Setup

Use NoVM version on local PC

# MB
cache_mem 4
# MB (so 1024 is 1GB)
cache_swap 1024
http_port 3128
icp_port 3130
cache_mgr <wherever>
cache_effective_user nobody nobody
cachemgr_passwd secretsound all
cache_host squid.myisp.com.au parent 3128 3130
local_domain mydomain.com.au
hierarchy_stoplist cgi-bin ?
cache_stoplist cgi-bin ?
cache_dir /var/spool/cache
cache_access_log /var/log/squid/access.log
cache_store_log none
refresh_pattern/i jpg$ 720 100% 10080
refresh_pattern/i gif$ 720 100% 10080
refresh_pattern . 360 20% 10080
quick_abort -1 0 0
acl me src mynet/mynetmask
http_access allow me
icp_access allow me
miss_access allow me
http_access deny all
miss_access deny all
swap_level1_dirs 1
swap_level2_dirs 16
dns_children 5
redirect_program /usr/local/bin/redirector
redirect_children 5
negative_ttl 1
# In seconds. 240 = 4 Minutes.
connect_timeout 240
# Seconds
shutdown_lifetime 5

3.2. University Sized Squid

Use VM version on server class machine (e.g. alphaserver 1000 - 256MB RAM, 20GB disk)

# MB
cache_mem 128
# MB (12000 ~ 12GB)
cache_swap 12000
http_port 8000
icp_port 3130
cache_host proxy.monash.edu.au neighbor 80 3130
cache_host proxywww.rmit.edu.au neighbor 8000 3130
cache_host squid.latrobe.edu.au neighbor 8080 3130
cache_host wwwproxy.swin.edu.au neighbor 8000 3130
cache_host camel.vut.edu.au neighbor 80 3138
cache_host deneb.its.deakin.edu.au neighbor 3128 3130
acl rmit       src 131.170.8.100
acl deakin     src 139.132.100.2 
acl latrobe    src 131.172.20.22 
acl vutnew     src 140.159.30.10 
acl monash     src 130.194.11.7 
acl swinburne  src 136.186.1.112 
acl uninet src 192.168.0.0/255.255.0.0
http_access allow  monash 
http_access allow  rmit 
http_access allow  latrobe 
http_access allow  deakin 
http_access allow  vut 
http_access allow  swinburne 
http_access allow  swinburne1 
icp_access  allow  monash 
icp_access  allow  deakin 
icp_access  allow  latrobe 
icp_access  allow  swinburne 
icp_access  allow  rmit 
icp_access  allow  vut 
http_access allow uninet
icp_access allow uninet
miss_access allow uninet
# No Freeloading neighbours.
miss_access deny monash
miss_access deny rmit
miss_access deny latrobe
miss_access deny vut
miss_access deny swinburne
miss_access deny deakin
# Uni ITS departments always listen intently to client whinges
cache_mgr devnull@cc.uni.edu.au
cache_effective_user squid squid
cachemgr_passwd foobar1
local_ip 192.168.0.0/255.255.0.0
hierarchy_stoplist cgi-bin ?
cache_stoplist cgi-bin ?
# 6 * 2Gb Cache Disks
cache_dir /cache/disk1
cache_dir /cache/disk2
cache_dir /cache/disk3
cache_dir /cache/disk4
cache_dir /cache/disk5
cache_dir /cache/disk6
cache_access_log /logs/squid-access.log
cache_store_log none
# KB, 50000 ~ 50MB
request_size 50000
refresh_pattern ^http://home.netscape.com/.*     720   100%  4320 
refresh_pattern ^http://www.netscape.com/.*      720   100%  4320 
refresh_pattern ^http://www.yahoo.com/.*         720   100%  4320 
refresh_pattern/i jpg$                             4320  100%  10080 
refresh_pattern/i gif$                             4320  100%  10080 
refresh_pattern   /$                               360   10%   4320 
refresh_pattern   .                                0     20%   4320 
swap_level1_dirs 16
swap_level2_dirs 256
dns_children 32
redirector_program /usr/local/bin/redirector
redirector_children 32

[Top] [Contents]
[Prev: 2. Squid]
[Next: Appendix A: Redirectors]


Generated:  13 November, 1998
Copyright:  © 1998 The University of Melbourne
Maintainer: cwis@www.unimelb.edu.au