localepurge command not found

In this troubleshooting guide we learn how to fix localepurge command not found error message

Introduction

When you run more command in linux terminal / console, you get the following error message

localepurge: command not found

or when using sudo you get the following error message

sudo: localepurge: command not found

Solutions to localepurge: command not found

How To Fix localepurge: command not found in Ubuntu / Debian / Kali Linux / Raspbian

In Ubuntu localepurge is provided by localepurge package.

localepurge is:

This package provides a script to recover disk space wasted for unneeded locales, GNOME/KDE localizations and localized man pages. Depending on the installation, it is possible to save hundreds of megabytes of disk space taken up by localization you will most probably never have any use for. It is run automatically upon completion of any APT installation actions.

This tool is a hack which is not integrated with the system’s package management system and therefore is not for the faint of heart. Its interference can provoke strange, but usually harmless, behavior in programs related to apt/dpkg, such as dpkg-repack, reportbug, etc. Responsibility for its usage and possible breakage of the system therefore lies in the system administrator’s hands.

Please do abstain from reporting any such bugs blaming localepurge if you break the system by using it. If you don’t know what you are doing and can’t handle any resulting breakage, you should not install this package.

To fix this problem, we can install more using the command below.

sudo apt-get -y install localepurge

This command might take some time to finish depending on your machine internet connection.

You can also use apt command to install localepurge.

sudo apt -y install localepurge

Or if you have aptitude installed you can use the following command.

sudo aptitude install localepurge

Summary

In this tutorial we learn how to fix localepurge command not found error in Ubuntu / Debian / Kali Linux or Raspbian distribution.