mergerepo_c command not found

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

Introduction

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

mergerepo_c: command not found

or when using sudo you get the following error message

sudo: mergerepo_c: command not found

Solutions to mergerepo_c: command not found

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

In Ubuntu mergerepo_c is provided by createrepo-c package.

createrepo-c is:

The createrepo_c tool generates the repodata directory and XML metadata that makes up a repository of RPM packages. This repository format is supported by apt-rpm, red-carpet(zen), smartpm, up2date, yast, and yum.

This package is similar to the apt-ftparchive or reprepro commands, but for working with RPM repositories.

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

sudo apt-get -y install createrepo-c

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

You can also use apt command to install createrepo-c.

sudo apt -y install createrepo-c

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

sudo aptitude install createrepo-c

Summary

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