Splunk Search

Top by a value inside the query

timbCFCA
Path Finder

Within each record in a query I have two fields, c_ip and cs_bytes which is numeric. How can I get the top 10 c_ip values for the highest sum total of the cs_bytes field? The direction I've tried is a stats sum(cs_bytes) by c_ip.

Tags (1)
1 Solution

Stephen_Sorkin
Splunk Employee
Splunk Employee

You can search:

... | stats sum(cs_bytes) as bytes by c_ip | sort - bytes | head 10

View solution in original post

Stephen_Sorkin
Splunk Employee
Splunk Employee

You can search:

... | stats sum(cs_bytes) as bytes by c_ip | sort - bytes | head 10
Get Updates on the Splunk Community!

Reduce and Transform Your Firewall Data with Splunk Data Management

Managing high-volume firewall data has always been a challenge. Noisy events and verbose traffic logs often ...

Automatic Discovery Part 1: What is Automatic Discovery in Splunk Observability Cloud ...

If you’ve ever deployed a new database cluster, spun up a caching layer, or added a load balancer, you know it ...

Real-Time Fraud Detection: How Splunk Dashboards Protect Financial Institutions

Financial fraud isn't slowing down. If anything, it's getting more sophisticated. Account takeovers, credit ...