Data from CSV is not inserting to Elastic search using Logstash

Data is not Inserting to Elastic search using LogStash

Config

input {
file {
path => ["C:\PR Files\Test\Account1.csv"]
start_position => "beginning"
sincedb_path => "nul"
}
}
filter {
csv {
separator => "|"
columns => ["RPT_ID","CAND_ID"]
}
}

output {

elasticsearch { 
hosts => ["localhost:9200"]
index => "qwer"
}
stdout { }
}

Data in CSV

RPT_ID|CAND_ID
QWER123|450564

Logs

[2019-09-19T15:47:09,566][WARN ][logstash.config.source.multilocal] Ignoring the 'pipelines.yml' file because modules or command line options are specified
[2019-09-19T15:47:09,584][INFO ][logstash.runner          ] Starting Logstash {"logstash.version"=>"7.3.2"}
[2019-09-19T15:47:10,885][INFO ][org.reflections.Reflections] Reflections took 28 ms to scan 1 urls, producing 19 keys and 39 values 
[2019-09-19T15:47:12,849][INFO ][logstash.outputs.elasticsearch] Elasticsearch pool URLs updated {:changes=>{:removed=>[], :added=>[http://localhost:9200/]}}
[2019-09-19T15:47:12,994][WARN ][logstash.outputs.elasticsearch] Restored connection to ES instance {:url=>"http://localhost:9200/"}
[2019-09-19T15:47:13,036][INFO ][logstash.outputs.elasticsearch] ES Output version determined {:es_version=>7}
[2019-09-19T15:47:13,039][WARN ][logstash.outputs.elasticsearch] Detected a 6.x and above cluster: the `type` event field won't be used to determine the document _type {:es_version=>7}
[2019-09-19T15:47:13,060][INFO ][logstash.outputs.elasticsearch] New Elasticsearch output {:class=>"LogStash::Outputs::ElasticSearch", :hosts=>["//localhost:9200"]}
[2019-09-19T15:47:13,116][INFO ][logstash.outputs.elasticsearch] Using default mapping template
[2019-09-19T15:47:13,170][INFO ][logstash.outputs.elasticsearch] Attempting to install template {:manage_template=>{"index_patterns"=>"logstash-*", "version"=>60001, "settings"=>{"index.refresh_interval"=>"5s", "number_of_shards"=>1}, "mappings"=>{"dynamic_templates"=>[{"message_field"=>{"path_match"=>"message", "match_mapping_type"=>"string", "mapping"=>{"type"=>"text", "norms"=>false}}}, {"string_fields"=>{"match"=>"*", "match_mapping_type"=>"string", "mapping"=>{"type"=>"text", "norms"=>false, "fields"=>{"keyword"=>{"type"=>"keyword", "ignore_above"=>256}}}}}], "properties"=>{"@timestamp"=>{"type"=>"date"}, "@version"=>{"type"=>"keyword"}, "geoip"=>{"dynamic"=>true, "properties"=>{"ip"=>{"type"=>"ip"}, "location"=>{"type"=>"geo_point"}, "latitude"=>{"type"=>"half_float"}, "longitude"=>{"type"=>"half_float"}}}}}}}
[2019-09-19T15:47:13,178][WARN ][org.logstash.instrument.metrics.gauge.LazyDelegatingGauge] A gauge metric of an unknown type (org.jruby.specialized.RubyArrayOneObject) has been create for key: cluster_uuids. This may result in invalid serialization.  It is recommended to log an issue to the responsible developer/development team.
[2019-09-19T15:47:13,192][INFO ][logstash.javapipeline    ] Starting pipeline {:pipeline_id=>"main", "pipeline.workers"=>4, "pipeline.batch.size"=>125, "pipeline.batch.delay"=>50, "pipeline.max_inflight"=>500, :thread=>"#<Thread:0x3c2bb460 run>"}
[2019-09-19T15:47:13,603][INFO ][logstash.javapipeline    ] Pipeline started {"pipeline.id"=>"main"}
[2019-09-19T15:47:13,685][INFO ][logstash.agent           ] Pipelines running {:count=>1, :running_pipelines=>[:main], :non_running_pipelines=>[]}
[2019-09-19T15:47:13,717][INFO ][filewatch.observingtail  ] START, creating Discoverer, Watch with file and sincedb collections
[2019-09-19T15:47:14,052][INFO ][logstash.agent           ] Successfully started Logstash API endpoint {:port=>9600}

Do not use backslash in the path option of a file input, use forward slash.

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