Support Questions

Find answers, ask questions, and share your expertise
Announcements
Celebrating as our community reaches 100,000 members! Thank you!

Create Topic ERROR in HDP2.6.4(Enabled kerberos):NoAuth for /config/topics

avatar
Explorer

Dear experts,I am running HDP 2.6.4 with enabled Kerberos and Ranger.Because the default zookeeper path of Kafka is under the root directory /, in order to facilitate the management of Kafka, the storage path of Kafka was changed to /kafka on the ambari page.

After change,the zookeeper.connect is:

 

 

 

hdp-node1:2181,hdp-node2:2181,hdp-node3:2181/kafka

 

 

 

Now I have a problem. When I create a topic with the following command, the following exception appears

 

 

 

sh kafka-topics.sh --create --zookeeper hdp-node1:2181,hdp-node2:2181,hdp-node3:2181/kafka --replication-factor 1 --partitions 3 --topic test_topic

 

 

 

And the follwing ERROR:

 

 

 

ERROR org.I0Itec.zkclient.exception.ZkException: org.apache.zookeeper.KeeperException$NoAuthException: KeeperErrorCode = NoAuth for /config/topics
	at org.I0Itec.zkclient.exception.ZkException.create(ZkException.java:68)
	at org.I0Itec.zkclient.ZkClient.retryUntilConnected(ZkClient.java:1000)
	at org.I0Itec.zkclient.ZkClient.create(ZkClient.java:527)
	at org.I0Itec.zkclient.ZkClient.createPersistent(ZkClient.java:293)
	at kafka.utils.ZkPath$.createPersistent(ZkUtils.scala:965)
	at kafka.utils.ZkUtils.createParentPath(ZkUtils.scala:437)
	at kafka.utils.ZkUtils.updatePersistentPath(ZkUtils.scala:507)
	at kafka.admin.AdminUtils$.writeEntityConfig(AdminUtils.scala:568)
	at kafka.admin.AdminUtils$.createOrUpdateTopicPartitionAssignmentPathInZK(AdminUtils.scala:453)
	at kafka.admin.AdminUtils$.createTopic(AdminUtils.scala:415)
	at kafka.admin.TopicCommand$.createTopic(TopicCommand.scala:107)
	at kafka.admin.TopicCommand$.main(TopicCommand.scala:60)
	at kafka.admin.TopicCommand.main(TopicCommand.scala)
Caused by: org.apache.zookeeper.KeeperException$NoAuthException: KeeperErrorCode = NoAuth for /config/topics
	at org.apache.zookeeper.KeeperException.create(KeeperException.java:113)
	at org.apache.zookeeper.KeeperException.create(KeeperException.java:51)
	at org.apache.zookeeper.ZooKeeper.create(ZooKeeper.java:783)
	at org.I0Itec.zkclient.ZkConnection.create(ZkConnection.java:99)
	at org.I0Itec.zkclient.ZkClient$3.call(ZkClient.java:530)
	at org.I0Itec.zkclient.ZkClient$3.call(ZkClient.java:527)
	at org.I0Itec.zkclient.ZkClient.retryUntilConnected(ZkClient.java:990)
	... 11 more

 

 

 

 

Please help me to solve this ERROR,I should create topic in kafka normally.

1 REPLY 1

avatar
Explorer

At last,I reinstall kafka and then it works.