[
https://issues.apache.org/jira/browse/ZOOKEEPER-3743?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Mate Szalay-Beko reassigned ZOOKEEPER-3743:
-------------------------------------------
Assignee: Mate Szalay-Beko
> Poor error messages about the parsing of the jass.conf file
> -----------------------------------------------------------
>
> Key: ZOOKEEPER-3743
> URL: https://issues.apache.org/jira/browse/ZOOKEEPER-3743
> Project: ZooKeeper
> Issue Type: Improvement
> Affects Versions: 3.5.6
> Environment: Debian 10
> Reporter: Alexandre Anouthcine
> Assignee: Mate Szalay-Beko
> Priority: Major
>
> I'm trying to set up a cluster of 3 Zookeeper nodes and I'm struggling to
> understand the error messages regarding jaas.conf file.
> I found 2 articles about the [Server-Server mutual
> authentication|[https://cwiki.apache.org/confluence/display/ZOOKEEPER/Server-Server+mutual+authentication]]
> jaas.conf file are the same on 3 nodes and it seems to be working:
> |{{QuorumServer {}}
> {{ org.apache.zookeeper.server.auth.DigestLoginModule required}}
> {{ user_zkinternal="pa$$word";}}
> {{};}}
> {{ }}
> {{QuorumLearner {}}
> {{ org.apache.zookeeper.server.auth.DigestLoginModule required}}
> {{ username="zkinternal"}}
> {{ password="pa$$word";}}
> {{};}}|
> Now I want to connect a Solr client to it. I found an article about
> [Client-Server mutual
> authentication|[https://cwiki.apache.org/confluence/display/ZOOKEEPER/Client-Server+mutual+authentication]]
> It show an example:
> |{{Server {}}
> {{ org.apache.zookeeper.server.auth.DigestLoginModule required}}
> {{ }}{{user_super=}}{{"adminsecret"}}
> {{ }}{{user_bob=}}{{"bobsecret"}}{{;}}
> {{};}}|
> The problem when I try to change my original jaas.conf file with something
> else like:
> |{{QuorumServer {}}
> {{ org.apache.zookeeper.server.auth.DigestLoginModule required}}
> {{ user_zkinternal="pa$$word";}}
> {{ user_solr=}}{{"solrsecret"}}{{;}}{{}}
> {{};}}
> {{ }}
> {{QuorumLearner {}}
> {{ org.apache.zookeeper.server.auth.DigestLoginModule required}}
> {{ username="zkinternal"}}
> {{ password="pa$$word";}}
> {{};}}|
> or
> |{{QuorumServer {}}
> {{ org.apache.zookeeper.server.auth.DigestLoginModule required}}
> {{ user_zkinternal="pa$$word";}}{{}}
> {{};}}
> {{ }}
> {{QuorumLearner {}}
> {{ org.apache.zookeeper.server.auth.DigestLoginModule required}}
> {{ username="zkinternal"}}
> {{ password="pa$$word";}}
> {{};}}
> {{}}
> {{}}
> {{Server {}}
> {{ org.apache.zookeeper.server.auth.DigestLoginModule required}}
> {{user_solr=}}{{"solrsecret"}}{{;}}{{}}
> {{};}}|
> or even
> |{{QuorumServer {}}
> {{ org.apache.zookeeper.server.auth.DigestLoginModule required}}
> {{ user_zkinternal="pa$$word"}}{{}}{{}}
> {{};}}
> {{ }}
> {{QuorumLearner {}}
> {{ org.apache.zookeeper.server.auth.DigestLoginModule required}}
> {{ username="zkinternal"}}
> {{ password="pa$$word";}}
> {{};}}|
> (Notice the missing semicolon for the user)
> I always get the same error message which doesn't make much sense to me:
> |{{}}2020-02-27 16:24:07,815 [myid:] - INFO [main:QuorumPeerConfig@133] -
> Reading configuration from: /conf/zoo.cfg2020-02-27 16:24:07,815 [myid:] -
> INFO [main:QuorumPeerConfig@133] - Reading configuration from:
> /conf/zoo.cfg2020-02-27 16:24:07,822 [myid:] - INFO
> [main:QuorumPeerConfig@385] - clientPortAddress is
> 0.0.0.0/0.0.0.0:21812020-02-27 16:24:07,822 [myid:] - INFO
> [main:QuorumPeerConfig@389] - secureClientPort is not set2020-02-27
> 16:24:08,676 [myid:3] - INFO [main:DatadirCleanupManager@78] -
> autopurge.snapRetainCount set to 32020-02-27 16:24:08,678 [myid:3] - INFO
> [main:DatadirCleanupManager@79] - autopurge.purgeInterval set to 02020-02-27
> 16:24:08,679 [myid:3] - INFO [main:DatadirCleanupManager@101] - Purge task
> is not scheduled.2020-02-27 16:24:08,680 [myid:3] - INFO
> [main:ManagedUtil@46] - Log4j found with jmx enabled.2020-02-27 16:24:08,690
> [myid:3] - INFO [main:QuorumPeerMain@141] - Starting quorum peer2020-02-27
> 16:24:08,697 [myid:3] - INFO [main:ServerCnxnFactory@135] - Using
> org.apache.zookeeper.server.NIOServerCnxnFactory as server connection
> factory2020-02-27 16:24:08,712 [myid:3] - ERROR [main:ServerCnxnFactory@231]
> - No JAAS configuration section named 'Server' was found in
> '/conf/jaas.conf'.2020-02-27 16:24:08,730 [myid:3] - ERROR
> [main:QuorumPeerMain@101] - Unexpected exception, exiting
> abnormallyjava.io.IOException: No JAAS configuration section named 'Server'
> was found in '/conf/jaas.conf'. at
> org.apache.zookeeper.server.ServerCnxnFactory.configureSaslLogin(ServerCnxnFactory.java:232)
> at
> org.apache.zookeeper.server.NIOServerCnxnFactory.configure(NIOServerCnxnFactory.java:646)
> at
> org.apache.zookeeper.server.quorum.QuorumPeerMain.runFromConfig(QuorumPeerMain.java:148)
> at
> org.apache.zookeeper.server.quorum.QuorumPeerMain.initializeAndRun(QuorumPeerMain.java:123)
> at
> org.apache.zookeeper.server.quorum.QuorumPeerMain.main(QuorumPeerMain.java:82)
> {{}}|
> So what does it mean ? How to do it ?
--
This message was sent by Atlassian Jira
(v8.3.4#803005)