By default squid almost works out of the box

Installation
there are two ways of installing squid. The tar file requires configuration, but the 
documentation is excellent. the other way is the RPM file. This may not be the most up 
to date version but it will be close. Try getting the RPM from 
http://rpmfind.net/linux/RPM/redhat/updates/7.3/i386/squid-2.4.STABLE6-6.7.3.i386.html 
and installing it using the command 

rpm -Uvh squidxxxxxxx      (where xxxxxxx is the file name)

the next thing to do is to look at the squid.conf file. This is usually installed in 
/etc/squid. In there will be a few files but the one you need is squid.conf. If you 
open the file in an editor you will see a lot of comments, and a few lines of config.  
I usually copy the file to a backup, and then strip out all the commented lines 
(prefixed #) to make things a little clearer.

grep -v "#" squid.conf > squid.new
mv squid.conf squid.old
mv squid.new squid.conf


This is pretty well all it needs. There are a few lines that need changing. 

acl localhost src 127.0.0.1/255.255.255.255

the above line is the default and allows only the local host to access the squid 
system. a few lines further down is 

http_access allow localhost

and then 

http_access deny all

what i tend to do is add a line under the first one to read 

acl localhost src 127.0.0.1/255.255.255.255
acl localnet src 192.168.0.0/255.255.255.0     (<----- your subnet will vary)

then add  

http_access allow localhost
http_access allow localnet


this allows all the machines within the 192.168.0 network access to the squid proxy. 
Other defaults mean that the proxy will accept connections for the internet on port 
3128.

Next we need to start/restart squid. Issue the command 

/etc/init.d/squid restart

and you should be up and running.

To prove it, go to a browser, and set the http proxy settings to the ip address of the 
machine running squid (127.0.0.1 if the same machine) and the proxy port to 3128

open a command window and su to root and run the command

tail -f /var/log/squid/access.log

when you browse, you should see the objects being downloaded in the command window.


Remember - this is a very basic install. Once you have it working there all sorts of 
tweaks and changes you can make. 

Hope this helps in some small way


-- 
redhat-list mailing list
unsubscribe mailto:[EMAIL PROTECTED]
https://www.redhat.com/mailman/listinfo/redhat-list

Reply via email to