[ https://issues.apache.org/jira/browse/HBASE-10793?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13940995#comment-13940995 ]
Ted Yu commented on HBASE-10793: -------------------------------- +1 > AuthFailed as a valid zookeeper state > -------------------------------------- > > Key: HBASE-10793 > URL: https://issues.apache.org/jira/browse/HBASE-10793 > Project: HBase > Issue Type: Bug > Components: Zookeeper > Affects Versions: 0.96.0 > Reporter: Demai Ni > Assignee: Demai Ni > Fix For: 0.96.2, 0.99.0, 0.98.2 > > Attachments: HBASE-10793-trunk-v0.patch > > > In kerberos mode, Zookeeper accepts SASL authentication. The AuthFailed > message indicates the client could not be authenticated, but it should > proceed anyway, because only access to znodes that require SASL > authentication will be denied and this client may never need to access them. > Furthermore, AuthFailed is a valid event supported by Zookeeper, and > following are valid Zookeeper events: > case 0: return KeeperState.Disconnected; > case 3: return KeeperState.SyncConnected; > case 4: return KeeperState.AuthFailed; > case 5: return KeeperState.ConnectedReadOnly; > case 6: return KeeperState.SaslAuthenticated; > case -112: return KeeperState.Expired; > Based on above, ZooKeeperWatcher should not throw exception for AuthFailed > event as an invalid event. For this kind of event, Zookeeper already logs it > as a warning and proceed with non-SASL connection. > {code:title=IllegalStateException from ZookeeperWatcher|borderStyle=solid} > hbase(main):006:0> list > TABLE > > > 14/01/23 17:26:11 ERROR zookeeper.ClientCnxn: Error while calling watcher > java.lang.IllegalStateException: Received event is not valid: AuthFailed > at > org.apache.hadoop.hbase.zookeeper.ZooKeeperWatcher.connectionEvent(ZooKeeperWatcher.java:410) > at > org.apache.hadoop.hbase.zookeeper.ZooKeeperWatcher.process(ZooKeeperWatcher.java:319) > at > org.apache.zookeeper.ClientCnxn$EventThread.processEvent(ClientCnxn.java:519) > at org.apache.zookeeper.ClientCnxn$EventThread.run(ClientCnxn.java:495) > BIMonitoring > > > BIMonitoringSummary > > > BIMonitoringSummary180 > > > BIMonitoringSummary900 > > > LogMetadata > > > LogRecords > > > Mtable > > > t1 > > > t2 > > > 9 row(s) in 0.4040 seconds > => ["BIMonitoring", "BIMonitoringSummary", "BIMonitoringSummary180", > "BIMonitoringSummary900", "LogMetadata", "LogRecords", "Mtable", "t1", "t2"] > {code} > the patch will be similar as HBase-8757 -- This message was sent by Atlassian JIRA (v6.2#6252)