How To Install apt-cacher-ng on Kali Linux

Hostnbit
In this tutorial we learn how to install apt-cacher-ng on Kali Linux. apt-cacher-ng is caching proxy server for software repositories

Introduction

In this tutorial we learn how to install apt-cacher-ng on Kali Linux.

What is apt-cacher-ng

apt-cacher-ng is:

Apt-Cacher NG is a caching proxy for downloading packages from Debian-style
software repositories (or possibly from other types).

The main principle is that a central machine hosts the proxy for a local
network, and clients configure their APT setup to download through it.
Apt-Cacher NG keeps a copy of all useful data that passes through it, and when
a similar request is made, the cached copy of the data is delivered without
being re-downloaded.

Apt-Cacher NG has been designed from scratch as a replacement for
apt-cacher, but with a focus on maximizing throughput with low system
resource requirements. It can also be used as replacement for apt-proxy and
approx with no need to modify clients’ sources.list files.

There are three methods to install apt-cacher-ng on Kali Linux. We can use apt-get, apt and aptitude. In the following sections we will describe each method. You can choose one of them.

Install apt-cacher-ng Using apt-get

Update apt database with apt-get using the following command.

sudo apt-get update

After updating apt database, We can install apt-cacher-ng using apt-get by running the following command:

sudo apt-get -y install apt-cacher-ng

Install apt-cacher-ng Using apt

Update apt database with apt using the following command.

sudo apt update

After updating apt database, We can install apt-cacher-ng using apt by running the following command:

sudo apt -y install apt-cacher-ng

Install apt-cacher-ng Using aptitude

If you want to follow this method, you might need to install aptitude on Kali Linux first since aptitude is usually not installed by default on Kali Linux. Update apt database with aptitude using the following command.

sudo aptitude update

After updating apt database, We can install apt-cacher-ng using aptitude by running the following command:

sudo aptitude -y install apt-cacher-ng

How To Uninstall apt-cacher-ng on Kali Linux

To uninstall only the apt-cacher-ng package we can use the following command:

sudo apt-get remove apt-cacher-ng

Uninstall apt-cacher-ng And Its Dependencies

To uninstall apt-cacher-ng and its dependencies that are no longer needed by Kali Linux, we can use the command below:

sudo apt-get -y autoremove apt-cacher-ng

Remove apt-cacher-ng Configurations and Data

To remove apt-cacher-ng configuration and data from Kali Linux we can use the following command:

sudo apt-get -y purge apt-cacher-ng

Remove apt-cacher-ng configuration, data, and all of its dependencies

We can use the following command to remove apt-cacher-ng configurations, data and all of its dependencies, we can use the following command:

sudo apt-get -y autoremove --purge apt-cacher-ng

Dependencies

apt-cacher-ng have the following dependencies:

References

Summary

In this tutorial we learn how to install apt-cacher-ng package on Kali Linux using different package management tools: apt, apt-get and aptitude.

Hostnbit

Leave a Comment

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Menu Title
Scroll to Top