Not able to add Rabbitmq plugin - rabbitmq

I was following this http://www.rabbitmq.com/plugin-development.html link to build rabbitmq plugin https://github.com/rabbitmq/rabbitmq-web-mqtt
after building i ONLY copied rabbitmq_mqtt.ez to /usr/lib/rabbitmq/lib/rabbitmq_server-3.6.2/plugins
running sudo rabbitmq-plugins enable rabbitmq_web_mqtt
shows :
The following plugins have been enabled:
cowlib
cowboy
rabbitmq_web_mqtt
Applying plugin configuration to rabbit#manish-Lenovo-G510... failed.
Error: {could_not_start,rabbitmq_web_mqtt,
{undef,
[{lager_config,get,
[{rabbit_log_lager_event,loglevel},{0,[]}],
[]},
{rabbit_web_mqtt_app,mqtt_init,0,
[{file,"src/rabbit_web_mqtt_app.erl"},{line,69}]},
{rabbit_web_mqtt_app,start,2,
[{file,"src/rabbit_web_mqtt_app.erl"},{line,31}]},
{application_master,start_it_old,4,
[{file,"application_master.erl"},{line,269}]}]}}
Running sudo rabbitmq-plugins list
Configured: E = explicitly enabled; e = implicitly enabled
| Status: * = running on rabbit#manish-Lenovo-G510
|/
[e*] amqp_client 3.6.2
[e ] cowboy 1.0.3
[e ] cowlib 1.0.1
[e*] mochiweb 2.13.1
[ ] rabbitmq_amqp1_0 3.6.2
[ ] rabbitmq_auth_backend_ldap 3.6.2
[ ] rabbitmq_auth_mechanism_ssl 3.6.2
[ ] rabbitmq_consistent_hash_exchange 3.6.2
[ ] rabbitmq_event_exchange 3.6.2
[ ] rabbitmq_federation 3.6.2
[ ] rabbitmq_federation_management 3.6.2
[E*] rabbitmq_management 3.6.2
[e*] rabbitmq_management_agent 3.6.2
[ ] rabbitmq_management_visualiser 3.6.2
[E*] rabbitmq_mqtt 3.6.2
[ ] rabbitmq_recent_history_exchange 1.2.1
[ ] rabbitmq_sharding 0.1.0
[ ] rabbitmq_shovel 3.6.2
[ ] rabbitmq_shovel_management 3.6.2
[ ] rabbitmq_stomp 3.6.2
[ ] rabbitmq_tracing 3.6.2
[e*] rabbitmq_web_dispatch 3.6.2
[E ] rabbitmq_web_mqtt
[ ] rabbitmq_web_stomp 3.6.2
[ ] rabbitmq_web_stomp_examples 3.6.2
[ ] sockjs 0.3.4
[e*] webmachine 1.10.3
I am not able to connect using paho JS client. So what is causing the issue? I tried port 1888, 8083,8883,15675

Applying plugin configuration to rabbit#manish-Lenovo-G510... failed.
Error: {could_not_start,rabbitmq_web_mqtt,
{undef,
[{lager_config,get,
Lager is only in the version 3.7.0, most likely you built the master branch.
To build the plugin version 3.6.2 you should:
git clone https://github.com/rabbitmq/rabbitmq-public-umbrella.git .
make up BRANCH=rabbitmq_v3_6_2
cd deps/rabbitmq_web_mqtt
make dist
EDIT
you have to disable and remove the old .ez file, after copied the new one, you have to enable the plugin.
just tried and it works correctly, see the test:

Related

PYTHONPATH issue on google colab

From different forum and tutorial it seem that the command
!python object_detection/builders/model_builder_test.py supposed to give an output like:
Running tests under Python 3.6.9: /usr/bin/python3
[ RUN ] ModelBuilderTest.test_create_experimental_model
[ OK ] ModelBuilderTest.test_create_experimental_model
[ RUN ] ModelBuilderTest.test_create_faster_rcnn_model_from_config_with_example_miner
[ OK ] ModelBuilderTest.test_create_faster_rcnn_model_from_config_with_example_miner
[ RUN ] ModelBuilderTest.test_create_faster_rcnn_models_from_config_faster_rcnn_with_matmul
[ OK ] ModelBuilderTest.test_create_faster_rcnn_models_from_config_faster_rcnn_with_matmul
[ RUN ] ModelBuilderTest.test_create_faster_rcnn_models_from_config_faster_rcnn_without_matmul
[ OK ] ModelBuilderTest.test_create_faster_rcnn_models_from_config_faster_rcnn_without_matmul
[ RUN ] ModelBuilderTest.test_create_faster_rcnn_models_from_config_mask_rcnn_with_matmul
[ OK ] ModelBuilderTest.test_create_faster_rcnn_models_from_config_mask_rcnn_with_matmul
[ RUN ] ModelBuilderTest.test_create_faster_rcnn_models_from_config_mask_rcnn_without_matmul
[ OK ] ModelBuilderTest.test_create_faster_rcnn_models_from_config_mask_rcnn_without_matmul
[ RUN ] ModelBuilderTest.test_create_rfcn_model_from_config
[ OK ] ModelBuilderTest.test_create_rfcn_model_from_config
[ RUN ] ModelBuilderTest.test_create_ssd_fpn_model_from_config
[ OK ] ModelBuilderTest.test_create_ssd_fpn_model_from_config
[ RUN ] ModelBuilderTest.test_create_ssd_models_from_config
[ OK ] ModelBuilderTest.test_create_ssd_models_from_config
[ RUN ] ModelBuilderTest.test_invalid_faster_rcnn_batchnorm_update
[ OK ] ModelBuilderTest.test_invalid_faster_rcnn_batchnorm_update
[ RUN ] ModelBuilderTest.test_invalid_first_stage_nms_iou_threshold
[ OK ] ModelBuilderTest.test_invalid_first_stage_nms_iou_threshold
[ RUN ] ModelBuilderTest.test_invalid_model_config_proto
[ OK ] ModelBuilderTest.test_invalid_model_config_proto
[ RUN ] ModelBuilderTest.test_invalid_second_stage_batch_size
[ OK ] ModelBuilderTest.test_invalid_second_stage_batch_size
[ RUN ] ModelBuilderTest.test_session
[ SKIPPED ] ModelBuilderTest.test_session
[ RUN ] ModelBuilderTest.test_unknown_faster_rcnn_feature_extractor
[ OK ] ModelBuilderTest.test_unknown_faster_rcnn_feature_extractor
[ RUN ] ModelBuilderTest.test_unknown_meta_architecture
[ OK ] ModelBuilderTest.test_unknown_meta_architecture
[ RUN ] ModelBuilderTest.test_unknown_ssd_feature_extractor
[ OK ] ModelBuilderTest.test_unknown_ssd_feature_extractor
----------------------------------------------------------------------
Ran 17 tests in 0.149s
But in my case it is not throwing any out put. Is it normal?
Here are my whole codes and output:
%cd /content
!git clone --quiet https://github.com/tensorflow/models.git
!apt-get install -qq protobuf-compiler python-pil python-lxml python-tk
!pip install -q Cython contextlib2 pillow lxml matplotlib
!pip install -q pycocotools
%cd /content/models/research
!protoc object_detection/protos/*.proto --python_out=.
import os
os.environ['PYTHONPATH'] += ':/content/models/research/:/content/models/research/slim/'
!python object_detection/builders/model_builder_test.py
/content
fatal: destination path 'models' already exists and is not an empty directory.
/content/models/research

Insufficient Security with RabbitMQ 3.7.15 and Erlang 22.0.1 / 22.0.2 on centOS 7.6

Observing an Insufficient Security error after upgrading RabbitMQ server to 3.7.15 with Erlang 22.0.1 / 22.0.2 on centOS 7.6.
Initial State of system where SSL was found to be working:
CentOS Linux release - 7.5
RMQ - 3.7.7-1.el7
Erlang - 20.3.8.2-1.el7.x86_64
SSL was found to be working even when CentOS was upgraded to 7.6 and RMQ to 3.7.15. Checked after RMQ restart.
However when Erlang was upgraded to erlang-22.0.2-1.el7.x86_64.rpm, SSL stopped working. (After RMQ restart)
RabbitMQ config:
[
{rabbitmq_management,
[{listener, [{port, 15671},
{ssl, true},
{ssl_opts, [{cacertfile, "<path>/cacert.pem"},
{certfile, "<path>/cert.pem"},
{keyfile, "<path>/key.pem"}]}
]}
]},
{rabbit, [
{log_levels, [{connection,info}]},
{tcp_listeners, []},
{ssl_listeners, [5671]},
{ssl_options, [{cacertfile,"<path>/all_cacerts.pem"},
{certfile,"<path>/cert.pem"},
{keyfile,"<path>/key.pem"},
{depth, 5},
{verify,verify_peer},
{fail_if_no_peer_cert,false}]},
{auth_mechanisms, ['PLAIN','AMQPLAIN','EXTERNAL']},
{loopback_users, []},
{ssl_cert_login_from, common_name}
]}
].
RabbitMQ enabled pluggins:
[rabbitmq_auth_mechanism_ssl,rabbitmq_management,rabbitmq_shovel,rabbitmq_shovel_management].
Please help.
Edit 1:
Updated the rabbitmq.config in this manner. Cert based auth is working now.
[
{rabbitmq_management,
[{listener, [{port, 15671},
{ssl, true},
{ssl_opts, [{cacertfile, "<path>/cacert.pem"},
{certfile, "<path>/cert.pem"},
{keyfile, "<path>/key.pem"}]},
{ssl, [{versions, ['tlsv1.3', 'tlsv1.2', 'tlsv1.1', 'tlsv1', 'sslv3']},
{ciphers,
[{ecdhe_ecdsa,aes_256_gcm,aead,sha384}, {...}]}
]}
]},
{ssl, [{versions, ['tlsv1.3', 'tlsv1.2', 'tlsv1.1', 'tlsv1', 'sslv3']},
{rabbit, [
{log_levels, [{connection,info}]},
{tcp_listeners, [5672]},
{ssl_listeners, [5671]},
{ssl_options, [{cacertfile,"<path>/all_cacerts.pem"},
{certfile,"<path>/cert.pem"},
{keyfile,"<path>/key.pem"},
{ssl, [{versions, ['tlsv1.3', 'tlsv1.2', 'tlsv1.1', 'tlsv1', 'sslv3']},
{ciphers,
[{ecdhe_ecdsa,aes_256_gcm,aead,sha384}, {...}]},
{depth, 5},
{verify,verify_peer},
{fail_if_no_peer_cert,false}]},
{auth_mechanisms, ['PLAIN','AMQPLAIN','EXTERNAL']},
{loopback_users, []},
{ssl_cert_login_from, common_name}
]}
].
However, shovels with amqps with port 5671 still error out.
[error] <0.7391.6> Shovel 'ShovelTest' failed to connect (URI: amqps://<ip>:5671/<blah>): {tls_alert,{insufficient_security,"received SERVER ALERT: Fatal - Insufficient Security"}}
Shovels work fine with ampq with port 5672 though.
Please help.

Rabbitmq management plugins - RMQ 3.6.5

I am having hard time here in enabling rmq management console on company laptop. I dont have admin rights to run cmd as admin here.
I am trying to enable console and see following output after that when I restart rabbit mq service and try to access console using http://localhost:15672, I am not able to access. I have also pasted output of list command for plugins.
(I am able to connect to broker via spring application though but cant access this console to view queues.)
C:\Program Files\RabbitMQ Server\rabbitmq_server-3.6.5\sbin>rabbitmq-plugins enable rabbitmq_management
The following plugins have been enabled:
mochiweb
webmachine
rabbitmq_web_dispatch
amqp_client
rabbitmq_management_agent
rabbitmq_management
Applying plugin configuration to rabbit#PCNAME... failed.
* Could not contact node rabbit#PCNAME.
Changes will take effect at broker restart.
* Options: --online - fail if broker cannot be contacted.
--offline - do not try to contact broker.
C:\Program Files\RabbitMQ Server\rabbitmq_server-3.6.5\sbin>rabbitmq-plugins list
Configured: E = explicitly enabled; e = implicitly enabled
| Status: [failed to contact rabbit#PCNAME - status not shown]
|/
[e ] amqp_client 3.6.5
[ ] cowboy 1.0.3
[ ] cowlib 1.0.1
[e ] mochiweb 2.13.1
[ ] rabbitmq_amqp1_0 3.6.5
[ ] rabbitmq_auth_backend_ldap 3.6.5
[ ] rabbitmq_auth_mechanism_ssl 3.6.5
[ ] rabbitmq_consistent_hash_exchange 3.6.5
[ ] rabbitmq_event_exchange 3.6.5
[ ] rabbitmq_federation 3.6.5
[ ] rabbitmq_federation_management 3.6.5
[ ] rabbitmq_jms_topic_exchange 3.6.5
[E ] rabbitmq_management 3.6.5
[e ] rabbitmq_management_agent 3.6.5
[ ] rabbitmq_management_visualiser 3.6.5
[ ] rabbitmq_mqtt 3.6.5
[ ] rabbitmq_recent_history_exchange 1.2.1
[ ] rabbitmq_sharding 0.1.0
[ ] rabbitmq_shovel 3.6.5
[ ] rabbitmq_shovel_management 3.6.5
[ ] rabbitmq_stomp 3.6.5
[ ] rabbitmq_top 3.6.5
[ ] rabbitmq_tracing 3.6.5
[ ] rabbitmq_trust_store 3.6.5
[e ] rabbitmq_web_dispatch 3.6.5
[ ] rabbitmq_web_stomp 3.6.5
[ ] rabbitmq_web_stomp_examples 3.6.5
[ ] sockjs 0.3.4
[e ] webmachine 1.10.3

Can't enable plugin in rabbitmq 3.7.3

I have a web application that receives location data via web sockets. I have installed rabbitmq on my mac via homebrew to run the web sockets locally. I am trying to enable rabbitmq_web_stomp but I get this error :
`
rabbitmq-plugins enable rabbitmq_web_stomp
Error:
{:plugins_not_found, [:rabbitmq_management_visualiser]
And when I run rabbitmq-plugins list
WARNING - plugins currently enabled but missing: rabbitmq_management_visualiser
Configured: E = explicitly enabled; e = implicitly enabled
| Status: * = running on rabbit#localhost
|/
[E*] rabbitmq_amqp1_0 3.7.3
[ ] rabbitmq_auth_backend_cache 3.7.3
[ ] rabbitmq_auth_backend_http 3.7.3
[ ] rabbitmq_auth_backend_ldap 3.7.3
[ ] rabbitmq_auth_mechanism_ssl 3.7.3
[ ] rabbitmq_consistent_hash_exchange 3.7.3
[ ] rabbitmq_event_exchange 3.7.3
[ ] rabbitmq_federation 3.7.3
[ ] rabbitmq_federation_management 3.7.3
[ ] rabbitmq_jms_topic_exchange 3.7.3
[E*] rabbitmq_management 3.7.3
[e*] rabbitmq_management_agent 3.7.3
[E*] rabbitmq_mqtt 3.7.3
[ ] rabbitmq_peer_discovery_aws 3.7.3
[ ] rabbitmq_peer_discovery_common 3.7.3
[ ] rabbitmq_peer_discovery_consul 3.7.3
[ ] rabbitmq_peer_discovery_etcd 3.7.3
[ ] rabbitmq_peer_discovery_k8s 3.7.3
[ ] rabbitmq_random_exchange 3.7.3
[ ] rabbitmq_recent_history_exchange 3.7.3
[ ] rabbitmq_sharding 3.7.3
[ ] rabbitmq_shovel 3.7.3
[ ] rabbitmq_shovel_management 3.7.3
[E*] rabbitmq_stomp 3.7.3
[ ] rabbitmq_top 3.7.3
[ ] rabbitmq_tracing 3.7.3
[ ] rabbitmq_trust_store 3.7.3
[e*] rabbitmq_web_dispatch 3.7.3
[ ] rabbitmq_web_mqtt 3.7.3
[ ] rabbitmq_web_mqtt_examples 3.7.3
[ ] rabbitmq_web_stomp 3.7.3
[ ] rabbitmq_web_stomp_examples 3.7.3
But when look at docs https://www.rabbitmq.com/plugins.html
It says rabbitmq_management_visualiser is discontinued and no longer maintained.
How do I fix this?
You should remove rabbitmq_management_visualiser from list of enabled plugins in /usr/local/etc/rabbitmq/enabled_plugins
Im my case i had an azure container and i discovered plugins were installed under /opt/rabbitmq/plugins instead of /usr/lib/rabbitmq/plugins according with the official guide:
https://www.rabbitmq.com/prometheus.html
I changed the plugins path in the script and i installed the plugin.

Rabbitmqctl command throws error

I am trying to create a 3 node cluster on RabbitMQ. I have the first node up and running. When I issue join cluster command from node 2, it is throwing an error that node is down.
rabbitmqctl join_cluster rabbit#hostname02
I am getting the following error:
Status of node rabbit#hostname02 ...
Error: unable to connect to node rabbit#hostname02: nodedown
DIAGNOSTICS
===========
attempted to contact: [rabbit#hostname02]
rabbit#hostname02:
* connected to epmd (port 4369) on hostname02
* epmd reports: node 'rabbit' not running at all
no other nodes on hostname02
* suggestion: start the node
current node details:
- node name: 'rabbitmq-cli-30#hostname02'
- home dir: /var/lib/rabbitmq
- cookie hash: bygafwoj/ISgb3yKej1pEg==
This is my config file.
[
{rabbit, [
{cluster_nodes, {[rabbit#hostname01, rabbitmq#hostname02, rabbit#hostname03], disc}},
{cluster_partition_handling, ignore},
{tcp_listen_options,
[binary,
{packet, raw},
{reuseaddr, true},
{backlog, 128},
{nodelay, true},
{exit_on_close, false}]
},
{default_user, <<"guest">>},
{default_pass, <<"guest">>},
{log_levels, [{autocluster, debug}, {connection, info}]}
]},
{kernel, [
]},
{rabbitmq_management, [
{listener, [
{port, 15672}
]}
]}
].
% EOF
I have updated the /etc/hosts file with the details of all 3 nodes on all the 3 servers. I am not sure where I am getting this wrong.