{"id":1998,"date":"2025-01-21T21:01:01","date_gmt":"2025-08-05T03:07:36","guid":{"rendered":""},"modified":"2025-02-02T00:46:17","modified_gmt":"2025-02-01T23:46:17","slug":"how-to-install-rabbitmq-on-ubuntu-24-04-server","status":"publish","type":"post","link":"https:\/\/netcloud24.com\/knowledgebase\/how-to-install-rabbitmq-on-ubuntu-24-04-server\/","title":{"rendered":"Linux VPS &#038; VPS Windows Setup Guide | NetCloud24 RabbitMQ on Ubuntu 24.04 Server"},"content":{"rendered":"<p>\u00a0<\/p>\n<\/p>\n<header>\n<h1>\u00a0<\/h1>\n<\/header>\n<section>\n<p><strong>RabbitMQ<\/strong> is a widely-used open-source message broker that enables applications to communicate asynchronously by sending messages between producers and consumers. It\u2019s ideal for building scalable, distributed systems. In this guide, we will walk you through how to install RabbitMQ on Ubuntu 24.04 Server, perfect for <strong>VPS servers<\/strong> hosting applications that require reliable messaging systems.<\/p>\n<h2>Step 1: Update Your System<\/h2>\n<p>Before installing RabbitMQ, it&#8217;s important to ensure your server is up to date. Run the following command to update your package list and upgrade any outdated packages:<\/p>\n<pre><code>sudo apt update &amp;&amp; sudo apt upgrade -y<\/code><\/pre>\n<h2>Step 2: Install Erlang<\/h2>\n<p>RabbitMQ relies on Erlang, so the first step is to install the Erlang package. Add the necessary Erlang repository to your server by running the following commands:<\/p>\n<pre><code>\r\nsudo apt install -y curl gnupg apt-transport-https\r\ncurl -fsSL https:\/\/packages.erlang-solutions.com\/ubuntu\/erlang_solutions.asc | sudo apt-key add -\r\necho \"deb https:\/\/packages.erlang-solutions.com\/ubuntu focal contrib\" | sudo tee \/etc\/apt\/sources.list.d\/erlang.list\r\n        <\/code><\/pre>\n<p>Once the repository is added, update your package list and install Erlang:<\/p>\n<pre><code>sudo apt update\r\nsudo apt install erlang -y<\/code><\/pre>\n<h2>Step 3: Install RabbitMQ<\/h2>\n<p>Next, install RabbitMQ by adding its official repository. Run the following commands to add the RabbitMQ repository to your system:<\/p>\n<pre><code>\r\necho \"deb https:\/\/dl.cloudsmith.io\/public\/rabbitmq\/rabbitmq-erlang\/deb\/ubuntu focal main\" | sudo tee \/etc\/apt\/sources.list.d\/rabbitmq.list\r\ncurl -fsSL https:\/\/dl.cloudsmith.io\/public\/rabbitmq\/rabbitmq-erlang\/gpg.83FBA17561E8805E2CF68F50C3D310BA61E928D4.key | sudo apt-key add -\r\n        <\/code><\/pre>\n<p>After adding the repository, update the package list and install RabbitMQ:<\/p>\n<pre><code>sudo apt update\r\nsudo apt install rabbitmq-server -y<\/code><\/pre>\n<h2>Step 4: Start and Enable RabbitMQ<\/h2>\n<p>Once RabbitMQ is installed, start the service and enable it to start automatically on boot:<\/p>\n<pre><code>\r\nsudo systemctl start rabbitmq-server\r\nsudo systemctl enable rabbitmq-server\r\n        <\/code><\/pre>\n<p>To verify that RabbitMQ is running, use the following command:<\/p>\n<pre><code>sudo systemctl status rabbitmq-server<\/code><\/pre>\n<h2>Step 5: Enable the RabbitMQ Management Console<\/h2>\n<p>RabbitMQ comes with a management console that provides a web-based interface for monitoring and managing your RabbitMQ server. To enable it, run the following command:<\/p>\n<pre><code>sudo rabbitmq-plugins enable rabbitmq_management<\/code><\/pre>\n<p>The management interface is now available at <code>http:\/\/your_server_ip:15672<\/code>. By default, RabbitMQ uses the default credentials (<code>guest<\/code>\/<code>guest<\/code>), but you should create a new user for better security.<\/p>\n<h2>Step 6: Create an Administrative User<\/h2>\n<p>To secure your RabbitMQ installation, create a new user with administrative privileges. Replace <code>your_username<\/code> and <code>your_password<\/code> with your desired username and password:<\/p>\n<pre><code>\r\nsudo rabbitmqctl add_user your_username your_password\r\nsudo rabbitmqctl set_user_tags your_username administrator\r\nsudo rabbitmqctl set_permissions -p \/ your_username \".*\" \".*\" \".*\"\r\n        <\/code><\/pre>\n<p>You can now log into the management console with your new administrative credentials at <code>http:\/\/your_server_ip:15672<\/code>.<\/p>\n<h2>Step 7: Configure Firewall (Optional)<\/h2>\n<p>If you are running a firewall on your server, ensure that RabbitMQ&#8217;s default ports (5672 for messaging and 15672 for the management console) are open. Use the following commands to allow RabbitMQ traffic through UFW:<\/p>\n<pre><code>\r\nsudo ufw allow 5672\/tcp\r\nsudo ufw allow 15672\/tcp\r\nsudo ufw reload\r\n        <\/code><\/pre>\n<h2>Step 8: Managing RabbitMQ<\/h2>\n<p>RabbitMQ provides several commands for managing your server. Below are some of the commonly used commands:<\/p>\n<ul>\n<li><code>sudo rabbitmqctl list_users<\/code> \u2013 Lists all users.<\/li>\n<li><code>sudo rabbitmqctl delete_user your_username<\/code> \u2013 Deletes a user.<\/li>\n<li><code>sudo rabbitmqctl stop<\/code> \u2013 Stops RabbitMQ.<\/li>\n<li><code>sudo rabbitmqctl start_app<\/code> \u2013 Starts the RabbitMQ application.<\/li>\n<\/ul>\n<h2>Running RabbitMQ on a VPS Server<\/h2>\n<p>Running RabbitMQ on a <strong>VPS server<\/strong> provides an efficient and scalable solution for message brokering. Whether you&#8217;re handling microservices or distributed applications, RabbitMQ&#8217;s lightweight footprint and reliable messaging architecture make it an ideal choice for VPS-hosted applications. With the management console, you can easily monitor queues, exchanges, and message activity on your server.<\/p>\n<h2>Looking for a Reliable VPS Solution?<\/h2>\n<p>If you&#8217;re looking for a powerful and scalable <strong>VPS server<\/strong> to run RabbitMQ, consider using . With <strong>Windows VPS<\/strong>, you get high-performance VPS hosting that\u2019s ideal for deploying RabbitMQ and other demanding applications.<\/p>\n<footer>\n<p>For more VPS server solutions and guides, visit <a href=\"https:\/\/ie.netcloud24.com\" target=\"_blank\" rel=\"follow\">netcloud24.com<\/a>.<\/p>\n<\/footer>\n<\/section>\n<div class=\"post-author-box\" style=\"border-top:1px solid #ddd;margin-top:20px;padding-top:15px;\">\n<p><strong>Author:<\/strong> \u0141ukasz Bodziony<\/p>\n<p><strong>Website:<\/strong> <a href=\"https:\/\/ca.netcloud24.com\" target=\"_blank\" rel=\"dofollow\">Windows VPS<\/a><\/p>\n<p><em>\u0141ukasz Bodziony is the CEO and founder of <a href=\"https:\/\/netcloud24.com\" target=\"_blank\" rel=\"dofollow\">NETCLOUD24<\/a>, a global VPS hosting brand proudly originating from Poland. With extensive experience in cloud computing, virtualization, and server management, he delivers high-performance <strong>Windows VPS<\/strong> and <strong>Remote Desktop Services (RDS)<\/strong> solutions to clients across Europe, North America, and beyond.<\/em><\/p>\n<p><em>His expertise covers a wide range of technologies, including <strong>Microsoft Azure<\/strong>, <strong>Proxmox VE<\/strong>, <strong>Amazon Web Services (AWS)<\/strong>, and numerous other virtualization and cloud platforms.<\/em><\/p>\n<p><em>Beyond running his hosting business, \u0141ukasz also provides <strong>professional paid server configuration and optimization services<\/strong> for companies and individuals. Outside of work, he is dedicated to caring for his children and building a secure future for them.<\/em><\/p>\n<p><em>If you are interested in working with him or need expert assistance with your hosting, cloud environment, or server setup, feel free to reach out via <a href=\"https:\/\/ca.netcloud24.com\" target=\"_blank\" rel=\"dofollow\">Windows VPS<\/a>.<\/em><\/p>\n<\/p><\/div>\n","protected":false},"excerpt":{"rendered":"<p>\u00a0 \u00a0 RabbitMQ is a widely-used open-source message broker that enables applications to communicate asynchronously by sending messages between producers and consumers. It\u2019s ideal for building scalable, distributed\u2026<\/p>\n","protected":false},"author":1,"featured_media":3421,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_seopress_robots_primary_cat":"","_seopress_titles_title":"","_seopress_titles_desc":"","_seopress_robots_index":"","footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2}},"categories":[],"tags":[14,12,11,23,20,21,22,17,7,8,6,10,18,19,15,24,16,5,13,9],"class_list":["post-1998","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","tag-cheapvps","tag-cloudvps","tag-hostingvps","tag-rds","tag-rdscal","tag-remotedesktop","tag-remotedesktopvps","tag-servervps","tag-ukvps","tag-virtualserver","tag-vpshosting","tag-vpsserver","tag-vpssolutions","tag-vpswindows","tag-vpswithwindows","tag-windowsrds","tag-windowsserver","tag-windowsvps","tag-windowsvpshosting","tag-windowsvpsuk"],"jetpack_publicize_connections":[],"_links":{"self":[{"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/posts\/1998","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/comments?post=1998"}],"version-history":[{"count":0,"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/posts\/1998\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/media\/3421"}],"wp:attachment":[{"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/media?parent=1998"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/categories?post=1998"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/tags?post=1998"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}