rabbitmq refusing to start

后端 未结 8 1502
伪装坚强ぢ
伪装坚强ぢ 2021-01-30 00:33

I have installed rabbitmq on ubuntu and trying to start it using rabbitmq-server start, however, I\'m getting this error:

Activating Ra         


        
相关标签:
8条回答
  • 2021-01-30 00:34

    Have a look what is in the log of the node that you are trying to start. It will be in /var/log/rabbitmq/ It was selinux in my case, rabbit could not bind to its ports.

    0 讨论(0)
  • 2021-01-30 00:35

    Seems like the Mnesia database was corrupted. Had to delete it to get sudo service rabbitmq-server start going again !

    $ sudo rm -rf /var/lib/rabbitmq/mnesia/

    Also make sure that any stray rabbit processes are killed before clearing out

    $ ps auxww | grep rabbit | awk '{print $2}' | sudo xargs kill -9

    0 讨论(0)
  • 2021-01-30 00:35

    My brew version of rabbitmq refused to start (after working fine for years without modification by me) too.

    $ cat /usr/local/etc/rabbitmq/rabbitmq-env.conf
    CONFIG_FILE=/usr/local/etc/rabbitmq/rabbitmq
    NODE_IP_ADDRESS=127.0.0.1
    NODENAME=rabbit@localhost
    RABBITMQ_LOG_BASE=/usr/local/var/log/rabbitmq
    

    I edited out rabbit@ on NODENAME and brew services restart rabbitmq started working again.

    0 讨论(0)
  • 2021-01-30 00:36

    Rabbitmq is set to start automatically after it's installed. I don't think it is configured run with the service command.

    To see the status of rabbitmq

    sudo rabbitmqctl status
    

    To stop the rabbitmq

    sudo rabbitmqctl stop
    

    (Try the status command again to see that it's stopped). To start it again, the recommended method is

    sudo invoke-rc.d rabbitmq-server start
    

    These all work with the vanilla ubuntu install using apt-get

    Still not working?

    If you've tried unsuccessfully to start or restart rabbitmq, check to see how many processes are running.

    ps -ef | grep rabbit
    

    There should be 5 processes running as the user rabbitmq. If you have more, particularly if they're running as other users (such as root, or your own user) you should stop these processes.

    The cleanest way is probably to reboot your machine.

    0 讨论(0)
  • 2021-01-30 00:40

    I had similar problem but these suggestions didn't work for me(restart too). When I run rabbitmq-server command, I get a response like that:

    $/ rabbitmq-server
    
    
    BOOT FAILED
    ===========
    
    Error description:
       {error,{cannot_log_to_file,"/var/log/rabbitmq/rabbit@haber01.log",
                                  {error,eacces}}}
    ....
    

    When I checked permissions of /var/log/rabbitmq/rabbit@haber01.log file, I saw that group has not write permisson for that file. So I gave permission to group with that command:

    /var/log/rabbigmq/$ chmod g+w *
    

    then problem has gone!

    Maybe this answer help someone.

    0 讨论(0)
  • 2021-01-30 00:44

    If you use celery, your queues could reach max size and rabbit won't start because of that. Maybe you wouldn't even able to use rabbitmqctl, so if you can afford to clean the queues, just remove

    /var/lib/rabbitmq/mnesia/rabbit@<host>/queues

    on unix (look for mnesia DB path on your system). Be careful: this will remove everything you have in rabbit, so this is a last solution ever.

    0 讨论(0)
提交回复
热议问题