Splunk Search

How to overlay two searches on the same chart in Splunk 6.1 or 6.2?

hlarimer
Communicator

I have 2 searches and would like to overlay them on the same chart. The first creates a stacked column chart:

index=av_log sourcetype=sophos_threat_events | dedup ComputerName FullFilePath | timechart count by ThreatType

The second creates a line graph:
index=av_log sourcetype=sophos_threat_events Status = Resolved | dedup ComputerName FullFilePath | timechart count

Any way to simply overlay these in Splunk 6.1 or 6.2?

Tags (2)
1 Solution

martin_mueller
SplunkTrust
SplunkTrust

Without the dedup I'd throw them into one simple search, with the dedup I'd fall back to pesky appendcols:

index=av_log sourcetype=sophos_threat_events | dedup ComputerName FullFilePath | timechart count by ThreatType
| appendcols
  [index=av_log sourcetype=sophos_threat_events Status = Resolved | dedup ComputerName FullFilePath | timechart count as Status_Resolved]

Set the line overlay to show the StatusResolved field.

View solution in original post

martin_mueller
SplunkTrust
SplunkTrust

Without the dedup I'd throw them into one simple search, with the dedup I'd fall back to pesky appendcols:

index=av_log sourcetype=sophos_threat_events | dedup ComputerName FullFilePath | timechart count by ThreatType
| appendcols
  [index=av_log sourcetype=sophos_threat_events Status = Resolved | dedup ComputerName FullFilePath | timechart count as Status_Resolved]

Set the line overlay to show the StatusResolved field.

hlarimer
Communicator

Thanks Martin, I just had to add "search" after the first "[" and it worked great.

martin_mueller
SplunkTrust
SplunkTrust

Ooooops 😄

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 ...