docker安装rabbitmq延时插件rabbitmq_delayed_message_exchange
1、先去下载插件,我的RabbitMq版本是3.7.7 但是我下载的插件版本是3.8.0,看网上有人说插件是可以兼容的。
2、下载好之后将插件上传到服务器。
随后将插件拷贝到mq容器当中,运行即可。
[root@node1 home]# docker cp rabbitmq_delayed_message_exchange-3.8.0.ez rabbitmq:/plugins [root@node1 home]# docker exec -it rabbitmq bash root@myRabbit:/# cd plugins root@myRabbit:/plugins# ls README rabbitmq_amqp1_0-3.7.7.ez rabbitmq_federation_management-3.7.7.ez rabbitmq_random_exchange-3.7.7.ez rabbitmq_web_mqtt-3.7.7.ez amqp10_client-3.7.7.ez rabbitmq_auth_backend_cache-3.7.7.ez rabbitmq_jms_topic_exchange-3.7.7.ez rabbitmq_recent_history_exchange-3.7.7.ez rabbitmq_web_mqtt_examples-3.7.7.ez amqp10_common-3.7.7.ez rabbitmq_auth_backend_http-3.7.7.ez rabbitmq_management-3.7.7.ez rabbitmq_sharding-3.7.7.ez rabbitmq_web_stomp-3.7.7.ez amqp_client-3.7.7.ez rabbitmq_auth_backend_ldap-3.7.7.ez rabbitmq_management_agent-3.7.7.ez rabbitmq_shovel-3.7.7.ez rabbitmq_web_stomp_examples-3.7.7.ez cowboy-2.2.2.ez rabbitmq_auth_mechanism_ssl-3.7.7.ez rabbitmq_mqtt-3.7.7.ez rabbitmq_shovel_management-3.7.7.ez ranch-1.5.0.ez cowlib-2.1.0.ez rabbitmq_aws-3.7.7.ez rabbitmq_peer_discovery_aws-3.7.7.ez rabbitmq_stomp-3.7.7.ez ranch_proxy_protocol-1.5.0.ez goldrush-0.1.9.ez rabbitmq_consistent_hash_exchange-3.7.7.ez rabbitmq_peer_discovery_common-3.7.7.ez rabbitmq_top-3.7.7.ez recon-2.3.2.ez jsx-2.8.2.ez rabbitmq_delayed_message_exchange-3.8.0.ez rabbitmq_peer_discovery_consul-3.7.7.ez rabbitmq_tracing-3.7.7.ez syslog-3.4.2.ez lager-3.6.3.ez rabbitmq_event_exchange-3.7.7.ez rabbitmq_peer_discovery_etcd-3.7.7.ez rabbitmq_trust_store-3.7.7.ez rabbit_common-3.7.7.ez rabbitmq_federation-3.7.7.ez rabbitmq_peer_discovery_k8s-3.7.7.ez rabbitmq_web_dispatch-3.7.7.ez root@myRabbit:/plugins# rabbitmq-plugins enable rabbitmq_delayed_message_exchange-3.8.0.ez Error: {:plugins_not_found, [:"rabbitmq_delayed_message_exchange-3.8.0.ez"]} root@myRabbit:/plugins# chmod 777 rabbitmq_delayed_message_exchange-3.8.0.ez root@myRabbit:/plugins# rabbitmq-plugins enable rabbitmq_delayed_message_exchange-3.8.0.ez Error: {:plugins_not_found, [:"rabbitmq_delayed_message_exchange-3.8.0.ez"]} root@myRabbit:/plugins# rabbitmq-plugins enable rabbitmq_delayed_message_exchange The following plugins have been configured: rabbitmq_delayed_message_exchange rabbitmq_management rabbitmq_management_agent rabbitmq_web_dispatch Applying plugin configuration to rabbit@myRabbit... The following plugins have been enabled: rabbitmq_delayed_message_exchange started 1 plugins. root@myRabbit:/plugins#
这里我启动的时候报了两次错误,第一次给插件文件赋予权限不行,第二次启动插件的时候不要带版本号就可以启动了。
启动好插件之后,到web页面可以看见。