Splunk Search

Count the number of events in between a recurring event

myli12
Path Finder

I have an event "trans" occurs from time to time, I want to be able to count the number of another type of events (say "down") occur in between this recurring event "trans".

What I tried is

link OR down | transaction endswith="trans" | stats count

Which actually gives me counts of transactions, rather than number of "down" events in between "trans" events.

Tags (1)
0 Karma
1 Solution

David
Splunk Employee
Splunk Employee

The transaction command adds the eventcount field. I'd try:

link OR down | transaction endswith="trans" | stats avg(eventcount)

Or if you like:

link OR down | transaction endswith="trans" | table _time duration eventcount

View solution in original post

0 Karma

David
Splunk Employee
Splunk Employee

The transaction command adds the eventcount field. I'd try:

link OR down | transaction endswith="trans" | stats avg(eventcount)

Or if you like:

link OR down | transaction endswith="trans" | table _time duration eventcount
0 Karma
Get Updates on the Splunk Community!

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 ...

.conf24 | Personalize your .conf experience with Learning Paths!

Personalize your .conf24 Experience Learning paths allow you to level up your skill sets and dive deeper ...