Splunk Search

How to edit my search to add a column with total count per source?

sicspunky
New Member

Hi All,

Cracking my head trying to get this to work.
Basically i need to add another column which will be "Count". Total count of all the hits per source to the URLs. Eg: Source A hits Google 10 times and Yahoo 12 times. So the url portion will show google & yahoo + a total count of 22.
alt text

Current search as below.

table src desc ResolvedDomain  |dedup ResolvedDomain src| mvcombine ResolvedDomain|rename src as Source |rename dst as "Dst IP"| rename desc as "Description" | rename ResolvedDomain as URL 

Can anyone point me in the right direction? what should i use?

Thanks
De

0 Karma

somesoni2
Revered Legend

Give this a try

base search| table src desc ResolvedDomain 
|stats count by src dst desc ResolvedDomain
| stats list(count) as count sum(count) as TotalCount list(ResolvedDomain) as URL by src dest desc
|rename src as Source dst as "Dst IP"  desc as "Description" 
0 Karma
Get Updates on the Splunk Community!

See just what you’ve been missing | Observability tracks at Splunk University

Looking to sharpen your observability skills so you can better understand how to collect and analyze data from ...

Weezer at .conf25? Say it ain’t so!

Hello Splunkers, The countdown to .conf25 is on-and we've just turned up the volume! We're thrilled to ...

How SC4S Makes Suricata Logs Ingestion Simple

Network security monitoring has become increasingly critical for organizations of all sizes. Splunk has ...