Skip to content

Instantly share code, notes, and snippets.

@gambrell
Created March 19, 2015 13:47
Show Gist options
  • Save gambrell/98cc955fb9cf889a54aa to your computer and use it in GitHub Desktop.
Save gambrell/98cc955fb9cf889a54aa to your computer and use it in GitHub Desktop.
Logstash filter to remove embedded NULL characters
# Logstash filter to remove embedded NULL characters
filter {
mutate {
gsub => [
# Replace all NULL characters empty string. Do this to the message field first which will apply to all fields instead of specifying individual fields.
"message", "[\u0000]", ""
]
}
# Add your grok here
}
@dilllay
Copy link

dilllay commented Aug 17, 2019

Nice! Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment