[ https://issues.apache.org/jira/browse/KAFKA-6107?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Manikumar resolved KAFKA-6107. ------------------------------ Resolution: Fixed Fix Version/s: 1.1.0 This was fixed in KafkaZkClient changes work. > SCRAM user add appears to fail if Kafka has never been started > -------------------------------------------------------------- > > Key: KAFKA-6107 > URL: https://issues.apache.org/jira/browse/KAFKA-6107 > Project: Kafka > Issue Type: Bug > Components: tools, zkclient > Affects Versions: 0.11.0.0 > Reporter: Dustin Cote > Priority: Minor > Fix For: 1.1.0 > > > When trying to add a SCRAM user in ZooKeeper without having ever starting > Kafka, the kafka-configs tool does not handle it well. This is a common use > case because starting a new cluster where you want SCRAM for inter broker > communication would generally result in seeing this problem. Today, the > workaround is to start Kafka, add the user, then restart Kafka. Here's how to > reproduce: > 1) Start ZooKeeper > 2) Run > {code} > bin/kafka-configs --zookeeper localhost:2181 --alter --add-config > 'SCRAM-SHA-256=[iterations=8192,password=broker_pwd],SCRAM-SHA-512=[password=broker_pwd]' > --entity-type users --entity-name broker > {code} > This will result in: > {code} > bin/kafka-configs --zookeeper localhost:2181 --alter --add-config > 'SCRAM-SHA-256=[iterations=8192,password=broker_pwd],SCRAM-SHA-512=[password=broker_pwd]' > --entity-type users --entity-name broker > Error while executing config command > org.apache.zookeeper.KeeperException$NoNodeException: KeeperErrorCode = > NoNode for /config/changes/config_change_ > org.I0Itec.zkclient.exception.ZkNoNodeException: > org.apache.zookeeper.KeeperException$NoNodeException: KeeperErrorCode = > NoNode for /config/changes/config_change_ > at org.I0Itec.zkclient.exception.ZkException.create(ZkException.java:47) > at org.I0Itec.zkclient.ZkClient.retryUntilConnected(ZkClient.java:1001) > at org.I0Itec.zkclient.ZkClient.create(ZkClient.java:528) > at > org.I0Itec.zkclient.ZkClient.createPersistentSequential(ZkClient.java:444) > at kafka.utils.ZkPath.createPersistentSequential(ZkUtils.scala:1045) > at kafka.utils.ZkUtils.createSequentialPersistentPath(ZkUtils.scala:527) > at > kafka.admin.AdminUtils$.kafka$admin$AdminUtils$$changeEntityConfig(AdminUtils.scala:600) > at > kafka.admin.AdminUtils$.changeUserOrUserClientIdConfig(AdminUtils.scala:551) > at kafka.admin.AdminUtilities$class.changeConfigs(AdminUtils.scala:63) > at kafka.admin.AdminUtils$.changeConfigs(AdminUtils.scala:72) > at kafka.admin.ConfigCommand$.alterConfig(ConfigCommand.scala:101) > at kafka.admin.ConfigCommand$.main(ConfigCommand.scala:68) > at kafka.admin.ConfigCommand.main(ConfigCommand.scala) > Caused by: org.apache.zookeeper.KeeperException$NoNodeException: > KeeperErrorCode = NoNode for /config/changes/config_change_ > at org.apache.zookeeper.KeeperException.create(KeeperException.java:111) > 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:100) > at org.I0Itec.zkclient.ZkClient$3.call(ZkClient.java:531) > at org.I0Itec.zkclient.ZkClient$3.call(ZkClient.java:528) > at org.I0Itec.zkclient.ZkClient.retryUntilConnected(ZkClient.java:991) > ... 11 more > {code} > The command doesn't appear to fail but it does throw an exception. The return > code of the script is still 0 and the user is created in ZooKeeper but this > should be cleaned up since it's misleading. -- This message was sent by Atlassian JIRA (v7.6.3#76005)