Unable to connect to broker library ( Deepstream-test5-app)

I am trying to run the DeepStream Test 5 sample app with local RTSP feed coming from an IP camera. I am getting this error.

deepstream-test5-app -c configs/test5_dec_infer-resnet_tracker_sgie_tiled_display_int8.txt 
** ERROR: <main:1123>: Failed to set pipeline to PAUSED
Quitting
ERROR from sink_sub_bin_sink2: Could not configure supporting library.
Debug info: /dvs/git/dirty/git-master_linux/deepstream/sdk/src/gst-plugins/gst-nvmsgbroker/gstnvmsgbroker.c(332): gst_nvmsgbroker_start (): /GstPipeline:pipeline/GstBin:sink_sub_bin2/GstNvMsgBroker:sink_sub_bin_sink2:
<b>unable to connect to broker library</b>
ERROR from sink_sub_bin_sink2: GStreamer error: state change failed and some element failed to post a proper error message with the reason for the failure.
Debug info: gstbasesink.c(5265): gst_base_sink_change_state (): /GstPipeline:pipeline/GstBin:sink_sub_bin2/GstNvMsgBroker:sink_sub_bin_sink2:
Failed to start
App run failed

Environment Details
Jetson NANO
Deepstream SDK 4.0.1

Relevant Configuration in the

[source0]
enable=1
#Type - 1=CameraV4L2 2=URI 3=MultiURI
type=4
uri=rtsp://admin:XVWWNL@192.168.1.39:554/h264_stream
num-sources=1
gpu-id=0
nvbuf-memory-type=0

[sink0]
enable=1
#Type - 1=FakeSink 2=EglSink 3=File
type=2
sync=0
source-id=0
gpu-id=0
nvbuf-memory-type=0

[sink1]
enable=1
#Type - 1=FakeSink 2=EglSink 3=File 4=UDPSink 5=nvoverlaysink 6=MsgConvBroker
type=6
msg-conv-config=dstest5_msgconv_sample_config.txt
#(0): PAYLOAD_DEEPSTREAM - Deepstream schema payload
#(1): PAYLOAD_DEEPSTREAM_MINIMAL - Deepstream schema payload minimal
#(256): PAYLOAD_RESERVED - Reserved type
#(257): PAYLOAD_CUSTOM   - Custom schema payload
msg-conv-payload-type=0
msg-broker-proto-lib=/opt/nvidia/deepstream/deepstream-4.0/lib/libnvds_kafka_proto.so
msg-broker-conn-str=ec2-11-239-30-175.compute-1.amazonaws.com;9002;DetectionEntry
topic=DetectionEntry

Output of GST Inspect Broker - gst-inspect-1.0 nvmsgbroker

arko@arko-jetson-01:/opt/nvidia/deepstream/deepstream-4.0/sources/libs/kafka_protocol_adaptor$ gst-inspect-1.0 nvmsgbroker
Plugin Details:
  Name                     nvdsgst_msgbroker
  Description              Message broker
  Filename                 /usr/lib/aarch64-linux-gnu/gstreamer-1.0/deepstream/libnvdsgst_msgbroker.so
  Version                  4.0.1
  License                  Proprietary
  Source module            nvmsgbroker
  Binary package           NvMsgBroker
  Origin URL               http://nvidia.com

Kafka Client is installed.

sudo apt install librdkafka-dev
librdkafka-dev is already the newest version (0.11.3-1build1).

Path to msg-broker-proto-lib is verified and correct.

arko@arko-jetson-01:$ ls -l /opt/nvidia/deepstream/deepstream-4.0/lib/libnvds_kafka_proto.so
-rw-r--r-- 1 root root 18496 Sep 11 15:45 /opt/nvidia/deepstream/deepstream-4.0/lib/libnvds_kafka_proto.so

So far, I can conclude that its a problem with the finding of Kafka library. But I have no idea, how to proceed the troubleshooting from this point due to my limited knowledge of Deepstream and Gstreamer.

The configuration looks right. I was using the wrong port number for the broker service connection string

msg-broker-conn-str=ec2-11-239-30-175.compute-1.amazonaws.com;9002;DetectionEntry

should be 9092 instead of 9002.

I am also getting the same error when i run this inside docker.
root@982234f8897a:/opt/nvidia/deepstream/deepstream-5.0/streams/sources/apps/sample_apps/deepstream-test5# deepstream-test5-app -c configs/test5_config_file_src_infer_tlt.txt

(deepstream-test5-app:76): GLib-CRITICAL **: 10:17:51.391: g_strchug: assertion ‘string != NULL’ failed

(deepstream-test5-app:76): GLib-CRITICAL **: 10:17:51.391: g_strchomp: assertion ‘string != NULL’ failed
Warning: ‘input-dims’ parameter has been deprecated. Use ‘infer-dims’ instead.
** ERROR: main:1451: Failed to set pipeline to PAUSED
Quitting
ERROR from sink_sub_bin_sink2: Could not configure supporting library.
Debug info: gstnvmsgbroker.c(388): legacy_gst_nvmsgbroker_start (): /GstPipeline:pipeline/GstBin:sink_sub_bin2/GstNvMsgBroker:sink_sub_bin_sink2:
unable to connect to broker library
ERROR from sink_sub_bin_sink2: GStreamer error: state change failed and some element failed to post a proper error message with the reason for the failure.
Debug info: gstbasesink.c(5265): gst_base_sink_change_state (): /GstPipeline:pipeline/GstBin:sink_sub_bin2/GstNvMsgBroker:sink_sub_bin_sink2:
Failed to start
App run failed

I have installed kafka outside the docker and it’s running properly. Still the above error is coming. Do i need to install kafka inside docker?
Here i am attaching the config file.
test5_config_file_src_infer_tlt.txt (6.6 KB)

hi,did u solve the problem? i also get the problem!

1 Like

I get the problem as well. Have you solved this issue?

1 Like