Config not parsed?
wols opened this issue · 1 comments
wols commented
- Version: logstash-output-csv-3.0.2; logstash-5.1.1
- Operating System: Gentto Linux
- Config File:
input {
file {
path => [ "/tmp/logstash-test.txt" ]
type => "test"
}
}
filter {}
output {
if [type] == "test" {
file {
path => "/tmp/logstash-test.json"
}
csv {
path => "/tmp/logstash-test.csv"
fields => [ "host", "path" ]
csv_options => { "col_sep" => ":" "row_sep" => "\n"}
}
}
}
- Sample Data:
/tmp/logstash-test.txt
091502 001 002 003
091517 001 002 003
/tmp/logstash-test.json
{"path":"/tmp/logstash-test.txt","@timestamp":"2017-02-03T09:15:03.119Z","@version":"1","host":"localhost","message":"091502 001 002 003","type":"test","tags":[]}
{"path":"/tmp/logstash-test.txt","@timestamp":"2017-02-03T09:15:18.130Z","@version":"1","host":"localhost","message":"091517 001 002 003","type":"test","tags":[]}
/tmp/logstash-test.csv
2017-02-03T09:15:03.119Z localhost 091502 001 002 0032017-02-03T09:15:18.130Z localhost 091517 001 002 003
- Steps to Reproduce:
echo "$(date -u +%H%M%S) 001 002 003" >> /tmp/logstash-test.txt
- Missing:
Expected fields "host" and "path" separated by ":" followed by newline :-(
localhost:/tmp/logstash-test.txt
localhost:/tmp/logstash-test.txt