Sam-T
Sam-T

Reputation: 1975

Zookeeper 3.5.6 start issue

Using Zookeeper 3.5.6-bin, on Win10, java8

PATH= ;%ZOOKEEPER_HOME%\bin;  
ZOOKEEPER_HOME=C:\apps\Apache\apache-zookeeper-3.5.6-bin  
dataDir=C:\appas\apache\apache-zookeeper-3.5.6-bin\data

I am starting with zkServer start

ERROR:

[main:ZooKeeperServerMain@66] - Invalid arguments, exiting abnormally  
java.lang.NumberFormatException: For input string: "C:\apps\apache\apache-zookeeper-3.5.6-bin\bin\..\conf\zoo.cfg" at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)
at org.apache.zookeeper.server.quorum.QuorumPeerMain.main(QuorumPeerMain.java:82)

2020-01-28 15:29:12,618 [myid:] - INFO  [main:ZooKeeperServerMain@67] - Usage: ZooKeeperServerMain configfile | port datadir [ticktime] [maxcnxns]  
Usage: ZooKeeperServerMain configfile | port datadir [ticktime] [maxcnxns]  

ZOOKEEPER_HOME etc seem correct?

Update/Resolution
zkServer [start] - is a documented legit way to start - but this gives errors - cant figure that out why. So just zkServer to start.
Port 8080 conflict for admin server: You can kill the existing process on this port (requires a bit of doing). Or you can start admin on different port (or even disable admin server completely). This is not clearly documented in the Docs - but check here

Upvotes: 1

Views: 778

Answers (1)

Scratte
Scratte

Reputation: 3166

In a joint effort the solution is to run it without start, just

> zkServer

..and to ensure nothing else is running on port 8080 for the AdminServer to be able to start, avoiding this:

Unable to start AdminServer, exiting abnormally
org.apache.zookeeper.server.admin.AdminServer$AdminServerException:
  Problem starting AdminServer on address 0.0.0.0, port 8080 and command URL /commands.
  Caused by: java.io.IOException: Failed to bind to /0.0.0.0:8080
  Caused by: java.net.BindException: Address already in use: bind.

Upvotes: 2

Related Questions