Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Logging not working #108

Closed
Fabian1976 opened this issue Oct 17, 2017 · 2 comments
Closed

Logging not working #108

Fabian1976 opened this issue Oct 17, 2017 · 2 comments

Comments

@Fabian1976
Copy link

The logfile of Zookeeper is not being written.

In my /var/log/messages i get this:

Oct 17 13:24:29 puppetdev-fabian01 java: java.io.FileNotFoundException: ./zookeeper.log (Permission denied)

In the log4j.properties, the zookeeper.log.dir is set to .
So ./zookeeper.log is legit.

In /etc/zookeeper/java.env this is set as the logdir: ZOO_LOG_DIR=/var/log/zookeeper but zookeeper seems to ignore this.

When I change the log4j template on my puppetmaster from this:

zookeeper.log.dir=.

to this

zookeeper.log.dir=<%= scope.lookupvar("zookeeper::log_dir") %>

It works fine.

I use a Satellite with zookeeper 3.4.10 compiled from source using this spec file: spec-file

@Fabian1976
Copy link
Author

I found the problem. When the default service_file is used, the log4j.properties file is used (as it should do).

When I set this parameter in my hiera yaml:

zookeeper::manage_service_file: true

The service file is managed by this module and all king of parameters are added as a startup parameter which are also in log4j.properties.

But then is does work.

I still think the log location should be properly set in log4j.properties. Why else use that file if you're going to override the zookeeper.log.dir parameter by adding it to the startup parameter. I believe conf files are there so that there is no need for adding everything as a startup parameter.

@deric
Copy link
Owner

deric commented Oct 17, 2017

Thanks for the report. It should be fixed in v0.7.5 release.

@deric deric closed this as completed Oct 17, 2017
cegeka-jenkins pushed a commit to cegeka/puppet-zookeeper that referenced this issue Sep 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants