This is zk 3.2.2? Are you sure that's all it said on start? When I start I see:

$ bin/ start
JMX enabled by default
Using config: /home/phunt/dev/workspace/gitzk/bin/../conf/zoo.cfg
Starting zookeeper ...

you might have some error case, for example if I start zk w/o having a datadir created (via mkdir) I see the following:

bin/ start
JMX enabled by default
Using config: /home/phunt/dev/workspace/gitzk/bin/../conf/zoo.cfg
Starting zookeeper ...
bin/ 120: cannot create /tmp/zktmp/ Directory nonexistent

in which case stop also does not stop the server (as the pid file is never created during start, used during stop)

Are you setting up/startting/stopping as the same user (correct permissions?)

After start you should check if your datadir contains a file and that the pid in the file is the same as the java process running zk.

the location/name of the pid file is defined as the following by
ZOOPIDFILE=$(grep dataDir $ZOOCFG | sed -e 's/.*=//')/
(your config file has a dataDir entry which is the directory of your data directory correct? what does your config file look like?)

Also I see this in your output which is unusual:

"/ file server1/data"

we are trying to :
    kill -9 $(cat $ZOOPIDFILE)

perhaps ZOOPIDFILE is not getting set correctly (try adding some 'echo' lines to the script, it may help you debug)


Michael Bauland wrote:

I'm running the ZooKeeper on three different servers. The following info
is printed by ZooKeeper when starting it with the zkServer start script:

Server environment:java.compiler=<NA>
Server environment:os.arch=amd64
Server environment:os.version=2.6.24-25-server

Whenever I then try to stop the server on any of those servers with the
same script using 'stop' as parameter, the script is executed and it says:

JMX enabled by default
Using config: /opt/zookeeper/bin/../conf/zoo.cfg
Stopping zookeeper ...
/ file server1/data

And that's it. A further status command tells me the server is still
running. I always have to kill the process to really stop the server.
This is not actually a problem, but it makes me wonder if there's maybe
some other hidden problem which causes this behaviour and might cause
other (not yet noticed) bigger problems!?

Thank you for any help or suggestions.


Reply via email to