Splunk Search

report only specific eventtypes

EricPartington
Communicator

I would like to report only on specific eventtypes.

I have a search that returns the eventtypes that i want to chart vs. each other (firewall-accept vs firewall-deny). But I also have a number of other eventtypes that apply to this data that also show up in this search (eventtype=cisco_firewall)

How can I only show the two eventtypes that I care about in the timechart (accept vs deny)

0 Karma
1 Solution

mw
Splunk Employee
Splunk Employee

Your search could either look something like:

(eventtype="firewall-accept" OR eventtype="firewall-deny") other search terms | timechart count by eventtype

or it could filter to the eventtypes

... | eval a=mvfilter(eventtype == "firewall-accept" or eventtype == "firewall-deny") | search a=* | timechart count by a

The first would probably be the cleanest way, if you're able to use either method.

View solution in original post

stollefsen
New Member

Neither 2 options worked for me in version 6.x.x. Interesting. I went back and disabled the one eventtype, I needed removed in my dashboard.

0 Karma

mw
Splunk Employee
Splunk Employee

Your search could either look something like:

(eventtype="firewall-accept" OR eventtype="firewall-deny") other search terms | timechart count by eventtype

or it could filter to the eventtypes

... | eval a=mvfilter(eventtype == "firewall-accept" or eventtype == "firewall-deny") | search a=* | timechart count by a

The first would probably be the cleanest way, if you're able to use either method.

mfscully
Explorer

Second option solved my problem as well! Thanks!

0 Karma

klaurean
Engager

I had this same problem and the second option was perfect. Thank you!

0 Karma

EricPartington
Communicator

The second query works like a charm, thanks

0 Karma
Get Updates on the Splunk Community!

ICYMI - Check out the latest releases of Splunk Edge Processor

Splunk is pleased to announce the latest enhancements to Splunk Edge Processor.  HEC Receiver authorization ...

Introducing the 2024 SplunkTrust!

Hello, Splunk Community! We are beyond thrilled to announce our newest group of SplunkTrust members!  The ...

Introducing the 2024 Splunk MVPs!

We are excited to announce the 2024 cohort of the Splunk MVP program. Splunk MVPs are passionate members of ...