No serviceName defined in either JAAS or Kafka config

Has anyone seen below error?

org.apache.kafka.common.KafkaException: Failed to construct kafka consumer
        at org.apache.kafka.clients.consumer.KafkaConsumer.<init>(KafkaConsumer.java:820)
        at org.apache.kafka.clients.consumer.KafkaConsumer.<init>(KafkaConsumer.java:631)
       at org.apache.kafka.clients.consumer.KafkaConsumer.<init>(KafkaConsumer.java:612)
        at org.apache.kafka.connect.runtime.Worker.buildWorkerTask(Worker.java:536)
        at org.apache.kafka.connect.runtime.Worker.startTask(Worker.java:467)
        at org.apache.kafka.connect.runtime.standalone.StandaloneHerder.createConnectorTasks(StandaloneHerder.java:313)
        at org.apache.kafka.connect.runtime.standalone.StandaloneHerder.updateConnectorTasks(StandaloneHerder.java:339)
        at org.apache.kafka.connect.runtime.standalone.StandaloneHerder.putConnectorConfig(StandaloneHerder.java:216)
        at org.apache.kafka.connect.cli.ConnectStandalone.main(ConnectStandalone.java:115)
Caused by: org.apache.kafka.common.KafkaException: java.lang.IllegalArgumentException: No serviceName defined in either JAAS or Kafka config
        at org.apache.kafka.common.network.SaslChannelBuilder.configure(SaslChannelBuilder.java:158)
        at org.apache.kafka.common.network.ChannelBuilders.create(ChannelBuilders.java:146)
        at org.apache.kafka.common.network.ChannelBuilders.clientChannelBuilder(ChannelBuilders.java:67)
        at org.apache.kafka.clients.ClientUtils.createChannelBuilder(ClientUtils.java:99)
        at org.apache.kafka.clients.consumer.KafkaConsumer.<init>(KafkaConsumer.java:741)
        ... 8 more
Caused by: java.lang.IllegalArgumentException: No serviceName defined in either JAAS or Kafka config
        at org.apache.kafka.common.security.kerberos.KerberosLogin.getServiceName(KerberosLogin.java:301)
        at org.apache.kafka.common.security.kerberos.KerberosLogin.configure(KerberosLogin.java:92)
        at org.apache.kafka.common.security.authenticator.LoginManager.<init>(LoginManager.java:61)
        at org.apache.kafka.common.security.authenticator.LoginManager.acquireLoginManager(LoginManager.java:112)
        at org.apache.kafka.common.network.SaslChannelBuilder.configure(SaslChannelBuilder.java:147)
        ... 12 more
[2021-05-11 19:08:33,221] INFO Created connector mongo-sink (org.apache.kafka.connect.cli.ConnectStandalone:112)

Hi @Natarajan77, can you give a bit more detail please?
Where are you seeing this error? Which component (Kafka Connect?)? How are you deploying it? What configuration are you using?

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.