amqp-declare-queue command not found

In this troubleshooting guide we learn how to fix amqp-declare-queue command not found error message

Introduction

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

amqp-declare-queue: command not found

or when using sudo you get the following error message

sudo: amqp-declare-queue: command not found

Solutions to amqp-declare-queue: command not found

How To Fix amqp-declare-queue: command not found in Ubuntu / Debian / Kali Linux / Raspbian

In Ubuntu amqp-declare-queue is provided by amqp-tools package.

amqp-tools is:

RabbitMQ provides robust messaging for applications. It is easy to use, fit for purpose at cloud scale and supported on all major operating systems and developer platforms. librabbitmq is a C-language AMQP client library for use with AMQP servers such as RabbitMQ speaking protocol versions 0-9-1.

This package includes command line utilities.

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

sudo apt-get -y install amqp-tools

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

You can also use apt command to install amqp-tools.

sudo apt -y install amqp-tools

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

sudo aptitude install amqp-tools

Summary

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