My simple config looks like this. I have created a dummy folder in my home directory and created some log files in it. My config file looks like this.
input{
file{
type => "dummylog"
path => [/home/rohit/dummy/*.log" ]
}
}
output{
elasticsearch{
embedded => true
}
}
Now after running logstash i am unable to see in any files in web ui of logstash. Those files have not fetched into elasticsearch. I am using an embedded elasticsearch so no need to run a separate process. Can anyone help me where i am committing mistake?
input {
file {
path => "/home/rohit/dummy/*.log"
type => "log"
}
}
filter {
if [type] == "log" {
grok {
pattern => "%{COMBINEDAPACHELOG}"
}
}
}
output {
elasticsearch { host => localhost } stdout { } }
}
to check for the pattern if correct run
$ bin/logstash agent -f httpd-shipper.conf --configtest
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With