elasticsearch - Cannot parse CSV file with Logstash -


i have issue importing csv file elasticsearch using logstash further processing in kibana.

this logstash config file:

input {     file {         path => ["/absolute_path_to_file/export.csv"]         start_position => beginning          ignore_older => 0          sincedb_path => "/dev/null"     } } #filter { #   csv { #       columns => [ #           "id", #           "cislo_smlouvy", #           "zdroj", #           "produkt", #           "sjednani", #           "datum_odeslani", #           "cas_odeslani", #           "pojistovna", #           "tarif", #           "pojistnik", #           "telefon", #           "predmet_pojisteni", #           "rz", #           "pocatek_pojisteni", #           "rocni_pojistne", #           "urgence", #           "stav" #       ] #       separator => ";" #       remove_field => ["message"] #   } #} output { #   elasticsearch { #       hosts => "localhost:9200" #       index => "smlouvy" #   }     stdout {         codec => rubydebug     } } 

and excerpt csv file:

"id";"číslo smlouvy";"zdroj";"produkt";"sjednání";"datum odeslaní";"čas odeslání";"pojišťovna";"tarif";"pojistník";"pojistnik telefon";"předmět pojištění";"rz";"počátek";"roční pojistné";"urgence";"stav" "114951";"6132681255";"sro";"pov";;"1.6.2016";"12:28";"csob";"csob-2";"bb test";"721666333";"Škoda favorit";"nenÍ";"2.6.2016 00:00";"4657,00";;"test" "114950";;"pov";"pov";"vo bukvicova";"1.6.2016";"12:16";"csob";"csob-2";"bb bb";"721000111";"bmw x3";"nenÍ";"3.6.2016 00:00";"5550,00";;"test" 

i calling command:
sudo logstash -f /absolute_path_to_file/logstash.conf --vebrose

with following output:

starting agent {:level=>:info} starting pipeline {:id=>"main", :level=>:info} settings: default pipeline workers: 2 registering file input {:path=>["/absolute_path_to_file/export.csv"], :level=>:info} starting pipeline {:id=>"main", :pipeline_workers=>2, :batch_size=>125, :batch_delay=>5, :max_inflight=>250, :level=>:info} pipeline main started 

after while of doing nothing, shut down:

^csigint received. shutting down agent. {:level=>:warn} stopping pipeline {:id=>"main"} closing inputs {:level=>:info} closed inputs {:level=>:info} input plugins stopped! shutdown filter/output workers. {:level=>:info} pipeline main has been shutdown 

possibly relevant version info:

logstash 2.3.2 logstash-input-file (2.2.5) logstash-filter-csv (2.1.3) logstash-output-elasticsearch (2.6.2) logstash-output-stdout (2.0.6) logstash-codec-rubydebug (2.0.7) 

i have read documentation find , tried replicate lot of logstash.conf examples github, no luck. missing?

so found out problem. input csv file.

the csv file had \r new line , logstash default \n.

btw: cannot set \r delimiter in logstash file input filter config, had convert csv file 1 \n


Popular posts from this blog

php - How should I create my API for mobile applications (Needs Authentication) -

5 Reasons to Blog Anonymously (and 5 Reasons Not To)

Google AdWords and AdSense - A Dynamic Small Business Marketing Duo