Splunk Search

splunk discard specific events

pdash
Path Finder
{[-] EventInfo : {[+]}, EventType : "INFO", Properties : {[+]}, TimeStamp : "2014-01-03T19:31:30.3319998Z" }

How do i discard events that have EventType = INFO?

Currently my transforms and props are:

(transforms)

[treessvcignore] 
REGEX = \"EventType\"\:\"INFO\" 
DEST_KEY = queue 
FORMAT = nullQueue

(props)

[host::TREESSVC*] 
TRANSFORMS-null = treessvcignore

This data is in json format

The raw data looks like this
The raw event is

{"EventType":"INFO","TimeStamp":"2014-01-03T06:59:59.9645694Z","Properties":{"StackId":"PER_RNK","applicationClass":"CollatorApplication","name":"PersonRank","type":"Collator","serverClassType":"Live","serverClassApplication":"Multi","ComponentId":"PersonRank","ClientId":"Unknown","ClassName":"CollatorHandlers","MethodName":"Query","ClientPath":"Unknown","RequestPath":"a61a2538-9ef6-4c2c-8579-0d6e073c4159","Metric":...
Tags (2)

lguinn2
Legend

dwaddle 's answer is great, but I think I see some typos in your REGEX, based on the sample event. I would do it this way

REGEX = "EventType"\s*:\s*"INFO" 

ah - I didn't see the quotes at first in the raw data.

0 Karma

pdash
Path Finder

Doesnot work either. It still shows up newly indexed data that have info in eventtype

0 Karma

dwaddle
SplunkTrust
SplunkTrust

I tested your configuation on my test system with your example event, and it seems to have filtered the event just fine. So I believe your configuration is (fundamentally) correct. Some questions:

  1. Where is this configuration defined? On a forwarder, or the indexer? With Light or Universal forwarders, this configuration needs to be installed at the indexer. If there is a heavy forwarder in your environment, it needs to be at the first heavy forwarder that will touch the event.
  2. Have you restarted Splunk since applying this change?
  3. Are these configs in an app or in the $SPLUNK_HOME/etc/system/local directory?
  4. Have you checked with the btool command to make sure your config is not being overridden by some other app? ( http://blogs.splunk.com/2012/10/02/tips-and-tricks-for-the-new-guy/ )

pdash
Path Finder

Thanks. So its on indexer not on forwarder. And within splunkhome/etc/system/local dir. Also i restarted to make the changes effective

0 Karma
Get Updates on the Splunk Community!

Stay Connected: Your Guide to May Tech Talks, Office Hours, and Webinars!

Take a look below to explore our upcoming Community Office Hours, Tech Talks, and Webinars this month. This ...

They're back! Join the SplunkTrust and MVP at .conf24

With our highly anticipated annual conference, .conf, comes the fez-wearers you can trust! The SplunkTrust, as ...

Enterprise Security Content Update (ESCU) | New Releases

Last month, the Splunk Threat Research Team had two releases of new security content via the Enterprise ...