Splunk Search

Help charting the total count on line chart?

tfitzgerald15
Explorer

Hey guys. So I need to display a dashboard panel with a single line, the total count of all hits from the Palo Altos that are either High or Critical. First, I pull out the criteria.

sourcetype="pan_threat" (severity="high" OR "critical")

Now, when I timechart that (timechart count by dst_ip), it throws a few lines at me. So far so good. However, when I do the following:

sourcetype="pan_threat" (severity="high" OR "critical") | timechart sum(count) by dst_ip

It throws me back 0 results. Using eval fails in an even more spectacular way.

sourcetype="pan_threat" (severity="high" OR "critical") | eval total=sum(count) | timechart total by dst_ip

Error in 'eval' command: The 'sum' function is unsupported or undefined.

I'll fully admit I'm confused. Logically, all I want it to do is add count per hour, and plot that number on the graph, moving onto the next one. If I can type it in one sentence here, it shouldn't be that hard to do. What am I missing?

0 Karma

lguinn2
Legend

Why not this?

sourcetype="pan_threat" (severity="high" OR "critical") | timechart span=1h count
0 Karma

tfitzgerald15
Explorer

I would have thought that would have just forced it to make them plot every hour instead of every day, giving harsher peaks and valleys to the 10 lines already on there.

Seems to have worked though!

0 Karma
Get Updates on the Splunk Community!

Index This | I am a number, but when you add ‘G’ to me, I go away. What number am I?

March 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with another ...

What’s New in Splunk App for PCI Compliance 5.3.1?

The Splunk App for PCI Compliance allows customers to extend the power of their existing Splunk solution with ...

Extending Observability Content to Splunk Cloud

Register to join us !   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to ...