Beberapa hari ini iseng di kantor menginstallkan Squid Proxy Server
versi 2.8 di Windows eh ternyata berhasil, windows yang saya installkan
squid ini adalah windows 7 namun setelah saya coba juga pada Windows Xp
Professional di Rumah berhasil juga.
Langsung saja, topologi di kantor saya sebagai berikut :
Modem AHA<--->Router TP_LINK<--->PC1<--->PC2<--->Dan_Seterusnya
Lebih rincinya kalian baca saja catatan yang terdokumentasi di bawah ini tentang install Squid di Windows 7 atau Windows XP Professional yang berjalan sukses.
- Download versi terakhir squid untuk Windows dari situs resmi disini atau download versi yang sama dengan yang saya pakai di sini yakni squid v2.7.2
- Install seperti biasa file installer squid yang baru anda download
di atas. Berikut screenshoot proses installasi executable-nya :
- Setelah langkah installasi squid selesai anda jangan heran di Start Menu > All Program tidak terindeks Aplikasi Squid ini. Direktori Squid default ada di c:\squid dan di dalam folder squid itu sendiri ada subfolder :
bin, docs, etc, libexec, sbin, share, system32, var
- Lakukan backup file squid.conf, contoh dengan cara berikut :
copy pastekan squid.conf lalu rename/namai menjadi squid.conf.asli dalam 1 folder tersebut supaya lebih gampang kalau ada apa-apa maka tinggal hapus squid.conf lalu namai squid.conf.asli menjadi squid.conf dan restart komputer. - Tidak seperti kebanyakan seting
software di Windows hanya cukup dengan klak-klik, cecklist/uncheck opsi
yang ada maka langsung berjalan.
Pada squid di windows untuk mengkonfigurasi harus mengedit file squid.conf barulah squid bisa berjalan, namun jika kalian kurang familiar dengan squid maka anda tinggal samakan isi squid.conf di sistem Windows anda dengan punya saya di bawah ini yang sudah berjalan dan sederhana :
# WELCOME TO SQUID 2.7.STABLE8
acl all src all
acl manager proto cache_object
acl localhost src 127.0.0.1/32
acl to_localhost dst 127.0.0.0/8 0.0.0.0/32
acl localnet src 10.0.0.0/8 # RFC1918 possible internal network
acl localnet src 172.16.0.0/12 # RFC1918 possible internal network
acl localnet src 192.168.0.0/16 # RFC1918 possible internal network
acl husen src 192.168.1.0/32 #SESUAIKAN DGN LOKAL ANDA
acl SSL_ports port 443
acl Safe_ports port 80 # http
acl Safe_ports port 21 # ftp
acl Safe_ports port 443 # https
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 allow husen
http_access deny manager
http_access deny !Safe_ports
http_access deny CONNECT !SSL_ports
http_access allow localnet
http_access deny all
icp_access allow localnet
icp_access deny all
http_port 3128 # port squid
hierarchy_stoplist cgi-bin ?
cache_mem 8 MB
maximum_object_size_in_memory 32 KB
memory_replacement_policy lru
cache_replacement_policy lru
cache_dir ufs c:/squid/var/cache 500 24 256
cache_swap_low 90
cache_swap_high 95
access_log c:/squid/var/logs/access.log squid
refresh_pattern ^ftp: 1440 20% 10080
refresh_pattern ^gopher: 1440 0% 1440
refresh_pattern -i (/cgi-bin/|\?) 0 0% 0
refresh_pattern . 0 20% 4320
quick_abort_pct 95
cache_mgr webmaster
Jika sudah di rasa pas dan tidak ada yang salah silahkan save dan tutup
- Sekarang saat nya mem-check apakah konfig kita file squid.conf ada
yang salah, cara nya Buka command promp Windows kemudian ketikan, jika
pas di Enter tidak ada apa berarti penulisan konfigurasi squid sudah
benar :
c:\squid\sbin\squid -k parse -n squid - Sekarang saat nya membuat direktori cache squid, cara nya masih pada
command promp Windows kemudian ketikan, tunggu hingga selesai :
c:\squid\sbin\squid -z - Masih pada Command Prompt, saatnya Install squid sebagai services dengan mengetikan seperti berikut:
c:\squid\sbin\squid -i
- Tutup command prompt Windows, saat-nya mengaktifkan services squid dari services.msc. Cara nya Buka Run atau tekan logo Windows+R kemudian ketikan services.msc kemudian Enter. Cari services yang bernama squid lalu klik Start
- Selesai dan silahkan restart komputer untuk menerapkan perubahan.