# Logstash 2.1 fails to start after logstash-output-elasticsearch update

**URL:** <https://discuss.elastic.co/t/logstash-2-1-fails-to-start-after-logstash-output-elasticsearch-update/38330>\
**Category:** Logstash\
**Created:** [January 4, 2016, 4:09pm UTC](https://discuss.elastic.co/t/logstash-2-1-fails-to-start-after-logstash-output-elasticsearch-update/38330 "2016-01-04T16:09:53Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![techcheez](https://avatars.discourse-cdn.com/v4/letter/t/47e85d/32.png) [@techcheez](https://discuss.elastic.co/u/techcheez)\
**Post date:** [January 4, 2016, 4:09pm UTC](https://discuss.elastic.co/t/logstash-2-1-fails-to-start-after-logstash-output-elasticsearch-update/38330/1 "2016-01-04T16:09:53Z")

</div>

I just ran a bin/plugin update and the logstash-output-elasticsearch plugin was upgraded from 2.3.0 to 2.3.1. When I tried restarting logstash I get the following error:

> The error reported is:

> you might need to reinstall the gem which depends on the missing jar or in case there is Jars.lock then resolve the jars with `lock_jars` command

> no such file to load -- org/apache/httpcomponents/httpclient/4.5/httpclient-4.5 (LoadError)

Any way to resolve this quickly?

---

<div class="post-metadata">

**Author:** ![techcheez](https://avatars.discourse-cdn.com/v4/letter/t/47e85d/32.png) [@techcheez](https://discuss.elastic.co/u/techcheez)\
**Post date:** [January 4, 2016, 4:54pm UTC](https://discuss.elastic.co/t/logstash-2-1-fails-to-start-after-logstash-output-elasticsearch-update/38330/2 "2016-01-04T16:54:15Z")

</div>

I did look through the history when running the bin/plugin update and saw these 2 errors:

> Updating logstash-codec-collectd, logstash-codec-dots, logstash-codec-edn, logstash-codec-edn\_lines, logstash-codec-es\_bulk, logstash-codec-fluent, logstash-codec-graphite, logstash-code c-json, logstash-codec-json\_lines, logstash-codec-line, logstash-codec-msgpack, logstash-codec-multiline, logstash-codec-netflow, logstash-codec-oldlogstashjson, logstash-codec-plain, lo gstash-codec-rubydebug, logstash-filter-anonymize, logstash-filter-checksum, logstash-filter-clone, logstash-filter-csv, logstash-filter-date, logstash-filter-dns, logstash-filter-drop, logstash-filter-fingerprint, logstash-filter-geoip, logstash-filter-grok, logstash-filter-json, logstash-filter-kv, logstash-filter-metrics, logstash-filter-multiline, logstash-filter-mu tate, logstash-filter-ruby, logstash-filter-sleep, logstash-filter-split, logstash-filter-syslog\_pri, logstash-filter-throttle, logstash-filter-translate, logstash-filter-urldecode, logs tash-filter-useragent, logstash-filter-uuid, logstash-filter-xml, logstash-input-beats, logstash-input-couchdb\_changes, logstash-input-elasticsearch, logstash-input-eventlog, logstash-in put-exec, logstash-input-file, logstash-input-ganglia, logstash-input-gelf, logstash-input-generator, logstash-input-graphite, logstash-input-heartbeat, logstash-input-http, logstash-inp ut-imap, logstash-input-irc, logstash-input-jdbc, logstash-input-kafka, logstash-input-log4j, logstash-input-lumberjack, logstash-input-pipe, logstash-input-rabbitmq, logstash-input-redi s, logstash-input-s3, logstash-input-snmptrap, logstash-input-sqs, logstash-input-stdin, logstash-input-syslog, logstash-input-tcp, logstash-input-twitter, logstash-input-udp, logstash-i nput-unix, logstash-input-xmpp, logstash-input-zeromq, logstash-output-cloudwatch, logstash-output-csv, logstash-output-elasticsearch, logstash-output-email, logstash-output-exec, logsta sh-output-file, logstash-output-ganglia, logstash-output-gelf, logstash-output-graphite, logstash-output-hipchat, logstash-output-http, logstash-output-irc, logstash-output-juggernaut, l ogstash-output-kafka, logstash-output-lumberjack, logstash-output-nagios, logstash-output-nagios\_nsca, logstash-output-null, logstash-output-opentsdb, logstash-output-pagerduty, logstash -output-pipe, logstash-output-rabbitmq, logstash-output-redis, logstash-output-s3, logstash-output-sns, logstash-output-sqs, logstash-output-statsd, logstash-output-stdout, logstash-outp ut-tcp, logstash-output-udp, logstash-output-xmpp, logstash-output-zeromq, logstash-patterns-core  
> Error Bundler::InstallError, retrying 1/10  
> An error occurred while installing jruby-kafka (1.5.0), and Bundler cannot continue.  
> Make sure that `gem install jruby-kafka -v '1.5.0'` succeeds before bundling.  
> WARNING: SSLSocket#session= is not supported  
> Error Bundler::InstallError, retrying 2/10  
> An error occurred while installing manticore (0.5.2), and Bundler cannot continue.  
> Make sure that `gem install manticore -v '0.5.2'` succeeds before bundling.  
> WARNING: SSLSocket#session= is not supported

When I try running `gem install manticore -v '0.5.2'` I get the following error:

> ERROR: Could not find a valid gem 'manticore' (= 0.5.2), here is why:  
> Found manticore (0.5.2), but was for platform java  
> ERROR: Possible alternatives: MINT-core, handscore, antidote, antinode, fat\_core

---

<div class="post-metadata">

**Author:** ![techcheez](https://avatars.discourse-cdn.com/v4/letter/t/47e85d/32.png) [@techcheez](https://discuss.elastic.co/u/techcheez)\
**Post date:** [January 4, 2016, 5:40pm UTC](https://discuss.elastic.co/t/logstash-2-1-fails-to-start-after-logstash-output-elasticsearch-update/38330/3 "2016-01-04T17:40:54Z")

</div>

Digging deeper into the rabbit hole I discovered I needed to specify the path to jruby to run the gem install command. When running the following command I now see missing dependency for manticore v0.5.2.

`env GEM_HOME=/opt/logstash/vendor/bundle/jruby/1.9 /opt/logstash/vendor/jruby/bin/jruby /opt/logstash/vendor/jruby/bin/gem install manticore -v '0.5.2'`

it was missing an xml file that was supposed to be included with ruby-maven 3.3.8.

The following 2 commands got me back up and running with logstash-output-elasticsearch v2.3.1:

`[user@host ~]# env GEM_HOME=/opt/logstash/vendor/bundle/jruby/1.9 /opt/logstash/vendor/jruby/bin/jruby /opt/logstash/vendor/jruby/bin/gem install ruby-maven`

this installed the lastest v.3.3.8 of ruby-maven and then I ran

`[user@host ~]# env GEM_HOME=/opt/logstash/vendor/bundle/jruby/1.9 /opt/logstash/vendor/jruby/bin/jruby /opt/logstash/vendor/jruby/bin/gem install manticore -v '0.5.2'`

after that install completed successfully I was able to restart logstash. Hope this helps!

---

<div class="post-metadata">

**Author:** ![bbach](https://avatars.discourse-cdn.com/v4/letter/b/d26b3c/32.png) [@bbach](https://discuss.elastic.co/u/bbach)\
**Post date:** [January 4, 2016, 9:17pm UTC](https://discuss.elastic.co/t/logstash-2-1-fails-to-start-after-logstash-output-elasticsearch-update/38330/4 "2016-01-04T21:17:49Z")

</div>

Hit this same issue. Thanks for the fix! -- Bud

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [January 5, 2016, 12:53am UTC](https://discuss.elastic.co/t/logstash-2-1-fails-to-start-after-logstash-output-elasticsearch-update/38330/5 "2016-01-05T00:53:10Z")

</div>

That's kinda sucky to have to do that to upgrade a plugin, lemme see if one of the LS team can comment.

---

<div class="post-metadata">

**Author:** ![suyograo](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/suyograo/32/44898_2.png) [@suyograo](https://discuss.elastic.co/u/suyograo)\
**Post date:** [January 5, 2016, 3:24am UTC](https://discuss.elastic.co/t/logstash-2-1-fails-to-start-after-logstash-output-elasticsearch-update/38330/6 "2016-01-05T03:24:31Z")

</div>

This error is because we updated logstash-output-elasticsearch to explicitly depend on manticore-http library, but the Logstash core 2.1.1 was bundled with a different version of it. The workaround @techcheez mentioned will work (its not ideal to do this) but we are soon releasing (target - next week) Logstash 2.1.2 with full update to all plugins.

Also, is there a reason users prefer to run bin/plugin update instead of updating entire LS binary? Can you please weigh in your thoughts here? [https://github.com/elastic/logstash/issues/4415](https://github.com/elastic/logstash/issues/4415)

---

<div class="post-metadata">

**Author:** ![ampodobas](https://avatars.discourse-cdn.com/v4/letter/a/3bc359/32.png) [@ampodobas](https://discuss.elastic.co/u/ampodobas)\
**Post date:** [January 14, 2016, 5:55am UTC](https://discuss.elastic.co/t/logstash-2-1-fails-to-start-after-logstash-output-elasticsearch-update/38330/7 "2016-01-14T05:55:39Z")

</div>

This worked for me:

**Issue: Error when starting logstash**  
“The error reported is: you might need to reinstall the gem which depends on the missing jar or in case there is Jars.lock then resolve the jars with `lock_jars` command no such file to load -- org/apache/httpcomponents/httpclient/4.5/httpclient-4.5 (LoadError)”

**Proximate cause: this plugin**  
logstash-output-elasticsearch

**Solution:**  
/opt/logstash/bin/plugin uninstall logstash-output-elasticsearch;  
/opt/logstash/bin/plugin install --version 2.3.0 logstash-output-elasticsearch;

If that works, great! However, you may see this error: "Plugin version conflict, aborting ERROR: Installation Aborted, message: Bundler could not find compatible versions for gem "manticore": In snapshot (Gemfile.lock): manticore (= 0.5.2) In Gemfile:  
logstash-output-elasticsearch (= 2.3.0) java depends on manticore (~\> 0.4.2) java"

Then:

vi /opt/logstash/Gemfile.jruby-1.9.lock;

Change manticore from 0.5.2 to 0.4.2 (in all places, it was in two places in my Gemfile.jruby-1.9.lock file) and save + exit, then run:  
/opt/logstash/bin/plugin install --version 2.3.0 logstash-output-elasticsearch;

**Result:**  
[root@elk logstash]# service logstash restart  
logstash started.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 6, 2017, 5:15am UTC](https://discuss.elastic.co/t/logstash-2-1-fails-to-start-after-logstash-output-elasticsearch-update/38330/8 "2017-07-06T05:15:46Z")

</div>


