Splunk Search

Search based on field value occurances

jturnerrdba
New Member

I'm trying to define a search that would output only the events that are related to a value of a field that occur at least X number of times.

So for instance, If I have a field named "Username" and a list of 100 events that contain that field. For sake of argument we'll say that there are 10 users that would display as values for the field "username". Lets also say that I have 2 users, "Bob" and "Mike", that show up more than 10 times each. I want a search that would output all events that contained "Bob" and "Mike" as values of "Username" based off the fact that there are more than 10 events for those users.

Tags (3)
0 Karma
1 Solution

kristian_kolb
Ultra Champion

your base search here | eventstats count by Username | where count>10

Ought to work.

/Kristian

View solution in original post

0 Karma

kristian_kolb
Ultra Champion

your base search here | eventstats count by Username | where count>10

Ought to work.

/Kristian

0 Karma

jturnerrdba
New Member

That works perfectly, and much simpler than I thought it would be. Thanks very much.

0 Karma
Get Updates on the Splunk Community!

Detecting Remote Code Executions With the Splunk Threat Research Team

REGISTER NOWRemote code execution (RCE) vulnerabilities pose a significant risk to organizations. If ...

Observability | Use Synthetic Monitoring for Website Metadata Verification

If you are on Splunk Observability Cloud, you may already have Synthetic Monitoringin your observability ...

More Ways To Control Your Costs With Archived Metrics | Register for Tech Talk

Tuesday, May 14, 2024  |  11AM PT / 2PM ET Register to Attend Join us for this Tech Talk and learn how to ...