[logstash.runner ] An unexpected error occurred! {:error=>#, :backtrace=>

My Config file is like this

input {
	file {
     path => "D:\logstash\logstash-6.1.0\bin\repoprolog.log"
		start_position => "beginning"
		sincedb_path => "/dev/null"
		ignore_older => 0
		codec => multiline
		{
			pattern => "%{DATE}_%{TIME} - "
			negate => true
			what => "previous"
			auto_flush_interval => 1
	}}} filter {
	 grok {
match => {"message" => "%{DATE}_%{TIME} - %{POSINT:value} %{DATA:status} %{WORD:result} %{GREEDYDATA:final}"} }}output {
	elasticsearch { 
		hosts => ["localhost:9200"] 
	 }}

sample of my log file is:

2018-01-30_09:36:56.149 - 119263 [http-apr-8080-exec-8] INFO  timeBased - validatepublisherLoggedinUser : DB Connection Established

I'm getting this error message:

[2018-06-22T13:29:23,090][FATAL][logstash.runner ] An unexpected error occurred! {:error=>#<NoMethodError: undefined method<' for nil:NilClass>, :backtrace=>["/home/automaton/logtesting/logstash-6.1.0/vendor/bundle/jruby/2.3.0/gems/logstash-output-elasticsearch-9.0.2-java/lib/logstash/outputs/elasticsearch/common.rb:213:in get_event_type'", "/home/automaton/logtesting/logstash-6.1.0/vendor/bundle/jruby/2.3.0/gems/logstash-output-elasticsearch-9.0.2-java/lib/logstash/outputs/elasticsearch/common.rb:165:inevent_action_params'", "/home/automaton/logtesting/logstash-6.1.0/vendor/bundle/jruby/2.3.0/gems/logstash-output-elasticsearch-9.0.2-java/lib/logstash/outputs/elasticsearch/common.rb:39:in event_action_tuple'", "/home/automaton/logtesting/logstash-6.1.0/vendor/bundle/jruby/2.3.0/gems/logstash-output-elasticsearch-9.0.2-java/lib/logstash/outputs/elasticsearch/common.rb:34:inblock in multi_receive'", "org/jruby/RubyArray.java:2486:in map'", "/home/automaton/logtesting/logstash-6.1.0/vendor/bundle/jruby/2.3.0/gems/logstash-output-elasticsearch-9.0.2-java/lib/logstash/outputs/elasticsearch/common.rb:34:inmulti_receive'", "/home/automaton/logtesting/logstash-6.1.0/logstash-core/lib/logstash/output_delegator_strategies/shared.rb:13:in multi_receive'", "/home/automaton/logtesting/logstash-6.1.0/logstash-core/lib/logstash/output_delegator.rb:50:inmulti_receive'", "/home/automaton/logtesting/logstash-6.1.0/logstash-core/lib/logstash/pipeline.rb:487:in block in output_batch'", "org/jruby/RubyHash.java:1343:ineach'", "/home/automaton/logtesting/logstash-6.1.0/logstash-core/lib/logstash/pipeline.rb:486:in output_batch'", "/home/automaton/logtesting/logstash-6.1.0/logstash-core/lib/logstash/pipeline.rb:438:inworker_loop'", "/home/automaton/logtesting/logstash-6.1.0/logstash-core/lib/logstash/pipeline.rb:393:in block in start_workers'"]}

I think this is some kind of configuration issue . Can someone help me how to solve this problem?

I had given the wrong port number for elastic search in the config file.Changed it to solve
the problem

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