• Categories
    Category
  • Categories
    Category
  • News
  • Tutorials
  • Forums
  • Tags
  • Users
Tutorial Comments FAQ Related Articles

How to Install and Configure Squid Proxy in Ubuntu 20.4.1

  • 00:38 Yum install httpd -y
  • 01:24 systemctl start httpd
  • 01:27 systemctl enable httpd
  • 01:37 systemctl status httpd
  • 01:48 yum install php php-zip php-soap php-cli php-common php-gd php-mbstring php-mcrypt php-mysqlnd php-xml
  • 02:20 wget https://opensolution.org/download/home.html?sFile=Quick.Cms_v6.6-en.zip
  • 03:20 mv quickcms /var/www/
  • 03:36 chown -R apache:apache /var/www/quickcms
  • 03:56 chmod -R 755 /var/www/quickcms
  • 04:14 vim /etc/httpd/conf.d/quickcms.conf
  • 06:05 systemctl restart httpd
6394

To Install and configure Squid proxy server in Ubuntu 20.4.1

Introduction:

Squid is a web proxy cache server that provides proxy and cache services for HTTP (HyperText Transport Protocol), FTP (File Transfer Protocol), and other network protocols.

Installation process:

Run lsb_release command to check the installed version of OS as follows.

root@linuxhelp:~#  lsb_release -a
No LSB modules are available.
Distributor ID:	Ubuntu
Description:	Ubuntu 20.04.1 LTS
Release:	20.04
Codename:	focal

Install Squid:

To install Squid enter the mentioned command:

root@linuxhelp:~# apt install squid
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following additional packages will be installed:
  libdbi-perl libecap3 squid-common squid-langpack
Suggested packages:
  libclone-perl libmldbm-perl libnet-daemon-perl libsql-statement-perl
  squidclient squid-cgi squid-purge resolvconf smbclient winbind
The following NEW packages will be installed:
  libdbi-perl libecap3 squid squid-common squid-langpack
0 upgraded, 5 newly installed, 0 to remove and 180 not upgraded.
Need to get 3,666 kB of archives.
After this operation, 15.6 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://in.archive.ubuntu.com/ubuntu focal/main amd64 libecap3 amd64 1.0.1-3.2ubuntu1 [17.4 kB]

After completing the above step, open the squid configuration file by using the following command:

root@linuxhelp:~# vim /etc/squid/squid.conf
#
# INSERT YOUR OWN RULE(S) HERE TO ALLOW ACCESS FROM YOUR CLIENTS
#
include /etc/squid/conf.d/*
acl localnet src 192.168.7.237
acl blocksite dstdomain "/etc/squid/blocksite"
http_access deny blocksite
http_access allow localnet
# Example rule allowing access from your local networks.
# Adapt localnet in the ACL section to list your (internal) IP networks
# from where browsing should be allowed
#http_access allow localnet
http_access allow localhost

# And finally deny all other access to this proxy
http_access allow all

After the configuration is completed. Let open block site file to block the particular website by using the following command.

root@linuxhelp:~# vim /etc/squid/blocksite
facebook.com

Once the above step is completed, restart the squid server by using the below command

root@linuxhelp:~# systemctl restart squid

After completed open the client machine browser and follow the below steps Go to the settings SNAP1 Select Advanced option SNAP2 Open Proxy settings SNAP3 Turn ON proxy server SNAP4 Enter IP address and Port number SNAP5 Facebook is not working SNAP6 Amazon is working SNAP7

With this method the Installation process of SQUID on Ubuntu comes to end.

Tags:
noah
Author: 

Comments ( 0 )

No comments available

Add a comment

Frequently asked questions ( 5 )

Q

How to install the squid server on ubuntu OS?

A

To install squid server on ubuntu OS use # apt install squid.

Q

How to open the squid configuration file?

A

To open the squid configuration file use # vim /etc/squid/squid.conf

Q

How to restart the squid server?

A

To restart the squid server use # systemctl

Q

What is the default port number of the squid server?

A

The default port number of the squid server is 3128

Q

How to check the status of the squid server?

A

To check the status of the squid server use # systemctl status squid.

Related Tutorials in How to Install and Configure Squid Proxy in Ubuntu 20.4.1

Related Tutorials in How to Install and Configure Squid Proxy in Ubuntu 20.4.1

How to install Meld tool in Ubuntu
How to install Meld tool in Ubuntu
Feb 25, 2017
How to install Dconf-Editor on Ubuntu 18.04
How to install Dconf-Editor on Ubuntu 18.04
Jul 14, 2018
How to install and update OpenSSL on Ubuntu 16.04
How to install and update OpenSSL on Ubuntu 16.04
Mar 9, 2017
How to install GLib 2.0 on Ubuntu 17.04
How to install GLib 2.0 on Ubuntu 17.04
May 22, 2017
How to Install Android Emulator on Ubuntu 20.4.1
How to Install Android Emulator on Ubuntu 20.4.1
Jul 13, 2021
How To Install AnyDesk on Ubuntu 16.04
How To Install AnyDesk on Ubuntu 16.04
Apr 4, 2018
How to install Genymotion 2.12.1 on Ubuntu 18.04
How to install Genymotion 2.12.1 on Ubuntu 18.04
Jul 9, 2018
How to limit bandwidth in Squid - Part 4
How to limit bandwidth in Squid - Part 4
Jun 28, 2016

Related Forums in How to Install and Configure Squid Proxy in Ubuntu 20.4.1

Related Forums in How to Install and Configure Squid Proxy in Ubuntu 20.4.1

Ubuntu
matthew class=
Failed to enable unit: Refusing to operate on linked unit file sshd.service
Apr 15, 2019
Ubuntu
mason class=
Passwd: You may not view or modify password information for root On Ubuntu 19.04
May 27, 2019
Ubuntu
isaac class=
/etc/apt/sources.list Permission denied
May 18, 2017
Squid
oliver class=
how to clear squid cache
Feb 7, 2017
Ubuntu
yousuf class=
lsb_release command not working : Debian
Jan 18, 2018
Squid
owen class=
How to change default logformat in squid access log
Sep 1, 2017
ifconfig command
jackbrookes class=
what is the location of the ifconfig program on your machine?
Jan 4, 2018
Ubuntu
mason class=
"E: Package 'php-mcrypt' has no installation candidate" error on Ubuntu 20.4.1
Mar 15, 2021

Related News in How to Install and Configure Squid Proxy in Ubuntu 20.4.1

Related News in How to Install and Configure Squid Proxy in Ubuntu 20.4.1

How To Install Mixxx on Ubuntu 16.04
How To Install Mixxx on Ubuntu 16.04
Oct 11, 2017
Ubuntu 17.04 released with greater expectations
Ubuntu 17.04 released with greater expectations
Apr 15, 2017
Ubuntu Core now available on i.MX6 based TS-4900 thanks to Technologic Systems Inc.
Ubuntu Core now available on i.MX6 based TS-4900 thanks to Technologic Systems Inc.
Mar 1, 2017
Ubuntu 17.10 Artful Aardvark Beta 1 is now here. Download Now
Ubuntu 17.10 Artful Aardvark Beta 1 is now here. Download Now
Sep 2, 2017
Ubuntu Unity is no more: One Linux dream has been axed
Ubuntu Unity is no more: One Linux dream has been axed
Apr 7, 2017
What’s next for Ubuntu Linux Desktop?
What’s next for Ubuntu Linux Desktop?
Apr 11, 2017
Say Hi to Ubuntu's new mascot
Say Hi to Ubuntu's new mascot
Mar 22, 2019
KDE Connect App was removed from Google Play Store and brought back in 24 hours
KDE Connect App was removed from Google Play Store and brought back in 24 hours
Mar 22, 2019
Back To Top!
Rank
User
Points

Top Contributers

userNamenaveelansari
135850

Top Contributers

userNameayanbhatti
92510

Top Contributers

userNamehamzaahmed
32150

Top Contributers

1
userNamelinuxhelp
31040

Top Contributers

userNamemuhammadali
24500
Can you help Isaac ?
How to run windows application in linux

I need to run the windows application in my Linux machine, instead of installing from yum repo or any other repos. How to do that..??

Networking
  • Routing
  • trunk
  • Netmask
  • Packet Capture
  • domain
  • HTTP Proxy
Server Setup
  • NFS
  • KVM
  • Memory
  • Sendmail
  • WebDAV
  • LXC
Shell Commands
  • Cloud commander
  • Command line archive tools
  • last command
  • Shell
  • terminal
  • Throttle
Desktop Application
  • Linux app
  • Pithos
  • Retrospect
  • Scribe
  • TortoiseHg
  • 4Images
Monitoring Tool
  • Monit
  • Apache Server Monitoring
  • EtherApe 
  • Arpwatch Tool
  • Auditd
  • Barman
Web Application
  • Nutch
  • Amazon VPC
  • FarmWarDeployer
  • Rukovoditel
  • Mirror site
  • Chef
Contact Us | Terms of Use| Privacy Policy| Disclaimer
© 2025 LinuxHelp.com All rights reserved. Linux™ is the registered trademark of Linus Torvalds. This site is not affiliated with linus torvalds in any way.