Skip to content
This repository has been archived by the owner on Dec 27, 2022. It is now read-only.

Logstash 2.3.4, 2.3.3 service fails #459

Open
imewish opened this issue Aug 5, 2016 · 9 comments
Open

Logstash 2.3.4, 2.3.3 service fails #459

imewish opened this issue Aug 5, 2016 · 9 comments

Comments

@imewish
Copy link

imewish commented Aug 5, 2016

Hi,

I have tried to install logstash 2.3.4 with this cookbook with test kitchen and EC2. The installation went well but i couldn't see the logstash services running.

root@ip-10-11-19-240:/tmp# /etc/init.d/logstash_server status
down: logstash_server: 1s, normally up, want up; run: log: (pid 10338) 2558s

Tried in both unbuntu 16.04,14.04 with java 8 and 7. no luck.

Logstash 1.5.4 which is default in this cookbook worked fine.

helps would be appreciated.

@praveenuchiha
Copy link

praveenuchiha commented Aug 11, 2016

Same issue, doesnt work for me either with LS 2.3.4 and ubuntu 14.04.
Also @imewish when you run the cookbook does [apt-get-update-periodic] execute without fail?
I think it bugs out when there is user/group associated with logstash and throws "Ran apt-get update returned 100" error.

Update: Fixed the service issue by following #452
The apt-get-update still throws "Returned 100 error"

Update 2: Fixed the apt-get-update issue. The problem was with my VM.

@eyalzek
Copy link

eyalzek commented Aug 24, 2016

I faced the same issue, the problem was with the service definition as far as I can tell. To fix it I had to change the following line:
https://github.com/lusis/chef-logstash/blob/master/templates/default/sv-logstash-run.erb#L12
and name the env variable LS_JAVA_OPTS instead of just JAVA_OPTS.

I created 2 files in my local cookbook's templates folder; sv-logstash-run.erb & sv-logstash-log-run.erb, both are the same as the files that you can find here:
https://github.com/lusis/chef-logstash/tree/master/templates/default

The only change being the renaming of the aforementioned environment variable. Then, in order to use these templates instead of the ones coming from the cookbook, set this attribute in your recipe:
node.default['logstash']['instance_default']['service_templates_cookbook'] = cookbook_name

@imewish
Copy link
Author

imewish commented Aug 30, 2016

@eyalzek Your fix worked :) Thanks man .. thanks alot

@imewish imewish closed this as completed Sep 5, 2016
@eyalzek
Copy link

eyalzek commented Sep 5, 2016

@imewish I wouldn't close this issue just yet, it should be fixed on the cookbook level.

@imewish imewish reopened this Sep 5, 2016
@imewish
Copy link
Author

imewish commented Sep 5, 2016

Okay.

@imewish
Copy link
Author

imewish commented Sep 5, 2016

@eyalzek BTW, i came across new problem with thiscookbook. How can we use custom config templates with with this cookbook? instead of these.
https://github.com/lusis/chef-logstash/tree/master/templates/default/config

@eyalzek
Copy link

eyalzek commented Sep 5, 2016

@imewish set node.default['logstash']['instance_default']['config_templates_cookbook'] to your wrapper cookbook's name. Besides that, you have to configure config_templates and pass variables if you need them.

Use this as reference:
https://github.com/rackspace-cookbooks/elkstack/blob/master/recipes/logstash.rb#L45
https://github.com/rackspace-cookbooks/elkstack/blob/master/attributes/logstash.rb#L33

@imewish
Copy link
Author

imewish commented Sep 5, 2016

Thanks man :)

@imewish
Copy link
Author

imewish commented Sep 7, 2016

@eyalzek did you face a time lag while installing plugins? when use the resource provider logstash_plugins for plugin installation?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants