Sunday, May 26, 2013

Installing RabbitMQ over Ubuntu/CentOS

This post’s gonna walk you through steps on how to install RabbitMQ on a:
  • Ubuntu machine
  • Centos machine
Installing RabbitMQ on Ubuntu

Step-I: Get the setup from
http://www.rabbitmq.com/install-debian.html                                                                           
Version: rabbitmq-server_3.0.2-1_all.deb

Step-II: Run the .deb file using
sudo dpkg -i rabbitmq-server_3.0.2-1_all.deb                                                                           

Step-III: Start or Stop the rabbitmq server/broker using
/etc/init.d/rabbitmq_server start
/etc/init.d/rabbitmq_server stop                                                                                                

Step-IV: Check the status of the server using
rabbitmqctl status                                                                                                                  

Installing RabbitMQ on CentOS

Step-I: Get the setup from
http://www.rabbitmq.com/install-rpm.html                                                                             
Version: rabbitmq-server-3.0.2-1.noarch.rpm

If the CentOS version on your machine is EL5:(For CentOS versions of the 5 series, Get to know that using the command "lsb_release -a") run the following commands: 
su -c 'rpm -Uvh http://download.fedoraproject.org/pub/epel/5/i386/epel-release-5-4.noarch.rpm'
su -c 'yum install foo'                                                                          

Else if its EL6: (For CentOS versions of the 6 series, Get to know that using the command "lsb_release -a") run the following commands: 
su -c 'rpm -Uvh http://download.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm'
su -c 'yum install foo'

Step-II: Get the Erlang repository using:
sudo wget -O /etc/yum.repos.d/epel-erlang.repo http://repos.fedorapeople.org/repos/peter/erlang/epel-erlang.repo

Step-III: Install Erlang using:
sudo yum install erlang                                                                                                              

Step-IV: You need to import a signing key for RabbitMQ, using the command:
sudo rpm --import http://www.rabbitmq.com/rabbitmq-signing-key-public.asc                                                                 

Step-V: Install the downloaded setup in Step-I using:
sudo yum install rabbitmq-server-3.0.2-1.noarch.rpm                                                                   

Step-VI: Start/Stop rabbitmq server using
sudo /sbin/service rabbitmq-server start
sudo /sbin/service rabbitmq-server stop                                                                                           

Some Extra Notes
  • If you ever feel the need to clear all messages from a rabbitmq queue, run the following commands:
rabbitmqctl stop_app
rabbitmqctl force_reset
/etc/init.d/rabbitmq-server stop
/etc/init.d/rabbitmq-server start                                                                                                  
  • If you need to configure some rabbitmq server parameters off the league, for example "disk_free_limit", create a file called “rabbitmq.config” and place it in “/etc/rabbitmq” for the server to read it at the time of startup. Here’s a sample config file for your ready reference:
 [
    {rabbit, [{disk_free_limit, 1000}]}
  ].                                                                                                                                                        


All the very best !!!

7 comments:

  1. hey jayati,
    First of all,you have a good thing going on with this blog, and you have got some awesome posts !

    I can't help but notice that you have got a lot of posts for installation and configuration,and if that's what interest you,you should look at chef or puppet to make it painless.For instance,chef has a cookbook for rabbit mq :http://community.opscode.com/cookbooks/rabbitmq.

    ReplyDelete
  2. Great post! I am actually getting ready to across this information, It’s very helpful for this blog.Also great with all of the valuable information you have Keep up the good work you are doing well.

    angularjs Training in chennai
    angularjs Training in chennai

    angularjs-Training in tambaram

    angularjs-Training in sholinganallur

    angularjs-Training in velachery

    ReplyDelete
  3. This is a nice post in an interesting line of content.Thanks for sharing this article, great way of bring this topic to discussion.
    python interview questions and answers | python tutorials

    ReplyDelete
  4. Excellant post!!!. The strategy you have posted on this technology helped me to get into the next level and had lot of information in it.
    Devops Training courses
    Devops Training in Bangalore
    Best Devops Training in pune
    Devops interview questions and answers

    ReplyDelete
  5. Read all the information that i've given in above article. It'll give u the whole idea about it.

    Java training in Annanagar | Java training in Chennai

    Java training in Chennai | Java training in Electronic city

    ReplyDelete
  6. I appreciate your efforts because it conveys the message of what you are trying to say. It's a great skill to make even the person who doesn't know about the subject could able to understand the subject . Your blogs are understandable and also elaborately described. I hope to read more and more interesting articles from your blog. All the best.
    Data Science Training in Chennai | Data Science course in anna nagar

    Data Science course in chennai | Data science course in Bangalore

    Data Science course in marathahalli | Data Science course in btm layout

    ReplyDelete