(help) squid.conf untuk ubuntu server 9.10

Diskusi tentang Ubuntu Server baik webserver, database server, samba server dan service lainnya serta jaringan menggunakan Sistem Operasi Ubuntu.
User avatar
rastaboy
Posts: 9
Joined: 19 Apr 2011, 09:10

(help) squid.conf untuk ubuntu server 9.10

Postby rastaboy » 19 Apr 2011, 09:17

buat abang2 senior yang ngerti cara setting squid.conf bantuin saya donk,, coz udah 5 hari ngga bisa tidur gara2 ini,, kenapa si koq cache.log saya selalu tcp_miss ini ss cache.log nya

Image

dan ini isi squid.conf saya

squid
http_port 3128 transparent
prefer_direct off

cache_mem 8 MB
cache_swap_low 95
cache_swap_high 97
max_filedesc 8192
#server_http11 on
maximum_object_size 100 MB
minimum_object_size 0 bytes
maximum_object_size_in_memory 32 KB
ipcache_size 4096
ipcache_low 95
ipcache_high 97
fqdncache_size 4096
cache_replacement_policy heap LFUDA
memory_replacement_policy heap GDSF
cache_dir aufs /cache1 5120 12 256
cache_dir aufs /cache2 5120 12 256
cache_dir aufs /cache3 5120 12 256
cache_dir aufs /cache4 5120 12 256
cache_access_log /var/log/squid/access.log
cache_log /var/log/squid/cache.log
cache_store_log none
cache_swap_log/var/log/squid/swap.state
emulate_httpd_log off
hosts_file /etc/hosts

refresh_pattern -i \.(jp?g|gif|pnp|png|\?bm?)$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.jar$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.dll$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.klz$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.dif$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.avi$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.iso$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.3gp$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.mpeg$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.xml$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.exe$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.zip$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.rar$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.mp3$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.npz$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.cfg$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.ver$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.elr$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.xt$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.xtp$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.des$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.new$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.t2bk$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.smd$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.gi$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.dat$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.luc$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.flv$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.html$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.htm$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.php$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.jsp$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.swf$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.bin$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.pdf$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.mp4$ 0 90% 43200 ignore-reload-override-expire reload-into-ims
refresh_pattern -i \.(/cgi-bin/|\?) 0 0% 0 ignore-reload-override-expire reload-into-ims
refresh_pattern ^http://mail.yahoo.com/.* 720 100% 4320
refresh_pattern ^http://*.yahoo.*/.* 720 100% 4320 override-expire override-lastmod reload-into-ims
refresh_pattern ^http://*.google.*/.* 720 100% 4320
refresh_pattern ^http://www.facebook.com/.* 720 100% 4320 override-expire override-lastmod reload-into-ims
refresh_pattern ^http://kaskus.us/.* 720 100% 4320 override-expire override-lastmod reload-into-ims
refresh_pattern ^http://*.indowebster.*/.* 720 100% 4320
refresh_pattern ^http://*.4*shared.*/.* 720 100% 4320
refresh_pattern ^http://www.yahoo.com/.* 720 100% 4320
refresh_pattern ^http://*.yimg.*/.* 720 100% 4320
refresh_pattern ^http://*.boleh.*/.* 720 100% 4320
#refresh_pattern ^http://*.detik.*/.* 180 100% 4320
#refresh_pattern ^http://*.detikinet.*/.* 180 100% 4320
#refresh_pattern ^http://*.detikhot.*/.* 180 100% 4320
#refresh_pattern ^http://*.detiportal.*/.* 180 100% 4320
#refresh_pattern ^http://*.kompas.*/.* 180 100% 4320
refresh_pattern ^http://*.facebook.*/.* 720 100% 4320
refresh_pattern ^http://*.texas_holdem.*/.* 720 100% 4320
refresh_pattern ^http://*.zynga.com.*/.* 720 100% 4320
refresh_pattern ^http://*.ninjasaga.*/.* 720 100% 4320
refresh_pattern ^http://*.texas.poker.*/.* 720 100% 4320
refresh_pattern ^http://apps.facebook.com/.* 720 100% 4320
refresh_pattern ^http://*.kapanlagi.*/.* 720 100% 4320
refresh_pattern ^http://*.google-analytics.*/.* 720 100% 4320
refresh_pattern ^ftp: 1440 20% 10080 ignore-reload-override-expire reload-into-ims
refresh_pattern ^gopher: 1440 0% 1440
refresh_pattern. 480 50% 22160 reload-into-ims

acl streaming url_regex -i \.youtube\.com\/get_video\?
acl streaming url_regex -i \.googlevideo\.com\/videoplayback \.googlevideo\.com\/videoplay \.googlevideo\.com\/get_video\?
acl streaming url_regex -i \.google\.com\/videoplayback \.google\.com\/videoplay \.google\.com\/get_video\?
acl streaming url_regex -i \.google\.[a-z][a-z]\/videoplayback \.google\.[a-z][a-z]\/videoplay \.google\.[a-z][a-z]\/get_video\?
acl streaming url_regex -i (25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\/videoplayback\?
acl streaming url_regex -i (25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\/videoplay\?
acl streaming url_regex -i (25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\/get_video\?
acl streaming url_regex -i proxy[a-z0-9\-][a-z0-9][a-z0-9][a-z0-9]?\.dailymotion\.com\/
acl streaming url_regex -i vid\.akm\.dailymotion\.com\/
acl streaming url_regex -i [a-z0-9][0-9a-z][0-9a-z]?[0-9a-z]?[0-9a-z]?\.xtube\.com\/(.*)flv
acl streaming url_regex -i bitcast\.vimeo\.com\/vimeo\/videos\/
acl streaming url_regex -i va\.wrzuta\.pl\/wa[0-9][0-9][0-9][0-9]?
acl streaming url_regex -i \.files\.youporn\.com\/(.*)\/flv\/
acl streaming url_regex -i \.msn\.com\.edgesuite\.net\/(.*)\.flv
acl streaming url_regex -i media[a-z0-9]?[a-z0-9]?[a-z0-9]?\.tube8\.com\/ mobile[a-z0-9]?[a-z0-9]?[a-z0-9]?\.tube8\.com\/
acl streaming url_regex -i \.mais\.uol\.com\.br\/(.*)\.flv
acl streaming url_regex -i \.video[a-z0-9]?[a-z0-9]?\.blip\.tv\/(.*)\.(flv|avi|mov|mp3|m4v|mp4|wmv|rm|ram)
acl streaming url_regex -i video\.break\.com\/(.*)\.(flv|mp4)
acl streaming url_regex -i get_video\?video_id videodownload\?
acl streaming_dom dstdomain .mccont.com dl.redtube.com .cdn.dailymotion.com .youtube.com .googlevideo.com
cache allow streaming
cache allow streaming_dom

acl all src 0.0.0.0/0.0.0.0
acl manager proto cache_object
acl localhost src 127.0.0.1
acl to_localhost dst 127.0.0.0/8
acl SSL_ports port 443 563 # http, snews
acl SSL_ports port 873 # rsync
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 Safe_ports port 631 # cups
acl Safe_ports port 873 # rsync
acl Safe_ports port 901 # SWAT
acl inputIP url_regex ^[url]http://[0-9]+\[/url].[0-9]+\.[0-9]+\.[0-9]+/$
acl inputIP url_regex ^[url]http://[0-9]+\[/url].[0-9]+\.[0-9]+\.[0-9]+$
acl PURGE method PURGE
acl CONNECT method CONNECT
http_access allow manager localhost
http_access deny manager
http_access allow PURGE localhost
#http_access deny inputIP
http_access deny PURGE
http_access deny !Safe_ports
http_access deny CONNECT !SSL_ports

acl homenet src 192.168.66.0/24
acl homenet src 192.168.22.0/24
http_access allow localhost
http_access allow homenet
http_access deny all
http_reply_access allow all
icp_access allow homenet
icp_access allow localhost
icp_access allow all
always_direct deny all

cache_effective_user proxy
cache_effective_group proxy
coredump_dir /var/spool/squid
pid_filename /var/run/squid.pid
shutdown_lifetime 5 seconds
logfile_rotate 7

#snmp_port 3401#acl snmpsquid snmp_community public
#snmp_access allow snmpsquid localhost
#snmp_access deny all

zph_mode tos
zph_local 0x30


mohon di kroces donk gan dimana salah saya
User avatar
immux
Posts: 19
Joined: 26 Aug 2010, 09:46
Location: malang
Contact:

Re: (help) squid.conf untuk ubuntu server 9.10

Postby immux » 19 Apr 2011, 10:01

coba pake konfigurasi yang basic aja dulu
User avatar
rastaboy
Posts: 9
Joined: 19 Apr 2011, 09:10

Re: (help) squid.conf untuk ubuntu server 9.10

Postby rastaboy » 19 Apr 2011, 10:10

[quote=immux]coba pake konfigurasi yang basic aja dulu

maskud nya abang immux konfigureasi defaultnya ubuntu ya bang