Jumat, 04 Juli 2014

Sqstat: Log Analyzer Squid

Aplikasi yg dibutuhkan sebagai berikut:

yang pasti harus sudah terinstall squid
>>>>>
root@Proxy:~# apt-get install apache2
root@Proxy:~# apt-get install php5
root@Proxy:~# apt-get install apache2-mpm-prefork
root@Proxy:~# apt-get install libapache2-mod-php5
root@Proxy:~# apt-get install apache2-mpm-worker

 setelah itu download sqstatnya..

root@Proxy:~# wget http://samm.kiev.ua/sqstat/sqstat-1.20.tar.gz
root@Proxy:~# tar -zxvf sqstat-1.20.tar.gz
root@Proxy:~# mv sqstat-1.20 /var/www/
root@Proxy:~# cd /var/www/
root@Proxy:/var/www# mv sqstat-1.20 sqstat

lalu masuk ke  folder  sqstat
root@Proxy:/var/www#cd sqstat
root@Proxy:/var/www/sqstat# mv config.inc.php.defaults config.inc.php

setelah itu edit file config.inc.php

root@Proxy:/var/www# vim /var/www/sqstat/config.inc.php

<?php
/* global settings */
$use_js=true; // use javascript for the HTML toolkits
//===================== Change the following settings =====================//
// Maximum URL length to display in URI table column
DEFINE(“SQSTAT_SHOWLEN”,100);
/* proxy settings */
/* Squid proxy server ip address or host name */
#$squidhost[0]=”127.0.0.1″;
$squidhost[0]=”192.168.1.11″;
/* Squid proxy server port */
#$squidport[0]=3128;
$squidport[0]=8080;
//========================================================================//
/* cachemgr_passwd in squid.conf. Leave blank to disable authorisation */
$cachemgr_passwd[0]=””;
/* Resolve user IP addresses or print them as numbers only [true|false] */
$resolveip[0]=false;
/* uncomment next line if you want to use hosts-like file.
   See hosts.txt.dist. */
// $hosts_file[0]=”hosts.txt
/* Group users by hostname – “host” or by User – “username”. Username work only
   with squid 2.6+ */
$group_by[0]=”host”;
/* you can specify more than one proxy in the configuration file, e.g.: */
// $squidhost[1]=”192.168.0.2″;
// $squidport[1]=3129;
// $cachemgr_passwd[1]=”secret”;
// $resolveip[1]=true;
// $hosts_file[1]=”otherhosts.txt
?>



Restart Squid and  web server.
root@Proxy:~# /etc/init.d/squid restart
root@Proxy:~# /etc/init.d/apache2 restart

buka browser arahkan ke

http://IP WEB/sqstat

Tidak ada komentar:

Posting Komentar