Reporting

do not show in report if one column = 0

jpburnison
New Member

Hello my friends,

I'm new to splunk and still trying to figure out the ins and outs of everything. I have a report that's been handed down to me that I'm trying to improve on it's timing. The report runs at 3 AM EST every day, but sends out at 8 PM that night. I suspect this has to do with the amount of data the report is trying to collect and then display. To fix that, I want to trim down how much data we are building, but I don't know if it will actually help.

What we are currently showing is how many times each of our 320 dispensers are dispensing, how many of each error they are getting, the error rate, and their total # of errors. What I am thinking of doing is focusing on the total # of errors. Specifically, if a dispenser returns 0 errors, it's not in the report. Currently, the TotalErrors column is evaluated like this :

| eval TotalError=(Error1+Error2+Error3)

My thoughts are to evaluate against TotalError and if the # of errors = 0, not to display that dispenser.

Labels (1)
0 Karma

richgalloway
SplunkTrust
SplunkTrust

Removing dispensers with no errors should help, but how much it helps depends on how much work is done beforehand.  If the filtering is late in the query then there is less benefit.

For maximum benefit, filter as early as possible.  For example,

index=foo (Error1>0 OR Error2>0 OR Error3>0)

Another way to improve performance is to be as specific as possible in the base query.  Always include the index name, but also include the sourcetype(s), host, and source where possible.  Avoid wildcards, especially leading wildcards.

Use the fields command to remove any fields you don't need.  This will reduce the amount of data Splunk is moving around and help speed things up.

Use centralized-distributable commands as late in the query as possible.  A centralized-distributable command sends the query back to the SH where it is processed by a single CPU rather than by multiple CPUs (one on each indexer).  A good example is table vs fields.  These commands are similar, but table is not distributable whereas fields is.

Consult the Job Inspector to see where the query is spending its time.  Focus on the most expensive operations first.

---
If this reply helps you, Karma would be appreciated.
0 Karma
Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.

Can’t make it to .conf25? Join us online!

Get Updates on the Splunk Community!

Take Action Automatically on Splunk Alerts with Red Hat Ansible Automation Platform

 Are you ready to revolutionize your IT operations? As digital transformation accelerates, the demand for ...

Calling All Security Pros: Ready to Race Through Boston?

Hey Splunkers, .conf25 is heading to Boston and we’re kicking things off with something bold, competitive, and ...

Beyond Detection: How Splunk and Cisco Integrated Security Platforms Transform ...

Financial services organizations face an impossible equation: maintain 99.9% uptime for mission-critical ...