RabbitMQ is a powerful message broker used to facilitate communication between applications. Follow this guide to install RabbitMQ on Ubuntu 24.
Step 1: Update System Packages
Start by updating your system’s package list to ensure you’re installing the latest versions:
sudo apt update && sudo apt upgrade -y
Step 2: Install Required Dependencies
Install Erlang, a dependency of RabbitMQ, by running:
sudo apt install -y erlang
Step 3: Add RabbitMQ Repository
Enable the official RabbitMQ repository for Ubuntu 24:
echo "deb https://dl.bintray.com/rabbitmq-erlang/debian focal erlang" | sudo tee /etc/apt/sources.list.d/rabbitmq.list
Import the repository’s signing key:
wget -O- https://keys.openpgp.org/vks/v1/by-fingerprint/6026DFCA
sudo apt-key add -
Step 4: Install RabbitMQ
After adding the repository, install RabbitMQ using:
sudo apt update
sudo apt install -y rabbitmq-server
Step 5: Start and Enable RabbitMQ
Start the RabbitMQ service and ensure it starts on boot:
sudo systemctl start rabbitmq-server
sudo systemctl enable rabbitmq-server
Step 6: Verify Installation
Check RabbitMQ’s status to confirm it is running:
sudo systemctl status rabbitmq-server
Step 7: Enable RabbitMQ Management Dashboard
Enable the RabbitMQ management plugin for a web-based interface:
sudo rabbitmq-plugins enable rabbitmq_management
Access the dashboard by visiting http://localhost:15672. Use the default credentials: username guest and password guest.
Conclusion
You have successfully installed RabbitMQ on Ubuntu 24. Configure RabbitMQ as needed to meet your application requirements.