1. Create a new rabbitmq in the /etc/init.d directory [root@localhost init.d]# vi rabbitmq File Contents #!/bin/bash #chkconfig:2345 61 61 export HOME=/opt/data/rabbitmq/ export PATH=$PATH:/usr/local/erlang/bin export PATH=$PATH:/usr/local/src/rabbitmq_server-3.6.15/sbin case "$1" in start) echo "Starting RabbitMQ ..." rabbitmq-server-detached ;; stop) echo "Stopping RabbitMQ ..." rabbitmqctl stop ;; status) echo "Status RabbitMQ ..." rabbitmqctl status ;; restart) echo "Restarting RabbitMQ ..." rabbitmqctl stop rabbitmq-server restart ;; *) echo "Usage: $prog {start|stop|status|restart}" ;; esac exit 0 2. Grant executable permissions to rabbitmq [root@localhost init.d]# chmod 777 rabbitmq 3. Add rabbitmq service to system services [root@localhost init.d]# chkconfig --add rabbitmq 4. Set up auto-start [root@localhost init.d]# chkconfig rabbitmq on 5. Check whether the startup item is set successfully [root@localhost init.d]# chkconfig --list rabbitmq 6. Enable rabbit service [root@localhost init.d]# ./rabbitmq start 7. Test boot and restart [root@localhost init.d]#reboot [root@localhost ~]# ps -elf|grep rabbitmq The above is the full content of this article. I hope it will be helpful for everyone’s study. I also hope that everyone will support 123WORDPRESS.COM. You may also be interested in:
|
<<: Introduction to Sublime Text 2, a web front-end tool
>>: Detailed explanation of the default values of width and height in CSS: auto and %
The GtkTreeView component is an advanced componen...
Table of contents 1. async 2. await: 3. Comprehen...
Restart all stopped Docker containers with one co...
Table of contents Preface Confusing undefined and...
Today I deployed the free-installation version of...
Anyone who has used the Linux system should know ...
Download the zip installation package: Download a...
This article summarizes some common MySQL optimiz...
All of us webmasters know that when optimizing a ...
Install FFmpeg flac eric@ray:~$ sudo apt install ...
Table of contents 01 Container consistency 02 Con...
In this experiment, we configure MySQL standard a...
First: Copy code The code is as follows: <input...
The json data must be returned in html format That...
1. Introduction This article will show you how to...