How do I stop the RabbitMQ server on localhost

前端 未结 3 628
温柔的废话
温柔的废话 2021-01-30 20:46

I installed RabbitMQ server on OS X, and started it on command line. Now, it is not obvious that how I should stop it from running? After I did:

sudo rabbitmq-se         


        
相关标签:
3条回答
  • 2021-01-30 20:58

    It turns out that it is related to permissions. Somehow my rabbitmq server was started with user 'rabbitmq' (which is strange), so that I had to do

    sudo -u rabbitmq rabbitmqctl stop
    
    0 讨论(0)
  • 2021-01-30 21:16

    Use rabbitmqctl stop to stop any node. If you need to specify the node giving you trouble, add the -n rabbit@[hostname] option.

    0 讨论(0)
  • 2021-01-30 21:19

    In my dev environment where I keep it running all the time, I use:

    launchctl unload ~/Library/LaunchAgents/homebrew.mxcl.rabbitmq.plist
    

    and to start it

    launchctl load ~/Library/LaunchAgents/homebrew.mxcl.rabbitmq.plist
    

    Even easier....

    brew services stop rabbitmq
    brew services start rabbitmq
    
    0 讨论(0)
提交回复
热议问题