2

I am getting the ERROR Failed to initialize SASL authentication: SASL handshake failed (start (-4)): SASL(-4): no mechanism available: No worthy mechs found when trying to use the Message Hub Bluemix service with node-rdkafka

Why would this be happening?

ValerieLampkin
  • 2,570
  • 9
  • 27

1 Answers1

2

This error indicates that librdkafka (the library node-rdkafka wraps) has not been compiled with SASL support.

Please ensure you have the required dependencies installed on your system and reinstall node-rdkafka via npm

For Linux:

libsasl2-dev
libsasl2-modules

For macOS and more details, see our documentation about librdkafka: https://github.com/ibm-messaging/message-hub-samples/blob/master/docs/librdkafka.md

Mickael Maison
  • 18,458
  • 7
  • 48
  • 49
  • 2
    Almost. It means librdkafka was compiled with SASL support but the required cyrus-sasl/libsasl2 runtime library modules for GSSAPI/Kerberos or PLAIN are not installed. Simply installing libsasl2-modules (name varies between distributions) and restarting the client should work. – Edenhill Feb 03 '17 at 15:16