Categories: Ubuntu

How to fix sudo: add-apt-repository: command not found error on Linux Ubuntu





The software applications can be installed on Ubuntu and Debian systems in many ways. The one common way to install applications is through the Personal Package Archive (PPA) Repository. The PPA’s are the external repositories that are created and maintained by developers.

The add-apt-repository command is used in the following way to add a PPA repository:

$ sudo add-apt-repository ppa: name/ppa

The sudo: add-apt-repository: command not found is a common error that we encounter while adding a PPA repository.

Fixing sudo: add-apt-repository: command not found error

This error is simple, and you face it when the specific package which allows you to add the external repositories is not installed on your system. To fix this error, we need to install the software-properties-common package because the add-apt-repository command is included in this package.

Fire up the terminal and complete the below-given steps to install the software-properties-common package.

Step 1: Update the repository

Execute the given-below command to update the system’s repository:

$ sudo apt update

Step 2: Install the software-properties-common package

Next, install the software-properties-common package with the command:

The software-properties-common package will be successfully installed.

Step 3: Add the PPA repository

Now, the add-apt-repository: command not found error is fixed, and you are ready to add any PPA repository. As an example, let’s add the LibreOffice repository and install it:

$ sudo add-apt-repository ppa:libreoffice/ppa

$ sudo apt update

$ sudo apt install libreoffice

Alright! That’s it. The PPA repository is successfully added to the system, and LibreOffice is successfully installed.

Conclusion

The add-apt-repository: command not found is a very common error that you may encounter while adding the external or PPA repository to the Ubuntu, Debian, Linux Mint, and many other Debian based systems. The add-apt-repository command is included in the software-properties-common package, and the error occurs due to the absence of this package. We can fix this error by installing the software-properties-common package.

Ubuntu Server Admin

Recent Posts

Harnessing the potential of 5G with Kubernetes: a cloud-native telco transformation perspective

Telecommunications networks are undergoing a cloud-native revolution. 5G promises ultra-fast connectivity and real-time services, but…

8 hours ago

The rhythm of reliability: inside Canonical’s operational cadence

In software engineering, we often talk about the “iron triangle” of constraints: time, resources, and…

1 day ago

Canonical to distribute AMD ROCm AI/ML and HPC libraries in Ubuntu

Canonical is pleased to announce an expanded collaboration with AMD to package and maintain AMD…

1 day ago

How telco companies can reduce 5G infrastructure costs with modern open source cloud-native technologies

5G continues to transform the telecommunications landscape, enabling massive device density, edge computing, and new…

3 days ago

From cloud to dashboard: experience the future of infotainment development at CES 2026

Every year at CES, we try to go beyond showing technology; we want to give…

6 days ago

Canonical announces Ubuntu Pro for WSL

Ubuntu Pro for WSL provides turnkey security maintenance and enterprise support for Ubuntu 24.04 LTS…

1 week ago