# Logstash file input plug - exception argument error

**URL:** <https://discuss.elastic.co/t/logstash-file-input-plug-exception-argument-error/188691>\
**Category:** Logstash\
**Created:** [July 3, 2019, 10:59am UTC](https://discuss.elastic.co/t/logstash-file-input-plug-exception-argument-error/188691 "2019-07-03T10:59:21Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![jamesp220291](https://avatars.discourse-cdn.com/v4/letter/j/91b2a8/32.png) [@jamesp220291](https://discuss.elastic.co/u/jamesp220291)\
**Post date:** [July 3, 2019, 10:59am UTC](https://discuss.elastic.co/t/logstash-file-input-plug-exception-argument-error/188691/1 "2019-07-03T10:59:21Z")

</div>

Hi All

Getting a weird error when trying to use the file input plugin.

Some information on my environment

java --version  
openjdk 11.0.3 2019-04-16  
OpenJDK Runtime Environment (build 11.0.3+7-Ubuntu-1ubuntu218.04.1)  
OpenJDK 64-Bit Server VM (build 11.0.3+7-Ubuntu-1ubuntu218.04.1, mixed mode, sharing)

logstash-input-file (4.1.10)

bin/logstash --version  
logstash 7.2.0

Logstash input config -

input {  
file {  
path =\> "/data/my-logs/\*"  
mode =\> "read"  
file\_completed\_action =\> "log"  
sincedb\_path =\> "/data/logstash-db/20\_sincedb"  
file\_completed\_log\_path =\> "/data/logstash-db/20\_file\_completed\_log"  
}  
}

The files are all .gz files.

The error -

Jul 3 11:53:50 sys-logstash-my-logs logstash[10366]: Plugin: \<LogStash::Inputs::File mode=\>"read", path=\>["/data/my-logs-logs/\*"], id=\>"46723655fc001488cf5ff6d5dc3bc4a6b319d2b1f226e73155eac6b447c1a9b1", file\_completed\_action=\>"log", sincedb\_path=\>"/data/logstash-db/20\_sincedb", file\_completed\_log\_path=\>"/data/logstash-db/20\_file\_completed\_log", enable\_metric=\>true, codec=\>\<LogStash::Codecs::Plain id=\>"plain\_868e1ea4-3fcc-457b-af16-40dc95679d0d", enable\_metric=\>true, charset=\>"UTF-8"\>, stat\_interval=\>1.0, discover\_interval=\>15, sincedb\_write\_interval=\>15.0, start\_position=\>"end", delimiter=\>"\n", close\_older=\>3600.0, sincedb\_clean\_after=\>1209600.0, file\_chunk\_size=\>32768, file\_chunk\_count=\>140737488355327, file\_sort\_by=\>"last\_modified", file\_sort\_direction=\>"asc"\>  
Jul 3 11:53:50 sys-logstash-my-logs logstash[10366]: Error: wrong number of arguments (given 1, expected 0)  
Jul 3 11:53:50 sys-logstash-my-logs logstash[10366]: Exception: ArgumentError  
Jul 3 11:53:50 sys-logstash-my-logs logstash[10366]: Stack: /usr/share/logstash/vendor/bundle/jruby/2.5.0/gems/logstash-input-file-4.1.10/lib/filewatch/read\_mode/handlers/read\_zip\_file.rb:26:in `handle_specifically' Jul 3 11:53:50 sys-logstash-my-logs logstash[10366]: /usr/share/logstash/vendor/bundle/jruby/2.5.0/gems/logstash-input-file-4.1.10/lib/filewatch/read_mode/handlers/base.rb:26:in`handle'  
Jul 3 11:53:50 sys-logstash-my-logs logstash[10366]: /usr/share/logstash/vendor/bundle/jruby/2.5.0/gems/logstash-input-file-4.1.10/lib/filewatch/read\_mode/processor.rb:39:in `read_zip_file' Jul 3 11:53:50 sys-logstash-my-logs logstash[10366]: /usr/share/logstash/vendor/bundle/jruby/2.5.0/gems/logstash-input-file-4.1.10/lib/filewatch/read_mode/processor.rb:102:in`block in process\_active'  
Jul 3 11:53:50 sys-logstash-my-logs logstash[10366]: org/jruby/RubyArray.java:1792:in `each' Jul 3 11:53:50 sys-logstash-my-logs logstash[10366]: /usr/share/logstash/vendor/bundle/jruby/2.5.0/gems/logstash-input-file-4.1.10/lib/filewatch/read_mode/processor.rb:88:in`process\_active'  
Jul 3 11:53:50 sys-logstash-my-logs logstash[10366]: /usr/share/logstash/vendor/bundle/jruby/2.5.0/gems/logstash-input-file-4.1.10/lib/filewatch/read\_mode/processor.rb:45:in `process_all_states' Jul 3 11:53:50 sys-logstash-my-logs logstash[10366]: /usr/share/logstash/vendor/bundle/jruby/2.5.0/gems/logstash-input-file-4.1.10/lib/filewatch/watch.rb:67:in`iterate\_on\_state'  
Jul 3 11:53:50 sys-logstash-my-logs logstash[10366]: /usr/share/logstash/vendor/bundle/jruby/2.5.0/gems/logstash-input-file-4.1.10/lib/filewatch/watch.rb:45:in `subscribe' Jul 3 11:53:50 sys-logstash-my-logs logstash[10366]: /usr/share/logstash/vendor/bundle/jruby/2.5.0/gems/logstash-input-file-4.1.10/lib/filewatch/observing_read.rb:12:in`subscribe'  
Jul 3 11:53:50 sys-logstash-my-logs logstash[10366]: /usr/share/logstash/vendor/bundle/jruby/2.5.0/gems/logstash-input-file-4.1.10/lib/logstash/inputs/file.rb:339:in `run' Jul 3 11:53:50 sys-logstash-my-logs logstash[10366]: /usr/share/logstash/logstash-core/lib/logstash/java_pipeline.rb:309:in`inputworker'  
Jul 3 11:53:50 sys-logstash-my-logs logstash[10366]: /usr/share/logstash/logstash-core/lib/logstash/java\_pipeline.rb:302:in `block in start\_input'

---

<div class="post-metadata">

**Author:** ![jamesp220291](https://avatars.discourse-cdn.com/v4/letter/j/91b2a8/32.png) [@jamesp220291](https://discuss.elastic.co/u/jamesp220291)\
**Post date:** [July 3, 2019, 12:22pm UTC](https://discuss.elastic.co/t/logstash-file-input-plug-exception-argument-error/188691/2 "2019-07-03T12:22:56Z")

</div>

fixed -

Just so everyone knows/if anyone finds this on google in the future.

the plugin doesnt work with Java 11, you need to install java 8, and everything is fine.

---

<div class="post-metadata">

**Author:** ![Badger](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/badger/32/25190_2.png) [@Badger](https://discuss.elastic.co/u/Badger)\
**Post date:** [July 3, 2019, 12:49pm UTC](https://discuss.elastic.co/t/logstash-file-input-plug-exception-argument-error/188691/3 "2019-07-03T12:49:56Z")

</div>

Yeah, this has been seen [before](https://discuss.elastic.co/t/does-logstash-7-0-1-support-gzip-file-input/181862/2) with Java 12, which is not supported, although 11 is.

---

<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 31, 2019, 12:49pm UTC](https://discuss.elastic.co/t/logstash-file-input-plug-exception-argument-error/188691/4 "2019-07-31T12:49:57Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
