Hello, i am very new to this, i guess this is a simple one, but i still need your help.
when running logstash i get the below configuration error:
[2019-04-23T22:27:14,022][ERROR][logstash.agent ] Failed to execute action {:action=>LogStash::PipelineAction::Create/pipeline_id:main, :exception=>"LogStash::ConfigurationError", :message=>"Expected one of #, => at line 22, column 10 (byte 433) after filter {\r\n grok {\r\n match => { "message" => "%{WORD:sevirity} %{WORD:server} %{GREEDYDATA:text}%{NUMBER:latency}" }\r\n\r\n mutate ", :backtrace=>["/usr/share/logstash/logstash-core/lib/logstash/compiler.rb:41:in compile_imperative'", "/usr/share/logstash/logstash-core/lib/logstash/compiler.rb:49:in
compile_graph'", "/usr/share/logstash/logstash-core/lib/logstash/compiler.rb:11:in block in compile_sources'", "org/jruby/RubyArray.java:2577:in
map'", "/usr/share/logstash/logstash-core/lib/logstash/compiler.rb:10:in compile_sources'", "org/logstash/execution/AbstractPipelineExt.java:151:in
initialize'", "/usr/share/logstash/logstash-core/lib/logstash/pipeline.rb:22:in initialize'", "/usr/share/logstash/logstash-core/lib/logstash/pipeline.rb:90:in
initialize'", "/usr/share/logstash/logstash-core/lib/logstash/pipeline_action/create.rb:43:in block in execute'", "/usr/share/logstash/logstash-core/lib/logstash/agent.rb:96:in
block in exclusive'", "org/jruby/ext/thread/Mutex.java:165:in synchronize'", "/usr/share/logstash/logstash-core/lib/logstash/agent.rb:96:in
exclusive'", "/usr/share/logstash/logstash-core/lib/logstash/pipeline_action/create.rb:39:in execute'", "/usr/share/logstash/logstash-core/lib/logstash/agent.rb:334:in
block in converge_state'"]}
[2019-04-23T22:27:15,891][INFO ][logstash.agent ] Successfully started Logstash API endpoint {:port=>9600}
And this is my config file:
input {
file {
path => "/var/log/apache.log"
start_position => "beginning"
}
}
filter {
grok {
match => { "message" => "%{WORD:sevirity} %{WORD:server} %{GREEDYDATA:text}%{NUMBER:latency}" }
mutate {
add_field => { "token" => "ulQScJxhoEUuCqEIeZhZwmbzuXGBrntQ" }
}
}
Output {
tcp {
host => "listener.logz.io"
port => 5050
codec => json_lines
}
I've been told this may be a spacing issue, but i am not sure
Thanks