title: Error while parsing csv to kafka in logstash
body: <p>I am trying to send csv data to kafka using LogStash implementing my own configuration script named test.conf.
  I got this error while parsing.</p>
  <pre><code>Using JAVA_HOME defined java: /usr/lib/jvm/java-1.8.0-openjdk-1.8.0.262.b10-0.el7_8.x86_64 
  WARNING, using JAVA_HOME while Logstash distribution comes with a bundled JDK 
  WARNING: Could not find logstash.yml which is typically located in $LS_HOME/config or /etc/logstash. You can specify the path using --path.settings. Continuing using the defaults 
  Could not find log4j2 configuration at path /usr/share/logstash/config/log4j2.properties. Using default config which logs errors to the console 
  [INFO ] 2021-05-24 19:12:08.565 [main] runner - Starting Logstash {&quot;logstash.version&quot;=&gt;&quot;7.10.0&quot;, &quot;jruby.version&quot;=&gt;&quot;jruby 9.2.13.0 (2.5.7) 2020-08-03 9a89c94bcc OpenJDK 64-Bit Server VM 25.262-b10 on 1.8.0_262-b10 +indy +jit [linux-x86_64]&quot;} 
  [FATAL] 2021-05-24 19:12:08.616 [main] runner - An unexpected error occurred! {:error=&gt;#&lt;ArgumentError: Path &quot;/usr/share/logstash/data&quot; must be a writable directory. It is not writable.&gt;, :backtrace=&gt;[&quot;/usr/share/logstash/logstash-core/lib/logstash/settings.rb:530:in `validate'&quot;, &quot;/usr/share/logstash/logstash-core/lib/logstash/settings.rb:290:in `validate_value'&quot;, &quot;/usr/share/logstash/logstash-core/lib/logstash/settings.rb:201:in `block in validate_all'&quot;, &quot;org/jruby/RubyHash.java:1415:in `each'&quot;, &quot;/usr/share/logstash/logstash-core/lib/logstash/settings.rb:200:in `validate_all'&quot;, &quot;/usr/share/logstash/logstash-core/lib/logstash/runner.rb:317:in `execute'&quot;, &quot;/usr/share/logstash/vendor/bundle/jruby/2.5.0/gems/clamp-0.6.5/lib/clamp/command.rb:67:in `run'&quot;, &quot;/usr/share/logstash/logstash-core/lib/logstash/runner.rb:273:in `run'&quot;, &quot;/usr/share/logstash/vendor/bundle/jruby/2.5.0/gems/clamp-0.6.5/lib/clamp/command.rb:132:in `run'&quot;, &quot;/usr/share/logstash/lib/bootstrap/environment.rb:88:in `&lt;main&gt;'&quot;]} 
  [ERROR] 2021-05-24 19:12:08.623 [main] Logstash - java.lang.IllegalStateException: Logstash stopped processing because of an error: (SystemExit) exit
  </code></pre>
  <p>This is the command used to run logstash.</p>
  <pre><code>/usr/share/logstash/bin/logstash -f test.conf
  </code></pre>
  <p>Here is the config file.</p>
  <pre><code>input {
    file {
       path =&gt; &quot;/home/data/*.csv&quot;
       start_position =&gt;&quot;beginning&quot;
       sincedb_path =&gt; &quot;/dev/null&quot;
    }
  }
  
  filter {
      mutate {
          add_field =&gt; {
          &quot;timestamp&quot; =&gt; &quot;%{Date} %{Time}&quot;
              }
      }
      
      date { match =&gt; [&quot;timestamp&quot;, &quot;dd-MM-YYYY HH:mm:ss&quot;]}
      
      csv {
          remove_field =&gt; [&quot;Date&quot;, &quot;Time&quot;]
      }
          
      grok {
          match =&gt; { &quot;message&quot; =&gt; [
              &quot;^%{DATE:timestamp},%{NUMBER:ab},%{NUMBER:cd},%{NUMBER:ef},%{NUMBER:gh},%{NUMBER:ij},%{NUMBER:kl},%{NUMBER:mn},%{NUMBER:op},%{NUMBER:qr},%{NUMBER:st},%{NUMBER:uv},%{NUMBER:wx},%{NUMBER:yz}$&quot;
              ]
          }
      }
  }
  
  output {
      stdout { codec =&gt; rubydebug }
      if &quot;_grokparsefailure&quot; not in [tags] {
              kafka {
                  codec =&gt; &quot;json&quot;
                  topic_id =&gt; &quot;abcd1234&quot;
                  bootstrap_servers =&gt; &quot;192.16.12.119:9092&quot;
          }
      }
  }
  </code></pre>
  <p>Please help me with this.</p>