Dear all,
I'm new on logstash, and I'm trying to parse this log with logstash:
2018-07-10T10:46:25+0200 coll_bddf [3] [0] [6] [24] [2] [5]
so, I've create the logstash configuration file below:
input {
file {
path => "/var/log/logstash/SOLR_LOGS/Solr_generate_1.log"
start_position => "beginning"
sincedb_path => "/dev/null"
}
}
filter {
grok {
match => { "message" => "%{TIMESTAMP_ISO8601:timestamp} %{USERNAME:collection-name} [%{INT:global_time}] [%{INT:num_docs}] [%{INT:creation_time}] [%{INT:commit_time}] [%{INT:search_time}] [%{INT:delete_time}]" }
overwrite => [“message”]
}
}
output {
elasticsearch{
hosts => ["192.168.186.120:9200"]
cluster => "elasticsearch"
protocol => "http"
index => "solrcollbddf-%{+YYYY.MM.dd}"
stdout { codec => rubydebug }
}
}
but, when I trying to run logstash, I receive this kind of error:
[2018-07-10T10:26:17,981][ERROR][logstash.agent ] Failed to execute action {:action=>LogStash::PipelineAction::Create/pipeline_id:main, :exception=>"LogStash::ConfigurationError", :message=>"Expected one of #, ", ', -, [, {, ] at line 12, column 15 (byte 393) after filter {\ngrok {\nmatch => { "message" => "%{TIMESTAMP_ISO8601:timestamp} %{USERNAME:collection-name} \[%{INT:global_time}\] \[%{INT:num_docs}\] \[%{INT:creation_time}\] \[%{INT:commit_time}\] \[%{INT:search_time}\] \[%{INT:delete_time}\]" }\noverwrite => [", :backtrace=>["/usr/share/logstash/logstash-core/lib/logstash/compiler.rb:42:in compile_imperative'", "/usr/share/logstash/logstash-core/lib/logstash/compiler.rb:50:in
compile_graph'", "/usr/share/logstash/logstash-core/lib/logstash/compiler.rb:12:in block in compile_sources'", "org/jruby/RubyArray.java:2486:in
map'", "/usr/share/logstash/logstash-core/lib/logstash/compiler.rb:11:in compile_sources'", "/usr/share/logstash/logstash-core/lib/logstash/pipeline.rb:49:in
initialize'", "/usr/share/logstash/logstash-core/lib/logstash/pipeline.rb:167:in initialize'", "/usr/share/logstash/logstash-core/lib/logstash/pipeline_action/create.rb:40:in
execute'", "/usr/share/logstash/logstash-core/lib/logstash/agent.rb:305:in `block in converge_state'"]}
[2018-07-10T10:26:18,519][INFO ][logstash.agent ] Successfully started Logstash API endpoint {:port=>9600}
Could you Help me to resolve this issue?
Many Thanks for your help
Kind regards