PROXY SERVER(SQUID) in Linux Operating System

  • Proxy servers are used to share an Internet connection with many clients.
  • A proxy server can be configured as:
    • A simple proxy server - to share the internet connection
    • A caching web server - to store web pages locally to improve performance.
    • A firewall- to control access to the internet.
  • Squid proxy is the most widely used open source proxy.

Requirements for Proxy:

  • Packages
    • squid*.rpm
  • Port numbers
    • 3128(Default)
  • Configuration file
    • /etc/squid/squid.conf
  • Service/Daemon
    • Squid

Configuration of Proxy Server

Step1: to configure Samba server
Check system IP address
#ifconfig eth0
Assign the host name temporarily and permanent.
#hostname proxy.group.com
# vi /etc/sysconfig/network
Edit the hostname
HOSTNAME=proxy.group.com
:wq!
Add the host entries.
#vi /etc/hosts
go to insert mode
192.168.1.253    proxy.group.com    proxy
:wq!
Then logoff & login
Assign DNS ip address
#vi /etc/resolv.conf
nameserver 192.168.1.170#remove all  the enteries except the one.
:wq!

Install packages
#yum install squid* -y
edit the configuration file
#vim /etc/squid/squid.conf
Set the line numbers
:se nu
64 http_port 3128
70Cache_dir ufs /var/spool/squid 100 16 256 (remove # symbol prefix to statement.)

53 acl groupnetwork src 192.168.0.0/24
54 acl block_web url_regex www.yahoo.com
55 http_access deny block_web
56 http_access allow groupnetwork
:wq!
Restart the service
#service squid restart
#chkconfig squid on

Proxy server windows client configuration

#rdesktop 192.168.0.190 -u administrator -p password123 -f

Go to Internet Explorer Select Tools--> Internet Options--> Connections-->Lan Settings and Enable proxy server ip as 192.168.1.253 port no: 3128
Access the websites including blocked site

Proxy server Linux client configuration

 Open browser.
# firefox &
Go to Edit-->Preferences-->Advanced-->Network-->Settings-->Manual Proxy config
Ip 192.168.1.253 port no: 3128.


Comments

Popular posts from this blog

Reasoning-Number Series

Reasoning-Letter Series

Multiply Negative numbers in java