Splunk Search

Find repeating rows from a specific client

jensolsson83
Engager

I am logging from Amazon ELB and I have some particular clients that seem to have a bug that causes them to flood the server with the same request over and over. Usually the server receive around 1000 requests during 1-2 seconds then it will stop. This happens around once a week. I would like to locate all these instances and put them in a table. In Splunk I have the following parameters available that I would like to group on:
deviceGuid
I would like to have a list showing the following each time count > 100:
DateTime, deviceGuid, deviceBrand, deviceModel, count

For example this would be perfect if I can achieve:

2016-01-01 00:00:00,d9244663-9ac8-48ce-b125-35b553e39c9a,IBM,ThinkPad 200,900
2016-01-01 00:05:00,d9244663-9ac8-48ce-b125-35b553e39c9a,IBM,ThinkPad 200,800
2016-01-01 00:05:00,2e718d56-91bf-401c-a305-79bc638ac705,IBM,ThinkPad 500,900

I would like DateTime of the span together deviceGuid to be unique on each row

This is what I have so far
host=cloudserver ClientConfig | timechart span=5sec count | where count > 100

Is this doable?

0 Karma
1 Solution

sundareshr
Legend

Try this

host=cloudserver ClientConfig | bin span=5s _time | eventstats count by ClientConfig _time | where count>100 | table _time deviceGuid, deviceBrand, deviceModel, count

View solution in original post

sundareshr
Legend

Try this

host=cloudserver ClientConfig | bin span=5s _time | eventstats count by ClientConfig _time | where count>100 | table _time deviceGuid, deviceBrand, deviceModel, count

jensolsson83
Engager

host=cloudserver ClientConfig | bin span=5s _time | eventstats count by ClientConfig _time | where count>100 | table _time deviceGuid, deviceBrand, deviceModel, count

Did not generate any results

I changed it like this:
host=cloudserver ClientConfig | bin span=5s _time | eventstats count by deviceGuid _time | where count>100 | table _time deviceGuid, deviceBrand, deviceModel, count

And now the list colums show as expected however there are many 100% equal rows with the exact same time, deviceguid. devicemodel, count.

0 Karma

jensolsson83
Engager

This actually seem to made it. Is this correct?

host=cloudserver ClientConfig | bin span=5s _time | eventstats count by deviceGuid _time | where count>100 | table _time deviceGuid, deviceBrand, deviceModel, count | dedup _time deviceGuid, deviceBrand, deviceModel, count

0 Karma

sundareshr
Legend

I guess I mis-understood you question. I thought you wanted to see all the repeating events, sounds like you want to only see one of the repeating events, right?. Your change should work, or you can try this change.

host=cloudserver ClientConfig | bin span=5s _time | eventstats count by deviceGuid _time | where count>100 | stats count by _time deviceGuid, deviceBrand, deviceModel
0 Karma

jensolsson83
Engager

Thanks! works perfectly

0 Karma
Got questions? Get answers!

Join the Splunk Community Slack to learn, troubleshoot, and make connections with fellow Splunk practitioners in real time!

Meet up IRL or virtually!

Join Splunk User Groups to connect and learn in-person by region or remotely by topic or industry.

Get Updates on the Splunk Community!

Why Splunk Customers Should Attend Cisco Live 2026 Las Vegas

Why Splunk Customers Should Attend Cisco Live 2026 Las Vegas     Cisco Live 2026 is almost here, and this ...

What Is the Name of the USB Key Inserted by Bob Smith? (BOTS Hint, Not the Answer)

Hello Splunkers,   So you searched, “what is the name of the usb key inserted by bob smith?”  Not gonna lie… ...

Automating Threat Operations and Threat Hunting with Recorded Future

    Automating Threat Operations and Threat Hunting with Recorded Future June 29, 2026 | Register   Is your ...