1.Run the rpm -qa|grep rabbitmq command to check whether RabbitMQ exists on this server.

[root@localhost ~]# rpm -qa|grep rabbitmq
rabbitmq-server-3.8.9-1.el7.noarch

2.If it exists, complete the following steps to uninstall it:

1)Run the cd /usr/lib/netbrain/installer/rabbitmq command to navigate to the rabbitmq directory.

2)Run the ./uninstall.sh command under the rabbitmq directory.

3)Specify whether to remove all RabbitMQ data. To remove data, type y or yes., otherwise, type n or no.

[root@linux3 ~]# cd /usr/lib/netbrain/installer/rabbitmq
[root@linux3 rabbitmq]# ./uninstall.sh
INFO: 2021-09-10 16-25-46.994: Setting AutoUpdate Client path to /usr/share/auclient
INFO: 2021-09-10 16-25-47.002: No AutoUpdate patch has been detected, exiting patch uninstallation...
INFO: 2021-09-10 16-25-47.080: Creating uninstallation log file SUCCEEDED
INFO: 2021-09-10 16-25-47.134: Preprocessing SUCCEEDED
INFO: 2021-09-10 16-25-47.138: Starting to uninstall RabbitMQ
WARNING: Do you want to remove the log/data/config files after uninstalling the RabbitMQ component?
Input [ yes | y ] if you want to remove the log files or [ no | n ] otherwise]: y
...
INFO: 2021-09-10 16-26-08.864: Removed RabbitMQ release info file
INFO: 2021-09-10 16-26-08.875: Removed RabbitMQ uninstall path /usr/lib/netbrain/installer/rabbitmq
INFO: 2021-09-10 16-26-08.880: RabbitMQ has been uninstalled successfully.