I use the following conf file to import data from elasticsearch to csv using logstash...
input {
elasticsearch {
hosts => "localhost:9200"
index => "croma"
query => '
{"query":
{
"match_phrase" : {
"search_data.full_text_boosted": "laptop bag "
}
}
}'
}
}
output {
csv {
fields => ["full_text_boosted","scores"]
path => "/root/sam/csv-export.csv"
}
}
I also installed following logstash plugin...
logstash-input-elasticsearch
logstash-output-csv
But it giving the following error...
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
Any body can tell me where I am wrong?
Thanks