Hey,
I'm seeing a lot of issues with certain specific multiline log entries.
Here's a log entry:
D, [2015-10-07T16:11:53.434110 #20457] DEBUG -- : Error occurred while parsing request parameters.
Contents:
{
"payload": {
"is_ingetrokken": true,
}
}
These loglines are forwarded via Logstash-Forwarder to Logstash where this multiline filter should, well, squash the multilines
multiline {
pattern => "^[DFEWI],\s"
negate => true
what => "previous"
}
When I go and look, this is what get's put in to ES:
{
"_index": "logstash-2015.10.07",
"_type": "coosy",
"_id": "AVBCsK05GGU6JV8bpMNR",
"_score": null,
"_source": {
"message": [
"Error occurred while parsing request parameters.\nContents:\n\n{"
],
"tags": [
"multiline",
"other"
],
"@version": "1",
"@timestamp": "2015-10-07T14:11:53.434Z",
"file": "/logs/coosy/production.log",
"host": "482a4b207db0",
"offset": [
"488372224",
"488372323",
"488372333",
"488372334"
],
"type": "coosy",
"deployment": "production",
"pid": 20457,
"loglevel": "DEBUG"
},
"fields": {
"@timestamp": [
1444227113434
]
},
"sort": [
1444227113434
]
}
As you can see, half of the multiline message does not get added to ES. Futhermore, when this happens, Logstash will generally hang and I have to reboot it (and Logstash Forwarder) to get back on track - at least untill the next occurence of such a log entry.
{:timestamp=>"2015-10-08T09:42:29.569000+0200", message=>"Lumberjack input: unhandled exception", :exception=>#<IndexError: string not matched>, :backtrace=>["org/jruby/RubyString.java:3912:in `[]='", "/opt/logstash/vendor/bundle/jruby/1.9/gems/logstash-core-1.5.4-java/lib/logstash/event.rb:73:in `initialize'", "/opt/logstash/vendor/bundle/jruby/1.9/gems/logstash-codec-json-1.0.1/lib/logstash/codecs/json.rb:46:in `decode'", "/opt/logstash/vendor/bundle/jruby/1.9/gems/logstash-input-lumberjack-1.0.5/lib/logstash/inputs/lumberjack.rb:77:in `run'", "org/jruby/RubyProc.java:271:in `call'", "/opt/logstash/vendor/bundle/jruby/1.9/gems/logstash-input-lumberjack-1.0.5/lib/logstash/inputs/lumberjack.rb:105:in `invoke'", "org/jruby/RubyProc.java:271:in `call'", "/opt/logstash/vendor/bundle/jruby/1.9/gems/jls-lumberjack-0.0.24/lib/lumberjack/server.rb:264:in `data'", "/opt/logstash/vendor/bundle/jruby/1.9/gems/jls-lumberjack-0.0.24/lib/lumberjack/server.rb:246:in `read_socket'", "/opt/logstash/vendor/bundle/jruby/1.9/gems/jls-lumberjack-0.0.24/lib/lumberjack/server.rb:190:in `data_field_value'", "/opt/logstash/vendor/bundle/jruby/1.9/gems/jls-lumberjack-0.0.24/lib/lumberjack/server.rb:101:in `feed'", "/opt/logstash/vendor/bundle/jruby/1.9/gems/jls-lumberjack-0.0.24/lib/lumberjack/server.rb:206:in `compressed_payload'", "/opt/logstash/vendor/bundle/jruby/1.9/gems/jls-lumberjack-0.0.24/lib/lumberjack/server.rb:101:in `feed'", "/opt/logstash/vendor/bundle/jruby/1.9/gems/jls-lumberjack-0.0.24/lib/lumberjack/server.rb:239:in `read_socket'", "/opt/logstash/vendor/bundle/jruby/1.9/gems/jls-lumberjack-0.0.24/lib/lumberjack/server.rb:224:in `run'", "/opt/logstash/vendor/bundle/jruby/1.9/gems/logstash-input-lumberjack-1.0.5/lib/logstash/inputs/lumberjack.rb:104:in `invoke'", "org/jruby/RubyProc.java:271:in `call'", "/opt/logstash/vendor/bundle/jruby/1.9/gems/concurrent-ruby-0.9.1-java/lib/concurrent/executor/executor_service.rb:515:in `run'", "Concurrent$$JavaExecutorService$$Job_1581672782.gen:13:in `run'"], :level=>:error}
Any ideas? Need more info?
Thank you for your help!
Jeroen