พอดีผมใ ช้ config ที่ได้มาจากในบอดของคนคนนึงอ่ะคับ ซึ่งทุกวันนี้ก้อยังใช้อยู่เลย แต่ว่า ยังตัดสินใจมะถูกว่าจะใช้ใครดีคับดี คับ
ช่วยดูให้หน่อยดิ ดีปะ ในที่เกบ cache_dir ufs c:/squid/var/cache 256 16 256 อ่ะคับ เคยลองไปดู ในc:/squid/var/cache
ไม่เคยเหงมันถึง เกิน200 MB ชักทีเปนเพราะไร คับ ผม ขอบคุนมากคับ
#############################################################################
###
### SquidNT Config by Lucifer
###
#############################################################################
###
http://www.acmeconsulting.it/SquidNT.htm#############################################################################
###
### Symbol '#' is comment.
###
#############################################################################
### NETWORK OPTIONS
#############################################################################
#@ source server accelerator (HTTP)
#@ - The Squid redirector can make one accelerator act as a single front-end for multiple servers.
#@ If you need to move parts of your filesystem from one server to another, or if separately
#@ administered HTTP servers should logically appear under a single URL hierarchy, the accelerator
#@ makes the right thing happen.
#@ - If you wish only to cache the ``rest of the world" to improve local users browsing performance,
#@ then accelerator mode is irrelevant. Sites which own and publish a URL hierarchy use an accelerator
#@ to improve other sites' access to it. Sites wishing to improve their local users' access to other
#@ sites' URLs use proxy caches. Many sites, like us, do both and hence run both.
http_port 80
#@ caching proxy simultaneously (SMTP)
http_port 25
#@ caching proxy simultaneously (POP3)
http_port 110
#@ caching proxy simultaneously (SOCKS)
http_port 1080
#@ caching proxy simultaneously (Active API Server Port)
http_port 3128
#@ caching proxy simultaneously (HTTP Alternate)
http_port 8080
#############################################################################
### OPTIONS WHICH AFFECT THE NEIGHBOR SELECTION ALGORITHM
#############################################################################
#@ not recommended
#cache_peer proxy.anet.net.th parent 8080 3130 no-query
#cache_peer proxy.asiaaccess.net.th parent 8080 3130 no-query
#cache_peer proxy.asianet.co.th parent 8080 3130 no-query
#cache_peer proxy.cscoms.com parent 8080 3130 no-query
#cache_peer proxy.cwn.net.th parent 8080 3130 no-query
#cache_peer proxy.linethai.co.th parent 8080 3130 no-query
#cache_peer netproxy1.inet.co.th parent 8080 3130 no-query
#cache_peer proxy.idn.co.th parent 8080 3130 no-query
#cache_peer proxy.infonews.co.th parent 8080 3130 no-query
#cache_peer proxy.ji-net.com parent 8080 3130 no-query
#cache_peer proxy.ksc.net.th parent 8080 3130 no-query
#cache_peer proxy.loxinfo.co.th parent 8080 3130 no-query
#cache_peer proxy.roynet.co.th parent 8080 3130 no-query
#cache_peer proxy.samart.co.th parent 8080 3130 no-query
#cache_peer proxy.sgn.net.th parent 8080 3130 no-query
#cache_peer proxy.siamit.co.th parent 8080 3130 no-query
#cache_peer proxy.wnet.net.th parent 8080 3130 no-query
#cache_peer proxy.sga.net.th parent 8080 3130 no-query
#cache_peer proxy.ksc.co.th sibling 8080 3130 no-query
#cache_peer 203.155.105.83 parent 444 3130 no-query
hierarchy_stoplist cgi-bin ?
acl QUERY urlpath_regex cgi-bin \?
no_cache deny QUERY
#@ Handle dynamic html (don't cache and always go direct)
acl DHTML urlpath_regex cgi-bin
acl DHTML urlpath_regex \.asp
acl DHTML urlpath_regex \.cgi
acl DHTML urlpath_regex \.jhtml
acl DHTML urlpath_regex \.jsp
acl DHTML urlpath_regex \.perl
acl DHTML urlpath_regex \.phtml
acl DHTML urlpath_regex \.pl
acl DHTML urlpath_regex \.php
acl DHTML urlpath_regex \.php3
acl DHTML urlpath_regex \.shtml
acl DHTML urlpath_regex \?
always_direct allow DHTML
no_cache deny DHTML
#############################################################################
### OPTIONS WHICH AFFECT THE CACHE SIZE
#############################################################################
#@ 'cache_mem' specifies the ideal amount of memory to be used.
#@ + use ram/4 (for ram 512 or greater)
#@ + use ram/8 (for ram less than 512)
cache_mem 96 MB ## [bytes]
cache_swap_low 90 ## [percent, 0-100]
cache_swap_high 100 ## [percent, 0-100]
maximum_object_size 4096 KB ## [bytes]
minimum_object_size 0 KB ## [bytes]
maximum_object_size_in_memory 8 KB ## [bytes]
ipcache_size 16384 ## [number of entries]
ipcache_low 90 ## [percent, 0-100]
ipcache_high 100 ## [percent, 0-100]
fqdncache_size 16384 ## [number of entries]
cache_replacement_policy heap GDSF
memory_replacement_policy heap GDSF
#############################################################################
### LOGFILE PATHNAMES AND CACHE DIRECTORIES
#############################################################################
#@ [cache_dir ufs Directory-Name Mbytes L1 L2]
#@ Mbytes = is the amount of disk space (MB) to use under this directory. [default=100]
#@ L1 = is the number of first-level subdirectories which will be created under the 'cache_dir'. [default=16]
#@ L2 = is the number of second-level subdirectories which will be created under each first-level directory. [default=256]
cache_dir ufs c:/squid/var/cache 256 16 256
cache_access_log none
cache_log none
cache_store_log none
log_ip_on_direct off
mime_table c:/squid/etc/mime.conf
pid_filename c:/squid/etc/pid.conf
#############################################################################
### OPTIONS FOR EXTERNAL SUPPORT PROGRAMS
#############################################################################
ftp_user Squid@
ftp_passive on
auth_param basic children 5
auth_param basic realm Squid proxy-caching web server
auth_param basic credentialsttl 2 hours
auth_param basic casesensitive off
#############################################################################
### OPTIONS FOR TUNING THE CACHE
#############################################################################
#@ java
refresh_pattern -i \.class 2880 60% 28800
#@ image - min 1 day, 50% of age and max 14 days
refresh_pattern ^http://.*\.gif$ 1440 50% 20160 reload-into-ims
refresh_pattern ^http://.*\.asis$ 1440 50% 20160
refresh_pattern -i \.gif 10080 300% 40320 reload-into-ims
#@ image - these min 7 days, 150% of age, max 28 days (not likely to change)
refresh_pattern -i \.bmp 10080 150% 40320 reload-into-ims
refresh_pattern -i \.jpg 10080 150% 40320 reload-into-ims
refresh_pattern -i \.jpeg 10080 150% 40320 reload-into-ims
refresh_pattern -i \.png 10080 150% 40320 reload-into-ims
refresh_pattern -i \.tif 2880 80% 28800 reload-into-ims
refresh_pattern -i \.tiff 2880 80% 28800 reload-into-ims
refresh_pattern -i \.xbm 2880 80% 28800 reload-into-ims
#@ animation
refresh_pattern -i \.avi 2880 80% 28800
refresh_pattern -i \.mov 2880 80% 28800
refresh_pattern -i \.mpg 2880 80% 28800
refresh_pattern -i \.swf 2880 80% 28800 reload-into-ims
#@ audio
refresh_pattern -i \.au 2880 80% 28800
refresh_pattern -i \.mid 2880 80% 28800
refresh_pattern -i \.midi 2880 80% 28800
refresh_pattern -i \.mp3 2880 80% 28800
refresh_pattern -i \.ram 2880 80% 28800
refresh_pattern -i \.wav 2880 80% 28800
#@ archive compresses
refresh_pattern -i \.zip 2880 200% 40320
refresh_pattern -i \.arj 2880 200% 40320
refresh_pattern -i \.rar 2880 200% 40320
refresh_pattern -i \.lha 2880 50% 28800
refresh_pattern -i \.lzh 2880 50% 28800
refresh_pattern -i \.gz 10080 200% 40320
refresh_pattern -i \.tgz 10080 200% 40320
refresh_pattern -i \.tar 10080 200% 40320
refresh_pattern -i \.Z 10080 200% 40320
#@ documents
refresh_pattern -i \.txt 2880 60% 28800 reload-into-ims override-lastmod
refresh_pattern -i \.rtf 2880 60% 28800 reload-into-ims
refresh_pattern -i \.doc 2880 60% 28800 reload-into-ims
refresh_pattern -i \.ppt 2880 60% 28800 reload-into-ims
refresh_pattern -i \.wp 2880 60% 28800
refresh_pattern -i \.wp5 2880 60% 28800
refresh_pattern -i \.ps 2880 60% 28800
refresh_pattern -i \.prn 2880 60% 28800
refresh_pattern -i \.srf 2880 60% 28800
#@ pdf min 6 hours, 100% of last modified max 28 days and enforce min (override-lastmod)
refresh_pattern -i \.pdf$ 720 100% 40320 override-lastmod
#@ static webpages
refresh_pattern -i \.htm$ 480 0% 22160 reload-into-ims override-lastmod
refresh_pattern -i \.html$ 480 0% 22160 reload-into-ims override-lastmod
refresh_pattern -i \.css$ 480 0% 22160 reload-into-ims override-lastmod
refresh_pattern -i \.js$ 480 0% 22160 reload-into-ims override-lastmod
#@ dynamic webpages
refresh_pattern -i cgi-bin 1 20% 2
refresh_pattern -i \.acgi$ 1 20% 2
refresh_pattern -i \.asp$ 1 20% 2
refresh_pattern -i \.cgi$ 1 20% 2
refresh_pattern -i \.jsp$ 1 20% 2
refresh_pattern -i \.perl$ 1 20% 2
refresh_pattern -i \.php$ 1 20% 2
refresh_pattern -i \.php3$ 1 20% 2
refresh_pattern -i \.pl$ 1 20% 2
refresh_pattern -i \.chtml$ 1 20% 2
refresh_pattern -i \.phtml$ 1 20% 2
refresh_pattern -i \.shtml$ 1 20% 2
refresh_pattern -i \.xhtml$ 1 20% 2
refresh_pattern -i \.xml$ 1 20% 2
refresh_pattern -i \? 1 20% 2
#@ executables
refresh_pattern .exe 2880 80% 28800
#@ keep ftp/gopher (mainly directories) fresh for 1 day, 50%, max 10 days
refresh_pattern ^ftp:// 1440 50% 14400 override-lastmod
refresh_pattern ^gopher:// 1440 50% 14400 override-lastmod
#@ all the rest 6 hours, 50% of age, max 5 days
refresh_pattern . 360 50% 7200 override-lastmod
quick_abort_min 100 KB
quick_abort_max 750 KB
quick_abort_pct 60
#dns_nameservers 203.155.33.1
#dns_nameservers 202.44.144.33
#############################################################################
### TIMEOUTS
#############################################################################
request_timeout 30 seconds
half_closed_clients off
#############################################################################
### ACCESS CONTROLS
#############################################################################
acl all src 0.0.0.0/0.0.0.0
acl manager proto cache_object
acl localhost src 127.0.0.1/255.255.255.255
acl localnet src 192.168.0.1-192.168.0.255/255.255.255.255
acl to_localhost dst 127.0.0.0/8
acl SSL_ports port 443 563
acl Safe_ports port 80 # http
acl Safe_ports port 21 # ftp
acl Safe_ports port 443 563 # https, snews
acl Safe_ports port 70 # gopher
acl Safe_ports port 210 # wais
acl Safe_ports port 1025-65535 # unregistered ports
acl Safe_ports port 280 # http-mgmt
acl Safe_ports port 488 # gss-http
acl Safe_ports port 591 # filemaker
acl Safe_ports port 777 # multiling http
acl CONNECT method CONNECT
http_access allow manager localhost
http_access deny manager
http_access deny !Safe_ports
http_access deny CONNECT !SSL_ports
#@ blacklist words in url <setup 1>
#@ template: acl blacklist_words url_regex [word1 word2 word3...]
#acl blacklist_words url_regex fuck
#acl blacklist_words url_regex kill
#acl blacklist_words url_regex sex
#@ blacklist words in url <setup 2>
#http_access deny blacklist_words
#@ blocked sites <setup 1>
#@ template: acl blacklist_words url_regex [site1 site2 site3 ...]
#acl blocked_sites url_regex
www.xxx.com#acl blocked_sites url_regex
www.yyy.com#acl blocked_sites url_regex
www.zzz.com#@ blocked sites <setup 2>
#http_access deny blocked_sites
#@ dirty domains <setup 1>
#@ template: acl dirty_domains dstdomain [domain1 domain2 domain3...]
#acl dirty_domains dstdomain playboy.com
#acl dirty_domains dstdomain hustler.com
#acl dirty_domains dstdomain hh.nl
#acl dirty_domains dstdomain penthouse.com
#acl dirty_domains dstdomain playgirl.com
#acl dirty_domains dstdomain penthouselive.com
#@ dirty domains <setup 2>
#http_access deny dirty_domains
#@ blacklist files <setup 1>
#@ template: acl download_files urlpath_regex -i \.[extension]$
#acl blacklist_files urlpath_regex -i \.asf$
#acl blacklist_files urlpath_regex -i \.avi$
#acl blacklist_files urlpath_regex -i \.com$
#acl blacklist_files urlpath_regex -i \.exe$
#acl blacklist_files urlpath_regex -i \.iso$
#acl blacklist_files urlpath_regex -i \.mp3$
#acl blacklist_files urlpath_regex -i \.mpg$
#acl blacklist_files urlpath_regex -i \.mpeg$
#acl blacklist_files urlpath_regex -i \.ogg$
#acl blacklist_files urlpath_regex -i \.rar$
#acl blacklist_files urlpath_regex -i \.wav$
#acl blacklist_files urlpath_regex -i \.wma$
#acl blacklist_files urlpath_regex -i \.wmv$
#acl blacklist_files urlpath_regex -i \.zip$
#@ blacklist files <setup 2>
#http_access deny blacklist_files
#@ allow to download blacklist files from specific ip <setup 1>
#acl allowed_downloads_ip src 172.16.1.65/32
#@ allow to download blacklist files from specific ip <setup 2>
#http_access allow blacklist_files allowed_downloads_ip
#@ block msn <setup 1> (use with fire wall -> disable port:1863)
#acl msn req_mime_type ^application/x-msn-messenger$
#acl msn url_regex gateway.dll
#acl msn_ports port 1863
#@ block msn <setup 2>
#http_access deny msn
#http_access deny msn_ports
http_access allow localhost
http_access allow localnet
http_access deny all
http_reply_access allow all
icp_access allow all
miss_access allow all
#############################################################################
### ADMINISTRATIVE PARAMETERS
#############################################################################
cache_mgr Administrator
cache_effective_user squid
cache_effective_group squid
visible_hostname ProxyServer
unique_hostname ProxyServer
#############################################################################
### OPTIONS FOR THE CACHE REGISTRATION SERVICE
#############################################################################
#############################################################################
### HTTPD-ACCELERATOR OPTIONS
#############################################################################
#@ set squid as transparent proxy (use with http_port 80)
httpd_accel_host virtual
httpd_accel_port 81
httpd_accel_with_proxy on
httpd_accel_single_host on
httpd_accel_uses_host_header on
#############################################################################
### MISCELLANEOUS
#############################################################################
#logfile_rotate 8
memory_pools_limit 8 MB
reload_into_ims on
never_direct deny localhost
never_direct deny localnet
never_direct allow all
#############################################################################
### DELAY POOL PARAMETERS (all require DELAY_POOLS compilation option)
#############################################################################
ie_refresh on
#############################################################################
# End config
#############################################################################