# Local install only copies rb file to local\_gems

**URL:** <https://discuss.elastic.co/t/local-install-only-copies-rb-file-to-local-gems/2054>\
**Category:** Logstash\
**Created:** [June 6, 2015, 3:58am UTC](https://discuss.elastic.co/t/local-install-only-copies-rb-file-to-local-gems/2054 "2015-06-06T03:58:30Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![kyunam](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kyunam/32/3576_2.png) [@kyunam](https://discuss.elastic.co/u/kyunam)\
**Post date:** [June 6, 2015, 3:58am UTC](https://discuss.elastic.co/t/local-install-only-copies-rb-file-to-local-gems/2054/1 "2015-06-06T03:58:30Z")

</div>

I followed "How to write a Logstash input plugin".  
When installed locally, only rb file is copied to local\_gems/..../logstash-input-something/lib/logstash/something.rb

I had to copy manually all other files and folders. Then my custom input plugin works.

What do I do to make local install does copy all files and folders to local\_gems?

Thanks!

---

<div class="post-metadata">

**Author:** ![theuntergeek](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/theuntergeek/32/44961_2.png) [@theuntergeek](https://discuss.elastic.co/u/theuntergeek)\
**Post date:** [June 8, 2015, 5:10pm UTC](https://discuss.elastic.co/t/local-install-only-copies-rb-file-to-local-gems/2054/2 "2015-06-08T17:10:47Z")

</div>

That sounds rather like the gem wasn't built properly. Can you provide more details of how you built and installed your gem?

---

<div class="post-metadata">

**Author:** ![kyunam](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kyunam/32/3576_2.png) [@kyunam](https://discuss.elastic.co/u/kyunam)\
**Post date:** [June 8, 2015, 7:32pm UTC](https://discuss.elastic.co/t/local-install-only-copies-rb-file-to-local-gems/2054/3 "2015-06-08T19:32:09Z")

</div>

I couldn't remember how gem was installed.  
So, I did the followings.

1. I checked the version and it was 2.2.2
2. I updated by running - gem update --system on my mac.
3. Version is now 2.4.8
4. I created a brand new log stash filter. This time, it only copied README.md to local\_gems/.../....

Thanks,  
Q

---

<div class="post-metadata">

**Author:** ![theuntergeek](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/theuntergeek/32/44961_2.png) [@theuntergeek](https://discuss.elastic.co/u/theuntergeek)\
**Post date:** [June 8, 2015, 7:55pm UTC](https://discuss.elastic.co/t/local-install-only-copies-rb-file-to-local-gems/2054/4 "2015-06-08T19:55:15Z")

</div>

I'm sorry for not being clear. When I said, "how you built and installed your gem," I meant your logstash filter. How did you build and install that?

---

<div class="post-metadata">

**Author:** ![kyunam](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kyunam/32/3576_2.png) [@kyunam](https://discuss.elastic.co/u/kyunam)\
**Post date:** [June 8, 2015, 8:56pm UTC](https://discuss.elastic.co/t/local-install-only-copies-rb-file-to-local-gems/2054/5 "2015-06-08T20:56:58Z")

</div>

i'm sorry - I'm new to Ruby land..  
Basically, I cloned [logstash-filter-example](https://github.com/logstash-plugins/logstash-filter-example/) and then "gem build log stash-filter-something.gemspec", then "./bin/install /.../logstash-filter-something/logstash-filter-something-0.1.0.gem"

I seee installation successful message but not all content is copied over to local\_gems directory.

---

<div class="post-metadata">

**Author:** ![eravelo](https://avatars.discourse-cdn.com/v4/letter/e/4bbf92/32.png) [@eravelo](https://discuss.elastic.co/u/eravelo)\
**Post date:** [June 9, 2015, 7:21am UTC](https://discuss.elastic.co/t/local-install-only-copies-rb-file-to-local-gems/2054/6 "2015-06-09T07:21:59Z")

</div>

This looks like the issue I had (see link bellow)  
I didn't try to copy the ruby files manually though.

I still don't know how to fix it.

> [@Local filter plugin pretended to be installed but not listed and not working](https://discuss.elastic.co/t/local-filter-plugin-pretended-to-be-installed-but-not-listed-and-not-working/2016):
>
> I tried writing a simple filter plugin, following this Howto: [https://www.elastic.co/guide/en/logstash/current/\_how\_to\_write\_a\_logstash\_filter\_plugin.html](https://www.elastic.co/guide/en/logstash/current/_how_to_write_a_logstash_filter_plugin.html) When installing the plugin, it was reported to be installed: # /opt/logstash/bin/plugin install /usr/local/src/logstash-plugins/logstash-filter-ticketracker/logstash-filter-ticketracker-0.1.0.gem Validating /usr/local/src/logstash-plugins/logstash-filter-ticketracker/logstash-filter-ticketracker-0.1.0.gem Installing logstash-filter-ticketrac…

---

<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:38am UTC](https://discuss.elastic.co/t/local-install-only-copies-rb-file-to-local-gems/2054/7 "2017-07-06T05:38:04Z")

</div>

Closed on July 6, 2017, 5:38am UTC


