Author Topic: How to use squid server as your proxy server .. (very easy)  (Read 3396 times)

Eric

  • Global Moderator
  • Newbie
  • *****
  • Posts: 13
Download Squid Source and Patches

 

Go and get  squid latest source from http://www.squid-cache.org/Versions/v2/2.5/ and patches from http://www.squid-cache.org/Versions/v2/2.5/bugs/ site.

 

# cd /usr/local/

# wget http://www.squid-cache.org/Versions/v2/2.5/squid-2.5.STABLE10.tar.bz2

# tar -xvjf squid-2.5.STABLE10-tar.bz2

# cd squid-2.5.STABLE10

 

Apply the patches as,


b)      Building Squid

 

Configure squid cache server and build based on your requirement. For default configuration,

 

# ./configure

# make

# make install

 

Note: If you get any issues  during configuration, act based upon the input given. If you could not solve it, please send your queries or problem to likedreaminator@gmail.com

c)Configuring Squid

 

With default configuration of squid installation, squid is installed in /usr/local/squid/ directory. Before starting squid, we have to change configuration file and ownership.

 

i)                     Check squid user availability

 

# id squid

 

Has to return user information with group details.

 

If you find Cann't find user squid then,

 

# groupadd squid

# useruser -G squid squid

 

ii)                   Editing squid configuration file (squid.conf) for Proxy Mode

 

Get your machine hostname or Fully Qualified Domain Name as,

 

# hostname

 

Open /usr/local/squid/etc/squid.conf with vi editor or view or vim as,

 

# vi /usr/local/squid/etc/squid.conf

Turn vi editor to Insert mode by pressing "i" character on keyboard

 

visible_hostname "your hostname"

cache_effective_user squid

cache_effetive_group squid

 

iii)   Changing directory permission

 

Change /usr/local/squid/var/ directory with permission to squid:squid as,

 

# chown -R squid:squid /usr/local/squid/var

d)      Creating swap directories and starting Squid

 

During first time startup of squid, you have to create swap directories as,

 

# /usr/local/squid/sbin/squid -z

 

Pls Note: If you get any problem during swap directories creation, act based upon the input given. If you could not solve it, please send your queries likedreaminator@gmail.com

 

Start squid in non-deamon and debug mode as,

 

# /usr/local/squid/sbin/squid -NCd10

 

If you get "Ready to server Requests" message then our squid installation is successful.

 

Troubleshooting Note:

 

Sometimes you may find problem to start squid because of DNS server resolvation, then you can start it by disabling INTERNAL DNS lookup as,

 

# /usr/local/squid/sbin/squid -NCd10 -D


e)Starting Squid in Daemon Mode

 

Start squid in daemon as,

 

# /usr/local/squid/sbin/squid

 
« Last Edit: June 14, 2007, 02:46:53 PM by Eric »

Romio

  • Global Moderator
  • Full Member
  • *****
  • Posts: 226
Re: How to use squid server as your proxy server .. (very easy)
« Reply #1 on: June 29, 2007, 10:14:48 AM »
I tried to Do this but after I set Access Lists I got Error Massage " Accsess Denied" or Some times I got "Server Refusing connections" Anybody I any Idea About this.
« Last Edit: September 18, 2007, 07:49:39 AM by Open Your Hands »
W w W . o P e n g U y s . o R g

GoogleTagged