Squid is good one, also webmin. I am still new to this, can someone helping how to see the Squid progress in terminal or in webmin? I mean when we open some site its going also on squid and showing the logs that site have being hit, miss, or have in cache? Also any idea to using Squid or webmin to block the ads, websites, or keywords? Thanks.
3 Answers
Squid logs are configured by default in /var/log/squid/access.log. You can change this setting via cache_access_log in /etc/squid/squid.conf (but remember to sudo service squid restart after making the change). You could tail -f that file.
For site-blocking, I recommend using jesred, which is available in the Ubuntu archive already. You can find details on using it here: http://www.linofee.org/~jel/webtools/jesred/
See the redirect_program /usr/lib/squid/jesred example in /etc/squid/squid.conf.
You can also use squid-graph for that to view cache hits,etc etc
http://squid-graph.sourceforge.net/
Monitoring Squid with Squid-Graph
Squid Graph is a free, simple, yet powerful Squid v2 native logfile analysis tool that generates reports with graphical representation of the proxy server’s traffic.
1.To install Squid-Graph we need perl and gd module.
sudo apt-get install libgd-gd2-perl
2.Download Squid-Graph from the source.We can also download with wget.
wget http://biznetnetworks.dl.sourceforge.net/project/squid-graph/squid-graph/3.2/squid-graph-3.2.tar.gz
3.Extract Squid-graph
tar xzvf squid-graph-3.2.tar.gz -C /etc/init.d/
4.Add execute permission
chmod +x /etc/init.d/squid-graph/*
5.Make html directory in document root (default : /var/www)
cd /var/www
mkdir squid-graph
cd /etc/init.d/squid-graph
./squid-graph --tcp-only -n -o=/var/www/squid-graph/ --title="proxy" < /var/log/squid/access.log
6.Open the web browser , type http://127.0.0.1/squid-graph

Thats it.
tail -f /var/log/squid/access.log
-
3It would be more helpful if you explained exactly what this answer did.– user323419Oct 1, 2015 at 17:02