Indexing logs in json format

(Daulet) #1

Hi guys! I am trying to index log in json format:

{"interests": "dota", "car": null, "surname": "Zhussipnazar", "name": "Daulet", "age": 20}

But it gives me error, _jsonparsefailure , because logstash cant handle value 'null'
How can I handle null value in json?

my config

file {
path => "/var/log/test.log"
sincedb_path => "/dev/null"
codec => "json"
filter {
json {
source => "message"
output {
stdout {
codec => rubydebug

(Magnus B├Ąck) #2

Is the null value really what trips up Logstash? What's the exact error message (use copy/paste)?

(Daulet) #3

sorry, the fail was on the new line after each log, thank for your reply

(system) #4

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.